From 2ae715f899be50fa6e266f99a1b866d5817dc9ea Mon Sep 17 00:00:00 2001 From: Luke Parker Date: Wed, 1 Jun 2022 17:14:57 -0400 Subject: [PATCH] Ignore transactions which use a timelock --- coins/monero/src/wallet/scan.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/coins/monero/src/wallet/scan.rs b/coins/monero/src/wallet/scan.rs index df5d1d6f..644a3a73 100644 --- a/coins/monero/src/wallet/scan.rs +++ b/coins/monero/src/wallet/scan.rs @@ -58,6 +58,12 @@ impl Transaction { view: Scalar, spend: EdwardsPoint ) -> Vec { + // Ignore transactions which utilize a timelock. Almost no transactions on Monero do, + // and they're not worth the effort to track given their complexities + if self.prefix.unlock_time != 0 { + return vec![]; + } + let mut extra = vec![]; write_varint(&u64::try_from(self.prefix.extra.len()).unwrap(), &mut extra).unwrap(); extra.extend(&self.prefix.extra);