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

Set the SigHashType of htlc signatures w/ anchors to SinglePlusAnyoneCanPay #5

Open
wants to merge 22 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
ae4f619
Add a constructor to MultiThreadedLockableScore
TheBlueMatt Dec 18, 2021
d26469a
Add a C-not exported tag to `NetGraphMsgHandler.network_graph`
TheBlueMatt Dec 18, 2021
7d1e187
Swap around generic argument ordering in InvoicePayer for bindings
TheBlueMatt Dec 18, 2021
d5a1435
Log gossip rejections due to stale channel_updates at GOSSIP level
TheBlueMatt Dec 19, 2021
5655590
Merge pull request #1218 from TheBlueMatt/2021-12-minor-bindings-tweaks
TheBlueMatt Dec 19, 2021
d46c2a2
update repo name to use lightningdevkit
hackerrdave Dec 27, 2021
036ea11
Merge pull request #1225 from hackerrdave/update-repo-lightningdevkit
TheBlueMatt Dec 29, 2021
3ca6342
Merge pull request #1220 from TheBlueMatt/2021-12-stale-update-gossip…
TheBlueMatt Jan 3, 2022
ffbef9f
Support building `cfg=c_bindings` with `no-std`
TheBlueMatt Jan 4, 2022
94c41d8
Merge pull request #1226 from TheBlueMatt/2022-01-bindings-no-std
TheBlueMatt Jan 5, 2022
0191581
Adapt lightning-invoice to no_std
devrandom Dec 22, 2021
b62b244
Merge pull request #1223 from lightning-signer/2021-12-invoice-nostd
TheBlueMatt Jan 6, 2022
8f09e5a
Set the SigHashType of remote htlc signatures w/ anchors to SinglePlu…
ksedgwic Dec 29, 2021
3a163d2
Isolated channelmonitor weight unit tests and added anchor loops
ksedgwic Dec 31, 2021
37001b8
make WEIGHT{_REVOKED,}_{OFFERED,RECEIVED}_HTLC functions with opt_anc…
ksedgwic Dec 31, 2021
c47d014
Add unit test coverage for package::weight_{offered,received}_htlc
ksedgwic Jan 2, 2022
9566795
Convert COMMITMENT_TX_BASE_WEIGHT to anchor-aware function
ksedgwic Jan 4, 2022
557a830
Convert HTLC_{SUCCESS,TIMEOUT}_TX_WEIGHT to anchor-aware functions
ksedgwic Jan 5, 2022
35a6e00
Debit funder's output to cover anchors
ksedgwic Jan 5, 2022
299b665
Add anchor tests to outbound_commitment_test
ksedgwic Jan 4, 2022
bee0012
Set opt_anchors for calls to CommitmentTransaction::new_with_auxiliar…
ksedgwic Jan 13, 2022
9c2270c
Fixed comment on weight_received_htlc
ksedgwic Jan 13, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -109,11 +109,19 @@ jobs:
run: RUSTFLAGS="-C link-dead-code" cargo test --verbose --color always
- name: Test on no-std bullds Rust ${{ matrix.toolchain }}
if: "matrix.build-no-std && !matrix.coverage"
shell: bash # Default on Winblows is powershell
run: |
cd lightning
cargo test --verbose --color always --no-default-features --features no-std
# check if there is a conflict between no-std and the default std feature
cargo test --verbose --color always --features no-std
# check if there is a conflict between no-std and the c_bindings cfg
RUSTFLAGS="--cfg=c_bindings" cargo test --verbose --color always --no-default-features --features=no-std
cd ..
cd lightning-invoice
cargo test --verbose --color always --no-default-features --features no-std
# check if there is a conflict between no-std and the default std feature
cargo test --verbose --color always --features no-std
cd ..
- name: Test on no-std builds Rust ${{ matrix.toolchain }} and full code-linking for coverage generation
if: "matrix.build-no-std && matrix.coverage"
Expand Down Expand Up @@ -240,7 +248,7 @@ jobs:
profile: minimal
- name: Fetch full tree and rebase on upstream
run: |
git remote add upstream https://github.com/rust-bitcoin/rust-lightning
git remote add upstream https://github.com/lightningdevkit/rust-lightning
git fetch upstream
export GIT_COMMITTER_EMAIL="[email protected]"
export GIT_COMMITTER_NAME="RL CI"
Expand Down
6 changes: 3 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ Communication about Rust-Lightning happens primarily on #ldk-dev on the
Discussion about code base improvements happens in GitHub issues and on pull
requests.

