Skip to content
Attack replay

A kworker-masquerading implant, caught at every step.

Scroll through the compromise that shaped Sentinel's implant-class detections: what the agent saw, the rule that fired at each step, the incident it became and a two-person containment.

Names, paths, techniques and rule ids are from the real incident and the agent's rules; PIDs, addresses and timings are illustrative.

  1. T+00:00Initial access

    The app runtime spawns a payload

    A request exploits the Node.js app on the host. Its runtime launches a binary that lives outside the app directory and outside the node install, yet still carries the app's PM2 environment. That mismatch is the first thread to pull.

    Evidenceprocess.start · env inspection (keys only, allowlisted values)
    parent
    node next start (pid 1204, PM2 app)
    exe
    /dev/shm/.guard
    env
    PM2_HOME · pm_id=0 · NODE_ENV=production
    redacted
    +38 environment values
    • SEN-PROC-010Web/app runtime spawned an unexpected binaryCriticalT1190
  2. T+00:02Defense evasion

    It hides in shared memory, dressed as a kernel thread

    The payload detaches from the app (re-parented to PID 1) and renames itself kworker/u16:2. Real kernel threads have no executable on disk; this one runs from /dev/shm with a hidden file name, which the tmp scanner hashes and diffs every 60 seconds.

    Evidenceprocess.snapshot · file.suspicious_executable
    comm
    kworker/u16:2
    exe
    /dev/shm/.guard (ELF, +x, hidden name)
    ppid
    1 re-parented to init, uid 1001
    sha256
    9f2c4e…a81e1
    • SEN-PROC-004Userland process masquerading as a kernel threadHighT1036.004
    • SEN-PROC-009Orphaned user process running from tmp, shm or memfdHighT1036
    • SEN-PROC-003Process executing from a world-writable staging directoryMediumT1105
    • SEN-FILE-001Executable staged in a temporary directoryMediumT1105
  3. T+00:03Defense evasion

    A fileless supervisor poses as redis-server

    Next, a supervisor starts from an anonymous memory file, so there is nothing on disk to find. Sentinel hashes the image through /proc/<pid>/exe (memfd and deleted images still work) and runs embedded YARA-lite rules over it.

    Evidenceprocess.start · binary.analysis
    comm
    redis-server
    exe
    /memfd:kworkerd (deleted)
    binary
    static · stripped · memfd_create + /proc/self/fd
    matches
    SEN-BIN-005 in-memory loader
    • SEN-PROC-002Fileless execution from memfdHighT1620
    • SEN-PROC-005System daemon name running from a non-standard pathHighT1036.005
    • SEN-PROC-001Process running from a deleted binaryHighT1070.004
    • SEN-BIN-005In-memory (memfd) loaderMediumT1620
  4. T+00:05Command and control

    Tor launches from a hidden directory

    The supervisor drops Tor into a dot-directory under /var/tmp, runs it as "kworker -f .c" and opens a loopback SOCKS listener. A suspicious parent spawning Tor is the implant staging its next hop.

    Evidenceprocess.start · network.listen · binary.analysis
    exe
    /var/tmp/.kworkerd/.d/tor
    argv
    kworker -f .c
    listen
    127.0.0.1:9151 (SOCKS)
    matches
    SEN-BIN-006 embedded Tor config (SocksPort, ClientOnly)
    • SEN-PROC-011Suspicious process spawned Tor, a miner or a downloaderCriticalT1105
    • SEN-PROC-008Executable inside a hidden directoryHighT1564.001
    • SEN-PROC-007Process name or argv[0] masqueradeHighT1036.005
    • SEN-NET-008SOCKS proxy listener opened by a non-system binaryHighT1090.003
    • SEN-BIN-006Embedded Tor configurationHighT1090.003
  5. T+00:09Command and control

    It reaches out for command and control

    Connections stuck in SYN_SENT are signal, not noise: failed C2 attempts. Tor relay connections follow on :9001. Server-side scoring adds up the reasons, and the flow crosses the suspicious line (≥ 40) on first sight.

    Evidencenetwork.connection.open · flow scoring
    SYN_SENT
    198.51.100.23:443 ×6 in 30 s
    ESTAB
    203.0.113.41:9001 tor relay
    reasons
    known-bad-port +50 · exe-in-tmp +40 · tor-relay +35
    risk
    100 / 100 → SRV-NET-001 (high)
    • SEN-NET-009Connection attempts to public IPs from a suspicious executableHighT1071
    • SEN-NET-005Tor network connectionMediumT1090.003
    • SEN-NET-003Outbound connection from a binary in a staging directoryHighT1105
    • SRV-NET-001Suspicious network flowHighserver
  6. T+00:14Persistence

    It makes sure it survives a reboot

    Finally the implant writes an @reboot line into the user crontab. Sentinel diffs cron files, flags the at-reboot line at high severity, and the binary scan already showed this executable writes reboot entries itself.

    Evidencepersistence watch · binary.analysis
    file
    /var/spool/cron/crontabs/app
    + line
    @reboot /dev/shm/.guard >/dev/null 2>&1
    matches
    SEN-BIN-004 writes reboot cron entries
    • SEN-PERS-005Cron reboot entryHighT1053.003
    • SEN-PERS-003New or modified cron jobMediumT1053.003
    • SEN-BIN-004Executable writes reboot cron entriesHighT1053.003
  7. T+00:15Correlation

    Sentinel connects the dots into one incident

    Open alerts on the same host within 30 minutes are auto-correlated into a single incident, titled from the top rule and host, with the maximum severity, every ATT&CK technique, the process tree, flows and a timeline. Export it as a print-ready forensic report.

    INC-0042AutoCriticalapp-01 · 30-min window

    Web/app runtime spawned an unexpected binary on app-01

    21
    alerts
    11
    techniques
    3
    processes
    T1190T1036.004T1036T1105T1620T1036.005T1070.004T1564.001T1090.003T1071T1053.003
    1. T+00:00The app runtime spawns a payload
    2. T+00:02It hides in shared memory, dressed as a kernel thread
    3. T+00:03A fileless supervisor poses as redis-server
    4. T+00:05Tor launches from a hidden directory
    5. T+00:09It reaches out for command and control
    6. T+00:14It makes sure it survives a reboot
    Forensic report: markdown or print-ready HTML
  8. T+00:21Response

    Contain it, with two people and a signature

    An analyst requests the playbook; a different admin approves each step. The control plane signs a short-lived command with Ed25519. The agent verifies the signature against its pinned key, its own host id, expiry, replay set and profile before it touches anything.

    1. 1suspend_processSIGSTOP the supervisor; memory preserved for forensicsrequested
    2. 2capture_process_imageCopy /proc/<pid>/exe to evidence/ with sha256queued
    3. 3block_ipDeny outbound to C2 and relay in inet oxumi_sentinelqueued
    4. 4kill_processpidfd + starttime verified, TERM → KILLqueued
    requested by analyst
    approved by a second admin
    Control plane
    sign Ed25519
    keyId k_01 · ttl 15m
    Agent · app-01
    • Ed25519 signature · pinned key
    • agentId / hostId are this host
    • now < expiresAt
    • commandId not seen before
    • kind allowed by profile "response"
    • params valid (pid + startTicks + exe)
    // command = base64url(payload) . base64url(sig)
    {"v":1,"kind":"suspend_process","params":{"pid":3186369,"startTicks":41823651},"expiresAt":"…"}
