In-placedeceptionconversion

At threshold, swap the reachable world beneath a live session without touching the session.

This is the mechanism the whole system exists for. When risk crosses T, three ordered steps run against the container that is already there, all from outside it: detach every network it is on, attach deception_net and imds_net, then verify. Nothing runs inside the container to make isolation hold, because the attacker has root there and could undo it.

The session is on none of those networks. SSH reaches the shell through the Docker API and HTTP enters through a helper sharing the container's network namespace, which is why the session on the attacker's screen does not drop, stutter, or reconnect. PIDs, the process tree, cwd, shell history, environment variables, files they dropped, uptime and /proc all continue because it is the same container. The command that crosses T is held for the moment the swap takes, then runs against the new world.

The order fails closed. After the first step the session can reach nothing, so if attaching or verification fails it stays cut off, shown as QUARANTINED, while the conversion is retried. It is never handed back to the real backend, and a session that can't even be detached is terminated.

The alternative, relocating the session to a separate honeypot, was considered and rejected. Relocation leaves fingerprints: a fresh process tree, a reset uptime, a different disk identity, missing history, missing dropped files. Any one of them tells the attacker the environment changed. Continuity is the deception.

Takes
  • Threshold crossing from L2
  • Session case from L3
Emits
  • Every network detached
  • deception_net and imds_net attached
  • Isolation verified
  • DECEPTION, or QUARANTINED while it can't be completed

Rules this layer holds to

Each of these is written down because relaxing it would be locally convenient and globally wrong.

Every network is detached before any deception network is attached.
Every network a session can be on is internal: no route to the internet or the host, before or after conversion.
A session is DECEPTION only once its attachments and its lack of a route out are verified.
A failed conversion leaves the session cut off, never back on the real backend.
Conversion is a state transition, not a scoring event: risk_before and risk_after are equal.
Where this is uncertain

Conversion can take the network away, not what the session has already read. Credentials baked into the sandbox image, or read before T, stay with the attacker, so real credentials should never be placed there. The swap is also visible to root inside: the interfaces change. And no route out is not a preference: letting a deception environment pivot to a third party would create real legal liability, which is why no sandbox network has one even before conversion.