Commit Graph
17100 Commits
Author SHA1 Message Date
Eugene Siegel 95acc78013 release-notes: update for 0.18.3 2024-08-27 14:11:07 -04:00
Eugene Siegel 013452cff0 discovery: implement ChannelAnnouncement banning
This commit hooks up the banman to the gossiper:
- peers that are banned and don't have a channel with us will get
  disconnected until they are unbanned.
- peers that are banned and have a channel with us won't get
  disconnected, but we will ignore their channel announcements until
  they are no longer banned. Note that this only disables gossip of
  announcements to us and still allows us to open channels to them.
2024-08-27 14:11:06 -04:00
Eugene Siegel 9380292a5a graph: export NewErrf and ErrorCode for upcoming gossiper unit tests 2024-08-27 14:11:06 -04:00
Eugene Siegel 8e0d7774b2 discovery: clean up scid variable usage 2024-08-27 14:11:06 -04:00
Eugene Siegel 99b86ba462 multi: extend lnpeer.Peer interface with Disconnect function
This will be used in the gossiper to disconnect from peers if their
ban score passes the ban threshold.
2024-08-27 14:11:06 -04:00
Eugene Siegel 0173e4c44d discovery: add banman for channel announcements
This commit introduces a ban manager that marks peers as banned if
they send too many invalid channel announcements to us. Expired
entries are purged after a certain period of time (currently 48 hours).
2024-08-27 14:11:06 -04:00
Eugene Siegel 199e83d3f2 channeldb: add PutClosedScid and IsClosedScid
This commit adds the ability to store closed channels by scid in
the database. This will allow the gossiper to ignore channel
announcements for closed channels without having to do any
expensive validation.
2024-08-27 14:11:05 -04:00
Oliver Gugger 8939a217c3 Merge pull request #9021 from aakselrod/run-nativesql-itests
itest: ensure LND gets correct CLI options when itest are parallel
2024-08-25 01:25:03 -06:00
Alex Akselrod 302c690136 docs: update release notes 2024-08-24 13:28:16 -07:00
Alex Akselrod 8d5f8d822d itest: ensure LND gets correct CLI options when itest are parallel 2024-08-24 13:28:14 -07:00
Oliver Gugger dcd921ad69 Merge pull request #9029 from tlindi/admin-macaroon-recreate-sample
update macaroons/README.md
2024-08-23 06:45:07 -06:00
tlindiandcoderabbitai[bot] b59ced60c0 update macaroons/README.md
Provide sample of command to create macaroon with similar rights as admin.macaroon to be used with 3rd party applications.

Co-Authored-By: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2024-08-23 15:10:04 +03:00
Oliver Gugger 306695cd78 Merge pull request #9025 from lightningnetwork/extract-from-staging-branch
[custom channels]: extract some independent commits from mega staging branch
2024-08-23 05:04:46 -06:00
Yong 278cf03078 Merge pull request #9028 from yyforyongyu/improve-ci-log
Makefile: silence testing log in `make itest-parallel`
2024-08-23 17:55:04 +08:00
Oliver Gugger d0d397545a Merge pull request #9026 from ziggie1984/bugfix-minHTLC-blindedpath
blindedpath: Minor bug fixes and feature addition.
2024-08-23 03:07:46 -06:00
Oliver Gugger 61edb36283 routing+lnrpc: fix log statements 2024-08-23 10:58:14 +02:00
Oliver Gugger 1167e9b6dd server: fix logging of pubkey 2024-08-23 10:58:14 +02:00
Oliver Gugger c5973aa136 cmd/commands: export StripPrefix 2024-08-23 10:58:13 +02:00
Oliver Gugger efbaf90caf lnwallet: add Tree() method, fix formatting 2024-08-23 10:58:13 +02:00
Oliver Gugger f0648e24a5 lnwallet: export GenTaprootHtlcScript 2024-08-23 10:58:13 +02:00
Oliver Gugger cf2174fc2d lnwallet: export AnchorSize 2024-08-23 10:58:13 +02:00
Oliver Gugger 22a3988222 cmd/lncli: move commands and export
We want to export some of our CLI code to re-use in other projects. But
in Golang you cannot import code from a `main` package.
So we need to move the actual code into its own package and only have
the `func main()` in the `main` package.
2024-08-23 10:57:59 +02:00
yyforyongyu 35287ee899 scripts: silence test outputs 2024-08-23 15:48:09 +08:00
ziggie 816b25e2ba docs: add release-notes. 2024-08-22 19:09:43 +02:00
ziggie 25f7b1c362 blindedpath: minHTLC for blinded path change.
We will not add a buffer to the chan policy for blinded paths in case
the sender amount violates the minHTLC restriction in the first place.

