Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // DirPath is the path of the default SSH directory. DirPath = ".ssh" // AuthorizedKeysPath is the path of the default authorized_keys file for SSH. AuthorizedKeysPath = ".ssh/authorized_keys" )
Functions ¶
func AuthorizeKeys ¶
AuthorizeKeys appends the given SSH public keys to the given os.File.
func AuthorizeKeysFor ¶
AuthorizeKeysFor initializes the SSH directory structure for the user and appends the given public keys to user's authorized keys file.
func InitializeFor ¶
InitializeFor checks whether .ssh directory exists in the given user's home directory and creates the directory if it doesn't exist.
Types ¶
Click to show internal directories.
Click to hide internal directories.