pub fn verify_signed(env: &SignedRoomMessage) -> Result<(RoomMessage, String)>Expand description
Verify a SignedRoomMessage envelope:
- The asserted
fingerprintmust equal the fingerprint derived fromed25519_pubkey_b64— closes the “claim someone else’s fingerprint but sign with your own key” attack. - The Ed25519 signature must
verify_strictover the decodedpayload_b64(strict rejects low-order / mixed-order pubkeys). - The payload must deserialize as a
RoomMessage. - huddle 0.7.11:
signed_at_msmust be non-zero and withinSIGNED_ENVELOPE_WINDOW_MSof the receiver’s wall clock — closes indefinite replay of captured signed messages.
Returns the inner message and the (verified) sender fingerprint on
success. Caller should still check that the fingerprint is one they
expect for this context (e.g. an owner for BanMember).