Commit cc60441
committed
zephyr: alloc: Add 16MB allocation limit to native_sim host allocator
When building the native_sim fuzzer, the host allocator does not
possess the strict bounds of the internal Zephyr memory pools. If
the fuzzer generates a malformed payload requesting an excessively
large size (e.g. 4GB), it passes directly to the host ASAN allocator
which aborts due to OOM or protection limits. Adding a 16MB cap
allows these to fail gracefully.
Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>1 parent bab5d00 commit cc60441
1 file changed
Lines changed: 5 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
466 | 466 | | |
467 | 467 | | |
468 | 468 | | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
| 473 | + | |
469 | 474 | | |
470 | 475 | | |
471 | 476 | | |
| |||
0 commit comments