code wiki / (root) / nx_md5.nx

nx_md5.nx

buildroot/runtime/nx_md5.nx

9362 B246 linesdepth 3pulls 3 transitivereach 1 importersview sourcekind tooltopic md5
docsdependenciesstructsconstsfunctions

about

nx_md5.nx -- MD5 message digest (RFC 1321). MD5 is cryptographically broken (collisions) but still used for: - Legacy file checksums (md5sum verification) - Apache .htdigest auth files (which we may need to interop) - ETag generation (when collision resistance isn't needed) - Cache keys for systems that hardcode 16-byte digests DO NOT use MD5 for passwords, signatures, or anything where an attacker controls the input. Use SHA-256 (already in tree) + HMAC. Algorithm: 64-round MD-construction with 4-word state, processing 64-byte blocks. Returns 16-byte digest.

dependencies 1 imports · 1 importers

syscalls.nx nx_md5.nx nx_tls13_chrome_hello_gate.nx

imports: syscalls.nx

imported by: nx_tls13_chrome_hello_gate.nx

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main nx_md5 nx_md5_block nx_md5_load_u32 nx_md5_FF nx_md5_F nx_md5_rotl nx_md5_GG nx_md5_G nx_md5_rotl ↻ nx_md5_HH nx_md5_H nx_md5_rotl ↻ nx_md5_II nx_md5_I nx_md5_rotl ↻

structs

none

consts

none

functions

25func nx_md5_rotl(x: i64, k: i64) -> i64
33func nx_md5_F(x: i64, y: i64, z: i64) -> i64 { return ((x & y) | ((~x) & z)) & 0xFFFFFFFF }
called by 1: nx_md5_FF
34func nx_md5_G(x: i64, y: i64, z: i64) -> i64 { return ((x & z) | (y & (~z))) & 0xFFFFFFFF }
called by 1: nx_md5_GG
35func nx_md5_H(x: i64, y: i64, z: i64) -> i64 { return (x ^ y ^ z) & 0xFFFFFFFF }
called by 1: nx_md5_HH
36func nx_md5_I(x: i64, y: i64, z: i64) -> i64 { return (y ^ (x | (~z))) & 0xFFFFFFFF }
called by 1: nx_md5_II
39func nx_md5_FF(a: i64, b: i64, c: i64, d: i64, m: i64, s: i64, t: i64) -> i64
called by 1: nx_md5_block calls 2: nx_md5_Fnx_md5_rotl
43func nx_md5_GG(a: i64, b: i64, c: i64, d: i64, m: i64, s: i64, t: i64) -> i64
called by 1: nx_md5_block calls 2: nx_md5_Gnx_md5_rotl
47func nx_md5_HH(a: i64, b: i64, c: i64, d: i64, m: i64, s: i64, t: i64) -> i64
called by 1: nx_md5_block calls 2: nx_md5_Hnx_md5_rotl
51func nx_md5_II(a: i64, b: i64, c: i64, d: i64, m: i64, s: i64, t: i64) -> i64
called by 1: nx_md5_block calls 2: nx_md5_Inx_md5_rotl
57func nx_md5_load_u32(p: *u8) -> i64
called by 1: nx_md5_block
65func nx_md5_block(state: *i64, blk: *u8) -> i64
161func nx_md5(data: *u8, n: i64, digest: *u8) -> i64
called by 2: mainmain calls 1: nx_md5_block
227func main() -> i64
calls 1: nx_md5