Upload Torture Test Pack

One archive covering the whole upload validation checklist. Point your upload endpoint at it and work through the README: each file names the check it exercises and what a correct implementation does with it. Nothing here is malware, and nothing here needs a network connection to be dangerous, because none of it is dangerous. It is all inert data designed to be mishandled.

↓ Download upload-torture-pack.zip22 files · 1.0 MB zipped

SHA-256 ccdfb70856e375153309efea81762f6c4d680aae8237d6d2b51aba9a963d08fe

What is inside

FileFormatSizeExpected result
0b.binBinary0 bytesRejected: an empty file is not a valid upload.
1b.binBinary1 bytesAccepted. Proves the zero-byte rejection is not an off-by-one.
1mb.binBinary1.0 MBAccepted or rejected by your size cap, never buffered whole into memory.
spaces in name.txtTXT142 bytesStored under a generated name; the original kept only as a label.
report.pdf.exeTXT142 bytesRejected by the allow-list, matched on the real final extension.
CON.txtTXT142 bytesNever written to disk as CON on Windows.
trailing-dot.txt.TXT142 bytesTrailing dot stripped or the name rejected; Windows silently drops it.
invoice‮gnp.txtTXT142 bytesThe right-to-left override is stripped before the name is ever displayed.
日本語ファイル名.txtTXT142 bytesRound-trips unchanged, NFC-normalised.
percent%20encoded.txtTXT142 bytesNot double-decoded into a space.
fake-jpeg-is-executable.jpgJPEG (spoofed)2.1 KBRejected: the extension says JPEG, the bytes disagree.
no-extensionPNG (no extension)183 bytesIdentified as PNG from its signature, not from a missing extension.
svg-with-script.svgSVG457 bytesSanitised, rasterised, or served from a separate origin. Never inline.
polyglot-gif-html.gifGIF + HTML polyglot192 bytesServed with nosniff so it can only ever be treated as an image.
corrupt-missing-content-types.docxDOCX577 bytesRejected at parse time: a valid ZIP that is not a valid DOCX.
zip-slip-traversal.zipZIP357 bytesEntry refused. Nothing written outside the extraction directory.
absolute-path.zipZIP161 bytesEntry refused.
modest-zip-bomb.zipZIP996 KBExtraction aborted once the decompressed total passes your limit.
billion-laughs.xmlXML794 bytesRejected: entity expansion disabled.
xxe-file-disclosure.xmlXML141 bytesParsed with no file read attempted.
deeply-nested-100000.jsonJSON195 KBRejected at a depth limit rather than overflowing the stack.
formula-injection.csvCSV357 bytesStored as text. Cells beginning = + - @ escaped on export.
Also in the archive: a README.md repeating this table with full digests, a manifest.json for scripting, and a SHA256SUMS you can check with sha256sum -c. Every file is generated from source, carries no third-party copyright, and is free to redistribute.
The largest file here is 1 MB, deliberately: this pack is meant to be cheap to fetch in CI on every run. To exercise a real size cap, pull a specific size from https://hexaqa.com/size-ladder (up to 250 MB stored) or stream anything up to 2 GB from https://hexaqa.com/generator.

Questions

What is in the upload torture test pack?

Twenty-two files covering the whole upload validation checklist: a zero-byte file, a 10 MB file, seven filename edge cases, a spoofed JPEG, a PNG with no extension, an SVG carrying a script, a GIF that is also an HTML page, a corrupt DOCX, three hostile archives, two XML attacks, deeply nested JSON and a formula-injection CSV. The README in the archive says what each one should do.

Is this pack safe to download?

Yes. Nothing in it is malware and nothing executes on download. The files are inert data built to be mishandled by software that parses them carelessly. Extract it somewhere disposable anyway, because two of the archives inside are specifically designed to write outside their extraction directory if your extractor lets them.

How do I use it in CI?

The archive has a stable URL and a published SHA-256, so you can fetch and verify it in a pipeline step, then post each file to your upload endpoint and assert on the status code. The manifest.json inside lists every file with its digest and expected result.

Other packs

Filename Compatibility Pack · Encoding and Unicode Pack · Archive and ZIP Security Pack · Document Parser Pack · Image Pipeline Pack · Structured Data Pack · Email Parser Pack