欢迎您访问 最编程 本站为您分享编程语言代码,编程技术文章!
您现在的位置是: 首页

如何解决Windows系统中连接SSH时.pem权限过开放的问题?

最编程 2024-02-12 18:07:45
...

Windows使用 -i 连接服务器ssh时报错:

Permissions for ‘1.pem’ are too open.
It is required that your private key files are NOT accessible by others.
This private key will be ignored.
Load key “1.pem”: bad permissions

这是因为.pem文件权限太大了。

解决方法:

1. 右击.pem文件,‘属性’ -> ‘安全’ -> ‘高级’:

在这里插入图片描述

2. 将所有者改为你自己,删除掉其它所有用户的权限:

在这里插入图片描述

3. Ok!