code wiki / _hdl_build / nx_vault_dynamic.nx

nx_vault_dynamic.nx

buildroot/runtime/_hdl_build/nx_vault_dynamic.nx

1749 B30 linesdepth 3pulls 3 transitivereach 2 importersview sourcekind librarytopic vault
docsdependenciesstructsconstsfunctions

about

nx_vault_dynamic.nx -- sovereign DYNAMIC SECRETS (HashiCorp Vault "dynamic secrets engines" gap from vault_capability_census.tsv). Instead of storing a long-lived credential, the vault GENERATES a fresh, short-lived credential on demand, bound to a LEASE (composes nx_vault_lease): it auto-expires and is revocable. Each issue yields a DISTINCT credential -> a leak is bounded to one short-lived cred, not the master. The generator is deterministic here (gate/replay); PRODUCTION pulls from the CSPRNG. ORIGINAL.

dependencies 2 imports · 2 importers

nx_vault_lease.nx nx_syscalls.nx nx_vault_dynamic.nx nx_vault_dynamic_test.nx nx_vault_suite_test.nx

imports: nx_vault_lease.nxnx_syscalls.nx

imported by: nx_vault_dynamic_test.nxnx_vault_suite_test.nx

structs

none

consts

8const K_MAGIC_7919: i64 = 7919
9const K_MAGIC_104729: i64 = 104729
10const K_MAGIC_2654435761: i64 = 2654435761
11const K_MAGIC_2246822519: i64 = 2246822519

functions

16func dyn_gen_cred(role: i64, counter: i64, seed: i64) -> i64
called by 2: mainmain
27func dyn_valid(now: i64, issued_at: i64, ttl: i64, revoked: i64) -> i64 { return lease_valid(now, issued_at, ttl, revoked) }
called by 1: main calls 1: lease_valid
30func dyn_remaining(now: i64, issued_at: i64, ttl: i64, revoked: i64) -> i64 { return lease_remaining(now, issued_at, ttl, revoked) }
called by 1: main calls 1: lease_remaining