server.go+accessman.go: introduce caches for access permissions

Here we introduce the access manager which has caches that will
determine the access control status of our peers. Peers that have
had their funding transaction confirm with us are protected. Peers
that only have pending-open channels with us are temporary access
and can have their access revoked. The rest of the peers are granted
restricted access.
This commit is contained in:
Eugene Siegel
2025-01-16 10:32:34 -05:00
parent 4cfc92f420
commit 6eb746fbba
10 changed files with 788 additions and 53 deletions

View File

@@ -78,6 +78,7 @@ func New(cfg *Config) (*Standalone, error) {
for _, listenAddr := range cfg.ListenAddrs {
listener, err := brontide.NewListener(
cfg.NodeKeyECDH, listenAddr.String(),
brontide.DisabledBanClosure,
)
if err != nil {
return nil, err