cc63db0aee
This commit adds detection of contract breaches within the commitment state-machine for a channel. A contract breach is defined as the event wherein a channel counter-party broadcasts a previously revoked commitment transaction. Such an event immediately closes a channel as the funds are now in a state of dispute. Once a breach is detected, a snapshot of the breached state is retrieved from the database’s revocation log. This snapshot is then used to generate the revocation leaf used within this particular state along with all the other information ncessary to sweep ALL active funds within the channel. This information is encapsulated within the BreachRetribution struct which is sent over a new channel dedicated to sending/receiving BreachRetributions. |
||
---|---|---|
.. | ||
btcwallet | ||
channel_test.go | ||
channel.go | ||
config.go | ||
interface_test.go | ||
interface.go | ||
log.go | ||
reservation.go | ||
script_utils_test.go | ||
script_utils.go | ||
wallet.go |