diff --git a/boringtun/src/device/api.rs b/boringtun/src/device/api.rs index 0486de68..22cf63f7 100644 --- a/boringtun/src/device/api.rs +++ b/boringtun/src/device/api.rs @@ -157,6 +157,8 @@ impl Device { fn api_get(writer: &mut BufWriter<&UnixStream>, d: &Device) -> i32 { // get command requires an empty line, but there is no reason to be religious about it if let Some(ref k) = d.key_pair { + writeln!(writer, "private_key={}", encode_hex(k.0.as_bytes())); + // Is this even needed? This seems like a custom extension in boringtun writeln!(writer, "own_public_key={}", encode_hex(k.1.as_bytes())); }