3 ms·
I don't think 8MB is the smallest preset, the text you quoted says that the lower levels use "1 MB or less". The concern I have is that this makes it sound lik
by caf 10y ago
I don't think 8MB is the smallest preset, the text you quoted says that the lower levels use "1 MB or less".
The concern I have is that this makes it sound like the compressor can choose how much memory the decompressor will need to use. Does this mean that zstd can't be used in a potentially adversarial environment? (Eg. is there a denial-of-service vector here by forcing the server to use large amounts of memory to decompress my requests?)
- gliptic 10y agoIt will not use (much) more memory than the size of the output in any case. 8MB is the window here, which just means the decompressor can discard data that falls outside this 8MB window as it is decompressing.
- Cyan4973 10y agoThe decompressor can receive a parameter to refuse compressed frames requiring more than a selected amount of memory.