Build better.
Debug smarter.
Deep technical articles on APIs, security, debugging, and developer tooling.
✦ AI-powered — understands natural language
Why 0 0 1 * 1 Runs 63 Times a Year: The Cron OR Trap
Secure Randomness: Why Math.random() Fails for Security Tokens — and the Right Alternatives
Math.random() in JavaScript is predictable from 128 observations. Python's random module explicitly warns it's not for security. Here's why PRNGs fail for tokens, the secure alternatives in every major language, and the specific bit lengths needed for different security contexts.
API Authentication Methods Compared: Keys, Bearer Tokens, OAuth 2.0, and HMAC
API keys, Bearer tokens, Basic Auth, OAuth 2.0, and HMAC signatures each fit different authentication scenarios. Here's how each method works, when it's the right choice, and how to test each one in an API checker — with the specific header formats.
Bit Manipulation and Bitmasks: From Unix Permissions to Feature Flags
Bit manipulation is where number bases become practical: Unix permissions, feature flags, IP subnetting, and protocol fields all use bitmasks. Here's how AND, OR, XOR, and shifts work, with real examples from file permissions and flag systems.
Merkle Trees and Hash Functions: How Git, Blockchain, and Certificate Transparency Work
Hash functions underpin Git commits, blockchain blocks, and certificate transparency logs through Merkle trees. Here's why MD5 and SHA-1 are "broken," how Merkle trees verify large datasets with O(log n) hashes, and how Bitcoin light clients verify transactions without the full blockchain.
ReDoS: How Catastrophic Backtracking in a Single Regex Can Take Down a Server
A single regex with a crafted input knocked Stack Overflow offline for 34 minutes and caused a global Cloudflare outage. Here's how catastrophic backtracking works, which patterns are vulnerable, how to test for ReDoS, and how to write safe alternatives.
Why JSON Gets Double-Encoded — and How to Detect and Fix It
Double-encoded JSON — JSON strings where objects were expected — happens when serialisation runs twice at different layers. Here's how it happens, how to detect it, how to fix it programmatically, and what the common Unicode escape sequences mean.
ISO 8601 and Date Handling Mistakes: The Bugs That Surface Months Later
"06/07/2024" means different dates in the US and UK. ISO 8601 solves this unambiguously. Here's the standard, common date handling mistakes (adding months with timedelta, DST in date arithmetic), storing UTC in databases, and the MySQL 2038 timestamp problem.
Why bcrypt: The History of Password Hashing, Cost Factors, and When Argon2 Is Better
SHA-1 and MD5 are fast by design — which is why GPUs crack them in hours after a breach. bcrypt's deliberate slowness and automatic salting are its defence. Here's how bcrypt works, the 72-byte limit, choosing a cost factor, and when Argon2 is the better choice.
Password Managers: How Zero-Knowledge Encryption Works and Which One to Choose
Credential stuffing is the main threat, and unique passwords are the defence — but only a password manager makes that practical at scale. Here's how zero-knowledge encryption works, Bitwarden vs 1Password vs KeePass compared, and how to set up recovery.
URL Structure: Query String Parsing Ambiguities, Punycode, and Open Redirect Vulnerabilities
A URL has five components — and bugs come from confusing which part you're encoding. Here's query string parsing ambiguities between frameworks, IDN Punycode for international domains, URL normalisation for comparison, open redirect vulnerabilities, and relative URL resolution edge cases.
Data URLs and Base64: When to Embed Resources Inline vs Link to Them
Data URLs embed files directly in HTML and CSS as Base64 strings — no separate HTTP request. Here's when that's faster, when it makes things worse, how JWT tokens use Base64URL, and how inline images in emails work around image blocking.
Beyond UUID: How Twitter's Snowflake IDs, ULID, CUID2, and Nano ID Work
Twitter, Discord, and Instagram all built custom ID systems because UUID couldn't handle time-sortability, distributed generation, and 64-bit constraints simultaneously. Here's how Snowflake IDs work, what ULID and CUID2 offer, and when each alternative makes sense.