当我通过 ssh 登录时,-v我看到 ssh 正在通过以下方式进行身份验证
debug1: Authentications that can continue: publickey,gssapi-with-mic,password,hostbased
Run Code Online (Sandbox Code Playgroud)
我想改变顺序……知道怎么做吗?
我更大的问题是帐户锁定的用户仍然可以通过公钥登录。我发现我可以将用户添加到一个“ssh-locked”组中,从 ssh 中添加拒绝该组,但我仍然想知道是否有办法告诉 ssh'd: 请在密钥之前检查密码...