microsoft / onefuzz

A self-hosted Fuzzing-As-A-Service platform
MIT License
2.82k stars 198 forks source link

Not terminating process on timeout in Windows for the coverage task #3513

Closed tevoinea closed 11 months ago

tevoinea commented 11 months ago

Information

Provide detailed reproduction steps (if any)

If this timeout case hits, we never terminate the child process. https://github.com/microsoft/onefuzz/blob/c7a982748e13cfd1d8bf2e39dd8b36ee28980e46/src/agent/coverage/src/record.rs#L128-L148

Expected result

What is the expected result of the above steps?

We should call quit_debugging from the Debugger module as well as kill and/or wait on the returned `Child.

https://github.com/microsoft/onefuzz/blob/c7a982748e13cfd1d8bf2e39dd8b36ee28980e46/src/agent/debugger/src/debugger.rs#L306 https://doc.rust-lang.org/std/process/struct.Child.html#method.kill https://doc.rust-lang.org/std/process/struct.Child.html#method.wait

AB#166281