🤯
Hacker Mind
  • Penetration Testing Notes
    • 00 - Kali Linux Preparation
    • Page 1
    • Web Application (80/443)
      • XSS
      • LFI / Path Traversal
      • Wordpress
    • SMB (445)
    • LDAP
    • MSRPC (135)
    • MSSQL
    • Kerberos (88/tcp)
    • DNS (53)
    • IPv6
    • Import Nessus to Metasploit
  • STUCK? Look at this :D
  • Buffer Overflow
    • WinDbg
    • BoF Script Python
  • Active Directory Recon
    • Username Generation
    • PowerView
    • BloodHound
    • Flooding Attack
  • Payload
    • Sendemail
    • Phishing Payload
    • Bypass All The Things
      • AppLocker
      • MSBuild Shell
      • C# Runner
      • Payload Mod
      • Powershell
      • Bypass AV Linux
        • C Runner
  • Exploit
    • Brute Force
    • File Upload
    • Cracking
    • Shell & Stabilization
    • Database
    • MSSQL Injection
  • Tradecraft
    • Invoke-ReflectivePEInjection
  • Metasploit
    • Meterpreter Tricks
  • Privilege Escalation
    • Lateral Movement
    • Linux
    • Windows
  • Post Exploit
    • Active Directory
      • Kerberos
      • ACLs/ACEs
      • DCSync
      • Golden Ticket with krbtgt
      • LAPS
      • Page
      • Impersonate Token
    • Pivoting
      • Pivot in a Case
    • Transfer File
    • Exfiltration
    • Persistence
  • WiFi Pentesting
    • WPA-PSK
    • WPA-E (hostapd)
    • Attack WEP
    • Evil Twin - Wi-Fi
    • WPA3 Downgrade
  • Hardware Hacking
    • Information Gathering
  • Practice & Lab
Powered by GitBook
On this page
  1. Penetration Testing Notes

SMB (445)

Anonymous Login

smbclient -L \\\\$IP -N

Bulk enumeration

crackmapexec smb 172.16.20.3-254 -u '' -p '' --shares

If you able to login to the machine, to retrieve all share folder in the specific hostname:

net view <hostname> /all

Enumerate / list the shares

smbclient -L //$IP/

smbmap -H $IP

crackmapexec smb $IP -u '' -p '' --shares -M spider_plus

Accessing the shares

smbclient //$IP/shares
# input blank password for anonymous login

smbclient //$IP/shares -U <username>%<password>

smbmap -u <username> -p <password -H $IP

there are some dir shares?

crackmapexec smb <ip> -u <username> -p <password> --shares

crackmapexec smb <ip> -u <username> -p <password> --shares -M spider_plus
# check spider_plus output in the [Tools]> [json]

smbmap -u <username> -p <password> -H $IP -r --exclude SYSVOL
smbmap -u <username> -p <password> -H $IP -R
smbmap -R <share> -H $IP

# wanna download a file?
smbmap -R <share> -H $IP -A <just filename> -q
locate <just filename>

smbclient -U <username> //$IP/shares
smbmap -u <username> -p <password> -H $IP --download <shares>/<folder>/<file>
PreviousWordpressNextLDAP

Last updated 6 months ago