So I’ve been out of the GPU cracking game for a while as I’ve been running a MacBook on OS X.

After doing a little digging tonight and reading up on the latest version of hashcat (v3.00) it became apparent to me that hashcat now runs on OS X platforms. At last! Thanks to @hashcat (atom) for making the software open source!

For those of you wanting to get it going on OS X (soon to be macOS) here’s what you have to do.

First get the latest source code available:

1
2
3
4
5
6
7
8
MacBook:Downloads phillips321$ git clone https://github.com/hashcat/hashcat.git
Cloning into 'hashcat'...
remote: Counting objects: 11330, done.
remote: Compressing objects: 100% (151/151), done.
remote: Total 11330 (delta 107), reused 0 (delta 0), pack-reused 11179
Receiving objects: 100% (11330/11330), 13.86 MiB | 6.47 MiB/s, done.
Resolving deltas: 100% (9355/9355), done.
Checking connectivity... done.

Then we need to download the latest OpenCL:

1
2
3
4
5
6
7
8
MacBook:Downloads phillips321$ mkdir -p hashcat/deps
MacBook:Downloads phillips321$ git clone https://github.com/KhronosGroup/OpenCL-Headers.git hashcat/deps/OpenCL
Cloning into 'hashcat/deps/OpenCL'...
remote: Counting objects: 243, done.
remote: Total 243 (delta 0), reused 0 (delta 0), pack-reused 243
Receiving objects: 100% (243/243), 193.58 KiB | 0 bytes/s, done.
Resolving deltas: 100% (158/158), done.
Checking connectivity... done.

Now simply build the code:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
MacBook:Downloads phillips321$ cd hashcat/
MacBook:hashcat phillips321$ make
gcc -D_POSIX -pipe -W -Wall -std=c99 -Iinclude/ -IOpenCL/ -Ideps/OpenCL-Headers/ -O2 -c -o obj/ext_OpenCL.NATIVE.o src/ext_OpenCL.c
gcc -D_POSIX -pipe -W -Wall -std=c99 -Iinclude/ -IOpenCL/ -Ideps/OpenCL-Headers/ -O2 -c -o obj/shared.NATIVE.o src/shared.c
gcc -D_POSIX -pipe -W -Wall -std=c99 -Iinclude/ -IOpenCL/ -Ideps/OpenCL-Headers/ -O2 -c -o obj/rp_kernel_on_cpu.NATIVE.o src/rp_kernel_on_cpu.c
src/ext_OpenCL.c:400:5: warning: implicitly declaring library function 'snprintf' with type 'int (char *, unsigned long, const
      char *, ...)'
[-Wimplicit-function-declaration]
    snprintf (options_update, len, "%s -cl-opt-disable", options);
    ^
src/ext_OpenCL.c:400:5: note: include the header <stdio.h> or explicitly provide a declaration for 'snprintf'
1 warning generated.
gcc -D_POSIX -pipe -W -Wall -std=c99 -Iinclude/ -IOpenCL/ -Ideps/OpenCL-Headers/ -O2    -o hashcat src/hashcat.c obj/ext_OpenCL.NATIVE.o obj/shared.NATIVE.o obj/rp_kernel_on_cpu.NATIVE.o -lpthread  -DCOMPTIME=1468103529 -DVERSION_TAG="v3.00-52-g3fa2d10" -DINSTALL_FOLDER="/usr/local/bin" -DSHARED_FOLDER="/usr/local/share/hashcat" -DDOCUMENT_FOLDER="/usr/local/share/doc/hashcat"
src/hashcat.c:13820:9: warning: unused variable 'need_nvapi' [-Wunused-variable]
    int need_nvapi   = 0;
        ^
src/hashcat.c:13822:9: warning: unused variable 'need_xnvctrl' [-Wunused-variable]
    int need_xnvctrl = 0;
        ^
2 warnings generated.