Moreover we disgard a route fast if the payment amount is smaller than
the minHTLC along the route.
2024-08-22 19:09:43 +02:00
Olaoluwa Osuntokun 75477c8896 funding: use atomic.Uint64 for chanIDNonce
This lets us get rid of the mutex usage there. We also shift the algo slightly to increment by 1, then use that as the next value, which plays nicer with the atomics.
2024-08-22 18:33:24 +02:00
Olaoluwa Osuntokun 614711748c funding: add new type alias for PendingChanID = [32]byte
This'll be useful for new interface definitions that use the contents of the package.
2024-08-22 18:33:24 +02:00
ffranr 1297e8f7c7 htlcswitch: add missing method doc 2024-08-22 18:33:24 +02:00
ffranr 7df093b3b1 multi: improve comment grammar 2024-08-22 18:33:24 +02:00
ffranr 9f3593a341 lnwire: add type CustomRecords
This commit introduces the `CustomRecords` type in the `lnwire` package,
designed to hold arbitrary byte slices. Each entry in this map can
associate with TLV type values that are greater than or equal to 65536.
2024-08-22 18:33:24 +02:00
ziggie 73984964a8 blindedpath: fix log output. 2024-08-22 17:48:27 +02:00
ziggie 5d7113ac1d blindedpath: remove blockexpiry check.
Removes a check where we would NOT allow to create a blinded invoice
with an expiry (invoice expiry in seconds considered as block time)
lower than the min_final_ctlv_delta.
2024-08-22 17:45:45 +02:00
Oliver Gugger 9e926924f1 mod: bump tlv to v1.2.6 2024-08-22 12:21:52 +02:00
Olaoluwa Osuntokun 38441d24c9 lnwallet/chanfunding: rename assembler.go to interface.go
In this commit, we rename the files as assembler.go houses the primary
interfaces/abstractions of the package. In the rest of the codebase,
this file is near uniformly called interface.go, so we rename the file
to make the repo more digestible at a scan.
2024-08-22 12:21:47 +02:00
Olaoluwa Osuntokun cc9e2b783e Merge pull request #8961 from yyforyongyu/fix-leaseoutput
Improve the performace of `LeaseOutput`
2024-08-21 16:31:26 -07:00
Oliver Gugger a028064fa7 Merge pull request #9007 from Roasbeef/go-1-22
build: set min build version to Go 1.22.6
2024-08-20 12:27:02 -06:00
Oliver Gugger 3ae6553eef .golangci: fix config, update new-from-rev 2024-08-20 19:14:44 +02:00
Oliver Gugger e99e6662cf multi: update linter, fix new issues 2024-08-20 19:14:44 +02:00
Oliver Gugger 9eef428e77 .golangci: remove or rename old and deprecated linters 2024-08-20 19:13:23 +02:00
Olaoluwa Osuntokun 19b5a1fb05 build: set min build version to Go 1.22.6
Go 1.23 was released this week, so with this PR we update the build
system to officially support the last two releases.
2024-08-20 19:13:23 +02:00
Olaoluwa Osuntokun b4693b2010 Merge pull request #9011 from ziggie1984/fix-gossip-syncer
Fix TimeStamp issue in the Gossip Syncer
2024-08-19 16:58:52 -07:00
ziggie fc5b763ab6 docs: update release-notes. 2024-08-17 04:29:58 +02:00
ziggie e5d7a7d371 discovery: add detailed comment.
Describe why it is ok to resurrect zombie channels based on the
timestamp of the `ReplyChannelRange` msg although its not verifiable
data.
2024-08-17 04:29:58 +02:00
ziggie 6fb1e0c17d multi: fix time.Time initialization.
ChanUpdate timestamps are now restircted so that they cannot be
more than two weeks into the future. Moreover channels with both
timestamps in the ReplyChannelRange msg either too far in the past
or too far in the future are not queried.

Moreover fix unitests.
2024-08-17 04:29:57 +02:00
Olaoluwa Osuntokun 8ac184a911 Merge pull request #8520 from lightningnetwork/peer-msg-router
[2/4] - peer: add new abstract message router
2024-08-16 14:57:44 -07:00
Olaoluwa Osuntokun 7c24e33614 Merge pull request #8996 from ProofOfKeags/dual
[MICRO]: lntypes: Add Dual[A] primitive type
2024-08-16 14:47:39 -07:00
Keagan McClelland 34f7c31dc8 lntypes: Add Dual[A] primitive type
This commit introduces a new type Dual[A] to make it easier to
manage symmetric configurations or state for lightning channels.
2024-08-15 10:53:18 -07:00
ziggie aecfe1c484 discovery: fix log line.
if we use %x here we would get the hex representation of the
String() method of the vertex, which is wrong.
2024-08-15 12:09:52 +02:00
Oliver Gugger 0aced5ce2d Merge pull request #8857 from MPins/issue-8793
Fixing the current state update when lncli debuglevel and lncli setmccfg are called
2024-08-15 02:33:54 -06:00
Olaoluwa Osuntokun f09c517bc6 peer: don't stop global msg router
In this commit, we fix a bug that would cause a global message router to
be stopped anytime a peer disconnected. The global msg router only
allows `Start` to be called once, so afterwards, no messages would
properly be routed.
2024-08-14 19:23:02 -07:00