Skip to content
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

lnd ignores update_fee on new connection? #3341

Open
rustyrussell opened this issue Dec 13, 2019 · 0 comments
Open

lnd ignores update_fee on new connection? #3341

rustyrussell opened this issue Dec 13, 2019 · 0 comments

Comments

@rustyrussell
Copy link
Contributor

I funded a channel with 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf (Zap Technologies) which seems to be an lnd node based on its features.

We create the commit tx at low feerate (1006):

0200000001d1051af7c4e2218cf21f1b450015148f134626cf4018fcc1580d898157dbc41501000000000e5f108001683f0f000000000016001456c9b57de7610ed4a7721cb5a7797e13ce53d9f47e5a5c20

All goes well, funding tx gets mined and we exchange funding_locked:

channeld-chan#17314: peer_in WIRE_FUNDING_LOCKED
channeld-chan#17314: peer_out WIRE_FUNDING_LOCKED

Then we immediately send update_fee (3767), followed by the signature on the updated tx:
0200000001d1051af7c4e2218cf21f1b450015148f134626cf4018fcc1580d898157dbc41501000000000e5f10800199370f000000000016001456c9b57de7610ed4a7721cb5a7797e13ce53d9f47f5a5c20

channeld-chan#17314: peer_out WIRE_UPDATE_FEE
channeld-chan#17314: peer_out WIRE_COMMITMENT_SIGNED

LND rejects it, using a tx with the old feerate:

0200000001d1051af7c4e2218cf21f1b450015148f134626cf4018fcc1580d898157dbc41501000000000e5f108001683f0f000000000016001456c9b57de7610ed4a7721cb5a7797e13ce53d9f47f5a5c20

Complete logs below:

