-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fuzz date is quickly identifying errors #3785
Comments
Cool that you are fuzzing it! |
I haven't tried to use real values from fuzzer because I have a problem even with static and almost empty input(since I didn't use uutils earlier I could done something wrong, so I want to fix or workaround this issue)
|
The offending function seems to be this: https://github.com/uutils/coreutils/blob/main/src/uucore/src/lib/lib.rs#L104 Which indeed intentionally leaks memory to create a |
@qarmin could you please suppress this leak and try again? I am curious :) |
I only tested date tool, because this it is tool with multiple options which is safe to use(not move any files etc.) - I was able to easily reproduce this issue in less than second of running fuzzer - #3780
Steps to reproduce
|
Very cool stuff. |
Good news! Using clap 4, I've been able to remove the leak. |
Nice, I didn't realize that it could be fixed by clap |
I originally wrote that function because I needed a string that lived as long as a |
With #4244 I was able to run the fuzzer for ~ 1hour without crashes. |
Closing this ticket because fuzzing of |
When I tried to use with this patch a fuzzer:
Then after first fuzzer(https://github.com/rust-fuzz/cargo-fuzz) run(with any value, since input is always same)
I got this memory leak;
I'm not sure if this is a problem with fuzzer or date
The text was updated successfully, but these errors were encountered: