fn convert_public_key(public_key: &[u8]) -> [u8; 32] {
    assert_eq!(public_key.len(), 32);
    let ed_y = Fe::from_bytes(&public_key);
    // Produce public key in Montgomery form.
    let mont_x = edwards_to_montgomery_x(ed_y);
    return mont_x.to_bytes();
}
/// Converts public key from edwards format to montgomery to use for crypto_box
Converts public key from edwards format to montgomery to use for crypto_box
Converts public key from edwards format to montgomery to use for crypto_box
fn convert_public_key(public_key: &[u8]) -> [u8; 32] {
    assert_eq!(public_key.len(), 32);
    let ed_y = Fe::from_bytes(&public_key);
    // Produce public key in Montgomery form.
    let mont_x = edwards_to_montgomery_x(ed_y);
    return mont_x.to_bytes();
}
fn convert_public_key ( public_key : & [ u8 ] ) -> [ u8 ; 32 ] { assert_eq ! ( public_key len ( ) 32 ) ; let ed_y = Fe :: from_bytes ( & public_key ) ; // Produce public key in Montgomery form. let mont_x = edwards_to_montgomery_x ( ed_y ) ; return mont_x . to_bytes ( ) ; }
Converts public key from edwards format to montgomery to use for crypto_box
Converts public key from edwards format to montgomery to use for crypto_box
public_key
&[u8]
public_key
&[u8]