mirror of
https://github.com/rustdesk/hbb_common.git
synced 2026-10-11 19:23:59 +00:00
KeyExchange: sign KxParams, a structure, in place of a fixed byte string
The server's second signature covered "rdkx-ver" || key || version, a layout that could take nothing more. It now covers KxParams, a message holding the key as it went out and the advertised version, so anything the server needs signed later is a field added to it, and a client that does not know a field parses past it, as with IdPk on the peer side. Field 3 keeps its number under the name signed_params. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019aokqJuhjvB3kijXtAg5Ns
This commit is contained in:
co-authored by
Claude Fable 5.1
parent
5194159858
commit
e74a188f4f
+10
-3
@@ -237,9 +237,16 @@ message KeyExchange {
|
||||
// From the server: the newest key exchange version it speaks. From the client: the version it
|
||||
// picked, the highest both speak. Absent, i.e. 0, is the original scheme.
|
||||
uint32 version = 2;
|
||||
// Server signature of "rdkx-ver" || on-wire ephemeral public key || little-endian uint32 version.
|
||||
// Bit 255 of the signed X25519 public key requires this field; legacy keys leave it clear.
|
||||
bytes signed_version = 3;
|
||||
// Server signature of KxParams. Bit 255 of the signed X25519 public key requires this field;
|
||||
// legacy keys leave it clear.
|
||||
bytes signed_params = 3;
|
||||
}
|
||||
|
||||
// Signed by the server beside its ephemeral public key: that key as it went out, so the signature
|
||||
// belongs to this exchange alone, and the newest key exchange version the server speaks.
|
||||
message KxParams {
|
||||
bytes pk = 1;
|
||||
uint32 version = 2;
|
||||
}
|
||||
|
||||
message HealthCheck {
|
||||
|
||||
Reference in New Issue
Block a user