Re:What is the smallest possible valid PDF?
by bronson on Friday March 20, 2020 @12:53PM
(#22639089)
Allowing %PDF anywhere also leads to false positives.
https://github.com/minad/mimemagic/issues/4
https://github.com/minad/mimemagic/issues?q=is%3Aissue+is%3A...
If you want a fully covered example it'll need a trailer, xref and at least one obj reference. ...and there are TWO flavors of those (linearized and not). ...and flate coded and not.
So, for a test harness you'd actually want a collection of small files.