Yoz Grahame's Unresolvable Discrepancy

I came here to apologise and eat biscuits, and I'm all out of biscuits

Scary-cool: Decompression bombs

Posted: February 11th, 2004 | 1 Comment »

Most
of us are used to relatively consistent ratios for data compression.
The standard ZIP algorithm usually takes ASCII files down by a factor
of ten or so, uncompressed binary data by a factor of three, both of
those wobbling +/-50%. However, those are averages based on real-world
use; if you aim to create a sample dataset purely for a high ratio, you
can get 100:1 or better quite easily. Why? Well, if you ever played
around with BBSes on a 14.4k modem, you may have seen some quite cool
experiments that let you download a megabyte or so in a mere minute,
taking advantage of v.32′s run-length compression algorithms. (Of
course, you were getting a megabyte of meaningless data, most of which
was the same byte repeated over and over, but who cares? It was a
MEGABYTE! In a MINUTE!)

But what use is there for such tricks now? Decompression bombs, that’s what.

Here’s an example scenario: A mail arrives at your
super-barbed-wire-protected mail gateway. The gzip-compressed
attachment – only 7k big – is grabbed by the anti-virus scanner,
looking for any suspicious signatures. It starts to decompress it and
BANG – the resulting file, over 100 gigabytes, crashes the AV scanner and completely fills the hard drive partition in the process.

Fortunately, a good number of the AV scanners that AERAsec tested
aren’t too vulnerable, but some require patching. Similarly, sending a
gzipped-HTML bomb to a browser will crash a fair few of them. Not so
scary, then, but nifty in an admirably-nasty way.


One Comment on “Scary-cool: Decompression bombs”

  1. 1 becky said at 10:10 am on July 14th, 2005:

    i just wanted to say it sounds great and how do you make small little bombs that cant harm you that bad

Archive

The complete list of posts lives here.

yoz's bookmarks

  • Lee Maguire – WikiLeaks and the future Hydra
    Lee on the similarities between WikiLeaks and comic-book villainous organisations.
  • WebGL Inspector
    Lovely Firebug/Web Inspector-alike for WebGL, usable either as an extension (for the top WebGL-enabled browsers) or embedded JS. Under rapid development.
  • ge.tt
    Gorgeous hack: web-based file sharing service where the link to your file works while it's still uploading. Instant, super simple and free. (via DMM)
  • Async.js (Caolan McMahon)
    One of the many flow-control packages for Javascript, of which at least 3 are called async.js. This one has some really nice tricks, especially auto() which fires off function calls as soon as their dependencies are met.
  • Adequately Good - JavaScript Module Pattern: In-Depth
    Really good explanations of several useful function and module patterns to use when building your own
  • News flash: Deadly terrorism existed before 9/11 - Ask the Pilot - Salon.com
    The quantity of air-travel-targeting terrorist attacks between 1985 and 1989 would be unthinkable today; yet the presented danger and precautions taken are far worse
  • 100 Free High Quality WordPress Themes: 2010 Edition - Smashing Magazine
    Some really nice minimal ones here, along with good theme tools and a bunch of things that I didn't know WordPress could do
  • Lenore Skenazy: 'Stranger Danger' and the Decline of Halloween - WSJ.com
    Despite American parents' increasing paranoia, Halloween may be the safest day of the year for kids. (via schneier)
  • becoming the alien: apartheid, racism and district 9 « a subtle knife
    Superb essay on District 9's relevance. "It confronts us with our complicity with racism, by making us identify with the perspective of the racist, inviting us to feel the revulsion of the xenophobe – and then pulling the carpet from under our feet." (via kevin marks)
  • Music Hack Day: The Uninterrupter - Andrew Shearer's Other Blog
    "For an increasing number of us, the same device we use to play music also handles email and GPS directions." The presented solutions are as brilliant as they are ludicrous. (via extensionfm blog)

yoz on twitter

    follow me on Twitter

    Meta

    • Log in
    • Entries RSS
    • Comments RSS
    • WordPress.org

    Content licensed under the Creative Commons (Attribution - Share Alike) | Theme based on Clean Room by Columbia, MO Web Design