code wiki / _hdl_build / nx_email_provision_lib.nx
nx_email_provision_lib.nx
buildroot/runtime/_hdl_build/nx_email_provision_lib.nx
about
nx_email_provision_lib.nx -- DATA-DRIVEN per-domain EMAIL provisioning (operator: finish andelinwest email, and
"not just andelinwest but all our sites"). Generalizes the jasonewest DNS-gate fixture into a reusable provisioner
keyed by domain: generate (or REUSE) the domain's ed25519 DKIM keypair, derive the public key, emit the publishable
DNS zone (MX/SPF/DKIM/DMARC via the proven nx_dns_zone), and persist artifacts under knowledge/status/<domain>_*.
IDEMPOTENT (Rule 10): if a private key already exists for the domain it is REUSED, so a previously published DKIM
pubkey stays valid across re-provisioning. The same keypair signs outbound (nx_email_send) and the same domain
string drives the receiving MTA's own-domain accept (nx_email_mta). Composes nx_email_dns + ed25519 + base64.
license_tier: ORIGINAL
dependencies 5 imports · 2 importers
imports: nx_email_dns.nxnx_email_auth.nxnx_csprng.nxnx_base64.nxnx_syscalls.nx
imported by: nx_email_provision.nxnx_email_provision_gate.nx
structs
| none |
consts
| none |
functions
| 15 | func ep_slen(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } return n } |
| 16 | func ep_cat(out: *u8, o: i64, s: *u8) -> i64 { var i: i64 = 0; while s[i] != (0 as u8) { out[o] = s[i]; o = o + 1; i = i + 1 } return o } |
| 19 | func ep_path(domain: *u8, suffix: *u8, out: *u8) -> i64 |
| 25 | func ep_write(path: *u8, buf: *u8, n: i64, mode: i64) -> i64 |
| 34 | func ep_load_priv(domain: *u8, priv32: *u8) -> i64 |
| 43 | func ep_hexbyte(out: *u8, oi: i64, b: i64) -> i64 called by 1: ep_provision |
| 55 | func ep_provision(domain: *u8, host: *u8, ip: *u8, selector: *u8, priv32: *u8, pub32: *u8, zoneout: *u8, zonecap: i64) -> i64 called by 2: mainmain calls 10: ep_load_privnx_csprng_filled25519_pub_from_privsys_mmapb64_encodenx_dns_zone+4 |