Security context

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

krzyzanowskim/cryptoswift
main @ f2a627b
28
Fixes
0
CVEs
HIGH
Peak severity
50.0%
Coverage
Highlights
Cryptographic Issues: 19 prior fixes. Scrutinize any change in this area.
CryptoSwift/CipherBlockMode.swift: most-fixed (5 issues). Treat as high-risk during review.
22 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.

Cryptographic Issues: The implementation failed to correctly validate authentication tags before releasing plaintext or during finalization, which fully compromises the authenticity guarantees of the AEAD mode. This occurred across both CCM and GCM decryptions.
Cryptographic Issues: Validation of the AES Initialization Vector (IV) length was incorrectly tied to the key size rather than the cipher block size, potentially leading to weakened cryptosystems or runtime errors.
Memory Corruption: An incorrect byte length calculation using type sizes inside UnsafeMutablePointer allocations could trigger out-of-bounds memory accesses during byte-array conversions.