Security context

What an agent needs to avoid regressing past fixes and find the next vuln in this repo.

python-pillow/pillow
main @ 6a8de89
21
Fixes
50
CVEs
CRITICAL
Peak severity
45.0%
Coverage
Highlights
Denial of Service: 7 prior fixes. Scrutinize any change in this area.
src/PIL/ImageShow.py: most-fixed (3 issues). Treat as high-risk during review.
11 high-severity fixes in this history; regressions here are high-impact.
Recurring patterns

The bug types that recur here, drawn from past fixes, not open vulnerabilities.

Command Injection: Execution of external viewers via subprocess or shell execution can be subverted by malicious file names containing unescaped shell metacharacters or quotes.
Memory Corruption: The TIFF encoder handles raw bytes and pointers via Python C extensions, exposing it to type-confusion and use-after-free bugs when type checking or reference counting is mishandled.
Buffer Overflow: Improper validation of stride values against minimum row sizes during memory mapping can result in severe out-of-bounds memory access.