From cbcbbd143b948391d91a39589b6a1aaa770ad58a Mon Sep 17 00:00:00 2001 From: wiire-a Date: Sun, 8 Oct 2017 18:23:28 +0200 Subject: [PATCH] Changed time span to +-1 day --- src/pixiewps.c | 6 +++--- src/pixiewps.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/pixiewps.c b/src/pixiewps.c index 51aac29..c04f54d 100644 --- a/src/pixiewps.c +++ b/src/pixiewps.c @@ -342,7 +342,7 @@ usage_err: if (is_mode_selected(RTL819x)) { /* Ignore --start and --end otherwise */ - wps->start = t_start.tv_sec; + wps->start = t_start.tv_sec + SEC_PER_DAY; /* Extra 1 day */ wps->end = t_start.tv_sec - MODE3_DAYS * SEC_PER_DAY; /* Attributes --start and --end can be switched start > end or end > start */ @@ -379,7 +379,7 @@ usage_err: } } else { if (wps->bruteforce) { - wps->start += SEC_PER_DAY >> 1; /* Extra 12 hour span */ + wps->start += SEC_PER_DAY; /* Extra 1 day */ wps->end = 0; } } @@ -432,7 +432,7 @@ usage_err: goto memory_err; memcpy(wps->authkey, buffer, WPS_AUTHKEY_LEN); - + if (wps->verbosity > 2) { wps->wrapkey = malloc(WPS_KEYWRAPKEY_LEN); if (!wps->wrapkey) diff --git a/src/pixiewps.h b/src/pixiewps.h index b1d7cae..fe4d02a 100644 --- a/src/pixiewps.h +++ b/src/pixiewps.h @@ -31,7 +31,7 @@ /* Modes constants */ #define MODE_LEN 5 -#define MODE3_DAYS 3 +#define MODE3_DAYS 1 #define MODE3_TRIES 3 #define SEC_PER_DAY 86400