keyring

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Feb 12, 2019 License: AGPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Keyring

type Keyring struct {
	// contains filtered or unexported fields
}

func Load

func Load() (*Keyring, error)

Load initialises the underlying keyring and returns a Keyring which provides accessor methods.

func (*Keyring) LoadPassword

func (k *Keyring) LoadPassword(fp fingerprint.Fingerprint) (password string, gotPassword bool)

LoadPassword attempts to load a password from the keyring for the given key and returns (password, gotPassword).

func (*Keyring) Name

func (k *Keyring) Name() string

func (*Keyring) PurgePassword

func (k *Keyring) PurgePassword(fp fingerprint.Fingerprint) error

PurgePassword deletes the key from the keyring or returns an error if it encounters one with the underlying keyring. If the keyring announces the key wasn't found, PurgePassword swallows that particular error.

func (*Keyring) SavePassword

func (k *Keyring) SavePassword(fp fingerprint.Fingerprint, newPassword string) error

SavePassword stores the given password in the keyring against the key and returns any error encountered in the underlying keyring.

Jump to

Keyboard shortcuts

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