go-ssh-examples

Go examples of SSH servers and clients

  • 所有者: Scalingo/go-ssh-examples
  • 平台:
  • 許可證: BSD 2-Clause "Simplified" License
  • 分類:
  • 主題:
  • 喜歡:
    0
      比較:

Github星跟蹤圖

SSH Client/Server example with Go

Initialization

To setup a SSH server, a host ssh keypair (usually RSA) has to be created, to do so, run:

bash init.sh

Those files should have been created in the project directory:

  • ./host_key
  • ./host_key.pub

Simple client usage

go run client.go <user> <server:port> <command>

Example:

└> go run client.go foobar example.com:22 'ls /'
Password: *********
bin
boot
conf.d
dev
etc
home
initrd.img
lib
lib64
lost+found
media
mnt
opt
proc
root
run
sbin
srv
sys
tmp
usr
var
vmlinuz

Notes:

Please create issues, if you want more details.

主要指標

概覽
名稱與所有者Scalingo/go-ssh-examples
主編程語言Go
編程語言Go (語言數: 2)
平台
許可證BSD 2-Clause "Simplified" License
所有者活动
創建於2014-12-05 14:48:45
推送於2023-06-23 08:02:11
最后一次提交2023-06-23 10:02:11
發布數0
用户参与
星數284
關注者數12
派生數66
提交數15
已啟用問題?
問題數10
打開的問題數6
拉請求數2
打開的拉請求數0
關閉的拉請求數0
项目设置
已啟用Wiki?
已存檔?
是復刻?
已鎖定?
是鏡像?
是私有?