Enet4 / nifti-rs

Rust implementation of the NIfTI-1 format
Apache License 2.0
41 stars 11 forks source link

Make code more robust to OOM attacks #57

Closed Enet4 closed 5 years ago

Enet4 commented 5 years ago

I found a few more edge cases through fuzzing (just in case, the fuzz project is currently in the fuzz branch). Not all cases of out-of-memory (OOM) attacks can be solved, but this will at least solve the trivial (yet very problematic) case of OOM by attempting to read a file which claims to have an extremely large size via dim.

Summary:

Enet4 commented 5 years ago

This looks good to go. @nilgoyette As usual, thank you for the review.