mirror of
https://github.com/ElementsProject/lightning.git
synced 2024-11-19 01:43:36 +01:00
BOLTs: more catchup ("BOLT 4: More clarifying changes.")
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
76cfff7533
commit
905461f7c4
2
Makefile
2
Makefile
@ -26,7 +26,7 @@ CCANDIR := ccan
|
||||
|
||||
# Where we keep the BOLT RFCs
|
||||
BOLTDIR := ../bolts/
|
||||
DEFAULT_BOLTVERSION := 6654c5711a2765f48a31389064c04a153670d73b
|
||||
DEFAULT_BOLTVERSION := 22b9c874531f67ec66975dcd9f7ec42ced012933
|
||||
# Can be overridden on cmdline.
|
||||
BOLTVERSION := $(DEFAULT_BOLTVERSION)
|
||||
|
||||
|
@ -243,7 +243,7 @@ void blindedpath_next_path_key(const struct tlv_encrypted_data_tlv *enc,
|
||||
/* BOLT #4:
|
||||
* - $`E_{i+1} = SHA256(E_i || ss_i) * E_i`$
|
||||
* ...
|
||||
* - If `encrypted_data` contains a `next_path_key_override`:
|
||||
* - If the `encrypted_data_tlv` contains a `next_path_key_override`:
|
||||
* - MUST use it as the next `path_key`.
|
||||
* - Otherwise:
|
||||
* - MUST use $`E_{i+1} = SHA256(E_i || ss_i) * E_i`$ as the next `path_key`
|
||||
|
@ -204,7 +204,7 @@ int main(int argc, char *argv[])
|
||||
struct pubkey alias, expected_alias;
|
||||
|
||||
assert(json_to_secret(json,
|
||||
json_get_member(json, t, "ephemeral_privkey"),
|
||||
json_get_member(json, t, "path_privkey"),
|
||||
&s));
|
||||
|
||||
/* First blinding/replacement is stated, remainder are
|
||||
@ -217,7 +217,7 @@ int main(int argc, char *argv[])
|
||||
assert(secret_eq_consttime(&path_key.secret, &s));
|
||||
|
||||
assert(pubkey_from_privkey(&path_key, &pubkey));
|
||||
json_to_pubkey(json, json_get_member(json, t, "ephemeral_pubkey"),
|
||||
json_to_pubkey(json, json_get_member(json, t, "path_key"),
|
||||
&expected_pubkey);
|
||||
assert(pubkey_eq(&pubkey, &expected_pubkey));
|
||||
|
||||
|
@ -9,7 +9,7 @@ tlvtype,payload,payment_data,8
|
||||
tlvdata,payload,payment_data,payment_secret,byte,32
|
||||
tlvdata,payload,payment_data,total_msat,tu64,
|
||||
tlvtype,payload,encrypted_recipient_data,10
|
||||
tlvdata,payload,encrypted_recipient_data,encrypted_data,byte,...
|
||||
tlvdata,payload,encrypted_recipient_data,encrypted_recipient_data,byte,...
|
||||
tlvtype,payload,current_path_key,12
|
||||
tlvdata,payload,current_path_key,path_key,point,
|
||||
tlvtype,payload,payment_metadata,16
|
||||
|
|
Loading…
Reference in New Issue
Block a user