sshd

package
v0.1.0-rc.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 18, 2022 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetShell

func GetShell(shell string) error

GetShell returns the shell in $PATH.

func LoadAuthorizedKeys

func LoadAuthorizedKeys(path string) ([]ssh.PublicKey, error)

LoadAuthorizedKeys loads path as an array. It will return nil if path doesn't exist.

Types

type Server

type Server struct {
	Port           int
	Shell          string
	AuthorizedKeys []ssh.PublicKey
}

Server holds the ssh server configuration.

func (*Server) ListenAndServe

func (srv *Server) ListenAndServe() error

ListenAndServe starts the SSH server using port

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL