diff --git a/Makefile b/Makefile index afcb61a6..6df3e538 100644 --- a/Makefile +++ b/Makefile @@ -14,7 +14,7 @@ # PROGNAME = afl -VERSION = 1.99b +VERSION = 2.00b PREFIX ?= /usr/local BIN_PATH = $(PREFIX)/bin diff --git a/afl-analyze.c b/afl-analyze.c index 426f76cf..ccd550a8 100644 --- a/afl-analyze.c +++ b/afl-analyze.c @@ -12,9 +12,11 @@ http://www.apache.org/licenses/LICENSE-2.0 - A nifty utility that takes an input file and takes a stab at explaining + A nifty utility that grabs an input file and takes a stab at explaining its structure by observing how changes to it affect the execution path. + If the output scrolls past the edge of the screen, pipe it to 'less -r'. + */ #define AFL_MAIN @@ -381,13 +383,13 @@ static void show_char(u8 val) { static void show_legend(void) { - SAYF(" " bgGRA cLGR " 01 " cRST " - no-op block " - bgLGN cBLK " 01 " cRST " - suspected length field\n" - " " bgGRA cBRI " 01 " cRST " - superficial content " - bgYEL cBLK " 01 " cRST " - suspected cksum or magic int\n" - " " bgCYA cBLK " 01 " cRST " - critical stream " - bgLRD cBLK " 01 " cRST " - suspected checksummed block\n" - " " bgMGN cBLK " 01 " cRST " - \"magic value\" section\n\n"); + SAYF(" " cLGR bgGRA " 01 " cRST " - no-op block " + cBLK bgLGN " 01 " cRST " - suspected length field\n" + " " cBRI bgGRA " 01 " cRST " - superficial content " + cBLK bgYEL " 01 " cRST " - suspected cksum or magic int\n" + " " cBLK bgCYA " 01 " cRST " - critical stream " + cBLK bgLRD " 01 " cRST " - suspected checksummed block\n" + " " cBLK bgMGN " 01 " cRST " - \"magic value\" section\n\n"); } @@ -496,13 +498,13 @@ static void dump_hex(u8* buf, u32 len, u8* b_data) { switch (rtype) { - case RESP_NONE: SAYF(bgGRA cLGR); break; - case RESP_MINOR: SAYF(bgGRA cBRI); break; - case RESP_VARIABLE: SAYF(bgCYA cBLK); break; - case RESP_FIXED: SAYF(bgMGN cBLK); break; - case RESP_LEN: SAYF(bgLGN cBLK); break; - case RESP_CKSUM: SAYF(bgYEL cBLK); break; - case RESP_SUSPECT: SAYF(bgLRD cBLK); break; + case RESP_NONE: SAYF(cLGR bgGRA); break; + case RESP_MINOR: SAYF(cBRI bgGRA); break; + case RESP_VARIABLE: SAYF(cBLK bgCYA); break; + case RESP_FIXED: SAYF(cBLK bgMGN); break; + case RESP_LEN: SAYF(cBLK bgLGN); break; + case RESP_CKSUM: SAYF(cBLK bgYEL); break; + case RESP_SUSPECT: SAYF(cBLK bgLRD); break; } diff --git a/debug.h b/debug.h index 54eb8cb9..1bdfb6c3 100644 --- a/debug.h +++ b/debug.h @@ -28,14 +28,14 @@ #ifdef USE_COLOR -# define cBLK "\x1b[30m" -# define cRED "\x1b[31m" -# define cGRN "\x1b[32m" -# define cBRN "\x1b[33m" -# define cBLU "\x1b[34m" -# define cMGN "\x1b[35m" -# define cCYA "\x1b[36m" -# define cLGR "\x1b[37m" +# define cBLK "\x1b[0;30m" +# define cRED "\x1b[0;31m" +# define cGRN "\x1b[0;32m" +# define cBRN "\x1b[0;33m" +# define cBLU "\x1b[0;34m" +# define cMGN "\x1b[0;35m" +# define cCYA "\x1b[0;36m" +# define cLGR "\x1b[0;37m" # define cGRA "\x1b[1;90m" # define cLRD "\x1b[1;91m" # define cLGN "\x1b[1;92m" diff --git a/docs/ChangeLog b/docs/ChangeLog index 8d63ab8c..14bef0b5 100644 --- a/docs/ChangeLog +++ b/docs/ChangeLog @@ -16,6 +16,15 @@ Not sure if you should upgrade? The lowest currently recommended version is 1.92b. If you're stuck on an earlier release, it's strongly advisable to get on with the times. +-------------- +Version 2.00b: +-------------- + + - Cleaned up color handling after a minor snafu in 1.99b (affecting some + terminals). + + - Made minor updates to the documentation. + -------------- Version 1.99b: -------------- diff --git a/docs/README b/docs/README index 4bdc3dca..d6f63cb0 100644 --- a/docs/README +++ b/docs/README @@ -327,9 +327,10 @@ afl-fuzz. Another recent addition to AFL is the afl-analyze tool. It takes an input file, attempts to sequentially flip bytes, and observes the behavior of the -tested program. It then annotates the structure of the input data by showing -which sections appear to be critical, and which are not. More info about its -output can be found near the end of technical_details.txt. +tested program. It then color-codes the input based on which sections appear to +be critical, and which are not; while not bulletproof, it can often offer quick +insights into complex file formats. More info about its operation can be found +near the end of technical_details.txt. 11) Common-sense risks ---------------------- diff --git a/docs/status_screen.txt b/docs/status_screen.txt index 3a764d4e..45e3069f 100644 --- a/docs/status_screen.txt +++ b/docs/status_screen.txt @@ -22,10 +22,8 @@ If you are using inverse video, you may want to change your settings, say: - For GNOME Terminal, go to Edit > Profile preferences, select the "colors" tab, and from the list of built-in schemes, choose "white on black". - - For the MacOS X Terminal app, go to Preferences > Settings, click on - the "Pro" color scheme, and select "Use bright colors for bold text". - Then, open a new window using the "Pro" scheme via the Shell > New Window - menu (or make "Pro" your default). + - For the MacOS X Terminal app, open a new window using the "Pro" scheme via + the Shell > New Window menu (or make "Pro" your default). Alternatively, if you really like your current colors, you can edit config.h to comment out USE_COLORS, then do 'make clean all'.