This does wonders when used in favicons :D
Biggest image in the smallest space
21–30 of 106 posts
Re: Biggest image in the smallest space
#22That's impressive. Here are some other compression curiosities. http://www.maximumcompression.com/compression_fun.php A 24 byte file that uncompresses to 5 MB; another file with good compression under RAR but almost no compression under ZIP; and a compressed file that decompresses to itself.
The file that decompresses to itself is a work of art. How does one even go about to create something like this?
Re: Biggest image in the smallest space
#23Is there a way to check for decompression bombs? I'd like my software to be able to unzip zip files safely.
Re: Biggest image in the smallest space
#24Is there a way to check for decompression bombs? I'd like my software to be able to unzip zip files safely.
Re: Biggest image in the smallest space
#25Is there a way to check for decompression bombs? I'd like my software to be able to unzip zip files safely.
Monitor zip files as they decompress. Halt decompression process if the size ratio between zip file and decompressed file exceeds a fixed ratio (for example, if ratio between the file sizes is something like 10:1).
Re: Biggest image in the smallest space
#26Re: Biggest image in the smallest space
#27Re: Biggest image in the smallest space
#28This does wonders when used in favicons :D
Re: Biggest image in the smallest space
#29Actually, it decompresses to a 5.8MB PNG. However, many graphics programs may choose to use three bytes per pixel when rendering the image and because it has incredibly large dimensions, this representation would take up 141GB of RAM.
Re: Biggest image in the smallest space
#30Actually, it decompresses to a 5.8MB PNG. However, many graphics programs may choose to use three bytes per pixel when rendering the image and because it has incredibly large dimensions, this representation would take up 141GB of RAM.
Now, go find an API/library for dealing with PNGs that allow you to pass in such a limit, let alone pass in a callback for dealing with violations. Go ahead. I'll wait.
(The Internet being what it is, if there is one, someone will pop up in a reply in five minutes citing it. If so, my compliments to the authors! But I think we can all agree that in general image APIs do not offer this control. In fact, in general, if you submit a patch to allow it, it would probably be rejected from most projects as unnecessarily complicating the API.)
This is the sort of thing that I mean when I say that we are so utterly buried by insecure coding practices that we can't hardly even perceive it around us. I should add this as another example in http://www.jerf.org/iri/post/2942 .