chaninfo

package
v0.5.5-alpha Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 7, 2022 License: MIT Imports: 8 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ChannelInfo

type ChannelInfo struct {
	// Version is the version of the channel backup. This uniquely
	// identifies the type of channel we're working with.
	Version chanbackup.SingleBackupVersion

	// LocalNodeKey is the node's identifying public key.
	LocalNodeKey *btcec.PublicKey

	// RemoteNodeKey is the remote node's identifying public key.
	RemoteNodeKey *btcec.PublicKey

	// LocalPaymentBasePoint is the node's base public key used within the
	// non-delayed pay-to-self output on the commitment transaction.
	LocalPaymentBasePoint *btcec.PublicKey

	// RemotePaymentBasePoint is the remote node's base public key used
	// within the non-delayed pay-to-self output on the commitment
	// transaction.
	RemotePaymentBasePoint *btcec.PublicKey
}

ChannelInfo contains the relevant info required for a third-party to detect a channel lifetime violation by either party. These are obtained individually from the channel backup of each channel participant.

func GatherChannelInfo

func GatherChannelInfo(ctx context.Context, client lndclient.LightningClient,
	wallet lndclient.WalletKitClient,
	channelPoint wire.OutPoint) (*ChannelInfo, error)

GatherChannelInfo retrieves the relevant channel info from a channel's participant point of view required for the auctioneer to enforce channel lifetime violations.

func (*ChannelInfo) Match

func (a *ChannelInfo) Match(b *ChannelInfo) error

Matches determines whether a pair of ChannelInfo correspond to each other. This serves as a helper function to ensure channel participants provide the auctioneer with the correct expected keys.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL