Skip to content
KitploitKITPLOIT
ToolsExploitsBlog
Log in
Submit
ToolsExploitsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

FeedsContactPrivacyΒ© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
BOF_ExecuteAssembly β€” Beacon Object File for Cobalt Strike that executes .NET assemblies in beacon with evasion techniques. | Kitploit
Tools/GitHubGitHub/ntdallas/bof_executeassembly
Privilege EscalationIDS/IPS EvasionShellcodePost-ExploitationCommand and ControlRed TeamingBinary Exploitation
GitHubntdallas/bof_executeassembly

BOF_ExecuteAssembly

Beacon Object File for Cobalt Strike that executes .NET assemblies in beacon with evasion techniques.

View Repository
195272610 months agoReviewed by Kitploit

Most Popular

View all β†’

Discover the most used tools by our community.

Explore all tools

Browse our collection of tools

View all tools β†’
Share

BOF Execute-Assembly

Beacon Object File for Cobalt Strike that executes .NET assemblies in beacon with evasion techniques.

Overview

Core Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                         Cobalt Strike Beacon                                 β”‚
β”‚                         (Parent Process)                                     β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                                   β”‚
                                   β”‚ beacon_inline_execute()
                                   β”‚ - Parse packed arguments
                                   β”‚ - Call go()
                                   β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                      BOF Execute-Assembly Entry (go)                         β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚
β”‚  β”‚ Configuration Parsing                                                  β”‚  β”‚
β”‚  β”‚  β€’ ProxyMethod (None/Draugr/Timer/RegWait)                             β”‚  β”‚
β”‚  β”‚  β€’ AmsiEvasion (None/Patch/HWBP)                                       β”‚  β”‚
β”‚  β”‚  β€’ EtwEvasion (None/Patch)                                             β”‚  β”‚
β”‚  β”‚  β€’ PipeName, AppDomainName, Assembly bytes, Arguments                  β”‚  β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β”‚
β”‚                                   β”‚                                          β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚
β”‚  β”‚ Framework Initialization                                               β”‚  β”‚
β”‚  β”‚  β€’ InitVxTable() - Resolve syscall numbers                             β”‚  β”‚
β”‚  β”‚    └─> NtProtectVirtualMemory, NtContinue, NtCreateEvent,              β”‚  β”‚
β”‚  β”‚        NtSetEvent, NtWaitForSingleObject, NtClose                      β”‚  β”‚
β”‚  β”‚  β€’ DraugrInit() - Setup synthetic stack frames                         β”‚  β”‚
β”‚  β”‚    └─> Locate RtlUserThreadStart, BaseThreadInitThunk                  β”‚  β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β”‚
β”‚                                   β”‚                                          β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚
β”‚  β”‚ DLL Loading (ProxyLoadLibraryA)                                        β”‚  β”‚
β”‚  β”‚  β€’ amsi.dll, OleAut32.dll, mscoree.dll, User32.dll                     β”‚  β”‚
β”‚  β”‚                                                                        β”‚  β”‚
β”‚  β”‚  PROXY_NONE:     LoadLibraryA() directly                               β”‚  β”‚
β”‚  β”‚  PROXY_DRAUGR:   DRAUGR_API(LoadLibraryA) - spoofed stack              β”‚  β”‚
β”‚  β”‚  PROXY_TIMER:    CreateTimerQueue β†’ Timer callback                     β”‚  β”‚
β”‚  β”‚  PROXY_REGWAIT:  RegisterWaitForSingleObject β†’ Event callback          β”‚  β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β”‚
β”‚                                   β”‚                                          β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚
β”‚  β”‚ AMSI Evasion Setup                                                     β”‚  β”‚
β”‚  β”‚                                                                        β”‚  β”‚
β”‚  β”‚  AMSI_PATCH:                         AMSI_HWBP:                        β”‚  β”‚
β”‚  β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”         β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚  β”‚
β”‚  β”‚  β”‚ 1. Backup 4 bytes       β”‚         β”‚ 1. Add VEH Handler           β”‚  β”‚  β”‚
β”‚  β”‚  β”‚ 2. NtProtectVirtualMem  β”‚         β”‚ 2. RtlCaptureContext         β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    (RW)                 β”‚         β”‚ 3. Set DR0 = AmsiScanBuffer  β”‚  β”‚  β”‚
β”‚  β”‚  β”‚ 3. Write:               β”‚         β”‚ 4. Enable DR7 breakpoint     β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    48 31 C0  xor rax,raxβ”‚         β”‚ 5. NtContinue (apply ctx)    β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    C3        ret        β”‚         β”‚                              β”‚  β”‚  β”‚
β”‚  β”‚  β”‚ 4. NtProtectVirtualMem  β”‚         β”‚ On AmsiScanBuffer call:      β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    (restore)            β”‚         β”‚   β†’ #BP Exception            β”‚  β”‚  β”‚
β”‚  β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜         β”‚   β†’ VEH redirects to RET     β”‚  β”‚  β”‚
β”‚  β”‚                                      β”‚   β†’ RAX = 0                  β”‚  β”‚  β”‚
β”‚  β”‚                                      β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β”‚  β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β”‚
β”‚                                   β”‚                                          β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚
β”‚  β”‚ ETW Evasion (if enabled)                                               β”‚  β”‚
β”‚  β”‚  β€’ NtProtectVirtualMemory(NtTraceEvent, RW)                            β”‚  β”‚
β”‚  β”‚  β€’ Backup 4 bytes                                                      β”‚  β”‚
β”‚  β”‚  β€’ Write: 48 31 C0 C3 (xor rax,rax; ret)                               β”‚  β”‚
β”‚  β”‚  β€’ NtProtectVirtualMemory(restore protection)                          β”‚  β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β”‚
β”‚                                   β”‚                                          β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚
β”‚  β”‚ Output Redirection Setup                                               β”‚  β”‚
β”‚  β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚  β”‚
β”‚  β”‚  β”‚ 1. CreateNamedPipeW(\\.\pipe\{CustomName})  β†’ hPipe              β”‚  β”‚  β”‚
β”‚  β”‚  β”‚ 2. CreateFileW(pipe path)                   β†’ hFile              β”‚  β”‚  β”‚
β”‚  β”‚  β”‚ 3. AllocConsole() + ShowWindow(SW_HIDE)     β†’ Hidden console     β”‚  β”‚  β”‚
β”‚  β”‚  β”‚                                                                  β”‚  β”‚  β”‚
β”‚  β”‚  β”‚ 4. PEB Manipulation:                                             β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    β€’ Backup: hCurrentStdOut = PEB->ProcessParameters->StdOut     β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    β€’ Backup: hCurrentStdErr = PEB->ProcessParameters->StdErr     β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    β€’ Redirect: PEB->StdOut = hFile                               β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    β€’ Redirect: PEB->StdErr = hFile                               β”‚  β”‚  β”‚
β”‚  β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β”‚  β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β”‚
β”‚                                   β”‚                                          β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚
β”‚  β”‚ CLR Hosting & Assembly Execution (ExecuteAssembly)                     β”‚  β”‚
β”‚  β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚  β”‚
β”‚  β”‚  β”‚ 1. CLR Version Detection                                         β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    β€’ Scan assembly bytes for "v2.0.50727" or "v4.0.30319"        β”‚  β”‚  β”‚
β”‚  β”‚  β”‚                                                                  β”‚  β”‚  β”‚
β”‚  β”‚  β”‚ 2. CLR Initialization                                            β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    β€’ CLRCreateInstance β†’ ICLRMetaHost                            β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    β€’ GetRuntime(v2/v4) β†’ ICLRRuntimeInfo                         β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    β€’ GetInterface β†’ ICorRuntimeHost                              β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    β€’ Start()                                                     β”‚  β”‚  β”‚
β”‚  β”‚  β”‚                                                                  β”‚  β”‚  β”‚
β”‚  β”‚  β”‚ 3. AppDomain Management                                          β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    β€’ GetDefaultDomain() β†’ Default AppDomain                      β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    β€’ CreateDomain(CustomName) β†’ Isolated AppDomain               β”‚  β”‚  β”‚
β”‚  β”‚  β”‚                                                                  β”‚  β”‚  β”‚
β”‚  β”‚  β”‚ 4. Assembly Loading                                              β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    β€’ Create SAFEARRAY (VT_UI1) with assembly bytes               β”‚  β”‚  β”‚
β”‚  β”‚  β”‚    β€’ SafeArrayAccessData β†’ Copy assembly to safe array           β”‚  β”‚  β”‚
Download Tool