Captured live

The same attack, on a real Sentinel.

We ran the repository's harmless attack simulation, including this implant, on a test host with the agent installed. This is the incident Sentinel correlated from it, exactly as the API returned it.

INC-39New listening port opened by a non-system process on prod-api-01Critical

35

alerts folded in

22

distinct rules fired

13

ATT&CK techniques

  1. 09:25:19New listening port opened by a non-system processSEN-NET-001 · command and controlMedium
  2. 09:25:19Executable staged in a temporary directorySEN-FILE-001 · command and controlMedium
  3. 09:25:54Process executing from a world-writable staging directorySEN-PROC-003 · command and controlMedium
  4. 09:25:54Cryptocurrency miner processSEN-PROC-012 · impactHigh
  5. 09:25:59Suspicious network flowSRV-NET-001 · command and controlHigh
  6. 09:25:59Connection to a cryptocurrency mining pool portSEN-NET-004 · impactHigh
  7. 09:25:59Outbound connection from a binary in a staging directorySEN-NET-003 · command and controlHigh
  8. 09:26:04Reverse shell command lineSEN-PROC-006 · executionHigh
  9. 09:26:09Shell or interpreter listening on all interfacesSEN-NET-006 · command and controlMedium
  10. 09:26:09Shell or netcat with a connection to a public IPSEN-NET-002 · executionHigh
  11. 09:26:14Botnet command vocabulary in executableSEN-BIN-001 · command and controlCritical
  12. 09:26:14Embedded Tor configurationSEN-BIN-006 · command and controlHigh
  13. 09:26:14Process running from a deleted binarySEN-PROC-001 · defense evasionHigh
  14. 09:26:14Suspicious process spawned Tor, a miner or a downloaderSEN-PROC-011 · command and controlCritical
  15. 09:26:14Fileless execution from memfdSEN-PROC-002 · defense evasionHigh
  16. 09:26:14Web/app runtime spawned an unexpected binarySEN-PROC-010 · initial accessCritical
  17. 09:26:14Process name or argv[0] masqueradeSEN-PROC-007 · defense evasionHigh
  18. 09:26:14Executable inside a hidden directorySEN-PROC-008 · defense evasionHigh
  19. 09:26:14Userland process masquerading as a kernel threadSEN-PROC-004 · defense evasionHigh
  20. 09:26:14System daemon name running from a non-standard pathSEN-PROC-005 · defense evasionHigh
  21. 09:26:19SOCKS proxy listener opened by a non-system binarySEN-NET-008 · command and controlHigh
  22. 09:28:04Sustained high CPU usageSEN-PROC-013 · impactMedium
