cmd

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Mar 25, 2026 License: MIT Imports: 53 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EAKeygenCmd

func EAKeygenCmd() *cobra.Command

EAKeygenCmd generates an ElGamal keypair for the Election Authority. The secret key is written to <home>/ea.sk and the public key to <home>/ea.pk.

func EncryptEAKeyCmd

func EncryptEAKeyCmd() *cobra.Command

EncryptEAKeyCmd produces a payloads.json for use with "svoted tx vote deal-ea-key". It reads ea.sk from disk, fetches all registered validators and their Pallas public keys from the chain's ceremony state, and ECIES-encrypts the secret key for each validator.

func InitValidatorKeysCmd

func InitValidatorKeysCmd() *cobra.Command

InitValidatorKeysCmd generates all cryptographic keys needed for a new validator in a single step: a Cosmos account key, a Pallas keypair, and an EA keypair.

func NewRootCmd

func NewRootCmd() *cobra.Command

NewRootCmd creates a new root command for svoted. It is called once in the main function.

func PallasKeygenCmd

func PallasKeygenCmd() *cobra.Command

PallasKeygenCmd generates a Pallas keypair for ECIES encryption. The secret key is written to <home>/pallas.sk and the public key to <home>/pallas.pk.

func ProvideClientContext

func ProvideClientContext(
	appCodec codec.Codec,
	interfaceRegistry codectypes.InterfaceRegistry,
	txConfigOpts tx.ConfigOptions,
	legacyAmino *codec.LegacyAmino,
) client.Context

ProvideClientContext provides the client context for depinject.

func SignArbitraryCmd

func SignArbitraryCmd() *cobra.Command

SignArbitraryCmd signs arbitrary data using a keyring key in ADR-036 format. Output: JSON with "signature" and "pub_key" (both base64).

Types

type CustomAppConfig

type CustomAppConfig struct {
	serverconfig.Config `mapstructure:",squash"`
	Vote                VoteConfig `mapstructure:"vote"`
}

CustomAppConfig embeds the standard server config and adds [vote].

type VoteConfig

type VoteConfig struct {
	EASkPath     string `mapstructure:"ea_sk_path"`
	PallasSkPath string `mapstructure:"pallas_sk_path"`
	CometRPC     string `mapstructure:"comet_rpc"`
}

VoteConfig holds the [vote] section of app.toml.

Jump to

Keyboard shortcuts

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