projects
/
rust-lightning
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Added tests to check the bolt 2 specs for Sending Node Channel
[rust-lightning]
/
src
/
ln
/
msgs.rs
diff --git
a/src/ln/msgs.rs
b/src/ln/msgs.rs
index 4c6524afbe62aa04cb9bda89d937578c4fbc19f4..62c4bb0d288512605a7a9487658fe52c4cfa9927 100644
(file)
--- a/
src/ln/msgs.rs
+++ b/
src/ln/msgs.rs
@@
-16,7
+16,7
@@
//! track the network on the less-secure system.
use secp256k1::key::PublicKey;
//! track the network on the less-secure system.
use secp256k1::key::PublicKey;
-use secp256k1::
{Secp256k1, Signature}
;
+use secp256k1::
Signature
;
use secp256k1;
use bitcoin::util::hash::Sha256dHash;
use bitcoin::blockdata::script::Script;
use secp256k1;
use bitcoin::util::hash::Sha256dHash;
use bitcoin::blockdata::script::Script;
@@
-1024,7
+1024,7
@@
impl<R: Read> Readable<R> for OnionPacket {
public_key: {
let mut buf = [0u8;33];
r.read_exact(&mut buf)?;
public_key: {
let mut buf = [0u8;33];
r.read_exact(&mut buf)?;
- PublicKey::from_slice(&
Secp256k1::without_caps(), &
buf)
+ PublicKey::from_slice(&buf)
},
hop_data: Readable::read(r)?,
hmac: Readable::read(r)?,
},
hop_data: Readable::read(r)?,
hmac: Readable::read(r)?,
@@
-1407,7
+1407,7
@@
mod tests {
fn encoding_channel_reestablish_with_secret() {
let public_key = {
let secp_ctx = Secp256k1::new();
fn encoding_channel_reestablish_with_secret() {
let public_key = {
let secp_ctx = Secp256k1::new();
- PublicKey::from_secret_key(&secp_ctx, &SecretKey::from_slice(&
secp_ctx, &
hex::decode("0101010101010101010101010101010101010101010101010101010101010101").unwrap()[..]).unwrap())
+ PublicKey::from_secret_key(&secp_ctx, &SecretKey::from_slice(&hex::decode("0101010101010101010101010101010101010101010101010101010101010101").unwrap()[..]).unwrap())
};
let cr = msgs::ChannelReestablish {
};
let cr = msgs::ChannelReestablish {