cmd

package
v1.8.2 Latest Latest
Warning

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

Go to latest
Published: Sep 14, 2022 License: MIT Imports: 46 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ChainCLICommand cli.Command

ChainCLICommand contains the definition of the ethereum command-line subcommand and its own subcommands.

View Source
var ChainSigningCommand = cli.Command{
	Name:  "ethereum",
	Usage: "Ethereum signatures calculation",
	Subcommands: []cli.Command{
		{
			Name:        "sign",
			Usage:       "Sign a message using the operator's key",
			Description: ethereumSignDescription,
			Action:      EthereumSign,
			ArgsUsage:   "[message]",
			Flags: []cli.Flag{
				cli.StringFlag{
					Name: "key-file,k",
					Usage: "Path to the ethereum key file. " +
						"If not provided read the path from a config file.",
				},
				cli.StringFlag{
					Name:  "output-file,o",
					Usage: "Output file for the signature",
				},
			},
		},
		{
			Name:        "verify",
			Usage:       "Verifies a signature",
			Description: ethereumVerifyDescription,
			Action:      EthereumVerify,
			ArgsUsage:   "[signature]",
			Flags: []cli.Flag{
				cli.StringFlag{
					Name:  "input-file,i",
					Usage: "Input file with the signature",
				},
			},
		},
	},
}

ChainSigningCommand contains the definition of the `signing ethereum` command-line subcommand and its own subcommands.

View Source
var ResolveBitcoinBeneficiaryAddressCommand cli.Command

ResolveBitcoinBeneficiaryAddressCommand contains the definition of the resolve-bitcoin-address command-line subcommand.

View Source
var SigningCommand cli.Command

SigningCommand contains the definition of the `signing` command-line subcommand and its own subcommands.

View Source
var StartCommand cli.Command

StartCommand contains the definition of the start command-line subcommand.

Functions

func DecryptKeyShare added in v1.3.0

func DecryptKeyShare(c *cli.Context) error

DecryptKeyShare decrypt key shares for given keep using provided operator config.

func EthereumSign added in v1.5.0

func EthereumSign(c *cli.Context) error

EthereumSign signs a string using operator's ethereum key.

func EthereumVerify added in v1.5.0

func EthereumVerify(c *cli.Context) error

EthereumVerify verifies if a signature was calculated by a signer with the given ethereum address.

func EthlikeSign added in v1.8.0

func EthlikeSign(
	c *cli.Context,
	extractKeyFile keyFileConfigExtractor,
) error

EthlikeSign signs a string using operator's ETH-like key.

func EthlikeVerify added in v1.8.0

func EthlikeVerify(c *cli.Context) error

EthlikeVerify verifies if a signature was calculated by a signer with the given ETH-like address.

func ResolveBitcoinBeneficiaryAddress added in v1.8.0

func ResolveBitcoinBeneficiaryAddress(c *cli.Context) error

ResolveBitcoinBeneficiaryAddress resolves the next bitcoin address that would be used for liquidation recovery based on the nodes configuration.

func SignDigest added in v1.3.0

func SignDigest(c *cli.Context) error

SignDigest signs a given digest using key shares from the provided directory.

func Start

func Start(c *cli.Context) error

Start starts a client.

Types

type EthlikeSignature added in v1.8.0

type EthlikeSignature struct {
	Address   commonAddress `json:"address"`
	Message   string        `json:"msg"`
	Signature string        `json:"sig"`
	Version   string        `json:"version"`
}

EthlikeSignature is a common ETH-like signature format.

Jump to

Keyboard shortcuts

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