forked from ElementsProject/lightning
-
Notifications
You must be signed in to change notification settings - Fork 2
Sign funding psbt #13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
e1d85a1
to
64a9898
Compare
* Converted debug logging to json format. * Switched status_debug to STATUS_DEBUG macro.
64a9898
to
307d70a
Compare
ksedgwic
added a commit
that referenced
this pull request
May 2, 2021
* Converted debug logging to json format. * Switched status_debug to STATUS_DEBUG macro.
ksedgwic
added a commit
that referenced
this pull request
May 2, 2021
Changed "warmstart" to "coldstart" (inverted semantic). Modified all satoshi variable names to have "_sat" suffixes. Removed deprecated Phase 1 fields. Added push_value to hsm_ready_channel. Added sanity checking to hsm_ready_channel stub. Fixed issues w/ rebase onto upstream/master. Replaced tx->input_amounts and tx->output_witscripts with tx->psbt. Fixed redeemscript confusion. (#11) Fix remote-hsmd CI (#12) * adding g++, protobuf, grpc++ * add libgrpc++-dev to .travis.yml * wget remotesigner.proto * added libprotobuf-dev * fixed compilation warnings/errors * use Get instead of [] in protobuf seq * fixed include sort order * added protobuf generated files to skip nogen checks * fixed gensrc pattern * added libstdc++6 * fixed python spacing * added specified inclusion guards * renamed c++ header extensions to hpp to avoid c checks * guard satoshi amount calculations * libstdc++-6-dev * added `ln -s /usr/lib/x86_64-linux-gnu/libstdc++.so.6 /usr/lib/x86_64-linux-gnu/libstdc++.so` Enable handle_sign_withdrawal_tx signing of PSBT. (#13) * Converted debug logging to json format. * Switched status_debug to STATUS_DEBUG macro. Skip two integration tests which mutate channel_nonce. fixed nit w/ run-one-test Added NodeConfig::NATIVE to InitReq. (#14) Converted remotesigner.PubKey from 64 byte raw to 33 byte compressed DER. (#15) Updated to channel_nonce0. (#17) Replaced option_static_remotekey w/ CommitmentType. (#18) * Replaced option_static_remotekey w/ CommitmentType. * Improved NOTES Upgraded SignFundingTxRequest KeyIndex to KeyPath. (#19) Adapted to CloseInfo moving into KeyLocator TxOut was replaced in API w/ it's only field. Adapted to remotesigner api-doc mods. Set input to 0 explicitly. SignCounterpartyHtlcToUs -> SignCounterpartyHtlcSweep SignJusticeTxToUs -> SignJusticeSweep SignDelayedPaymentToUs -> SignDelayedSweep (#20)
ksedgwic
added a commit
that referenced
this pull request
Jun 28, 2021
Changed "warmstart" to "coldstart" (inverted semantic). Modified all satoshi variable names to have "_sat" suffixes. Removed deprecated Phase 1 fields. Added push_value to hsm_ready_channel. Added sanity checking to hsm_ready_channel stub. Fixed issues w/ rebase onto upstream/master. Replaced tx->input_amounts and tx->output_witscripts with tx->psbt. Fixed redeemscript confusion. (#11) Fix remote-hsmd CI (#12) * adding g++, protobuf, grpc++ * add libgrpc++-dev to .travis.yml * wget remotesigner.proto * added libprotobuf-dev * fixed compilation warnings/errors * use Get instead of [] in protobuf seq * fixed include sort order * added protobuf generated files to skip nogen checks * fixed gensrc pattern * added libstdc++6 * fixed python spacing * added specified inclusion guards * renamed c++ header extensions to hpp to avoid c checks * guard satoshi amount calculations * libstdc++-6-dev * added `ln -s /usr/lib/x86_64-linux-gnu/libstdc++.so.6 /usr/lib/x86_64-linux-gnu/libstdc++.so` Enable handle_sign_withdrawal_tx signing of PSBT. (#13) * Converted debug logging to json format. * Switched status_debug to STATUS_DEBUG macro. Skip two integration tests which mutate channel_nonce. fixed nit w/ run-one-test Added NodeConfig::NATIVE to InitReq. (#14) Converted remotesigner.PubKey from 64 byte raw to 33 byte compressed DER. (#15) Updated to channel_nonce0. (#17) Replaced option_static_remotekey w/ CommitmentType. (#18) * Replaced option_static_remotekey w/ CommitmentType. * Improved NOTES Upgraded SignFundingTxRequest KeyIndex to KeyPath. (#19) Adapted to CloseInfo moving into KeyLocator TxOut was replaced in API w/ it's only field. Adapted to remotesigner api-doc mods. Set input to 0 explicitly. SignCounterpartyHtlcToUs -> SignCounterpartyHtlcSweep SignJusticeTxToUs -> SignJusticeSweep SignDelayedPaymentToUs -> SignDelayedSweep (#20)
ksedgwic
added a commit
that referenced
this pull request
Sep 8, 2021
Changed "warmstart" to "coldstart" (inverted semantic). Modified all satoshi variable names to have "_sat" suffixes. Removed deprecated Phase 1 fields. Added push_value to hsm_ready_channel. Added sanity checking to hsm_ready_channel stub. Fixed issues w/ rebase onto upstream/master. Replaced tx->input_amounts and tx->output_witscripts with tx->psbt. Fixed redeemscript confusion. (#11) Fix remote-hsmd CI (#12) * adding g++, protobuf, grpc++ * add libgrpc++-dev to .travis.yml * wget remotesigner.proto * added libprotobuf-dev * fixed compilation warnings/errors * use Get instead of [] in protobuf seq * fixed include sort order * added protobuf generated files to skip nogen checks * fixed gensrc pattern * added libstdc++6 * fixed python spacing * added specified inclusion guards * renamed c++ header extensions to hpp to avoid c checks * guard satoshi amount calculations * libstdc++-6-dev * added `ln -s /usr/lib/x86_64-linux-gnu/libstdc++.so.6 /usr/lib/x86_64-linux-gnu/libstdc++.so` Enable handle_sign_withdrawal_tx signing of PSBT. (#13) * Converted debug logging to json format. * Switched status_debug to STATUS_DEBUG macro. Skip two integration tests which mutate channel_nonce. fixed nit w/ run-one-test Added NodeConfig::NATIVE to InitReq. (#14) Converted remotesigner.PubKey from 64 byte raw to 33 byte compressed DER. (#15) Updated to channel_nonce0. (#17) Replaced option_static_remotekey w/ CommitmentType. (#18) * Replaced option_static_remotekey w/ CommitmentType. * Improved NOTES Upgraded SignFundingTxRequest KeyIndex to KeyPath. (#19) Adapted to CloseInfo moving into KeyLocator TxOut was replaced in API w/ it's only field. Adapted to remotesigner api-doc mods. Set input to 0 explicitly. SignCounterpartyHtlcToUs -> SignCounterpartyHtlcSweep SignJusticeTxToUs -> SignJusticeSweep SignDelayedPaymentToUs -> SignDelayedSweep (#20)
ksedgwic
added a commit
that referenced
this pull request
Oct 23, 2021
Changed "warmstart" to "coldstart" (inverted semantic). Modified all satoshi variable names to have "_sat" suffixes. Removed deprecated Phase 1 fields. Added push_value to hsm_ready_channel. Added sanity checking to hsm_ready_channel stub. Fixed issues w/ rebase onto upstream/master. Replaced tx->input_amounts and tx->output_witscripts with tx->psbt. Fixed redeemscript confusion. (#11) Fix remote-hsmd CI (#12) * adding g++, protobuf, grpc++ * add libgrpc++-dev to .travis.yml * wget remotesigner.proto * added libprotobuf-dev * fixed compilation warnings/errors * use Get instead of [] in protobuf seq * fixed include sort order * added protobuf generated files to skip nogen checks * fixed gensrc pattern * added libstdc++6 * fixed python spacing * added specified inclusion guards * renamed c++ header extensions to hpp to avoid c checks * guard satoshi amount calculations * libstdc++-6-dev * added `ln -s /usr/lib/x86_64-linux-gnu/libstdc++.so.6 /usr/lib/x86_64-linux-gnu/libstdc++.so` Enable handle_sign_withdrawal_tx signing of PSBT. (#13) * Converted debug logging to json format. * Switched status_debug to STATUS_DEBUG macro. Skip two integration tests which mutate channel_nonce. fixed nit w/ run-one-test Added NodeConfig::NATIVE to InitReq. (#14) Converted remotesigner.PubKey from 64 byte raw to 33 byte compressed DER. (#15) Updated to channel_nonce0. (#17) Replaced option_static_remotekey w/ CommitmentType. (#18) * Replaced option_static_remotekey w/ CommitmentType. * Improved NOTES Upgraded SignFundingTxRequest KeyIndex to KeyPath. (#19) Adapted to CloseInfo moving into KeyLocator TxOut was replaced in API w/ it's only field. Adapted to remotesigner api-doc mods. Set input to 0 explicitly. SignCounterpartyHtlcToUs -> SignCounterpartyHtlcSweep SignJusticeTxToUs -> SignJusticeSweep SignDelayedPaymentToUs -> SignDelayedSweep (#20)
ksedgwic
added a commit
that referenced
this pull request
Nov 30, 2021
Changed "warmstart" to "coldstart" (inverted semantic). Modified all satoshi variable names to have "_sat" suffixes. Removed deprecated Phase 1 fields. Added push_value to hsm_ready_channel. Added sanity checking to hsm_ready_channel stub. Fixed issues w/ rebase onto upstream/master. Replaced tx->input_amounts and tx->output_witscripts with tx->psbt. Fixed redeemscript confusion. (#11) Fix remote-hsmd CI (#12) * adding g++, protobuf, grpc++ * add libgrpc++-dev to .travis.yml * wget remotesigner.proto * added libprotobuf-dev * fixed compilation warnings/errors * use Get instead of [] in protobuf seq * fixed include sort order * added protobuf generated files to skip nogen checks * fixed gensrc pattern * added libstdc++6 * fixed python spacing * added specified inclusion guards * renamed c++ header extensions to hpp to avoid c checks * guard satoshi amount calculations * libstdc++-6-dev * added `ln -s /usr/lib/x86_64-linux-gnu/libstdc++.so.6 /usr/lib/x86_64-linux-gnu/libstdc++.so` Enable handle_sign_withdrawal_tx signing of PSBT. (#13) * Converted debug logging to json format. * Switched status_debug to STATUS_DEBUG macro. Skip two integration tests which mutate channel_nonce. fixed nit w/ run-one-test Added NodeConfig::NATIVE to InitReq. (#14) Converted remotesigner.PubKey from 64 byte raw to 33 byte compressed DER. (#15) Updated to channel_nonce0. (#17) Replaced option_static_remotekey w/ CommitmentType. (#18) * Replaced option_static_remotekey w/ CommitmentType. * Improved NOTES Upgraded SignFundingTxRequest KeyIndex to KeyPath. (#19) Adapted to CloseInfo moving into KeyLocator TxOut was replaced in API w/ it's only field. Adapted to remotesigner api-doc mods. Set input to 0 explicitly. SignCounterpartyHtlcToUs -> SignCounterpartyHtlcSweep SignJusticeTxToUs -> SignJusticeSweep SignDelayedPaymentToUs -> SignDelayedSweep (#20)
ksedgwic
added a commit
that referenced
this pull request
Dec 14, 2021
Changed "warmstart" to "coldstart" (inverted semantic). Modified all satoshi variable names to have "_sat" suffixes. Removed deprecated Phase 1 fields. Added push_value to hsm_ready_channel. Added sanity checking to hsm_ready_channel stub. Fixed issues w/ rebase onto upstream/master. Replaced tx->input_amounts and tx->output_witscripts with tx->psbt. Fixed redeemscript confusion. (#11) Fix remote-hsmd CI (#12) * adding g++, protobuf, grpc++ * add libgrpc++-dev to .travis.yml * wget remotesigner.proto * added libprotobuf-dev * fixed compilation warnings/errors * use Get instead of [] in protobuf seq * fixed include sort order * added protobuf generated files to skip nogen checks * fixed gensrc pattern * added libstdc++6 * fixed python spacing * added specified inclusion guards * renamed c++ header extensions to hpp to avoid c checks * guard satoshi amount calculations * libstdc++-6-dev * added `ln -s /usr/lib/x86_64-linux-gnu/libstdc++.so.6 /usr/lib/x86_64-linux-gnu/libstdc++.so` Enable handle_sign_withdrawal_tx signing of PSBT. (#13) * Converted debug logging to json format. * Switched status_debug to STATUS_DEBUG macro. Skip two integration tests which mutate channel_nonce. fixed nit w/ run-one-test Added NodeConfig::NATIVE to InitReq. (#14) Converted remotesigner.PubKey from 64 byte raw to 33 byte compressed DER. (#15) Updated to channel_nonce0. (#17) Replaced option_static_remotekey w/ CommitmentType. (#18) * Replaced option_static_remotekey w/ CommitmentType. * Improved NOTES Upgraded SignFundingTxRequest KeyIndex to KeyPath. (#19) Adapted to CloseInfo moving into KeyLocator TxOut was replaced in API w/ it's only field. Adapted to remotesigner api-doc mods. Set input to 0 explicitly. SignCounterpartyHtlcToUs -> SignCounterpartyHtlcSweep SignJusticeTxToUs -> SignJusticeSweep SignDelayedPaymentToUs -> SignDelayedSweep (#20)
ksedgwic
added a commit
that referenced
this pull request
Dec 14, 2021
Changed "warmstart" to "coldstart" (inverted semantic). Modified all satoshi variable names to have "_sat" suffixes. Removed deprecated Phase 1 fields. Added push_value to hsm_ready_channel. Added sanity checking to hsm_ready_channel stub. Fixed issues w/ rebase onto upstream/master. Replaced tx->input_amounts and tx->output_witscripts with tx->psbt. Fixed redeemscript confusion. (#11) Fix remote-hsmd CI (#12) * adding g++, protobuf, grpc++ * add libgrpc++-dev to .travis.yml * wget remotesigner.proto * added libprotobuf-dev * fixed compilation warnings/errors * use Get instead of [] in protobuf seq * fixed include sort order * added protobuf generated files to skip nogen checks * fixed gensrc pattern * added libstdc++6 * fixed python spacing * added specified inclusion guards * renamed c++ header extensions to hpp to avoid c checks * guard satoshi amount calculations * libstdc++-6-dev * added `ln -s /usr/lib/x86_64-linux-gnu/libstdc++.so.6 /usr/lib/x86_64-linux-gnu/libstdc++.so` Enable handle_sign_withdrawal_tx signing of PSBT. (#13) * Converted debug logging to json format. * Switched status_debug to STATUS_DEBUG macro. Skip two integration tests which mutate channel_nonce. fixed nit w/ run-one-test Added NodeConfig::NATIVE to InitReq. (#14) Converted remotesigner.PubKey from 64 byte raw to 33 byte compressed DER. (#15) Updated to channel_nonce0. (#17) Replaced option_static_remotekey w/ CommitmentType. (#18) * Replaced option_static_remotekey w/ CommitmentType. * Improved NOTES Upgraded SignFundingTxRequest KeyIndex to KeyPath. (#19) Adapted to CloseInfo moving into KeyLocator TxOut was replaced in API w/ it's only field. Adapted to remotesigner api-doc mods. Set input to 0 explicitly. SignCounterpartyHtlcToUs -> SignCounterpartyHtlcSweep SignJusticeTxToUs -> SignJusticeSweep SignDelayedPaymentToUs -> SignDelayedSweep (#20)
ksedgwic
pushed a commit
that referenced
this pull request
Mar 3, 2023
This will fix a crash that I caused on armv7 and by looking inside the coredump with gdb (by adding an assert on n that must be different from null) I get the following stacktrace ``` (gdb) bt \#0 0x00000000 in ?? () \#1 0x0043a038 in send_backtrace (why=0xbe9e3600 "FATAL SIGNAL 11") at common/daemon.c:36 \#2 0x0043a0ec in crashdump (sig=11) at common/daemon.c:46 \#3 <signal handler called> \#4 0x00406d04 in node_announcement (map=0x938ecc, nann_off=495146) at common/gossmap.c:586 \#5 0x00406fec in map_catchup (map=0x938ecc, num_rejected=0xbe9e3a40) at common/gossmap.c:643 \#6 0x004073a4 in load_gossip_store (map=0x938ecc, num_rejected=0xbe9e3a40) at common/gossmap.c:697 \#7 0x00408244 in gossmap_load (ctx=0x0, filename=0x4e16b8 "gossip_store", num_channel_updates_rejected=0xbe9e3a40) at common/gossmap.c:976 \#8 0x0041a548 in init (p=0x93831c, buf=0x9399d4 "\n\n{\"jsonrpc\":\"2.0\",\"id\":\"cln:init#25\",\"method\":\"init\",\"params\":{\"options\":{},\"configuration\":{\"lightning-dir\":\"/home/vincent/.lightning/testnet\",\"rpc-file\":\"lightning-rpc\",\"startup\":true,\"network\":\"te"..., config=0x939cdc) at plugins/topology.c:622 \#9 0x0041e5d0 in handle_init (cmd=0x938934, buf=0x9399d4 "\n\n{\"jsonrpc\":\"2.0\",\"id\":\"cln:init#25\",\"method\":\"init\",\"params\":{\"options\":{},\"configuration\":{\"lightning-dir\":\"/home/vincent/.lightning/testnet\",\"rpc-file\":\"lightning-rpc\",\"startup\":true,\"network\":\"te"..., params=0x939c8c) at plugins/libplugin.c:1208 \#10 0x0041fc04 in ld_command_handle (plugin=0x93831c, toks=0x939bec) at plugins/libplugin.c:1572 \#11 0x00420050 in ld_read_json_one (plugin=0x93831c) at plugins/libplugin.c:1667 \#12 0x004201bc in ld_read_json (conn=0x9391c4, plugin=0x93831c) at plugins/libplugin.c:1687 \#13 0x004cb82c in next_plan (conn=0x9391c4, plan=0x9391d8) at ccan/ccan/io/io.c:59 \#14 0x004cc67c in do_plan (conn=0x9391c4, plan=0x9391d8, idle_on_epipe=false) at ccan/ccan/io/io.c:407 \#15 0x004cc6dc in io_ready (conn=0x9391c4, pollflags=1) at ccan/ccan/io/io.c:417 \#16 0x004cf8cc in io_loop (timers=0x9383c4, expired=0xbe9e3ce4) at ccan/ccan/io/poll.c:453 \#17 0x00420af4 in plugin_main (argv=0xbe9e3eb4, init=0x41a46c <init>, restartability=PLUGIN_STATIC, init_rpc=true, features=0x0, commands=0x6167e8 <commands>, num_commands=4, notif_subs=0x0, num_notif_subs=0, hook_subs=0x0, num_hook_subs=0, notif_topics=0x0, num_notif_topics=0) at plugins/libplugin.c:1891 \#18 0x0041a6f8 in main (argc=1, argv=0xbe9e3eb4) at plugins/topology.c:679 ``` I do not know if this is a solution because I do not know when I can parse a node announcement for a node that it is not longer in the gossip map. So, I hope this is just usefult for @rustyrussell Changelog-Fixed: fixes `FATAL SIGNAL 11` on gossmap node announcement parsing. Signed-off-by: Vincenzo Palazzo <[email protected]>
ksedgwic
pushed a commit
that referenced
this pull request
Apr 21, 2023
pubkey_from_hexstr() was failing, which we didn't notice because we weren't checking the return value. The problem was that we were passing it a strlen that was half the actual length. Relevant error: [libsecp256k1] illegal argument: !secp256k1_fe_is_zero(&ge->x) ==417723== ERROR: libFuzzer: deadly signal #7 0x7f5deaacc7fb in abort #8 0x51b0b0 in secp256k1_default_illegal_callback_fn secp256k1.c #9 0x51bd8e in secp256k1_ec_pubkey_serialize #10 0x4e235b in pubkey_to_der bitcoin/pubkey.c:29:7 #11 0x4e2941 in pubkey_cmp bitcoin/pubkey.c:89:2 #12 0x4e333d in bitcoin_redeem_2of2 bitcoin/script.c:144:6 #13 0x4f1396 in run tests/fuzz/fuzz-close_tx.c:78:19
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR completes a rebase of
remote-hsmd
ontoupstream/master
.The interface to
handle_sign_withdrawal_tx
changed, had to modify to support PSBT.