All of lore.kernel.org
 help / color / mirror / Atom feed
From: Phil Sutter <phil@nwl.cc>
To: Florian Westphal <fw@strlen.de>
Cc: netfilter-devel@vger.kernel.org
Subject: Re: [PATCH nft] initial support for the afl++ (american fuzzy lop++) fuzzer
Date: Wed, 6 Dec 2023 14:03:36 +0100	[thread overview]
Message-ID: <ZXBxKEhprUVUvG7m@orbyte.nwl.cc> (raw)
In-Reply-To: <20231206074342.GC8352@breakpoint.cc>

On Wed, Dec 06, 2023 at 08:43:42AM +0100, Florian Westphal wrote:
> Phil Sutter <phil@nwl.cc> wrote:
> > > +__AFL_FUZZ_INIT();
> > > +/* this get passed via afl-cc, declares prototypes
> > > + * depending on the afl-cc flavor.
> > > + */
> >
> > This comment seems out of place?
> 
> I wanted to add some explanation as to where this
> macro is defined/coming from.

Ah, so it relates to the preceding macro call. Maybe
s/this/above macro declaraction/ ?

> 
> > > +	len = strlen(buf);
> > > +
> > > +	rv = write(fd, buf, len);
> > 
> > So this sets input->fname to name and writes into the opened fd, but
> > what if savebuf() noticed buf fits into input->buffer and thus set
> > input->use_filename = false?
> 
> What about it?  The idea is to have an on-disk copy in case afl or the
> vm its running in crashes.

Hmm. Probably I miss the point regarding struct nft_afl_input. IMO, if
save_candidate() writes data into the file despite called savebuf()
setting use_filename = false, nft_afl_run_cmd() will try to read from
->buffer when it should read from ->fname.

Cheers, Phil

  reply	other threads:[~2023-12-06 13:03 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-01 15:43 [PATCH nft] initial support for the afl++ (american fuzzy lop++) fuzzer Florian Westphal
2023-12-01 18:57 ` Phil Sutter
2023-12-06  2:11 ` Phil Sutter
2023-12-06  7:43   ` Florian Westphal
2023-12-06 13:03     ` Phil Sutter [this message]
2023-12-06 13:13       ` Florian Westphal
2023-12-06 13:30         ` Phil Sutter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZXBxKEhprUVUvG7m@orbyte.nwl.cc \
    --to=phil@nwl.cc \
    --cc=fw@strlen.de \
    --cc=netfilter-devel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.