Finally onto the test:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
MacBook:hashcat phillips321$ ./example0.sh
hashcat (v3.00-52-g3fa2d10) starting...
OpenCL Platform #1: Apple              
=========================
- Device #1: Intel(R) Core(TM) i7-3635QM CPU @ 2.40GHz, skipped
- Device #2: HD Graphics 4000, 384/1536 MB allocatable, 16MCU
- Device #3: GeForce GT 650M, 256/1024 MB allocatable, 2MCU
Hashes: 6494 hashes; 6494 unique digests, 1 unique salts
Bitmaps: 16 bits, 65536 entries, 0x0000ffff mask, 262144 bytes, 5/13 rotates
Applicable Optimizers:
* Zero-Byte
* Precompute-Init
* Precompute-Merkle-Demgard
* Meet-In-The-Middle
* Early-Skip
* Not-Salted
* Not-Iterated
* Single-Salt
* Raw-Hash
- Device #2: Kernel m00000_a1.cf940205.kernel not found in cache! Building may take a while...
- Device #2: Kernel markov_le.cf940205.kernel not found in cache! Building may take a while...
- Device #3: Kernel m00000_a1.b0228507.kernel not found in cache! Building may take a while...
- Device #3: Kernel markov_le.b0228507.kernel not found in cache! Building may take a while...
Generated dictionary stats for example.dict: 1080240 bytes, 129988 words, 136302297088 keyspace          
ccda5674a0ad1937a46a6cae69c674bb:chan12345678
c80693e7f09211327d9f5c1a0ac0439b:sike2005                
[s]tatus [p]ause [r]esume [b]ypass [c]heckpoint [q]uit => q
Session.Name...: hashcat
Status.........: Aborted
Input.Left.....: Mask (?a?a?a?a) [4]
Input.Right....: File (example.dict)
Hash.Target....: File (example0.hash)
Hash.Type......: MD5
Time.Started...: Sat Jul  9 23:33:04 2016 (2 secs)
Time.Estimated.: Sat Jul  9 23:46:33 2016 (13 mins, 21 secs)
Speed.Dev.#2...: 93005.2 kH/s (11.92ms)
Speed.Dev.#3...: 76644.6 kH/s (8.69ms)
Speed.Dev.#*...:   169.6 MH/s
Recovered......: 91/6494 (1.40%) Digests, 0/1 (0.00%) Salts
Recovered/Time.: CUR:N/A,N/A,N/A AVG:2120.22,127213.42,3053122.00 (Min,Hour,Day)
Progress.......: 403491840/136302297088 (0.30%)
Rejected.......: 0/403491840 (0.00%)
Restore.Point..: 0/129988 (0.00%)

Started: Sat Jul  9 23:33:04 2016
Stopped: Sat Jul  9 23:33:13 2016

One thing to note is that there are 2 GPUs and a single CPU, we can enable them all using the -D flag but in all honesty the CPU and Intel HD Graphics don’t really cut the mustard!

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
MacBook:hashcat phillips321$ ./hashcat -b -D 1,2,3
hashcat (v3.00-52-g3fa2d10) starting in benchmark-mode...

OpenCL Platform #1: Apple
=========================
- Device #1: Intel(R) Core(TM) i7-3635QM CPU @ 2.40GHz, 2048/8192 MB allocatable, 8MCU
- Device #2: HD Graphics 4000, 384/1536 MB allocatable, 16MCU
- Device #3: GeForce GT 650M, 256/1024 MB allocatable, 2MCU

Hashtype: MD4

Speed.Dev.#1.:   361.5 MH/s (23.15ms)
Speed.Dev.#2.:   314.3 MH/s (95.07ms)
Speed.Dev.#3.:  1743.1 GH/s (0.11ms)
Speed.Dev.#*.:  1743.8 GH/s

Hashtype: MD5

Speed.Dev.#1.:   222.2 MH/s (37.70ms)
Speed.Dev.#2.:   184.0 MH/s (95.63ms)
Speed.Dev.#3.:  1275.2 GH/s (0.11ms)
Speed.Dev.#*.:  1275.6 GH/s

Hashtype: Half MD5

Speed.Dev.#1.:   164.0 MH/s (51.06ms)
Speed.Dev.#2.:   123.4 MH/s (95.28ms)
Speed.Dev.#3.:   230.3 MH/s (104.45ms)
Speed.Dev.#*.:   517.7 MH/s

Hashtype: SHA1

Speed.Dev.#1.:   113.7 MH/s (73.72ms)
Speed.Dev.#2.: 63056.2 kH/s (97.53ms)
Speed.Dev.#3.:   238.9 GH/s (0.11ms)
Speed.Dev.#*.:   239.1 GH/s

Hashtype: SHA256

Speed.Dev.#1.: 35210.8 kH/s (100.66ms)
Speed.Dev.#2.: 24164.3 kH/s (95.31ms)
Speed.Dev.#3.: 57223.5 MH/s (0.11ms)
Speed.Dev.#*.: 57282.9 MH/s

Hashtype: SHA384

Speed.Dev.#1.: 11995.0 kH/s (96.22ms)
Speed.Dev.#2.:  7470.3 kH/s (97.95ms)
Speed.Dev.#3.: 76641.1 MH/s (0.12ms)
Speed.Dev.#*.: 76660.6 MH/s

Screen Shot 2016-07-09 at 23.36.35

Leave a Reply