diff --git a/ChangeLog b/ChangeLog index 56aeb03..8217331 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Version 1.55b: +-------------- + + - Improved 404 directory no-parse checks. + Version 1.54b: -------------- diff --git a/Makefile b/Makefile index 5548aa3..4f79c01 100644 --- a/Makefile +++ b/Makefile @@ -20,7 +20,7 @@ # PROGNAME = skipfish -VERSION = 1.54b +VERSION = 1.55b OBJFILES = http_client.c database.c crawler.c analysis.c report.c INCFILES = alloc-inl.h string-inl.h debug.h types.h http_client.h \ diff --git a/crawler.c b/crawler.c index 3e1a571..150ad9d 100644 --- a/crawler.c +++ b/crawler.c @@ -2432,10 +2432,30 @@ bad_404: req->pivot->r404_cnt = 0; /* We can still try parsing the response, if it differs from parent - in any way... */ + and is not on parent's 404 list. */ - if (!RPAR(req)->res || !same_page(&RPRES(req)->sig, &RPAR(req)->res->sig)) + if (!RPAR(req)->res) { PIVOT_CHECKS(req->pivot->req, req->pivot->res); + } else { + + if (!same_page(&RPRES(req)->sig, &RPAR(req)->res->sig)) { + + struct pivot_desc* par; + par = dir_parent(req->pivot); + + if (par) { + + for (i=0;ir404_cnt;i++) + if (same_page(&res->sig, &par->r404[i])) break; + + } + + if (!par || i == par->r404_cnt) + PIVOT_CHECKS(req->pivot->req, req->pivot->res); + + } + + } } else DEBUG("* 404 detection successful.\n");