Process lineage
  1. simplevisor1
  2. containerd-shim4126529
  3. timeout4126548
  4. python34126572
  5. redis-server re4126574

exe /memfd:kworkerd

Suspicious connections
  • 100tor 192.168.117.11:9001
  • 100xmrig 192.168.117.5:3333
  • 90bash 104.20.23.154:443
  • 25whatomate 192.168.167.2:6379
  • 25whatomate 192.168.167.1:33020

Captured from a live Sentinel instance on 2026-11-25 while the repository's harmless attack simulation ran on a test host. Nothing on this card is edited.

The incident page for the simulated implant: timeline, affected host, tactics observed and its alerts.
Process investigation for the implant: lineage, the masquerading process, its detections, files and the remote it reached.
Run it yourself

Reproduce it, harmlessly.

The simulation runs in disposable, locked-down containers (no capabilities, read-only root, memory and pid limits) on a private network. Payloads are copies of sleep, python, perl and busybox; nothing malicious is contacted.

ScenarioWhat it does
kworker-implantThe shape of the 2026-11-23 incident: a memfd supervisor posing as redis-server, a kworker-named guard and a Tor child in a hidden directory
xmrig-poolA /tmp binary named xmrig connected to a local listener on :3333
shell-socketbash holding /dev/tcp to a local nc listener
python-listenerA python one-liner listening on 0.0.0.0:8765
tmp-execA copy of sleep run from /tmp
ssh-bruteforce12 failed logins from 203.0.113.77 (TEST-NET-3) in a test log
cpu-burnA niced busy loop on one CPU for 180 s
shell-publicbash with a TCP socket to www.example.com:443 that sends nothing
From the repository
# all scenarios, detached (~4 min)scripts/simulate/simulate.sh# only the implant from this pagescripts/simulate/simulate.sh --only kworker-implant# fully offline: skip the two public-network scenariosscripts/simulate/simulate.sh --skip curl-public,shell-public# remove every sentinel-sim-* object nowscripts/simulate/simulate.sh --cleanup

Put a sentinel on every Linux server.

One command to install, one dashboard to monitor, one workspace to understand what happened across your fleet.