Commit Graph

428 Commits

Author SHA1 Message Date
Slyghtning
b732b1a0e2 go.mod: bump lnd to v0.20.0-beta 2026-01-13 14:33:58 +01:00
Olaoluwa Osuntokun
a7cb3334b4 Merge pull request #199 from starius/fix-flacky-tests
hashmail: fix flacky tests
2025-12-17 16:55:31 -08:00
Boris Nagaev
e734b4a068 hashmail: block until stream is freed
Fix flaky tests. Reproducer:
go test -run TestHashMailServerReturnStream -count=20

TestHashMailServerReturnStream fails because the test cancels a read stream
and immediately dials RecvStream again expecting the same stream to be handed
out once the server returns it. The hashmail server implemented
RequestReadStream/RequestWriteStream with a non-blocking channel poll and
returned "read/write stream occupied" as soon as the mailbox was busy. That
raced with the deferred ReturnStream call and the reconnect often happened
before the stream got pushed back, so clients received the occupancy error
instead of the context cancellation they triggered.

Teach RequestReadStream/RequestWriteStream to wait for the stream to become
available (or the caller's context / server shutdown) with a bounded timeout.
If the wait expires we still return the "... stream occupied" error, so callers
that legitimately pile up can see that signal. The new streamAcquireTimeout
constant documents the policy, and the blocking select removes the race, so
reconnect attempts now either succeed or surface the original context error.
2025-11-26 23:38:00 -03:00
Boris Nagaev
bf020ea103 hashmail: isolate server per test
Register the Aperture instance created in setupAperture with t.Cleanup so
that every test stops its own server even if it fails. This keeps the global
HashMail stream map clean and prevents TestHashMailServerLargeMessage from
inheriting leftover streams from TestHashMailServerReturnStream.

This prevents cascading test failures, when a failure in one test is replicated
as many failures in many tests, complicating debugging from logs.
2025-11-26 22:26:18 -03:00
Olaoluwa Osuntokun
92e54ece11 Merge pull request #198 from starius/fix-empty-domain
aperture: filter empty TLS SAN hostnames
2025-11-26 11:19:53 -08:00
Boris Nagaev
e9515c1ddd aperture: filter empty TLS SAN hostnames
Go 1.25 tightened x509 validation and now rejects empty dNSName entries, causing
the default self-signed cert generation to fail when ServerName is left unset
(`x509: SAN dNSName is malformed`). Filter out empty host names before calling
cert.GenCertPair and reuse the same SAN list when renewing, allowing the default
config to keep working. Add a unit test that reproduces the failure.
2025-11-26 15:02:01 -03:00
Slyghtning
fc00f171a8 Merge pull request #197 from lightninglabs/dependabot/go_modules/golang.org/x/crypto-0.45.0
build(deps): bump golang.org/x/crypto from 0.36.0 to 0.45.0
2025-11-20 11:48:44 +01:00
Slyghtning
092da9d450 linter: fix context package 2025-11-20 11:08:20 +01:00
dependabot[bot]
e351fa6928 build(deps): bump golang.org/x/crypto from 0.36.0 to 0.45.0
Bumps [golang.org/x/crypto](https://github.com/golang/crypto) from 0.36.0 to 0.45.0.
- [Commits](https://github.com/golang/crypto/compare/v0.36.0...v0.45.0)

---
updated-dependencies:
- dependency-name: golang.org/x/crypto
  dependency-version: 0.45.0
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-20 01:44:55 +00:00
András Bánki-Horváth
68aa32afef Merge pull request #196 from lightninglabs/dependabot/go_modules/github.com/opencontainers/runc-1.2.8
build(deps): bump github.com/opencontainers/runc from 1.2.0 to 1.2.8
2025-11-05 19:20:21 +01:00
dependabot[bot]
9b2bd207df build(deps): bump github.com/opencontainers/runc from 1.2.0 to 1.2.8
Bumps [github.com/opencontainers/runc](https://github.com/opencontainers/runc) from 1.2.0 to 1.2.8.
- [Release notes](https://github.com/opencontainers/runc/releases)
- [Changelog](https://github.com/opencontainers/runc/blob/v1.2.8/CHANGELOG.md)
- [Commits](https://github.com/opencontainers/runc/compare/v1.2.0...v1.2.8)

---
updated-dependencies:
- dependency-name: github.com/opencontainers/runc
  dependency-version: 1.2.8
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-05 16:49:46 +00:00
Slyghtning
2779c9ef6c Merge pull request #194 from lightninglabs/dependabot/go_modules/github.com/go-viper/mapstructure/v2-2.4.0
build(deps): bump github.com/go-viper/mapstructure/v2 from 2.3.0 to 2.4.0
2025-08-26 16:07:55 +02:00
Slyghtning
4093998f85 Merge pull request #170 from shaojunda/challenger/start-call
challenger: remove redundant Start() call in NewLNCChallenger
2025-08-26 16:01:18 +02:00
dependabot[bot]
e31a59b148 build(deps): bump github.com/go-viper/mapstructure/v2
Bumps [github.com/go-viper/mapstructure/v2](https://github.com/go-viper/mapstructure) from 2.3.0 to 2.4.0.
- [Release notes](https://github.com/go-viper/mapstructure/releases)
- [Changelog](https://github.com/go-viper/mapstructure/blob/main/CHANGELOG.md)
- [Commits](https://github.com/go-viper/mapstructure/compare/v2.3.0...v2.4.0)

---
updated-dependencies:
- dependency-name: github.com/go-viper/mapstructure/v2
  dependency-version: 2.4.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-21 15:32:28 +00:00
Oliver Gugger
7e5d505edd Merge pull request #190 from hieblmi/bump-linter
linter: upgrade `golangci-lint` to v2
2025-08-20 06:48:48 -06:00
Slyghtning
536bc0d241 linter: fix lint issues after linter v2 update 2025-08-20 14:42:42 +02:00
Slyghtning
d4884d5aee linter: migrate .golangci.yml to v2
The migration was done via:
golangci-lint migrate --skip-validation
2025-08-20 14:42:41 +02:00
Slyghtning
049be3eb04 linter: update dolangci-lint to v2 2025-08-20 07:03:35 +02:00
Olaoluwa Osuntokun
666de67808 Merge pull request #189 from hieblmi/bump-go
gomod: bump go to v1.24.6
2025-08-19 18:02:46 -07:00
Slyghtning
200a203d22 gomod: bump go to v1.24.6 2025-08-19 15:44:19 +02:00
Oliver Gugger
5b83c503e9 Merge pull request #187 from lightninglabs/fix-rpc-check
proxy+pricesrpc: fix RPC check by bumping Golang version
2025-08-07 03:22:33 -06:00
Oliver Gugger
d365f0cd79 proxy+pricesrpc: fix RPC check by bumping Golang version 2025-08-07 11:11:29 +02:00
Oliver Gugger
57dee6953d Merge pull request #186 from bhandras/go-bump-v1.23.12
build: bump go to v1.23.12
2025-08-07 03:09:17 -06:00
Andras Banki-Horvath
84452ffdf4 build: bump go to v1.23.12 2025-08-07 10:31:32 +02:00
Oliver Gugger
72d880d04b Merge pull request #185 from lightninglabs/dependabot/go_modules/tools/github.com/go-viper/mapstructure/v2-2.3.0
build(deps): bump github.com/go-viper/mapstructure/v2 from 2.2.1 to 2.3.0 in /tools
2025-06-30 10:13:04 +02:00
dependabot[bot]
132d0143e5 build(deps): bump github.com/go-viper/mapstructure/v2 in /tools
---
updated-dependencies:
- dependency-name: github.com/go-viper/mapstructure/v2
  dependency-version: 2.3.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-30 07:56:49 +00:00
Oliver Gugger
e483545f04 Merge pull request #184 from lightninglabs/dependabot/go_modules/github.com/go-viper/mapstructure/v2-2.3.0
build(deps): bump github.com/go-viper/mapstructure/v2 from 2.2.1 to 2.3.0
2025-06-30 08:15:31 +02:00
dependabot[bot]
1100d173c1 build(deps): bump github.com/go-viper/mapstructure/v2
Bumps [github.com/go-viper/mapstructure/v2](https://github.com/go-viper/mapstructure) from 2.2.1 to 2.3.0.
- [Release notes](https://github.com/go-viper/mapstructure/releases)
- [Changelog](https://github.com/go-viper/mapstructure/blob/main/CHANGELOG.md)
- [Commits](https://github.com/go-viper/mapstructure/compare/v2.2.1...v2.3.0)

---
updated-dependencies:
- dependency-name: github.com/go-viper/mapstructure/v2
  dependency-version: 2.3.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-27 16:50:19 +00:00
Olaoluwa Osuntokun
3d991cec59 Merge pull request #181 from starius/bump-lightning-node-connect
update lightning-node-connect
2025-06-18 17:56:58 -07:00
Boris Nagaev
c99b44efd1 update lightning-node-connect
Include https://github.com/lightninglabs/lightning-node-connect/pull/116
It replaced a deprecated and removed dependency (nhooyr.io/websocket) with
an updated version.

Fix building with GOPROXY=direct.
2025-06-10 15:29:02 -03:00
Oliver Gugger
a990f62319 Merge pull request #180 from hieblmi/fix-shutdown-panic
challanger: fix shutdown panic
v0.3.14-beta
2025-05-27 20:38:41 +02:00
Slyghtning
6ee08290c5 challanger: cancel inv context when strictly verifying inv states 2025-05-27 20:30:18 +02:00
Oliver Gugger
c44ae45a07 Merge pull request #179 from lightninglabs/bump-lnd-version
GitHub+Docker: bump Golang version used
v0.3.13-beta
2025-05-26 13:52:00 +02:00
Oliver Gugger
b35b2b2742 GitHub+Docker: bump Golang version used 2025-05-26 13:42:43 +02:00
Oliver Gugger
8e175f9150 Merge pull request #178 from lightninglabs/lnd-19
mod: bump lnd, use latest modularized LNC
v0.3.12-beta
2025-05-26 13:19:17 +02:00
Oliver Gugger
491c0be94e multi: bump lnd, use latest modularized LNC 2025-05-26 12:49:05 +02:00
András Bánki-Horváth
20564d4a1d Merge pull request #172 from djkazic/aggregated-session-stats
aperture: internally aggregate session statistics to reduce cardinality
v0.3.11-beta
2025-05-22 16:54:45 +02:00
djkazic
eab9d755b6 fix: comment punctuation and shutdown of ticker 2025-05-21 11:28:34 -04:00
djkazic
7233c25bce aperture: internally aggregate session statistics to reduce cardinality 2025-05-19 12:40:24 -04:00
Oliver Gugger
47d72bdde3 Merge pull request #175 from Roasbeef/skip-invoice-load
multi: add new strict-verify CLI option to control invoice usage
2025-05-16 08:31:50 +02:00
Olaoluwa Osuntokun
ea6378110f sample-conf: add newer config options to sample conf 2025-05-15 14:59:58 -07:00
Olaoluwa Osuntokun
459a5728db multi: add new strict-verify CLI option to control invoice usage
In this commit, we add a new CLI argument that allows a user to control
if we use strict verification or not. Strict verification relies on
checking the actual invoice state against lnd, and requires more state
for the Aperture server.

When strict verification isn't on, we rely only on the preimage payment
hash relationship. Namely that the only way a user can obtain the
preimage is to pay the invoice, and as we check the HMAC on the
macaroon, we know that we created it with an invoice obtained from lnd.
2025-05-15 14:59:57 -07:00
András Bánki-Horváth
ab83de2961 Merge pull request #176 from sputn1ck/invoice_skip_list
Add Invoice skip list
v0.3.10-beta
2025-05-15 08:48:07 +02:00
sputn1ck
b1b0dc5570 proxy: add skipping invoice creation on request 2025-05-15 08:41:03 +02:00
sputn1ck
2c4de2acec proxy: add skip invoice creation param 2025-05-15 08:41:03 +02:00
sputn1ck
324c27dd55 proxy: set Content-Type for gRPC requests
Prior we would not set the Content-Type header for
grpc request, which on failure events would cause
the response to be invalid gRPC responses, as the
grpc code path in sendDirectResponse expects the
Content-Type header to be set.

This change fixes the problem by setting the
Content-Type header to application/grpc for gRPC
requests.
2025-05-14 22:23:32 +02:00
Oliver Gugger
a4d7a023c9 Merge pull request #177 from sputn1ck/precompile_regexes
proxy: precompile regexp
2025-05-14 22:17:46 +02:00
sputn1ck
1557c4aef9 proxy: precompile regexp 2025-05-14 22:12:25 +02:00
Oliver Gugger
4e5a50a0b8 Merge pull request #173 from djkazic/blocklist
proxy: implement blocklist
v0.3.9-beta
2025-05-14 16:30:09 +02:00
djkazic
d8e17e2da3 proxy: implement blocklist 2025-05-14 09:54:34 -04:00