Major projects are tracked [here](https://github.com/rust-bitcoin/rust-lightning/projects).
Major milestones are tracked [here](https://github.com/rust-bitcoin/rust-lightning/milestones?direction=asc&sort=title&state=open).
Major projects are tracked [here](https://github.com/lightningdevkit/rust-lightning/projects).
Major milestones are tracked [here](https://github.com/lightningdevkit/rust-lightning/milestones?direction=asc&sort=title&state=open).

Getting Started
---------------
Expand All @@ -33,7 +33,7 @@ This doesn't mean don't be ambitious with the breadth and depth of your contribu
understand the project culture before investing an asymmetric number of hours on
development compared to your merged work.

Browsing through the [meeting minutes](https://github.com/rust-bitcoin/rust-lightning/wiki/Meetings)
Browsing through the [meeting minutes](https://github.com/lightningdevkit/rust-lightning/wiki/Meetings)
is a good first step. You will learn who is working on what, how releases are drafted, what are the
pending tasks to deliver, where you can contribute review bandwidth, etc.

Expand Down
2 changes: 1 addition & 1 deletion lightning-background-processor/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name = "lightning-background-processor"
version = "0.0.104"
authors = ["Valentine Wallace <[email protected]>"]
license = "MIT OR Apache-2.0"
repository = "http://github.com/rust-bitcoin/rust-lightning"
repository = "http://github.com/lightningdevkit/rust-lightning"
description = """
Utilities to perform required background tasks for Rust Lightning.
"""
Expand Down
2 changes: 1 addition & 1 deletion lightning-block-sync/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name = "lightning-block-sync"
version = "0.0.104"
authors = ["Jeffrey Czyz", "Matt Corallo"]
license = "MIT OR Apache-2.0"
repository = "http://github.com/rust-bitcoin/rust-lightning"
repository = "http://github.com/lightningdevkit/rust-lightning"
description = """
Utilities to fetch the chain data from a block source and feed them into Rust Lightning.
"""
Expand Down
17 changes: 12 additions & 5 deletions lightning-invoice/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,20 @@ license = "MIT OR Apache-2.0"
keywords = [ "lightning", "bitcoin", "invoice", "BOLT11" ]
readme = "README.md"

[features]
default = ["std"]
no-std = ["hashbrown", "lightning/no-std", "core2/alloc"]
std = ["bitcoin_hashes/std", "num-traits/std", "lightning/std"]

[dependencies]
bech32 = "0.8"
lightning = { version = "0.0.104", path = "../lightning" }
secp256k1 = { version = "0.20", features = ["recovery"] }
num-traits = "0.2.8"
bitcoin_hashes = "0.10"
lightning = { version = "0.0.104", path = "../lightning", default-features = false }
secp256k1 = { version = "0.20", default-features = false, features = ["recovery", "alloc"] }
num-traits = { version = "0.2.8", default-features = false }
bitcoin_hashes = { version = "0.10", default-features = false }
hashbrown = { version = "0.11", optional = true }
core2 = { version = "0.3.0", default-features = false, optional = true }

[dev-dependencies]
lightning = { version = "0.0.104", path = "../lightning", default-features = false, features = ["_test_utils"] }
hex = "0.3"
lightning = { version = "0.0.104", path = "../lightning", features = ["_test_utils"] }
16 changes: 10 additions & 6 deletions lightning-invoice/src/de.rs
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
#[cfg(feature = "std")]
use std::error;
use std::fmt;
use std::fmt::{Display, Formatter};
use std::num::ParseIntError;
use std::str;
use std::str::FromStr;
use core::fmt;
use core::fmt::{Display, Formatter};
use core::num::ParseIntError;
use core::str;
use core::str::FromStr;

use bech32;
use bech32::{u5, FromBase32};

use bitcoin_hashes::Hash;
use bitcoin_hashes::sha256;
use crate::prelude::*;
use lightning::ln::PaymentSecret;
use lightning::routing::network_graph::RoutingFees;
use lightning::routing::router::{RouteHint, RouteHintHop};
Expand All @@ -28,7 +30,7 @@ use self::hrp_sm::parse_hrp;

/// State machine to parse the hrp
mod hrp_sm {
use std::ops::Range;
use core::ops::Range;

#[derive(PartialEq, Eq, Debug)]
enum States {
Expand Down Expand Up @@ -723,8 +725,10 @@ impl Display for ParseOrSemanticError {
}
}

#[cfg(feature = "std")]
impl error::Error for ParseError {}

#[cfg(feature = "std")]
impl error::Error for ParseOrSemanticError {}

macro_rules! from_error {
Expand Down
Loading