|
|
@@ -359,9 +359,8 @@ func testPermissionsPassing(withPermissions bool, t *testing.T) {
|
|
|
PublicKeyCallback: func(conn ConnMetadata, key PublicKey) (*Permissions, error) {
|
|
|
if conn.User() == "nopermissions" {
|
|
|
return nil, nil
|
|
|
- } else {
|
|
|
- return &Permissions{}, nil
|
|
|
}
|
|
|
+ return &Permissions{}, nil
|
|
|
},
|
|
|
}
|
|
|
serverConfig.AddHostKey(testSigners["rsa"])
|
|
|
@@ -510,9 +509,8 @@ func TestClientAuthMaxAuthTries(t *testing.T) {
|
|
|
n--
|
|
|
if n == 0 {
|
|
|
return "right", nil
|
|
|
- } else {
|
|
|
- return "wrong", nil
|
|
|
}
|
|
|
+ return "wrong", nil
|
|
|
}), tries),
|
|
|
},
|
|
|
HostKeyCallback: InsecureIgnoreHostKey(),
|