SFTP秘钥认证

到当前用户目录下

cd ~

/home/[user]

找到 .ssh目录

cd .ssh

 

 

ssh-keygen -t rsa   执行创建密钥对命令

Generating public/private rsa key pair.

Please be patient....   Key generation may take a few minutes

Enter file in which to save the key (/home/ap/appnms/.ssh/id_rsa):

# 按回车保存为: //.ssh/id_rsa,即当前用户的私钥 私钥名称可以在这里自定义

Enter passphrase (empty for no passphrase):

# 按回车,表示读取密钥时不需要密钥的密码

Enter same passphrase again:

# 确认密钥的密码,必须和上面的输入相同

Your identification has been saved in /home/ap/appnms/.ssh/id_rsa.

# 私钥保存信息

Your public key has been saved in /home/ap/appnms/.ssh/id_rsa.pub.

# 公钥保存信息

The key fingerprint is:

31:03:78:64:4f:8e:9d:a9:31:bf:38:5d:1a:79:08:e6 appnms@T254N0V4

# 密钥指纹

The key's randomart image is:

+--[ RSA 2048]----+

|     o+ .        |

|    ...B o       |

|     .* X        |

|     o * *       |

|      E S o      |

|       o *       |

|      o +        |

|       .         |

|                 |

+-----------------+

 

转载于:https://www.cnblogs.com/jiaozi-li/p/8064939.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值