Exemplo n.º 1
0
Arquivo: sign.go Projeto: jsdir/fleet
// NewSignatureVerifierFromSSHAgent return SignatureVerifier which uses ssh-agent to verify
func NewSignatureVerifierFromSSHAgent() (*SignatureVerifier, error) {
	keyring, err := ssh.NewSSHAgentKeyring()
	if err != nil {
		return nil, err
	}
	return NewSignatureVerifierFromKeyring(keyring)
}
Exemplo n.º 2
0
Arquivo: sign.go Projeto: jsdir/fleet
// NewSignatureCreatorFromSSHAgent return SignatureCreator which uses ssh-agent to sign
func NewSignatureCreatorFromSSHAgent() (*SignatureCreator, error) {
	keyring, err := ssh.NewSSHAgentKeyring()
	if err != nil {
		return nil, err
	}
	return &SignatureCreator{keyring}, nil
}