pub fn hex_dump(data: &[u8], max_bytes: usize) -> String
Format a byte slice as a hex dump suitable for debug logging.