Add diagnostic log message for compression bombs.
commitd9a6b37ab1597ac726e5f972ebfbccf024c58cbc
authorAlexander Færøy <ahf@torproject.org>
Wed, 13 Sep 2023 14:13:28 +0000 (13 16:13 +0200)
committerAlexander Færøy <ahf@torproject.org>
Wed, 13 Sep 2023 14:13:28 +0000 (13 16:13 +0200)
tree23b3f58f0e9762f2ff1f5a2f33b024dfba800490
parentd6c89b1ae1b18cc3cae42638d7bbe1edd7e35715
Add diagnostic log message for compression bombs.

This patch causes `tor_compress_is_compression_bomb()` to emit a
warning-level log message that lets us learn the potential ratio of the
input to output buffer sizes. Hopefully, this will give us a bit of a
better idea whether the compression bomb ratio needs some tuning.

See: tpo/core/tor#40739.
changes/ticket40739 [new file with mode: 0644]
src/lib/compress/compress.c
src/test/test_util.c