htlcswitch+config: make circular forwarding defence configurable

Add a bool to the switch's config which can be used to disable same
channel circular route checks.
This commit is contained in:
carla
2020-01-30 10:01:18 +02:00
parent a3478f1d99
commit afc7cc7f84
2 changed files with 3 additions and 0 deletions

View File

@@ -341,6 +341,8 @@ type config struct {
Watchtower *lncfg.Watchtower `group:"watchtower" namespace:"watchtower"`
LegacyProtocol *lncfg.LegacyProtocol `group:"legacyprotocol" namespace:"legacyprotocol"`
AllowCircularRoute bool `long:"allow-circular-route" description:"If true, our node will allow htlc forwards that arrive and depart on the same channel."`
}
// loadConfig initializes and parses the config using a config file and command