libkaspawallet

package
v0.10.2-rc1 Latest Latest
Warning

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

Go to latest
Published: May 14, 2021 License: ISC Imports: 13 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Address

func Address(params *dagconfig.Params, pubKeys [][]byte, minimumSignatures uint32, ecdsa bool) (util.Address, error)

Address returns the address associated with the given public keys and minimum signatures parameters.

func CreateKeyPair

func CreateKeyPair(ecdsa bool) ([]byte, []byte, error)

CreateKeyPair generates a private-public key pair

func CreateUnsignedTransaction

func CreateUnsignedTransaction(
	pubKeys [][]byte,
	minimumSignatures uint32,
	ecdsa bool,
	payments []*Payment,
	selectedUTXOs []*externalapi.OutpointAndUTXOEntryPair) ([]byte, error)

CreateUnsignedTransaction creates an unsigned transaction

func ExtractTransaction

func ExtractTransaction(psTxBytes []byte) (*externalapi.DomainTransaction, error)

ExtractTransaction extracts a domain transaction from partially signed transaction after all of the relevant parties have signed it.

func IsTransactionFullySigned

func IsTransactionFullySigned(psTxBytes []byte) (bool, error)

IsTransactionFullySigned returns whether the transaction is fully signed and ready to broadcast.

func PublicKeyFromPrivateKey

func PublicKeyFromPrivateKey(privateKeyBytes []byte) ([]byte, error)

PublicKeyFromPrivateKey returns the public key associated with a private key

func Sign

func Sign(privateKeys [][]byte, serializedPSTx []byte, ecdsa bool) ([]byte, error)

Sign signs the transaction with the given private keys

Types

type Payment

type Payment struct {
	Address util.Address
	Amount  uint64
}

Payment contains a recipient payment details

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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