Earlier quoted context omitted.
Next week on HN, C++ released! :)
Was thinking something simular... First time I discovered this I was a teenager still using dial-up. And apparently the virus-scanner on the school-pc's couldn't handle it :)
Zip Bomb
41–50 of 113 posts
Re: Zip Bomb
#42I found a similar file to this (a zip file that contains itself) and e-mailed it to a friend at work. He never received it, but I thought nothing of it (I assumed the email filters just destroyed it). A days later the mail server stops working and the sysadmin turns up at my desk. Turns out the anti-virus scanner had been unzipping and scanning repeatedly. It eventually filled up the entire disk and bad things happen…
>> ... eventually filled up the entire disk and bad things happened I can only imagine what would have happened. Can you share more details about that. Also, wonder how the mail servers these days are equipped to handle such attachments. Can someone throw light on that? Is it just plain simple to detect these files?
Re: Zip Bomb
#43I've seen something similar with a PNG file for user supplied profile image [1]. The image was a 10000x10000 all black PNG image which compresses to a pretty small file size. Unless you validate the image dimensions as well as the file size it may cause problems, for instance when GD is used to try to resize it exhausted the memory limit. [1] https://bugs.launchpad.net/mahara/+bug/784978
Re: Zip Bomb
#44Re: Zip Bomb
#45I found a similar file to this (a zip file that contains itself) and e-mailed it to a friend at work. He never received it, but I thought nothing of it (I assumed the email filters just destroyed it). A days later the mail server stops working and the sysadmin turns up at my desk. Turns out the anti-virus scanner had been unzipping and scanning repeatedly. It eventually filled up the entire disk and bad things happen…
>> ... eventually filled up the entire disk and bad things happened I can only imagine what would have happened. Can you share more details about that. Also, wonder how the mail servers these days are equipped to handle such attachments. Can someone throw light on that? Is it just plain simple to detect these files?
Re: Zip Bomb
#46Earlier quoted context omitted.
Maybe not at the transport or protocol level, but it wouldn't be too hard to DoS an application server that handles compressed data, such as images. Make a billion-pixel PNG image that compresses very well, upload several copies simultaneously to a LAMP server running on an average Linode, and watch it run out of memory while trying to create thumbnails with GD.
PHP usually has a pretty reasonable memory limit set, so it would puke on itself pretty quickly. But I don't think you'd bring the site down.
Re: Zip Bomb
#47Earlier quoted context omitted.
>Old as fuck. So is algebra, and yet, every year millions of people learn it for the first time.
But they don't immediately rush out to tell the world the "News"
Re: Zip Bomb
#48Re: Zip Bomb
#49But examples like this happen in many forms, heck windows on some file types/sizes doing thumbnails has done wonderous things like exponentialy growing the swap file to a ever impending churned slowdown.
Even computers have mental farts.
Re: Zip Bomb
#50Earlier quoted context omitted.
>> ... eventually filled up the entire disk and bad things happened I can only imagine what would have happened. Can you share more details about that. Also, wonder how the mail servers these days are equipped to handle such attachments. Can someone throw light on that? Is it just plain simple to detect these files?
All of the email virus scanners I've used are aware of this sort of thing, and will have a maximum depth or maximum size for scanning within attachments. I don't think any of them try to "detect" them in any cleverer way.
Or are those scanners just rejecting files that are too large or deep?