Rust SDK API Reference / Record V1 codecs / check_sol_record
Function: check_sol_record()
pub fn check_sol_record(record: &[u8], signed_record: &[u8], pubkey: Pubkey) -> Result<bool, SnsError>
Defined in: record_v1.rs:11
Verifies an Ed25519 signature over record with pubkey.
Parameters
record is signed content, signed_record is its signature bytes, and pubkey is the verifying public key.
Returns
true for a valid signature and false for a mismatch. Invalid key or signature encodings return SnsError.
Example
use sns_sdk::record::record_v1::check_sol_record;
let valid = check_sol_record(record, signature, pubkey)?;