multi: update btcd to v0.26.2 - #11029
Conversation
In this commit, we update the btcd dependency from v0.26.0 to v0.26.2, along with the tagged v2 submodule releases that ship with it: btcutil/v2 v2.0.1, wire/v2 v2.0.1, and v2transport v1.1.0. The release is mostly hardening of the parsing + decoding paths: btcutil.NewTxFromBytes and btcutil.NewBlockFromBytes now reject trailing bytes, DecodeWIF rejects out-of-range private keys, and wire.ReadV2MessageN rejects trailing payload data. The v2transport bump restores responder handshake progress for the v2 noise transport, and the rpcclient gains a DisableAuth option for cookie-less setups. No API changes, so the bump is a straight go.mod/go.sum update with no code changes needed on our side.
🟡 PR Severity: MEDIUM
🟡 Medium (10 files)
🟢 Low (3 files)
AnalysisThis PR is a routine dependency-bump across the repo's Go submodules (root, To override, add a |
Lrifton92
left a comment
There was a problem hiding this comment.
Did a full pass on this, verifying the bump against the btcd side rather than just the diff. LGTM.
Verified:
- Version set is internally consistent. The pinned versions match btcd v0.26.2's own
go.modexactly:btcutil/v2 v2.0.1,wire/v2 v2.0.1,v2transport v1.1.0, and the unchangedaddress/v2,chaincfg/v2,chainhash/v2,psbt/v2,txscript/v2at v2.0.0. Grepped everygo.modon the PR head — no module (root, kvdb, healthcheck, tor, tlv, tools) is left pinning v0.26.0 or wire/btcutil v2.0.0. - The
golang.org/x/timev0.3.0 -> v0.15.0 bump is MVS-required, not incidental: btcd v0.26.2 addsgolang.org/x/time v0.15.0as a direct dependency (connmgr now usesrate.Sometimesfor inbound-limit logging). Its propagation as// indirectinto healthcheck/tor/tools/kvdb is expected. - All new
go.sumentries match sum.golang.org — checked theh1:/go.modhashes for btcd v0.26.2, btcutil/v2 v2.0.1, wire/v2 v2.0.1, v2transport v1.1.0, and x/time v0.15.0 against the checksum DB lookups. No mismatches, no replace directives introduced. - On the "no API changes" claim — true at the signature level, with two behavioral notes I confirmed are inert for lnd:
- btcutil v2.0.1 tightens
NewTxFromBytes/NewBlockFromBytes(trailing bytes now rejected) andDecodeWIF(out-of-range/zero scalars rejected). lnd's only call sites of the first two are the test helpers inlnwallet/test_utils.go(fixed hex fixtures, no trailing bytes), and lnd doesn't callDecodeWIFat all. - connmgr gains an additive
Config.MaxInbound *uint32field wherenilpreserves the historical unlimited behavior — lnd'sconnmgr.Configusage doesn't set it, so no behavior change.wire.ReadV2MessageNalso got stricter on trailing payload bytes, but lnd never calls it directly.
- btcutil v2.0.1 tightens
- The claim that the psbt/address strictness fixes aren't included is accurate: no
psbt/v2.0.1oraddress/v2.0.1tags exist on btcd, and both stay at v2.0.0 here. (Skipping v0.26.1 is also expected — only av0.26.1-beta.rc1tag exists, no final v0.26.1.) - Go directives compose fine: btcd v0.26.2 requires
go 1.25.0, wire/v2 v2.0.1 moved togo 1.25; lnd is atgo 1.25.11. - Release-notes entry is in the current in-progress file (
release-notes-0.22.0.md) under Code Health, and CI is fully green across backends.
In this PR, we update the btcd dependency from v0.26.0 to v0.26.2. The v2 submodule migration landed already in #10913, so this is a patch-level bump on top of that work: btcutil/v2 v2.0.1, wire/v2 v2.0.1, and v2transport v1.1.0 come along with the root module.
No API changes in the release, so the bump is a straight go.mod/go.sum update across the root module and the submodules that pin btcd (kvdb, healthcheck, tor, tlv, tools). The psbt + address strictness fixes on btcd master don't have tagged submodule releases yet, so they aren't part of this bump.