gossh

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Jul 18, 2019 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddConf

func AddConf(db *bolt.DB, rootBucketConf string, key string, value string) error

AddConf for updating sha key to database with hosts informations

func AddHosts

func AddHosts(db *bolt.DB, rootBucket string, bucket string, hostname string, ip string, user string, port string, pass string, key []byte) error

AddHosts for updating database with hosts informations

func DeleteHost

func DeleteHost(db *bolt.DB, rootBucket string, bucket string, host string) error

DeleteHost for deleting host from db

func FindConf

func FindConf(db *bolt.DB, rootBucket string, key string) string

FindConf search for key pair

func GetKey

func GetKey() string

GetKey Get sha key for encrypt and decrypt of entry

func KeyGen

func KeyGen() error

KeyGen generate sha key for conf db

func ListBucket

func ListBucket(db *bolt.DB, rootBucket string, bucket string, arg string)

ListBucket for listings all hosts and value

func ListBucketHOSTS

func ListBucketHOSTS(db *bolt.DB, rootBucket string, bucket string)

ListBucketHOSTS for listings all hosts

func SetupDB

func SetupDB(dbFile string, rootBucket string, bucket string) (*bolt.DB, error)

SetupDB for setting up root bucket and bucket

Types

type Config

type Config struct {
	IP         string `json:"ip"`
	User       string `json:"user"`
	PortNumber string `json:"port"`
	Password   string `json:"password"`
	Key        []byte `json:"key"`
}

Config struct which contain hosts infomation

func FindHost

func FindHost(db *bolt.DB, rootBucket string, bucket string, host string) Config

FindHost search for host detail

func (Config) SSSHConn

func (c Config) SSSHConn()

SSSHConn make ssh connection to server

Jump to

Keyboard shortcuts

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