Skip to content

Commit dba48f6

Browse files
authored
Merge pull request #2620 from TheBlueMatt/2023-09-cut-0.0.117
Cut 0.0.117
2 parents 7aefa31 + c748746 commit dba48f6

File tree

16 files changed

+174
-43
lines changed

16 files changed

+174
-43
lines changed

CHANGELOG.md

+147
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,150 @@
1+
# 0.0.117 - XXX - "Everything but the Twelve Sinks"
2+
3+
## API Updates
4+
* `ProbabilisticScorer`'s internal models have been substantially improved,
5+
including better decaying (#1789), a more granular historical channel
6+
liquidity tracker (#2176) and a now-default option to make our estimate for a
7+
channel's current liquidity nonlinear in the channel's capacity (#2547). In
8+
total, these changes should result in improved payment success rates at the
9+
cost of slightly worse routefinding performance.
10+
* Support for custom TLVs for recipients of HTLCs has been added (#2308).
11+
* Support for generating transactions for third-party watchtowers has been
12+
added to `ChannelMonitor/Update`s (#2337).
13+
* `KVStorePersister` has been replaced with a more generic and featureful
14+
`KVStore` interface (#2472).
15+
* A new `MonitorUpdatingPersister` is provided which wraps a `KVStore` and
16+
implements `Persist` by writing differential updates rather than full
17+
`ChannelMonitor`s (#2359).
18+
* Batch funding of outbound channels is now supported using the new
19+
`ChannelManager::batch_funding_transaction_generated` method (#2486).
20+
* `ChannelManager::send_preflight_probes` has been added to probe a payment's
21+
potential paths while a user is providing approval for a payment (#2534).
22+
* Fully asynchronous `ChannelMonitor` updating is available as an alpha
23+
preview. There remain a few known but incredibly rare race conditions which
24+
may lead to loss of funds (#2112, #2169, #2562).
25+
* `ChannelMonitorUpdateStatus::PermanentFailure` has been removed in favor of a
26+
new `ChannelMonitorUpdateStatus::UnrecoverableError`. The new variant panics
27+
on use, rather than force-closing a channel in an unsafe manner, which the
28+
previous variant did (#2562). Rather than panicking with the new variant,
29+
users may wish to use the new asynchronous `ChannelMonitor` updating using
30+
`ChannelMonitorUpdateStatus::InProgress`.
31+
* `RouteParameters::max_total_routing_fee_msat` was added to limit the fees
32+
paid when routing, defaulting to 1% + 50sats when using the new
33+
`from_payment_params_and_value` constructor (#2417, #2603, #2604).
34+
* Implementations of `UtxoSource` are now provided in `lightning-block-sync`.
35+
Those running with a full node should use this to validate gossip (#2248).
36+
* `LockableScore` now supports read locking for parallel routefinding (#2197).
37+
* `ChannelMonitor::get_spendable_outputs` was added to allow for re-generation
38+
of `SpendableOutputDescriptor`s for a channel after they were provided via
39+
`Event::SpendableOutputs` (#2609, #2624).
40+
* `[u8; 32]` has been replaced with a `ChannelId` newtype for chan ids (#2485).
41+
* `NetAddress` was renamed `SocketAddress` (#2549) and `FromStr` impl'd (#2134)
42+
* For `no-std` users, `parse_onion_address` was added which creates a
43+
`NetAddress` from a "...onion" string and port (#2134, #2633).
44+
* HTLC information is now provided in `Event::PaymentClaimed::htlcs` (#2478).
45+
* The success probability used in historical penalties when scoring is now
46+
available via `historical_estimated_payment_success_probability` (#2466).
47+
* `RecentPaymentDetails::*::payment_id` has been added (#2567).
48+
* `Route` now contains a `RouteParameters` rather than a `PaymentParameters`,
49+
tracking the original arguments passed to routefinding (#2555).
50+
* `Balance::*::claimable_amount_satoshis` was renamed `amount_satoshis` (#2460)
51+
* `*Features::set_*_feature_bit` have been added for non-custom flags (#2522).
52+
* `channel_id` was added to `SpendableOutputs` events (#2511).
53+
* `counterparty_node_id` and `channel_capacity_sats` were added to
54+
`ChannelClosed` events (#2387).
55+
* `ChannelMonitor` now implements `Clone` for `Clone`able signers (#2448).
56+
* `create_onion_message` was added to build an onion message (#2583, #2595).
57+
* `HTLCDescriptor` now implements `Writeable`/`Readable` (#2571).
58+
* `SpendableOutputDescriptor` now implements `Hash` (#2602).
59+
* `MonitorUpdateId` now implements `Debug` (#2594).
60+
* `Payment{Hash,Id,Preimage}` now implement `Display` (#2492).
61+
* `NodeSigner::sign_bolt12_invoice{,request}` were added for future use (#2432)
62+
63+
## Backwards Compatibility
64+
* Users migrating to the new `KVStore` can use a concatentation of
65+
`[{primary_namespace}/[{secondary_namespace}/]]{key}` to build a key
66+
compatible with the previous `KVStorePersister` interface (#2472).
67+
* Downgrading after receipt of a payment with custom HTLC TLVs may result in
68+
unintentionally accepting payments with TLVs you do not understand (#2308).
69+
* `Route` objects (including pending payments) written by LDK versions prior
70+
to 0.0.117 won't be retryable after being deserialized by LDK 0.0.117 or
71+
above (#2555).
72+
* Users of the `MonitorUpdatingPersister` can upgrade seamlessly from the
73+
default `KVStore` `Persist` implementation, however the stored
74+
`ChannelMonitor`s are deliberately unreadable by the default `Persist`. This
75+
ensures the correct downgrade procedure is followed, which is: (#2359)
76+
* First, make a backup copy of all channel state,
77+
* then ensure all `ChannelMonitorUpdate`s stored are fully applied to the
78+
relevant `ChannelMonitor`,
79+
* finally, write each full `ChannelMonitor` using your new `Persist` impl.
80+
81+
## Bug Fixes
82+
* Anchor channels which were closed by a counterparty broadcasting its
83+
commitment transaction (i.e. force-closing) would previously not generate a
84+
`SpendableOutputs` event for our `to_remote` (i.e. non-HTLC-encumbered)
85+
balance. Those with such balances available should fetch the missing
86+
`SpendableOutputDescriptor`s using the new
87+
`ChannelMonitor::get_spendable_outputs` method (#2605).
88+
* Anchor channels may result in spurious or missing `Balance` entries for HTLC
89+
balances (#2610).
90+
* `ChannelManager::send_spontaneous_payment_with_retry` spuriously did not
91+
provide the recipient with enough information to claim the payment, leading
92+
to all spontaneous payments failing (#2475).
93+
`send_spontaneous_payment_with_route` was unaffected.
94+
* The `keysend` feature on node announcements was spuriously un-set in 0.0.112
95+
and has been re-enabled (#2465).
96+
* Fixed several races which could lead to deadlock when force-closing a channel
97+
(#2597). These races have not been seen in production.
98+
* The `ChannelManager` is persisted substantially less when it has not changed,
99+
leading to substantially less I/O traffic for it (#2521, #2617).
100+
* Passing new block data to `ChainMonitor` no longer results in all other
101+
monitor operations being blocked until it completes (#2528).
102+
* When retrying payments, any excess amount sent to the recipient in order to
103+
meet an `htlc_minimum` constraint on the path is now no longer included in
104+
the amount we send in the retry (#2575).
105+
* Several edge cases in route-finding around HTLC minimums were fixed which
106+
could have caused invalid routes or panics when built with debug assertions
107+
(#2570, #2575).
108+
* Several edge cases in route-finding around HTLC minimums and route hints
109+
were fixed which would spuriously result in no route found (#2575, #2604).
110+
* The `user_channel_id` passed to `SignerProvider::generate_channel_keys_id`
111+
for inbound channels is now correctly using the one passed to
112+
`ChannelManager::accept_inbound_channel` rather than a default value (#2428).
113+
* Users of `impl_writeable_tlv_based!` no longer have use requirements (#2506).
114+
* No longer force-close channels when counterparties send a `channel_update`
115+
with a bogus `htlc_minimum_msat`, which LND users can manually build (#2611).
116+
117+
## Node Compatibility
118+
* LDK now ignores `error` messages generated by LND in response to a
119+
`shutdown` message, avoiding force-closes due to LND bug 6039. This may
120+
lead to non-trivial bandwidth usage with LND peers exhibiting this bug
121+
during the cooperative shutdown process (#2507).
122+
123+
## Security
124+
0.0.117 fixes several loss-of-funds vulnerabilities in anchor output channels,
125+
support for which was added in 0.0.116, in reorg handling, and when accepting
126+
channel(s) from counterparties which are miners.
127+
* When a counterparty broadcasts their latest commitment transaction for a
128+
channel with anchor outputs, we'd previously fail to build claiming
129+
transactions against any HTLC outputs in that transaction. This could lead
130+
to loss of funds if the counterparty is able to eventually claim the HTLC
131+
after a timeout (#2606).
132+
* Anchor channels HTLC claims on-chain previously spent the entire value of any
133+
HTLCs as fee, which has now been fixed (#2587).
134+
* If a channel is closed via an on-chain commitment transaction confirmation
135+
with a pending outbound HTLC in the commitment transaction, followed by a
136+
reorg which replaces the confirmed commitment transaction with a different
137+
(but non-revoked) commitment transaction, all before we learn the payment
138+
preimage for this HTLC, we may previously have not generated a proper
139+
claiming transaction for the HTLC's value (#2623).
140+
* 0.0.117 now correctly handles channels for which our counterparty funded the
141+
channel with a coinbase transaction. As such transactions are not spendable
142+
until they've reached 100 confirmations, this could have resulted in
143+
accepting HTLC(s) which are not enforcible on-chain (#1924).
144+
145+
up to date as of 620244dc2ec3153a61e009b80a8c59cf41514482
146+
XXX: add diff statas
147+
1148
# 0.0.116 - Jul 21, 2023 - "Anchoring the Roadmap"
2149

3150
## API Updates

lightning-background-processor/Cargo.toml

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "lightning-background-processor"
3-
version = "0.0.117-rc1"
3+
version = "0.0.117"
44
authors = ["Valentine Wallace <[email protected]>"]
55
license = "MIT OR Apache-2.0"
66
repository = "https://github.com/lightningdevkit/rust-lightning"
@@ -22,11 +22,11 @@ default = ["std"]
2222

2323
[dependencies]
2424
bitcoin = { version = "0.29.0", default-features = false }
25-
lightning = { version = "0.0.117-rc1", path = "../lightning", default-features = false }
26-
lightning-rapid-gossip-sync = { version = "0.0.117-rc1", path = "../lightning-rapid-gossip-sync", default-features = false }
25+
lightning = { version = "0.0.117", path = "../lightning", default-features = false }
26+
lightning-rapid-gossip-sync = { version = "0.0.117", path = "../lightning-rapid-gossip-sync", default-features = false }
2727

2828
[dev-dependencies]
2929
tokio = { version = "1.14", features = [ "macros", "rt", "rt-multi-thread", "sync", "time" ] }
30-
lightning = { version = "0.0.117-rc1", path = "../lightning", features = ["_test_utils"] }
31-
lightning-invoice = { version = "0.25.0-rc1", path = "../lightning-invoice" }
32-
lightning-persister = { version = "0.0.117-rc1", path = "../lightning-persister" }
30+
lightning = { version = "0.0.117", path = "../lightning", features = ["_test_utils"] }
31+
lightning-invoice = { version = "0.25.0", path = "../lightning-invoice" }
32+
lightning-persister = { version = "0.0.117", path = "../lightning-persister" }

lightning-block-sync/Cargo.toml

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "lightning-block-sync"
3-
version = "0.0.117-rc1"
3+
version = "0.0.117"
44
authors = ["Jeffrey Czyz", "Matt Corallo"]
55
license = "MIT OR Apache-2.0"
66
repository = "https://github.com/lightningdevkit/rust-lightning"
@@ -19,11 +19,11 @@ rpc-client = [ "serde_json", "chunked_transfer" ]
1919

2020
[dependencies]
2121
bitcoin = "0.29.0"
22-
lightning = { version = "0.0.117-rc1", path = "../lightning" }
22+
lightning = { version = "0.0.117", path = "../lightning" }
2323
tokio = { version = "1.0", features = [ "io-util", "net", "time" ], optional = true }
2424
serde_json = { version = "1.0", optional = true }
2525
chunked_transfer = { version = "1.4", optional = true }
2626

2727
[dev-dependencies]
28-
lightning = { version = "0.0.117-rc1", path = "../lightning", features = ["_test_utils"] }
28+
lightning = { version = "0.0.117", path = "../lightning", features = ["_test_utils"] }
2929
tokio = { version = "1.14", features = [ "macros", "rt" ] }

lightning-custom-message/Cargo.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "lightning-custom-message"
3-
version = "0.0.117-rc1"
3+
version = "0.0.117"
44
authors = ["Jeffrey Czyz"]
55
license = "MIT OR Apache-2.0"
66
repository = "https://github.com/lightningdevkit/rust-lightning"
@@ -15,4 +15,4 @@ rustdoc-args = ["--cfg", "docsrs"]
1515

1616
[dependencies]
1717
bitcoin = "0.29.0"
18-
lightning = { version = "0.0.117-rc1", path = "../lightning" }
18+
lightning = { version = "0.0.117", path = "../lightning" }

lightning-invoice/Cargo.toml

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[package]
22
name = "lightning-invoice"
33
description = "Data structures to parse and serialize BOLT11 lightning invoices"
4-
version = "0.25.0-rc1"
4+
version = "0.25.0"
55
authors = ["Sebastian Geisler <[email protected]>"]
66
documentation = "https://docs.rs/lightning-invoice/"
77
license = "MIT OR Apache-2.0"
@@ -21,7 +21,7 @@ std = ["bitcoin_hashes/std", "num-traits/std", "lightning/std", "bech32/std"]
2121

2222
[dependencies]
2323
bech32 = { version = "0.9.0", default-features = false }
24-
lightning = { version = "0.0.117-rc1", path = "../lightning", default-features = false }
24+
lightning = { version = "0.0.117", path = "../lightning", default-features = false }
2525
secp256k1 = { version = "0.24.0", default-features = false, features = ["recovery", "alloc"] }
2626
num-traits = { version = "0.2.8", default-features = false }
2727
bitcoin_hashes = { version = "0.11", default-features = false }
@@ -30,6 +30,6 @@ serde = { version = "1.0.118", optional = true }
3030
bitcoin = { version = "0.29.0", default-features = false }
3131

3232
[dev-dependencies]
33-
lightning = { version = "0.0.117-rc1", path = "../lightning", default-features = false, features = ["_test_utils"] }
33+
lightning = { version = "0.0.117", path = "../lightning", default-features = false, features = ["_test_utils"] }
3434
hex = "0.4"
3535
serde_json = { version = "1"}

lightning-net-tokio/Cargo.toml

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "lightning-net-tokio"
3-
version = "0.0.117-rc1"
3+
version = "0.0.117"
44
authors = ["Matt Corallo"]
55
license = "MIT OR Apache-2.0"
66
repository = "https://github.com/lightningdevkit/rust-lightning/"
@@ -16,9 +16,9 @@ rustdoc-args = ["--cfg", "docsrs"]
1616

1717
[dependencies]
1818
bitcoin = "0.29.0"
19-
lightning = { version = "0.0.117-rc1", path = "../lightning" }
19+
lightning = { version = "0.0.117", path = "../lightning" }
2020
tokio = { version = "1.0", features = [ "rt", "sync", "net", "time" ] }
2121

2222
[dev-dependencies]
2323
tokio = { version = "1.14", features = [ "macros", "rt", "rt-multi-thread", "sync", "net", "time" ] }
24-
lightning = { version = "0.0.117-rc1", path = "../lightning", features = ["_test_utils"] }
24+
lightning = { version = "0.0.117", path = "../lightning", features = ["_test_utils"] }

lightning-persister/Cargo.toml

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "lightning-persister"
3-
version = "0.0.117-rc1"
3+
version = "0.0.117"
44
authors = ["Valentine Wallace", "Matt Corallo"]
55
license = "MIT OR Apache-2.0"
66
repository = "https://github.com/lightningdevkit/rust-lightning"
@@ -15,7 +15,7 @@ rustdoc-args = ["--cfg", "docsrs"]
1515

1616
[dependencies]
1717
bitcoin = "0.29.0"
18-
lightning = { version = "0.0.117-rc1", path = "../lightning" }
18+
lightning = { version = "0.0.117", path = "../lightning" }
1919

2020
[target.'cfg(windows)'.dependencies]
2121
windows-sys = { version = "0.48.0", default-features = false, features = ["Win32_Storage_FileSystem", "Win32_Foundation"] }
@@ -24,5 +24,5 @@ windows-sys = { version = "0.48.0", default-features = false, features = ["Win32
2424
criterion = { version = "0.4", optional = true, default-features = false }
2525

2626
[dev-dependencies]
27-
lightning = { version = "0.0.117-rc1", path = "../lightning", features = ["_test_utils"] }
27+
lightning = { version = "0.0.117", path = "../lightning", features = ["_test_utils"] }
2828
bitcoin = { version = "0.29.0", default-features = false }

lightning-rapid-gossip-sync/Cargo.toml

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "lightning-rapid-gossip-sync"
3-
version = "0.0.117-rc1"
3+
version = "0.0.117"
44
authors = ["Arik Sosman <[email protected]>"]
55
license = "MIT OR Apache-2.0"
66
repository = "https://github.com/lightningdevkit/rust-lightning"
@@ -15,11 +15,11 @@ no-std = ["lightning/no-std"]
1515
std = ["lightning/std"]
1616

1717
[dependencies]
18-
lightning = { version = "0.0.117-rc1", path = "../lightning", default-features = false }
18+
lightning = { version = "0.0.117", path = "../lightning", default-features = false }
1919
bitcoin = { version = "0.29.0", default-features = false }
2020

2121
[target.'cfg(ldk_bench)'.dependencies]
2222
criterion = { version = "0.4", optional = true, default-features = false }
2323

2424
[dev-dependencies]
25-
lightning = { version = "0.0.117-rc1", path = "../lightning", features = ["_test_utils"] }
25+
lightning = { version = "0.0.117", path = "../lightning", features = ["_test_utils"] }

lightning-transaction-sync/Cargo.toml

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "lightning-transaction-sync"
3-
version = "0.0.117-rc1"
3+
version = "0.0.117"
44
authors = ["Elias Rohrer"]
55
license = "MIT OR Apache-2.0"
66
repository = "https://github.com/lightningdevkit/rust-lightning"
@@ -21,15 +21,15 @@ esplora-blocking = ["esplora-client/blocking"]
2121
async-interface = []
2222

2323
[dependencies]
24-
lightning = { version = "0.0.117-rc1", path = "../lightning", default-features = false }
24+
lightning = { version = "0.0.117", path = "../lightning", default-features = false }
2525
bitcoin = { version = "0.29.0", default-features = false }
2626
bdk-macros = "0.6"
2727
futures = { version = "0.3", optional = true }
2828
esplora-client = { version = "0.4", default-features = false, optional = true }
2929
reqwest = { version = "0.11", optional = true, default-features = false, features = ["json"] }
3030

3131
[dev-dependencies]
32-
lightning = { version = "0.0.117-rc1", path = "../lightning", features = ["std"] }
32+
lightning = { version = "0.0.117", path = "../lightning", features = ["std"] }
3333
electrsd = { version = "0.22.0", features = ["legacy", "esplora_a33e97e1", "bitcoind_23_0"] }
3434
electrum-client = "0.12.0"
3535
tokio = { version = "1.14.0", features = ["full"] }

lightning/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "lightning"
3-
version = "0.0.117-rc1"
3+
version = "0.0.117"
44
authors = ["Matt Corallo"]
55
license = "MIT OR Apache-2.0"
66
repository = "https://github.com/lightningdevkit/rust-lightning/"

pending_changelog/custom_tlv_downgrade.txt

-3
This file was deleted.

pending_changelog/kvstore.txt

-3
This file was deleted.

pending_changelog/monitorupdatingpersister.txt

-5
This file was deleted.

pending_changelog/move_netaddress_to_socketaddress.txt

-1
This file was deleted.

pending_changelog/new_channel_id_type_pr_2485.txt

-1
This file was deleted.

pending_changelog/routes_route_params.txt

-3
This file was deleted.

0 commit comments

Comments
 (0)