Documentation ¶
Index ¶
- func Agent() (gossh.AuthMethod, error)
- func EncodePrivateKeyToPEM(privateKey *rsa.PrivateKey) []byte
- func EnterKeyPhrase(keyFile string) []byte
- func GeneratePrivateRSAKey(size int) (*rsa.PrivateKey, error)
- func KeyFile(keyFile string) (gossh.AuthMethod, error)
- func PrivateKey(keyFile string) (gossh.AuthMethod, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EncodePrivateKeyToPEM ¶
func EncodePrivateKeyToPEM(privateKey *rsa.PrivateKey) []byte
EncodePrivateKeyToPEM is a helper function for converting a key to PEM format.
func EnterKeyPhrase ¶
EnterKeyPhrase is required to read phrase protected private keys.
func GeneratePrivateRSAKey ¶
func GeneratePrivateRSAKey(size int) (*rsa.PrivateKey, error)
GeneratePrivateRSAKey is used by the server to generate its key.
func KeyFile ¶
func KeyFile(keyFile string) (gossh.AuthMethod, error)
KeyFile returns the key as a SSH auth method.
func PrivateKey ¶
func PrivateKey(keyFile string) (gossh.AuthMethod, error)
PrivateKey returns the private key as a SSH auth method.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.