Skip to content

Zstd workspace poisoning doesn't unpoison before memory is freed #3714

@terrelln

Description

@terrelln

This causes issues when using a custom allocator that doesn't actually free() memory.

  1. Use a custom allocator
  2. Use the allocator for compression
  3. Compression poisons part of the memory
  4. Free that memory
  5. Re-use that custom allocator for decompression
  6. Decompression will run into use-after-poison issues

Workaround: define ZSTD_ASAN_DONT_POISON_WORKSPACE

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions