
Research
GemStuffer Campaign Abuses RubyGems as Exfiltration Channel Targeting UK Local Government
GemStuffer abuses RubyGems as an exfiltration channel, packaging scraped UK council portal data into junk gems published from new accounts.
@trpc-rate-limiter/cloudflare
Advanced tools
@trpc-rate-limiter/cloudflareThis package includes WorkersKV and Durable Object store for the @trpc-rate-limiter.
# Using npm/yarn/pnpm/bun
npm add @trpc-rate-limiter/cloudflare
WorkersKVStore# wrangler.toml
[[kv_namespaces]]
binding = "CACHE"
id = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
For more info on setting up your WorkersKV you can check out Get Started Guide on cloudflare.
// index.ts
import { WorkersKVStore } from "@trpc-rate-limiter/cloudflare";
import { trpcRateLimiter } from "@trpc-rate-limiter/hono";
import { KVNamespace } from "cloudflare:worker";
// Add this in Hono app
type Bindings = {
CACHE: KVNamespace;
// ... other binding types
};
const app = new Hono<{ Bindings: Bindings }>();
const t = initTRPC.context<TRPCContext>().create();
// Apply the rate limiter to the tRPC middleware
const rateLimiterMiddleware = t.middleware(async ({ ctx, next }) => {
const { c } = ctx;
await trpcRateLimiter<AppRouter>({
config: {
"auth.signIn": {
windowMs: 5 * 60 * 1000,
limit: 5,
},
default: { windowMs: 60 * 1000, limit: 5 },
},
store: new WorkersKVStore({ namespace: c.env.CACHE }), // Here CACHE is your WorkersKV Binding.
})(c);
return next();
});
DurableObjectStore# wrangler.toml
[[durable_objects.bindings]]
name = "CACHE"
class_name = "DurableObjectRateLimiter"
[[migrations]]
tag = "v1" # Should be unique for each entry
new_classes = ["DurableObjectRateLimiter"]
For more info on setting up your Durable Objects you can check out Get Started Guide on cloudflare.
// index.ts
import { DurableObjectStore, DurableObjectRateLimiter } from "@trpc-rate-limiter/cloudflare";
import { trpcRateLimiter } from "@trpc-rate-limiter/hono";
import { Context, Next } from "hono";
import { DurableObjectNamespace } from "cloudflare:worker";
// Add this in Hono app
type Bindings = {
CACHE: DurableObjectNamespace<DurableObjectRateLimiter>;
// ... other binding types
};
const app = new Hono<{ Bindings: Bindings }>();
const t = initTRPC.context<TRPCContext>().create();
// Apply the rate limiter to the tRPC middleware
const rateLimiterMiddleware = t.middleware(async ({ ctx, next }) => {
const { c } = ctx;
await trpcRateLimiter<AppRouter>({
config: {
"auth.signIn": {
windowMs: 5 * 60 * 1000,
limit: 5,
},
default: { windowMs: 60 * 1000, limit: 5 },
},
store: new DurableObjectStore({ namespace: c.env.CACHE }), // Here CACHE is your Durable Object Binding.
})(c);
return next();
});
// Export DurableObjectRateLimiter in the index file of your Worker
export { DurableObjectRateLimiter };
export default app;
WorkersKVStore and DurableObjectStorenamespaceThe KV / Durable Object namespace to use. The value you set for <BINDING_NAME> will be used to reference this database / durable object in your Worker.
prefixThe text to prepend to the key in the KV / Durable Object namespace.
Defaults to hrl:.
The @trpc-rate-limiter/cloudflare is based on the @hono-rate-limiter/cloudflare store.
FAQs
Cloudflare stores for trpc-rate-limiter.
The npm package @trpc-rate-limiter/cloudflare receives a total of 6 weekly downloads. As such, @trpc-rate-limiter/cloudflare popularity was classified as not popular.
We found that @trpc-rate-limiter/cloudflare demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Research
GemStuffer abuses RubyGems as an exfiltration channel, packaging scraped UK council portal data into junk gems published from new accounts.

Company News
Socket was named to the Rising in Cyber 2026 list, recognizing 30 private cybersecurity startups selected by CISOs and security executives.

Research
Socket detected 84 compromised TanStack npm package artifacts modified with suspected CI credential-stealing malware.