Documentation
¶
Index ¶
- type Agent
- func (a *Agent) Add(key agent.AddedKey) error
- func (a *Agent) Extension(extensionType string, contents []byte) ([]byte, error)
- func (a *Agent) List() ([]*agent.Key, error)
- func (a *Agent) Lock(passphrase []byte) error
- func (a *Agent) Remove(key ssh.PublicKey) error
- func (a *Agent) RemoveAll() error
- func (a *Agent) Sign(key ssh.PublicKey, data []byte) (*ssh.Signature, error)
- func (a *Agent) SignWithFlags(key ssh.PublicKey, data []byte, flags agent.SignatureFlags) (*ssh.Signature, error)
- func (a *Agent) Signers() ([]ssh.Signer, error)
- func (a *Agent) Unlock(passphrase []byte) error
- type MuxAgent
- func (m *MuxAgent) Add(key agent.AddedKey) error
- func (m *MuxAgent) Extension(extensionType string, contents []byte) ([]byte, error)
- func (m *MuxAgent) List() ([]*agent.Key, error)
- func (m *MuxAgent) Lock(passphrase []byte) error
- func (m *MuxAgent) Remove(key ssh.PublicKey) error
- func (m *MuxAgent) RemoveAll() error
- func (m *MuxAgent) Sign(key ssh.PublicKey, data []byte) (*ssh.Signature, error)
- func (m *MuxAgent) SignWithFlags(key ssh.PublicKey, data []byte, flags agent.SignatureFlags) (*ssh.Signature, error)
- func (m *MuxAgent) Signers() ([]ssh.Signer, error)
- func (m *MuxAgent) Unlock(passphrase []byte) error
- func (m *MuxAgent) Update(targets []*Agent, addTargets []*Agent, selectTargetCommand string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Agent ¶
type Agent struct {
// contains filtered or unexported fields
}
func MustNewAgent ¶
MustNewAgent creates a new Agent instance and connects to the agent socket. It panics if the connection fails. This is for compatibility with existing code. Prefer NewAgent for error handling.
func NewAgent ¶ added in v0.4.0
NewAgent creates a new Agent instance and connects to the agent socket. It returns an error if the connection fails.
func (*Agent) Lock ¶ added in v0.0.3
Lock locks the agent. Sign and Remove will fail, and List will empty an empty list.
func (*Agent) Sign ¶ added in v0.0.3
Sign has the agent sign the data using a protocol 2 key as defined in [PROTOCOL.agent] section 2.6.2.
func (*Agent) SignWithFlags ¶ added in v0.0.4
type MuxAgent ¶
type MuxAgent struct {
AddTargets []*Agent
Targets []*Agent
SelectTargetCommand string
// contains filtered or unexported fields
}
func NewMuxAgent ¶
func (*MuxAgent) SignWithFlags ¶ added in v0.0.4
func (m *MuxAgent) SignWithFlags(key ssh.PublicKey, data []byte, flags agent.SignatureFlags) (*ssh.Signature, error)
SignWithFlags implements agent.ExtendedAgent.
Click to show internal directories.
Click to hide internal directories.