LOLBAS. GitHub
LIVING OFF THE LAND / OTHER MICROSOFT BINARIES

Cdb.exe

View source

Debugging tool included with Windows Debugging Tools.

03COMMAND EXAMPLES
01ATT&CK TECHNIQUES
04DETECTION RESOURCES
01CAPABILITIES
01 / TRADECRAFT

Command reference

3 examples

Execute3

EXAMPLE 01T1127

Launch 64-bit shellcode from the specified .wds file using cdb.exe.

COMMAND
cdb.exe -cf {PATH:.wds} -o notepad.exe
USE CASE
Local execution of assembly shellcode.
PRIVILEGES
User
OPERATING SYSTEM
Windows
Execute · Shellcode
EXAMPLE 02T1127

Attaching to any process and executing shell commands.

COMMAND
cdb.exe -pd -pn {process_name}
.shell {CMD}
USE CASE
Run a shell command under a trusted Microsoft signed binary
PRIVILEGES
User
OPERATING SYSTEM
Windows
Execute · CMD
EXAMPLE 03T1127

Execute arbitrary commands and binaries using a debugging script (see Resources section for a sample file).

COMMAND
cdb.exe -c {PATH:.txt} "{CMD}"
USE CASE
Run commands under a trusted Microsoft signed binary
PRIVILEGES
User
OPERATING SYSTEM
Windows
Execute · CMD
02 / ON DISK

Known paths

C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\cdb.exe
C:\Program Files (x86)\Windows Kits\10\Debuggers\x86\cdb.exe
03 / DEFENSIVE INTELLIGENCE

Detection & indicators

4 resources
REFERENCE IMPLEMENTATIONS

Code samples

FURTHER READING

Research & resources

COMMUNITY RESEARCH

Acknowledgements

Matt Graeber@mattifestation
mr.d0x@mrd0x
Spooky Sec@sec_spooky
Nasreddine Bencherchali@nas_bench