Documentation ¶
Index ¶
- Constants
- func CheckKeyType(filePath string, passPhrase string) (*sshkey.PrivateKeyFile, error)
- func JSONDump(data interface{}) string
- func LoadKeyfile(filePath string, passPhrase string) (*sshkey.PrivateKeyFile, *agent.AddedKey, error)
- type KeyRing
- func (k *KeyRing) Add(key agent.AddedKey) error
- func (k *KeyRing) AddKey(keyID string) error
- func (k *KeyRing) AddKeySettings(key sshkey.PrivateKeyFile) (string, error)
- func (k *KeyRing) AddKeys() error
- func (k *KeyRing) DeleteKeySettings(sha256 string) error
- func (k *KeyRing) Extension(extensionType string, contents []byte) ([]byte, error)
- func (k *KeyRing) KeyList() ([]sshkey.PrivateKeyFile, error)
- func (k *KeyRing) List() ([]*agent.Key, error)
- func (k *KeyRing) Lock(passphrase []byte) error
- func (k *KeyRing) Remove(key ssh.PublicKey) error
- func (k *KeyRing) RemoveAll() error
- func (k *KeyRing) RemoveKey(sha256 string) error
- func (k *KeyRing) Sign(key ssh.PublicKey, data []byte) (*ssh.Signature, error)
- func (k *KeyRing) SignWithFlags(key ssh.PublicKey, data []byte, flags agent.SignatureFlags) (*ssh.Signature, error)
- func (k *KeyRing) Signers() ([]ssh.Signer, error)
- func (k *KeyRing) Unlock(passphrase []byte) error
Constants ¶
View Source
const (
LocalStore = "LocalStore"
)
Variables ¶
This section is empty.
Functions ¶
func CheckKeyType ¶
func CheckKeyType(filePath string, passPhrase string) (*sshkey.PrivateKeyFile, error)
CheckKeyType Check the information in the PrivateKey file
func LoadKeyfile ¶
func LoadKeyfile(filePath string, passPhrase string) (*sshkey.PrivateKeyFile, *agent.AddedKey, error)
LoadKeyfile Read privateKey file from local filesystem
Types ¶
type KeyRing ¶
type KeyRing struct { NotifyCallback func(action string, data interface{}) // contains filtered or unexported fields }
KeyRing saves the state of ssh-agent
func NewKeyRing ¶
NewKeyRing an Agent that holds keys in memory.
func (*KeyRing) AddKeySettings ¶
func (k *KeyRing) AddKeySettings(key sshkey.PrivateKeyFile) (string, error)
AddKeySettings saves PrivateKeyFile informatio in the store
func (*KeyRing) DeleteKeySettings ¶
DeleteKeySettings Delete PrivateKeyFile informatio in the store
func (*KeyRing) KeyList ¶
func (k *KeyRing) KeyList() ([]sshkey.PrivateKeyFile, error)
KeyList wails function to display the key list with
func (*KeyRing) SignWithFlags ¶
Click to show internal directories.
Click to hide internal directories.