nx_lysis.nx
buildroot/runtime/nx_lysis.nx
about
nx_lysis.nx -- selective foreign-entity neutralization.
Per [[feedback-unified-immune-architecture-three-tier]] item 3:
the user's specific question: "take how would you combat and
deactivate nano bots as if they were viruses or stuff like that,
would a giant magnet work or what is the equivalent that would
purge but not hurt the host think of the mechanisms of anti
parasites on things like ivermectin or whatever."
THE UNIVERSAL PRINCIPLE: selective targeting via host-threat
biochemical/physical/electromagnetic/structural differences.
Ivermectin works because parasite ion channels differ from
mammalian; magnetic-particle hyperthermia works because
ferromagnetic threats heat in alternating fields while diamagnetic
tissue does not; chelation works because EDTA binds heavy metals
preferentially.
SOFTWARE SUBSTRATE EQUIVALENT: neutralize the foreign entity by
exploiting a difference between FOREIGN and HOST that the host can
tolerate. We have several such differences available -- foreign
processes lack the substrate's capability tokens, foreign memory
pages lack the chromatin chain, foreign egress targets aren't on
the substrate's allowlist. Each difference = an attack vector
against the foreign entity that costs the host nothing.
Mechanism catalog shipped V1 (each = one host-tolerant difference
the substrate can exploit):
CAPABILITY_REVOKE -- drop the brane capability tokens; foreign
loses access without affecting self
MEMORY_ZERO -- overwrite foreign memory region with zeros
(caller has already isolated the region)
NETWORK_BLACKHOLE -- route foreign egress to /dev/null; host
egress on other interfaces unaffected
PROCESS_PAUSE -- SIGSTOP foreign process (reversible; gathers
evidence while frozen)
PROCESS_TERMINATE -- SIGKILL foreign process (irreversible)
QUARANTINE -- isolate-but-preserve (no kill, no read,
operator review gates next step)
CRYPTO_REKEY -- rotate the substrate's master keys; any
foreign cached credentials become useless
dependencies 5 imports · 4 importers
imports: nx_syscalls.nxnx_tier.nxnx_budget.nxnx_attention_class.nxnx_evict_journal.nx
imported by: nx_immune.nxnx_lysis_test.nxnx_tier1_immune_compose_test.nxnx_tier2_immune_compose_test.nx
structs
| 138 | struct NxLysisAction |
consts
| 103 | const NX_LYSIS_NONE: nx_int = 0 |
| 104 | const NX_LYSIS_CAPABILITY_REVOKE: nx_int = 1 |
| 105 | const NX_LYSIS_MEMORY_ZERO: nx_int = 2 |
| 106 | const NX_LYSIS_NETWORK_BLACKHOLE: nx_int = 3 |
| 107 | const NX_LYSIS_PROCESS_PAUSE: nx_int = 4 |
| 108 | const NX_LYSIS_PROCESS_TERMINATE: nx_int = 5 |
| 109 | const NX_LYSIS_QUARANTINE: nx_int = 6 |
| 110 | const NX_LYSIS_CRYPTO_REKEY: nx_int = 7 |
| 111 | const NX_LYSIS_PEER_MESH_EVICT: nx_int = 8 |
| 112 | const NX_LYSIS_DECOY_PROMOTE: nx_int = 9 |
| 113 | const NX_LYSIS_N_MECHANISMS: nx_int = 10 |
| 119 | const NX_LYSIS_SEV_LOW: nx_int = 0 // suspect; quarantine + observe |
| 120 | const NX_LYSIS_SEV_MED: nx_int = 1 // confirmed probing; revoke caps |
| 121 | const NX_LYSIS_SEV_HIGH: nx_int = 2 // active compromise; pause/kill |
| 122 | const NX_LYSIS_N_SEVS: nx_int = 3 |
| 126 | const NX_LYSIS_OK: nx_int = 0 |
| 127 | const NX_LYSIS_ERR_BAD_MECHANISM: nx_int = 1 |
| 128 | const NX_LYSIS_ERR_BAD_SEVERITY: nx_int = 2 |
| 129 | const NX_LYSIS_ERR_HOST_INTOLERANT: nx_int = 3 // mechanism would harm host |
| 130 | const NX_LYSIS_ERR_OPERATOR_GATED: nx_int = 4 // requires twin-key |
functions
| 149 | func nx_lysis_mechanism_is_valid(m: nx_int) -> nx_int |
| 155 | func nx_lysis_severity_is_valid(s: nx_int) -> nx_int |
| 167 | func nx_lysis_is_reversible(m: nx_int) -> nx_int |
| 183 | func nx_lysis_is_host_tolerant(m: nx_int) -> nx_int |
| 203 | func nx_lysis_requires_operator(m: nx_int) -> nx_int |
| 225 | func nx_lysis_select(severity: nx_int, |
| 260 | func nx_lysis_emit(target_id: nx_int, |
| 285 | func nx_lysis_log(action: *NxLysisAction, |