I'm looking at the barnyard2.c code as I get ready to add a new command line option. I noticed this in the options for unix:
static char *valid_options = "?a:Ac:C:d:Def:Fg:G:h:i:Il:m:noOqr:R:S:t:Tu:UvVw:xXy";
and below that:
{"snaplen", LONGOPT_ARG_REQUIRED, NULL, 'P'},
Why is the P not reflected in the valid_options? It doesn't appear to be in the options processing loop below. My only guess would be that it has to do with future features around snort as snort has the P/snaplen option. Is this correct? I was wanting to use the -P for an IDS/IPS feature but not sure if that would be discouraged.
thanks,
-hojo