mirror of
https://github.com/Dichgrem/Blog.git
synced 2025-02-22 21:48:36 -05:00
just push
This commit is contained in:
parent
2dc0946075
commit
bdd70817d4
@ -393,12 +393,13 @@ ip -6 addr show scope global
|
||||
|
||||
- 随后将.pub后缀的公钥中的内容写入服务器的``~/.ssh/authorized_keys``中;
|
||||
|
||||
- 使用命令``vim /etc/ssh/sshd_config``编译服务器的SSH配置,将其中的该行改为``PasswordAuthentication no``,保存退出;随后使用``sudo systemctl restart sshd``重启SSH即可禁用密码登录;
|
||||
- 使用命令``vim /etc/ssh/sshd_config``编译服务器的SSH配置,将其中的该行改为``PasswordAuthentication no``,保存退出;随后使用``sudo systemctl restart sshd``重启SSH即可禁用密码登录;将**PermitRootLogin prohibit-password**改为prohibit-password,即可实现仅root用户密钥登录;
|
||||
|
||||
- 使用``sudo cat /etc/ssh/sshd_config | grep -E 'PasswordAuthentication|PubkeyAuthentication'
|
||||
`` 命令查看输出,如有**PasswordAuthentication no → 禁用密码登录**以及**PubkeyAuthentication yes → 允许密钥登录**则成功。 ``
|
||||
- 使用**sudo cat /etc/ssh/sshd_config | grep -E 'PasswordAuthentication|PubkeyAuthentication'**命令查看输出,如有**PasswordAuthentication no → 禁用密码登录**以及**PubkeyAuthentication yes → 允许密钥登录**则成功。
|
||||
|
||||
- 注意**authorized_keys**的权限为600,如果不是则需要改正:``chmod 600 ~/.ssh/authorized_keys``
|
||||
|
||||
- 随后可以在本地尝试登录,命令为``ssh -i ~/.ssh/id_xxx -p 端口 用户名@服务器IP``,第一次登录会提示服务器公钥的哈希值,需要选Yes。
|
||||
|
||||
|
||||
|
||||
|
@ -334,10 +334,10 @@
|
||||
<p>随后将.pub后缀的公钥中的内容写入服务器的<code>~/.ssh/authorized_keys</code>中;</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>使用命令<code>vim /etc/ssh/sshd_config</code>编译服务器的SSH配置,将其中的该行改为<code>PasswordAuthentication no</code>,保存退出;随后使用<code>sudo systemctl restart sshd</code>重启SSH即可禁用密码登录;</p>
|
||||
<p>使用命令<code>vim /etc/ssh/sshd_config</code>编译服务器的SSH配置,将其中的该行改为<code>PasswordAuthentication no</code>,保存退出;随后使用<code>sudo systemctl restart sshd</code>重启SSH即可禁用密码登录;将<strong>PermitRootLogin prohibit-password</strong>改为prohibit-password,即可实现仅root用户密钥登录;</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>使用<code>sudo cat /etc/ssh/sshd_config | grep -E 'PasswordAuthentication|PubkeyAuthentication' </code> 命令查看输出,如有<strong>PasswordAuthentication no → 禁用密码登录</strong>以及<strong>PubkeyAuthentication yes → 允许密钥登录</strong>则成功。 ``</p>
|
||||
<p>使用<strong>sudo cat /etc/ssh/sshd_config | grep -E 'PasswordAuthentication|PubkeyAuthentication'<strong>命令查看输出,如有</strong>PasswordAuthentication no → 禁用密码登录</strong>以及<strong>PubkeyAuthentication yes → 允许密钥登录</strong>则成功。</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>注意<strong>authorized_keys</strong>的权限为600,如果不是则需要改正:<code>chmod 600 ~/.ssh/authorized_keys</code></p>
|
||||
|
BIN
public/pagefind/fragment/en_65987e9.pf_fragment
Normal file
BIN
public/pagefind/fragment/en_65987e9.pf_fragment
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
public/pagefind/index/en_62a2501.pf_index
Normal file
BIN
public/pagefind/index/en_62a2501.pf_index
Normal file
Binary file not shown.
BIN
public/pagefind/index/en_6b8bfb9.pf_index
Normal file
BIN
public/pagefind/index/en_6b8bfb9.pf_index
Normal file
Binary file not shown.
Binary file not shown.
BIN
public/pagefind/index/en_9dc8e02.pf_index
Normal file
BIN
public/pagefind/index/en_9dc8e02.pf_index
Normal file
Binary file not shown.
BIN
public/pagefind/index/en_a45bb42.pf_index
Normal file
BIN
public/pagefind/index/en_a45bb42.pf_index
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -1 +1 @@
|
||||
{"version":"1.3.0","languages":{"en":{"hash":"en_9e6273b20d","wasm":"en","page_count":105}}}
|
||||
{"version":"1.3.0","languages":{"en":{"hash":"en_1267fe75e5","wasm":"en","page_count":105}}}
|
BIN
public/pagefind/pagefind.en_1267fe75e5.pf_meta
Normal file
BIN
public/pagefind/pagefind.en_1267fe75e5.pf_meta
Normal file
Binary file not shown.
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user