seckey

package
v1.1.2 Latest Latest
Warning

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

Go to latest
Published: Mar 8, 2020 License: Unlicense Imports: 11 Imported by: 0

Documentation

Overview

Package seckey implements helper functions for secret key files.

Index

Constants

This section is empty.

Variables

View Source
var TestPass string

TestPass is a passphrase used for testing purposes. Do not set!

Functions

func Check

func Check(homeDir, seckey string) error

Check that the file seckey exists, if it is given. Otherwise make sure that at least the secrets subdirectory of homeDir exists.

func Load

func Load(c *hashchain.HashChain, homeDir, filename string) (*[64]byte, *[64]byte, []byte, error)

Load loads secret from filename, if given. Otherwise it loads the secret corresponding to the signer in given hash chain and makes sure that only one such secret exists.

func Read

func Read(filename string) (*[64]byte, *[64]byte, []byte, error)

Read reads the secret key from given filename. It reads the the passphrase from the terminal. If the wrong passphrase is given, the function reads the passphrase again.

Types

This section is empty.

Jump to

Keyboard shortcuts

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