Documentation
¶
Index ¶
- type Client
- func (c *Client) Close() error
- func (c *Client) Connect() (err error)
- func (c *Client) Run(commands []string, login bool) ([]string, error)
- func (c *Client) ScpGet(path string) ([]byte, error)
- func (c *Client) ScpPut(path string, file []byte) error
- func (c *Client) WithPTY(cb func(io.WriteCloser, io.Reader)) error
- func (c *Client) WithSession(cb func(*ssh.Session)) error
- type Config
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is an SSH session with the HSM.
type Config ¶
type Config struct {
Nickname string `json:"nickname"`
Hostname string `json:"hostname"`
SSHport int `json:"ssh_port"`
SSHlogin string `json:"ssh_login"`
SSHpassword string `json:"ssh_password"`
SSHfingerprint string `json:"ssh_fingerprint"`
Password string `json:"hsm_password"`
}
Config stores information about a single HSM configuration.
func LoadAllConfigs ¶
LoadAllConfigs loads all Configs from a config file.
func LoadConfig ¶
LoadConfig loads the config for the HSM with the given nickname or hostname.
func LoadConfigs ¶
LoadConfigs loads the configs for the HSMs with the given nicknames or hostnames.
Click to show internal directories.
Click to hide internal directories.