django/django — pull request #1473 by adamdeprince (2013-08-14 17:52:36+00:00)
Title: Ticket 20869

Make GzipMiddleware BREACH resistant by calling flush at a few randomly selected points when starting to compress a file to randomize its length. To prevent averaging attacks the random number generator is seeded by the hash of the data to compress, so while the same data sent twice will be compressed the same way, two different files will not be able to be meaningfully compared to one another.