Documentation ¶
Index ¶
- func PrintCertificate(cert *ssh.Certificate, w io.Writer) error
- type Agent
- type AgentKeyManager
- func (a *AgentKeyManager) GetKey() (crypto.PublicKey, crypto.PrivateKey, error)
- func (a *AgentKeyManager) HasValidCertificate() (bool, error)
- func (a *AgentKeyManager) ListCertificates() ([]*ssh.Certificate, error)
- func (a *AgentKeyManager) WriteKey(priv crypto.PrivateKey, cert *ssh.Certificate) error
- type KeyManager
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PrintCertificate ¶ added in v1.3.0
func PrintCertificate(cert *ssh.Certificate, w io.Writer) error
Types ¶
type Agent ¶ added in v0.5.0
type Agent struct { agent.ExtendedAgent // contains filtered or unexported fields }
func GetSSHAgent ¶ added in v0.5.0
Get an SSH agent
type AgentKeyManager ¶ added in v0.7.0
type AgentKeyManager struct {
// contains filtered or unexported fields
}
func (*AgentKeyManager) GetKey ¶ added in v0.7.0
func (a *AgentKeyManager) GetKey() (crypto.PublicKey, crypto.PrivateKey, error)
GetKey will generate new ssh keypair
func (*AgentKeyManager) HasValidCertificate ¶ added in v0.7.0
func (a *AgentKeyManager) HasValidCertificate() (bool, error)
func (*AgentKeyManager) ListCertificates ¶ added in v0.7.0
func (a *AgentKeyManager) ListCertificates() ([]*ssh.Certificate, error)
func (*AgentKeyManager) WriteKey ¶ added in v0.7.0
func (a *AgentKeyManager) WriteKey( priv crypto.PrivateKey, cert *ssh.Certificate, ) error
WriteKey will write the key and certificate to the agent
type KeyManager ¶ added in v0.7.0
type KeyManager interface { GetKey() (crypto.PublicKey, crypto.PrivateKey, error) WriteKey(crypto.PrivateKey, *ssh.Certificate) error HasValidCertificate() (bool, error) ListCertificates() ([]*ssh.Certificate, error) }
func NewAgentKeyManager ¶ added in v0.7.0
func NewAgentKeyManager(agent agent.ExtendedAgent) KeyManager
Click to show internal directories.
Click to hide internal directories.