101 Commits

Author SHA1 Message Date
wiire-a
d3e4aab2e8 Added forward and backward time windows when seed is found (mode 3)
Fixed #63. Added more debug info. Added separate seeds for secret
nonces.
2017-10-31 12:00:54 +01:00
wiire-a
2f1bbbea1d Renamed 'RT/MT' mode to 'RT/MT/CL' 2017-10-29 11:21:40 +01:00
wiire-a
4937d61d40 Fixed CFLAGS typo in Makefile
Introduced in (81d5b4b).
2017-10-25 09:57:00 +02:00
wiire-a
887fbbb33d Merge pull request #62 from rofl0r/makeit
Makefile improvements
2017-10-25 00:15:04 +02:00
rofl0r
c56e689f58 Makefile: use DESTDIR in the conventional way
DESTDIR gets only used in the install target, so prefix doesn't get
cluttered and can be used internally to reference file dependencies.
e.g. if for example a DB would be used, the filename to the DB could
be passed in CPPFLAGS like "-DDBPATH=$(PREFIX)/share/pixiewps.db".
this doesn't happen at the moment, but it's good practice to follow
the conventions.

additionally, remove the "rm" command in the install target - running
`make install` should never ever delete files from user's prefix.
2017-10-24 22:53:29 +01:00
rofl0r
367697a24f Makefile: rename CCFLAGS to CFLAGS
the latter is the standard way of naming it.
it was pretty surprising when doing

    make CFLAGS="-O0 -g"

ended up running `gcc -O0 -g -O3 ...`
2017-10-24 22:44:29 +01:00
wiire-a
2b3dc759f1 Merge pull request #61 from binarymaster/master
Fix compilation in mingw-w64
2017-10-22 14:22:02 +02:00
Stas'M
3fbd36a735 Fix compilation in mingw-w64 2017-10-22 15:17:41 +03:00
wiire-a
e4d1bde5bb Merge pull request #60 from rofl0r/no_attr
Add workaround for mingw toolchains with broken pthread_attr_t support
2017-10-22 13:39:40 +02:00
rofl0r
147a615891 add workaround for mingw toolchains with broken pthread_attr_t support
toolchains from https://sourceforge.net/projects/mingw-w64/ don't
define PTHREAD_STACK_MIN, and when using pthread_attr_t fail due to
internal bugs in their atomics implementation:

   __buildlogicali(_InterlockedAnd, __LONG32, and)
   mingw32/include/psdk_inc/intrin-impl.h:977:1:
   error: static declaration of '_InterlockedAnd' follows non-static declaration

OTOH, they implement pthread support without the need of external DLL's,
so using them might be preferable.
2017-10-22 12:35:37 +01:00
wiire-a
d12f0ea0a2 Added option -7
This option is used to decrypt the field encrypted settings in M7, which
contains the wireless configuration of the AP. This option exploits a
misconfigured crypto library that always generates the same random
number, resulting in always generating the same static Private key (and
Public key). Hence, Diffie-Hellman encryption can be broken and the
passphrase recovered by anyone passively sniffing the air.
2017-10-22 12:04:20 +02:00
wiire-a
9af4c43b73 Added missing frees 2017-10-22 02:45:07 +02:00
wiire-a
537dd74029 Merge pull request #58 from rofl0r/pthread_stack
Set a reasonable stacksize for threads to prevent huge waste with GLIBC
2017-10-15 20:47:17 +02:00
rofl0r
7cad1983da set a reasonable stacksize for threads to prevent huge waste with GLIBC
GLIBC defaults to giving new threads an insanely huge 8MB stack each, which
causes unnecessary memory waste. we set it to a conservative 64KB, even though
we need less than 1KB ourselves, to give sufficient leeway to buffers used
by libc itself when calling out to some of its functions.
2017-10-15 17:53:50 +01:00
wiire-a
6ee757e808 Updated usage screen 2017-10-14 12:03:32 +02:00
wiire-a
7a875fb09d Updated README 2017-10-14 12:01:41 +02:00
wiire-a
7d0f03d400 Changed default behavior to use all cores available
Used workaround to make it compile on Windows with some MinGW
installations
2017-10-14 11:43:10 +02:00
wiire-a
e2f480a900 Added libpthread dependency 2017-10-09 23:53:24 +02:00
wiire-a
4c25e2059d Removed useless C99 compilation guard 2017-10-09 23:47:59 +02:00
wiire-a
f424be2590 Merge pull request #55 from rofl0r/pthreads
Implement -j option for parallel cracks using pthreads
2017-10-09 23:45:14 +02:00
rofl0r
1e69706bb9 fix endless loop when seed wraps around from 0 to 0xffffffff
the issue could be experienced when the full brute-force space
till the unix epoch was searched.

