mirror of
https://github.com/AFLplusplus/AFLplusplus.git
synced 2025-06-13 10:38:07 +00:00
Merge pull request #1025 from f0rki/custom_mutator_havoc_uaf
fixed potential UAF with custom mutator havoc after realloc
This commit is contained in:
@ -2057,7 +2057,7 @@ havoc_stage:
|
|||||||
temp_len = new_len;
|
temp_len = new_len;
|
||||||
if (out_buf != custom_havoc_buf) {
|
if (out_buf != custom_havoc_buf) {
|
||||||
|
|
||||||
afl_realloc(AFL_BUF_PARAM(out), temp_len);
|
out_buf = afl_realloc(AFL_BUF_PARAM(out), temp_len);
|
||||||
if (unlikely(!afl->out_buf)) { PFATAL("alloc"); }
|
if (unlikely(!afl->out_buf)) { PFATAL("alloc"); }
|
||||||
memcpy(out_buf, custom_havoc_buf, temp_len);
|
memcpy(out_buf, custom_havoc_buf, temp_len);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user