在SecureCRT中配置SSH密钥认证是一个相对简单的过程,以下是详细的步骤:
Tools
> Key Generation...
。Generate
按钮生成密钥对,通常会生成两个文件:Identity
(私钥)和 Identity.pub
(公钥)。Identity.pub
文件上传到远程服务器的 ~/.ssh
目录下。可以使用FTP、SCP或其他文件传输工具。~/.ssh
目录,创建 authorized_keys
文件(如果不存在),并将 Identity.pub
文件的内容追加到该文件中。chmod 700 ~/.ssh
chmod 644 ~/.ssh/authorized_keys
/etc/ssh/sshd_config
,确保以下配置项设置正确:PermitRootLogin no
PubkeyAuthentication yes
AuthorizedKeysFile .ssh/authorized_keys
RSAAuthentication yes
PasswordAuthentication no
/etc/init.d/ssh restart
File
> New Session...
。SSH2
或 SSH1
标签页。Key Authentication
,然后点击 Browse...
按钮选择私钥文件(Identity
文件)。OK
保存会话配置。完成以上步骤后,您就可以使用SSH密钥认证方式通过SecureCRT安全地连接到远程服务器了。如果登录过程中需要输入通行短语,请输入在密钥生成时设置的通行短语。