test with: --start 02/1970 --end 01/1970
2017-10-09 22:36:04 +01:00
rofl0r
80f7774e98 implement -j option for parallel cracks using pthreads
a user-defined number of jobs (N) is started, each one is assigned
SECS_PER_JOB_BLOCK seeds to iterate over, after finishing the block
N * SECS_PER_JOB_BLOCK jobs are skipped, and it goes on again.
that way it is assured that more recent seeds get treated first.
in preliminary tests with a seed 2 years ago, using 8 jobs the
cracking time was reduced from 77 to 24 seconds.
it is possible that adjusting SECS_PER_JOB_BLOCK to a higher value
than currently speeds up cracking even more, since there will be
less "interruptions" in the CPUs branch prediction.
2017-10-09 00:07:08 +01:00
wiire-a
cbcbbd143b Changed time span to +-1 day 2017-10-08 18:23:37 +02:00
wiire-a
6c145761c3 Merge pull request #54 from rofl0r/inline
Fix inline so -O0 works too
2017-10-08 16:22:31 +02:00
wiire-a
9f39191ff2 Merge pull request #53 from rofl0r/getopt
Group getopt non-option arguments together for POSIX compat
2017-10-08 16:22:14 +02:00
rofl0r
cd61db2be5 fix inline so -O0 works too 2017-10-08 14:51:21 +01:00
rofl0r
1a395250c6 group getopt non-option arguments together for POSIX compat
for compatibility with POSIX getopt, non-option arguments
should be grouped together, since on the first occurence
of such an argument, it will consider all following arguments
non-option arguments too. this could be an issue with alternative
libc implementations.
2017-10-08 13:39:47 +01:00
wiire-a
3c8daf98df Updated to 1.3 v1.3 2017-10-07 18:13:10 +02:00
wiire-a
f33dd7a99d Updated to 1.3 2017-10-07 18:11:23 +02:00
wiire-a
5ec1e433aa Merge pull request #49 from binarymaster/master
Add new features
2017-10-07 17:38:25 +02:00
Stas'M
120ed9c8a3 Eliminate warnings, get rid of dynamic pin alloc 2017-10-07 18:34:18 +03:00
binarymaster
85413d0d6e Add full-length brute-force 2017-09-02 13:13:28 +03:00
binarymaster
622b086572 Add option for output file 2017-09-02 09:26:04 +03:00
binarymaster
64ecc3e8c2 Add support for empty string pin 2017-09-01 22:48:18 +03:00
wiire
f723d5017f Added modes 1,2 when mode 3 is detected in auto 2017-02-11 20:28:15 +01:00
wiire
2f12ef5277 Enforced e-nonce mandatory 2017-02-11 20:21:07 +01:00
wiire
fe3bedcb02 Corrected author 2017-02-11 20:17:59 +01:00
wiire
2052795813 Merge pull request #39 from wpa2/patch-1
Update Makefile
2017-02-11 19:31:18 +01:00
wpa2
157cd3d96e Update Makefile 2016-12-25 16:13:54 +02:00
wiire
fd62b81852 Merge pull request #33 from samueloph/master
Changes to makefile
2016-11-03 21:41:31 +01:00
Samuel Henrique
a42a1d21f7 Add manpage 2016-11-03 01:48:13 -02:00
Samuel Henrique
7a90b8e50d Only use optimization CCFLAGS if not set prvlsy 2016-11-02 17:49:50 -02:00
Samuel Henrique
81d5b4bd2a Add flags to debug target 2016-11-02 17:47:56 -02:00
Samuel Henrique
250085102b Remove double PREFIX declaration 2016-11-02 17:46:55 -02:00
Samuel Henrique
d9860f01d1 Add -f parameter to rm on unistall target 2016-11-02 17:46:27 -02:00
Samuel Henrique
867c332755 Remove LOCDIR variable 2016-11-02 17:45:51 -02:00
wiire
953cdd461c Merge pull request #32 from samueloph/master
[src/Makefile] Change paths and add missing flags
2016-10-19 15:31:12 +02:00
Samuel Henrique
520f46d154 Change path and add missing flags
Fix paths and add missing flags: LDFLAGS, CFLAGS and CPPFLAGS.
The authors of this patch are:
Sophie Brun <sophie@freexian.com>,
Samuel Henrique <samueloph@gmail.com>
Gianfranco Costamagna <locutusofborg@debian.org>
2016-10-19 00:06:04 -02:00
wiire
1448fff39f Fixed previous commit 2016-04-27 17:01:34 +02:00
wiire
cfe3d94b46 Added an extra time span of 12 hours when --force is used
See #25
2016-04-25 20:40:39 +02:00