Skip to content

Commit

Permalink
Fix staticheck
Browse files Browse the repository at this point in the history
  • Loading branch information
Philipp Heckel committed Aug 23, 2021
1 parent 0f06097 commit dd718f1
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions bot/bot.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,12 @@ const (

// Key exchange algorithms, ciphers,and MACs (see `ssh-audit` output)
const (
kexAlgoCurve25519Sha256 = "[email protected]"
macHmacSha256Etm = "[email protected]"
cipherAes128Gcm = "[email protected]"
cipherSshRsa = "ssh-rsa"
cipherEd25519 = "ssh-ed25519"
sshVersion = "OpenSSH_7.6p1" // fake!
kexCurve25519SHA256 = "[email protected]"
macHMACSHA256ETM = "[email protected]"
cipherAES128GCM = "[email protected]"
cipherSSHRSA = "ssh-rsa"
cipherED25519 = "ssh-ed25519"
sshVersion = "OpenSSH_7.6p1" // fake!
)

var (
Expand Down Expand Up @@ -416,8 +416,8 @@ func (b *Bot) sshPtyCallback(ctx ssh.Context, pty ssh.Pty) bool {
// sshServerConfigCallback configures the SSH server algorithms to be more secure (see `ssh-audit` output)
func (b *Bot) sshServerConfigCallback(ctx ssh.Context) *gossh.ServerConfig {
conf := &gossh.ServerConfig{}
conf.KeyExchanges = []string{kexAlgoCurve25519Sha256}
conf.Ciphers = []string{cipherAes128Gcm, cipherEd25519, cipherSshRsa}
conf.MACs = []string{macHmacSha256Etm}
conf.KeyExchanges = []string{kexCurve25519SHA256}
conf.Ciphers = []string{cipherAES128GCM, cipherED25519, cipherSSHRSA}
conf.MACs = []string{macHMACSHA256ETM}
return conf
}

0 comments on commit dd718f1

Please sign in to comment.