
Research
Supply Chain Attack on Axios Pulls Malicious Dependency from npm
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.
A modular, Redis-backed rate limiting middleware for Express with pluggable strategies and exponential backoff.
Redis-backed rate limiter middleware for Express applications using token bucket algorithm.
npm install reflo
import express from 'express';
import { rateLimiter } from 'reflo';
const app = express();
app.use(rateLimiter({
timeWindowSeconds: 60,
requestCount: 100,
}));
app.listen(3000);
interface LimiterConfig {
timeWindowSeconds: number;
requestCount: number;
exceptions?: Array<{ route: string; count: number }>;
allowlist?: string[];
blocklist?: string[];
getIdentifier?: (req: Request) => string;
backoffStrategy?: (overuse: number) => number;
}
| Option | Type | Description |
|---|---|---|
timeWindowSeconds | number | Rate limit window in seconds |
requestCount | number | Maximum requests per window |
exceptions | Array<{route, count}> | Per-route limit overrides |
allowlist | string[] | Bypass rate limiting |
blocklist | string[] | Always blocked |
getIdentifier | (req) => string | User identification function |
backoffStrategy | (overuse) => number | Delay calculation function |
import { identifierStrategies } from 'reflo';
// By IP address
identifierStrategies.byIP()
// By header value
identifierStrategies.byHeader('x-api-key')
import { backoffStrategies } from 'reflo';
backoffStrategies.none() // No delay
backoffStrategies.fixed(500) // Fixed 500ms delay
backoffStrategies.linear(100, 5000) // Linear: 100ms * overuse, max 5s
backoffStrategies.exponential(200, 10000) // Exponential: 200ms * 2^overuse, max 10s
app.use(rateLimiter({
timeWindowSeconds: 60,
requestCount: 100,
exceptions: [
{ route: '/api/upload', count: 5 },
{ route: '/api/search', count: 500 },
],
}));
app.use(rateLimiter({
timeWindowSeconds: 60,
requestCount: 100,
allowlist: ['ip:127.0.0.1', 'hdr:x-api-key:admin-key'],
blocklist: ['ip:192.168.1.100'],
}));
const customIdentifier = (req) => `user:${req.user?.id || req.ip}`;
const customBackoff = (overuse) => Math.min(1000, 50 * Math.pow(overuse, 1.5));
app.use(rateLimiter({
timeWindowSeconds: 60,
requestCount: 100,
getIdentifier: customIdentifier,
backoffStrategy: customBackoff,
}));
REDIS_URL=redis://localhost:6379
REDIS_TLS=true # Enable TLS connection
X-RateLimit-Limit: Maximum requests allowedX-RateLimit-Remaining: Requests remaining in current windowMIT
FAQs
A modular, Redis-backed rate limiting middleware for Express with pluggable strategies and exponential backoff.
The npm package reflo receives a total of 0 weekly downloads. As such, reflo popularity was classified as not popular.
We found that reflo demonstrated a healthy version release cadence and project activity because the last version was released less than 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
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.

Research
Malicious versions of the Telnyx Python SDK on PyPI delivered credential-stealing malware via a multi-stage supply chain attack.

Security News
TeamPCP is partnering with ransomware group Vect to turn open source supply chain attacks on tools like Trivy and LiteLLM into large-scale ransomware operations.