Skip to content
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: new target with different config options #9531

Closed
wants to merge 1 commit into from

Conversation

catenacyber
Copy link
Contributor

Link to redmine ticket:
https://redmine.openinfosecfoundation.org/issues/3591

Describe changes:

  • Adds a new fuzz target which takes config + signature + pcap as an entry

Draft : expecting feedback if this looks a good approach

Still to do :

  • ticket number in commit
  • think about this extract urls list
  • Make FuzzConfReload call more than SMTPConfigure

@codecov
Copy link

codecov bot commented Sep 28, 2023

Codecov Report

Merging #9531 (26ffe56) into master (af4bb91) will decrease coverage by 0.04%.
The diff coverage is 38.70%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #9531      +/-   ##
==========================================
- Coverage   82.19%   82.16%   -0.04%     
==========================================
  Files         968      968              
  Lines      274203   274231      +28     
==========================================
- Hits       225373   225310      -63     
- Misses      48830    48921      +91     
Flag Coverage Δ
fuzzcorpus 64.13% <38.70%> (+0.04%) ⬆️
suricata-verify 60.89% <100.00%> (-0.06%) ⬇️
unittests 62.88% <33.33%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

@catenacyber
Copy link
Contributor Author

cc @jasonish

@@ -500,6 +535,16 @@ int ConfGetBool(const char *name, int *val)
*/
int ConfGetChildValueBool(const ConfNode *base, const char *name, int *val)
{
#ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How will this work when all this is done in Rust? Hopefully in the 8.0 cycle.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, I was cc-ing you to ask you if it will be compatible with the conf+rust changes.

We can have #cfg[fuzz] or something like that (as a way to #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION)

But will still SMTP use ConfGetChildValueBool ? (just its implementation will be in rust)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But will still SMTP use ConfGetChildValueBool ? (just its implementation will be in rust)

For the most part. Rust code should be able to use serde to convert raw config to a struct, but that won't work so well for the C.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So, should I go on with this work ? Or wait for the conf+rust to start it from there ?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I probably wouldn't wait, but might need to come back to you for reworking when the time comes.

@catenacyber catenacyber mentioned this pull request Oct 5, 2023
@catenacyber
Copy link
Contributor Author

Replaced by #9567

@catenacyber catenacyber closed this Oct 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants