mirror of
https://github.com/serai-dex/serai.git
synced 2025-12-08 12:19:24 +00:00
monero: match monero's stricter check when decompressing points (#515)
* monero: match monero's stricter check when decompressing points * Reverted type change for output key
This commit is contained in:
@@ -283,7 +283,7 @@ impl Wallet {
|
||||
}
|
||||
|
||||
Wallet::Monero { handle, ref spend_key, ref view_pair, ref mut inputs } => {
|
||||
use curve25519_dalek::{constants::ED25519_BASEPOINT_POINT, edwards::CompressedEdwardsY};
|
||||
use curve25519_dalek::constants::ED25519_BASEPOINT_POINT;
|
||||
use monero_serai::{
|
||||
Protocol,
|
||||
wallet::{
|
||||
@@ -291,6 +291,7 @@ impl Wallet {
|
||||
SpendableOutput, Decoys, Change, FeePriority, Scanner, SignableTransaction,
|
||||
},
|
||||
rpc::HttpRpc,
|
||||
decompress_point,
|
||||
};
|
||||
use processor::{additional_key, networks::Monero};
|
||||
|
||||
@@ -317,8 +318,7 @@ impl Wallet {
|
||||
.await
|
||||
.unwrap();
|
||||
|
||||
let to_spend_key =
|
||||
CompressedEdwardsY(<[u8; 32]>::try_from(to.as_ref()).unwrap()).decompress().unwrap();
|
||||
let to_spend_key = decompress_point(<[u8; 32]>::try_from(to.as_ref()).unwrap()).unwrap();
|
||||
let to_view_key = additional_key::<Monero>(0);
|
||||
let to_addr = Address::new(
|
||||
AddressMeta::new(
|
||||
|
||||
Reference in New Issue
Block a user