Skip to content

Commit 7d7d7bd

Browse files
committed
fixed host information deserialisation
1 parent f166892 commit 7d7d7bd

File tree

1 file changed

+9
-0
lines changed
  • nym-node/nym-node-requests/src/api/v1/node

1 file changed

+9
-0
lines changed

nym-node/nym-node-requests/src/api/v1/node/models.rs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,11 +128,13 @@ pub struct HostKeys {
128128
/// Base58-encoded ed25519 public key of this node. Currently, it corresponds to either mixnode's or gateway's identity.
129129
#[schemars(with = "String")]
130130
#[cfg_attr(feature = "openapi", schema(value_type = String))]
131+
#[serde(with = "bs58_ed25519_pubkey")]
131132
pub ed25519_identity: ed25519::PublicKey,
132133

133134
#[deprecated(note = "use explicit primary_x25519_sphinx_key instead")]
134135
#[schemars(with = "String")]
135136
#[cfg_attr(feature = "openapi", schema(value_type = String))]
137+
#[serde(with = "bs58_x25519_pubkey")]
136138
pub x25519_sphinx: x25519::PublicKey,
137139

138140
/// Current, active, x25519 sphinx key clients are expected to use when constructing packets
@@ -413,4 +415,11 @@ mod tests {
413415
let res = serde_json::from_str::<SignedHostInformation>(legacy_raw);
414416
assert!(res.is_ok());
415417
}
418+
419+
#[test]
420+
fn current_host_information_deserialisation_and_verification() {
421+
let current_raw = r#"
422+
423+
"#;
424+
}
416425
}

0 commit comments

Comments
 (0)