Impact
Syft versions before v1.52.0 was sizing internal buffers, scan window sizes, and loop boundaries using header fields from scanned file artifacts. This could result in a small file triggering a large allocation leading to resource exhaustion rather than a recoverable panic.
This resource exhaustion could result in users of Syft scanning content that could cause Syft to crash instead of recovering from the error. By not exiting gracefully, Syft will not write output documents or clean up temporary files.
Patches
The patch has been released in v1.52.0
Syft now fails gracefully when encountering file artifacts with headers fields that would cause a large allocation.
Workarounds
There are no workarounds for this vulnerability in Syft. Users that find their temporary storage depleted can manually remove the temporary files.
References
Pull requests related to this fix:
- #5187 (compressed ELF section processing)
- #5195 (golang UPX binary processing)
- #5267 (.NET PE/ELF binary processing)
- #5291 (graalVM binary processing)
- #5292 (arch linux package processing)
- #5293 (debian package processing)
- #5294 (kernel module archive processing)
- #5298 (linter configuration to protect against regression)
Impact
Syft versions before v1.52.0 was sizing internal buffers, scan window sizes, and loop boundaries using header fields from scanned file artifacts. This could result in a small file triggering a large allocation leading to resource exhaustion rather than a recoverable panic.
This resource exhaustion could result in users of Syft scanning content that could cause Syft to crash instead of recovering from the error. By not exiting gracefully, Syft will not write output documents or clean up temporary files.
Patches
The patch has been released in v1.52.0
Syft now fails gracefully when encountering file artifacts with headers fields that would cause a large allocation.
Workarounds
There are no workarounds for this vulnerability in Syft. Users that find their temporary storage depleted can manually remove the temporary files.
References
Pull requests related to this fix: