====== Hashcat Beispiele ======
===== Hashes erzeugen: =====
* http://www.pythoncentral.io/hashing-strings-with-python/
* https://pypi.python.org/pypi/bcrypt/1.0.1
* http://www.vidarholen.net/contents/blog/?p=32
===== Hashcat Parameter =====
- a Angriffsart: 3 - BruteForce
- m Hashverfahren:
0 - MD5
10 - MD5 ($pass.$salt) oclhashcat erwartet immer das Format "hash:salt" unabhängig, davon wie gehashd wurde
20 - MD5 ($salt.$pass) oclhashcat erwartet immer das Format "hash:salt" unabhängig, davon wie gehashd wurde
100 - SHA1
500 - md5crypt, MD5(Unix), FreeBSD MD5, Cisco-IOS MD5
3200 - bcrypt
- 1 CustomCharset: ?l lower $u upper $d digit $s symbol
-1 ?l?u ?1?1?1?1?1?1?1?1 (8 Zeichen mit groß und Kleinschreibung in allen Stellen)
- O Optimized Kernel (geringere Passwortlänge, höherer Hashrate)
**Default Mask:**\\
If ''-a 3'' is requested without specifying a mask, the following default mask is used:
?1?2?2?2?2?2?2?3?3?3?3?d?d?d?d
**Bereits berechnete Hash-Werte:**\\
Hashcat speichert bereits berechnete Werte in ''~/.local/share/hashcat/hashcat.potfile''
===== Wörterbuchangriffe =====
* https://hashcat.net/wiki/doku.php?id=hybrid_attack
===== MD5 =====
**MD5-Hash erzeugen:**\\
''echo -n "testTest" | openssl md5 > hashfile_md5_testTest''
**Hashcat starten:**\\
hashcat -a 3 -m 0 hashfile_md5_testTest -1 ?l?u ?1?1?1?1?1?1?1?1 -0
7de54850c58a539219a3a7e02cca2ed3:testTest
Session.Name...: hashcat
Status.........: Cracked
Input.Mode.....: Mask (?1?1?1?1?1?1?1?1) [8]
Hash.Target....: 7de54850c58a539219a3a7e02cca2ed3
Hash.Type......: MD5
Time.Started...: Mon Feb 17 11:05:04 2014 (4 secs)
Speed.GPU.#1...: 1416.7 MH/s
Speed.GPU.#2...: 351.6 MH/s
Speed.GPU.#*...: 1768.3 MH/s
Recovered......: 1/1 (100.00%) Digests, 1/1 (100.00%) Salts
Progress.......: 6442450944/53459728531456 (0.01%)
Rejected.......: 0/6442450944 (0.00%)
HWMon.GPU.#1...: 93% Util, 69c Temp, 30% Fan
HWMon.GPU.#2...: 91% Util, 76c Temp, 30% Fan
Started: Mon Feb 17 11:05:04 2014
Stopped: Mon Feb 17 11:05:11 2014
===== SHA-1 =====
**SHA1-Hash erzeugen:**\\
''echo -n "TestTest" | openssl sha1 > hashfile_sha1_testTest''
**oclHashcat starten:**\\
hashcat -a 3 -m 100 hashfile_sha1_testTest
Session.Name...: cudaHashcat
Status.........: Running
Input.Mode.....: Mask (?1?2?2?2?2?2?2?3) [8]
Hash.Target....: 7df71b73819f2e0c618339a2a45308a9775e3c6f
Hash.Type......: SHA1
Time.Started...: Sun Feb 16 22:28:25 2014 (2 hours, 53 mins)
Time.Estimated.: 0 secs
Speed.GPU.#1...: 0 H/s
Speed.GPU.#2...: 0 H/s
Speed.GPU.#*...: 0 H/s
Recovered......: 0/1 (0.00%) Digests, 0/1 (0.00%) Salts
Progress.......: 0/5533380698112 (0.00%)
Rejected.......: 0/0 (0.00%)
HWMon.GPU.#1...: 0% Util, 73c Temp, 44% Fan
HWMon.GPU.#2...: 84% Util, 86c Temp, 43% Fan
[s]tatus [p]ause [r]esume [b]ypass [q]uit =>
Session.Name...: cudaHashcat
Status.........: Running
Input.Mode.....: Mask (?1?2?2?2?2?2?2?3?3) [9]
Hash.Target....: 7df71b73819f2e0c618339a2a45308a9775e3c6f
Hash.Type......: SHA1
Time.Started...: Sun Feb 16 22:28:25 2014 (6 hours, 34 mins)
Time.Estimated.: Sat Feb 22 00:06:49 2014 (4 days, 16 hours)
Speed.GPU.#1...: 420.0 MH/s
Speed.GPU.#2...: 111.3 MH/s
Speed.GPU.#*...: 531.3 MH/s
Recovered......: 0/1 (0.00%) Digests, 0/1 (0.00%) Salts
Progress.......: 12579333210112/226868608622592 (5.54%)
Rejected.......: 0/12579333210112 (0.00%)
HWMon.GPU.#1...: 99% Util, 82c Temp, 52% Fan
HWMon.GPU.#2...: 99% Util, 88c Temp, 46% Fan
===== Bcrypt =====
''hashcat -a 3 -m 3200 --gpu-accel 160 bcryp''t
**Python:**\\
import bcrypt
hashed = bcrypt.hashpw(password, bcrypt.gensalt(10)) # Workfaktor-default ist 12
print hashed
brcypt mit Workfaktor 4
Speed.GPU.#1...: 1865 H/s
Speed.GPU.#2...: 236 H/s
Speed.GPU.#*...: 2100 H/s
bcrypt mit Workfaktor 10;
Speed.GPU.#1...: 31 H/s
Speed.GPU.#2...: 4 H/s
Speed.GPU.#*...: 34 H/s