Ignore:
Timestamp:
Dec 29, 2006, 6:22:11 PM (14 years ago)
Author:
Sam Hocevar
Message:
  • Added the -i flag (for stdin fuzzing).
File:
1 edited

Legend:

Unmodified
Added
Removed
  • zzuf/trunk/src/zzuf.c

    r1525 r1526  
    9898            { "include",   1, NULL, 'I' },
    9999            { "exclude",   1, NULL, 'E' },
     100            { "stdin",     0, NULL, 'i' },
    100101            { "seed",      1, NULL, 's' },
    101102            { "ratio",     1, NULL, 'r' },
     
    108109            { "version",   0, NULL, 'v' },
    109110        };
    110         int c = getopt_long(argc, argv, "I:E:s:r:F:B:T:qdhv",
     111        int c = getopt_long(argc, argv, "I:E:is:r:F:B:T:qdhv",
    111112                            long_options, &option_index);
    112113#   else
    113114#       define MOREINFO "Try `%s -h' for more information.\n"
    114         int c = getopt(argc, argv, "I:E:s:r:F:B:T:qdhv");
     115        int c = getopt(argc, argv, "I:E:is:r:F:B:T:qdhv");
    115116#   endif
    116117        if(c == -1)
     
    124125        case 'E': /* --exclude */
    125126            setenv("ZZUF_EXCLUDE", optarg, 1);
     127            break;
     128        case 'i': /* --stdin */
     129            setenv("ZZUF_STDIN", "1", 1);
    126130            break;
    127131        case 's': /* --seed */
     
    426430static void usage(void)
    427431{
    428     printf("Usage: zzuf [ -vqdh ] [ -r ratio ] [ -s seed | -s start:stop]\n");
    429     printf("                      [ -F children ] [ -B bytes ] [ -T seconds ]\n");
    430     printf("                      [ -I include ] [ -E exclude ] COMMAND [ARGS]...\n");
    431     printf("Run COMMAND and randomly fuzz its input files.\n");
     432    printf("Usage: zzuf [ -vqdhi ] [ -r ratio ] [ -s seed | -s start:stop]\n");
     433    printf("                       [ -F children ] [ -B bytes ] [ -T seconds ]\n");
     434    printf("                       [ -I include ] [ -E exclude ] COMMAND [ARGS]...\n");
     435    printf("Run COMMAND and randomly fuzz its input.\n");
    432436    printf("\n");
    433437    printf("Mandatory arguments to long options are mandatory for short options too.\n");
     
    440444    printf("  -T, --max-time <n>       kill children that run for more than <n> seconds\n");
    441445    printf("  -q, --quiet              do not print children's messages\n");
     446    printf("  -i, --stdin              fuzz standard input\n");
    442447    printf("  -I, --include <regex>    only fuzz files matching <regex>\n");
    443448    printf("  -E, --exclude <regex>    do not fuzz files matching <regex>\n");
     
    453458    printf("  -T <n>           kill children that run for more than <n> seconds\n");
    454459    printf("  -q               do not print the fuzzed application's messages\n");
     460    printf("  -i               fuzz standard input\n");
    455461    printf("  -I <regex>       only fuzz files matching <regex>\n");
    456462    printf("  -E <regex>       do not fuzz files matching <regex>\n");
Note: See TracChangeset for help on using the changeset viewer.