2019-12-13T06:07:06.998Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-connectd: Connect OUT
2019-12-13T06:07:07.001Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-connectd: peer_out WIRE_INIT
2019-12-13T06:07:07.224Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-connectd: peer_in WIRE_INIT
2019-12-13T06:07:07.310Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-openingd-chan#17314: pid 17015, msgfd 56
2019-12-13T06:07:07.318Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-gossipd: seeker: disabling gossip
2019-12-13T06:07:09.746Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-openingd-chan#17314: Handed peer, entering loop
2019-12-13T06:07:09.871Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-openingd-chan#17314: peer_out WIRE_OPEN_CHANNEL
2019-12-13T06:07:09.979Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-openingd-chan#17314: peer_out WIRE_GOSSIP_TIMESTAMP_FILTER
2019-12-13T06:07:10.189Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-openingd-chan#17314: peer_in WIRE_ACCEPT_CHANNEL
2019-12-13T06:07:10.744Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-openingd-chan#17314: signature 3044022041cee74c0fddc333787570674b6848c8e75b463bd44d34557153062c5526b13d02204ea643e68ce5274c3f61f26ae3ebe7779783b43148cfb738ff16969c2d396de101 on tx 0200000001d1051af7c4e2218cf21f1b450015148f134626cf4018fcc1580d898157dbc41501000000000e5f108001683f0f000000000016001456c9b57de7610ed4a7721cb5a7797e13ce53d9f47e5a5c20 using key 037ad0224ed47a6891ddc89fb5040f45305bdb8aa550a159fb8ad2fc36e0b8ab5f
2019-12-13T06:07:10.751Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-openingd-chan#17314: peer_out WIRE_FUNDING_CREATED
2019-12-13T06:07:10.952Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-openingd-chan#17314: peer_in WIRE_FUNDING_SIGNED
2019-12-13T06:07:11.557Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: pid 17024, msgfd 57
2019-12-13T06:07:11.562Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-chan#17314: Waiting for funding confirmations
2019-12-13T06:07:14.427Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: init LOCAL: remote_per_commit = 021b19f371e5874c270cf8d9d20be6da75c95d850de73d2dd496d89eb2028cc929, old_remote_per_commit = 021b19f371e5874c270cf8d9d20be6da75c95d850de73d2dd496d89eb2028cc929 next_idx_local = 1 next_idx_remote = 1 revocations_received = 0 feerates { SENT_ADD_ACK_REVOCATION:1006 } range 253-37670
2019-12-13T06:07:14.437Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: option_static_remotekey = 1
2019-12-13T06:11:22.709Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: peer_in WIRE_FUNDING_LOCKED
2019-12-13T06:11:22.727Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-chan#17314: Got funding_locked
2019-12-13T06:12:34.521Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-chan#17314: Got depth change 0->1 for 15c4db5781890d58c1fc1840cf2646138f141500451b1ff28c21e2c4f71a05d1
2019-12-13T06:12:34.543Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-chan#17314: Funding tx 15c4db5781890d58c1fc1840cf2646138f141500451b1ff28c21e2c4f71a05d1 depth 1 of 1
2019-12-13T06:12:34.694Z INFO 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-chan#17314: State changed from CHANNELD_AWAITING_LOCKIN to CHANNELD_NORMAL
2019-12-13T06:12:34.900Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: funding_locked: sending commit index 1: 023ff1bb81d3f0a1f2c476887d61e576aa327e622dba95f19c6099f87209ba60df
2019-12-13T06:12:34.932Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: peer_out WIRE_FUNDING_LOCKED
2019-12-13T06:12:35.016Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: We need 12727sat at feerate 3767 for 0 untrimmed htlcs: we have 1000000000msat/1000000000msat
2019-12-13T06:12:35.021Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: Setting REMOTE feerate to 3767
2019-12-13T06:12:35.034Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: peer_out WIRE_UPDATE_FEE
2019-12-13T06:12:35.058Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: Trying commit
2019-12-13T06:12:35.078Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: Feerate: SENT_ADD_HTLC->SENT_ADD_COMMIT REMOTE now 3767
2019-12-13T06:12:35.851Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: Creating commit_sig signature 1 304402205a882df21bac4672ce9be922b7956c154a48a12e901931f05c95b28ab04f5f7c02201a9caddffbce2a0e2e5fea5a49de541d2758e94a6e4f457a5e82f57ffcd1614201 for tx 0200000001d1051af7c4e2218cf21f1b450015148f134626cf4018fcc1580d898157dbc41501000000000e5f10800199370f000000000016001456c9b57de7610ed4a7721cb5a7797e13ce53d9f47f5a5c20 wscript 52210315803cac8097608a4ee5c0d863615fad5e118bc0618700680d6fe5cf9ecbe90421037ad0224ed47a6891ddc89fb5040f45305bdb8aa550a159fb8ad2fc36e0b8ab5f52ae key 037ad0224ed47a6891ddc89fb5040f45305bdb8aa550a159fb8ad2fc36e0b8ab5f
2019-12-13T06:12:35.867Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: Telling master we're about to commit...
2019-12-13T06:12:36.133Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: Sending master 1020
2019-12-13T06:12:36.341Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: ... , awaiting 1120
2019-12-13T06:12:36.760Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: Nope, got 1027 instead
2019-12-13T06:12:36.792Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: Got it!
2019-12-13T06:12:36.833Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: Sending commit_sig with 0 htlc sigs
2019-12-13T06:12:36.863Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: peer_out WIRE_COMMITMENT_SIGNED
2019-12-13T06:12:36.896Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: Now dealing with deferred WIRE_CHANNEL_FEERATES
2019-12-13T06:12:36.995Z DEBUG 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-channeld-chan#17314: peer_in WIRE_ERROR
2019-12-13T06:12:37.052Z UNUSUAL 03634bda49c9c42afd876d8288802942c49e58fbec3844ff54b46143bfcb6cdfaf-chan#17314: Peer permanent failure in CHANNELD_NORMAL: channeld: received ERROR channel d1051af7c4e2218cf21f1b450015148f134626cf4018fcc1580d898157dbc414: rejected commitment: commit_height=1, invalid_commit_sig=304402205a882df21bac4672ce9be922b7956c154a48a12e901931f05c95b28ab04f5f7c02201a9caddffbce2a0e2e5fea5a49de541d2758e94a6e4f457a5e82f57ffcd16142, commit_tx=0200000001d1051af7c4e2218cf21f1b450015148f134626cf4018fcc1580d898157dbc41501000000000e5f108001683f0f000000000016001456c9b57de7610ed4a7721cb5a7797e13ce53d9f47f5a5c20, sig_hash=4cd3c264eac393d81b0426d713e98f9a89ba0f2253b1058660a06db9de381a4a
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant