Articles in this topic
A 4 KB PNG can decode to 12 GB. Read dimensions from the header with Sharp metadata(), enforce a pixel budget, then decode behind limitInputPixels.
Read article →Detect spoofed uploads by reading magic bytes with libmagic in Node.js — a bounded-memory stream gate, a flag reference, and native-binding fixes.
Read article →