Skip to content

Commit b7409d3

Browse files
committed
Disable chdir in execute fuzzers
We don't want the current working directory to change during fuzzing, as that breaks corpus access unless an absolute path is used. I'm not sure why this issue never came up before.
1 parent 831a2b3 commit b7409d3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sapi/fuzzer/fuzzer-sapi.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ const char HARDCODED_INI[] =
4747
"open_basedir=/tmp\n"
4848
"disable_functions=dl,mail,mb_send_mail"
4949
",shell_exec,exec,system,proc_open,popen,passthru,pcntl_exec"
50-
",chgrp,chmod,chown,copy,file_put_contents,lchgrp,lchown,link,mkdir"
50+
",chdir,chgrp,chmod,chown,copy,file_put_contents,lchgrp,lchown,link,mkdir"
5151
",move_uploaded_file,rename,rmdir,symlink,tempname,touch,unlink,fopen"
5252
/* Networking code likes to wait and wait. */
5353
",fsockopen,pfsockopen"

0 commit comments

Comments
 (0)