MCPcopy Create free account
hub / github.com/NodeDB-Lab/nodedb / hex_encode

Function hex_encode

nodedb/src/control/security/auth_apikey.rs:334–336  ·  view source on GitHub ↗

Hex-encode a byte slice (lowercase).

(bytes: &[u8])

Source from the content-addressed store, hash-verified

332
333/// Hex-encode a byte slice (lowercase).
334fn hex_encode(bytes: &[u8]) -> String {
335 bytes.iter().map(|b| format!("{b:02x}")).collect()
336}
337
338#[cfg(test)]
339mod tests {

Callers 2

create_key_innerMethod · 0.70
verifyMethod · 0.70

Calls 2

collectMethod · 0.80
iterMethod · 0.45

Tested by

no test coverage detected