自拍偷在线精品自拍偷,亚洲欧美中文日韩v在线观看不卡

CentOS Linux創(chuàng)建私鑰與SSH配置文件

系統(tǒng) Linux
CentOS Linux創(chuàng)建進入sshd_config(/etc/ssh/sshd_config)#ServerKeyBits 768 ServerKeyBits 1024 修改加密強度為1024bit

向大家詳細介紹CentOS Linux創(chuàng)建公鑰與私鑰,首先讓大家了解下CentOS Linux系統(tǒng),然后全面介紹CentOS Linux創(chuàng)建,希望對大家有用。CentOS Linux和與之對應版本號的RHEL發(fā)行版具有軟件包級別的二進制兼容性,即某個RPM軟件包如果可以安裝運行在RHEL產(chǎn)品中,就可以正常地安裝運行在對應版本的CentOS Linux中。CentOS Linux創(chuàng)建安全的私鑰文件。

1、CentOS Linux創(chuàng)建進入sshd_config(/etc/ssh/sshd_config)#ServerKeyBits 768ServerKeyBits 1024 修改加密強度為1024bit#PasswordAuthentication yes
PasswordAuthenticatino no 不允許密碼方式登陸#PermitEmptyPasswords onPermitEmptyPasswords no 禁止空密碼登陸

2、CentOS Linux創(chuàng)建修改hosts.deny(/etc/hosts.deny)文件,禁止所有的SSH連接。在hosts.deny文件末尾加上sshd:ALL

3、CentOS Linux創(chuàng)建修改hosts.allow(/etc/hosts.allow)文件,加上允許進行SSH連接的IP地址或IP地址段。在hosts.allow文件末尾加上sshd:IP地址或IP地址段

4、CentOS Linux創(chuàng)建重啟SSH服務service sshd restart

5、CentOS Linux創(chuàng)建公鑰與私鑰文件[root@CentOS~]ssh-keygen -t rsa 創(chuàng)建公鑰與私鑰Generating public/private rsa key pair.Enter file in which to save the key (/root/.ssh/id_rsa):  ← 鑰匙的文件名,這里保持默認直接回車Created directory '/root/.ssh'Enter passphrase (empty for no passphrase):  ← 輸入口令Enter same passphrase again:   ← 再次輸入口令Your identification has been saved in /root/.ssh/id_rsa.Your public key has been saved in /root/.ssh/id_rsa.pub.The key fingerprint is:
tf:rs:e3:7s:28:59:5s:93:fe:33:84:01:cj:65:3b:8e root@CentOS~[root@CentOS ~]# cd ~/.ssh  ← 進入用戶SSH配置文件的目錄[root@CentOS ~]# ls -l  ← 列出文件total 16 -rw------- 1 root root 951 Sep 4 19:22 id_rsa  ← 確認私鑰已被建立-rw-r--r-- 1 root root 241 Sep 4 19:22 id_rsa.pub  ← 確認公鑰已被建立
[root@CentOS ~]# cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys  ← 公鑰內(nèi)容輸出到相應文件中
[root@CentOS ~]# rm -f ~/.ssh/id_rsa.pub  ← 刪除原來的公鑰文件
[root@CentOS ~]# chmod 400 ~/.ssh/authorized_keys  ← 將新建立的公鑰文件屬性設(shè)置為400

6、CentOS Linux導出id_rsa文件

7、使用PuTTY工具組里的PuTTYGen來轉(zhuǎn)換私鑰,打開PuTTYGen,選擇“載入”,選擇剛才的“id_rsa”文件(選擇文件的時候,文件類型改為“所有文件(*.*)”),輸入剛才創(chuàng)建公鑰與私鑰時候的密碼,便可以轉(zhuǎn)缼成功,并選擇“保存私鑰”。

8、在用PuTTY登陸Linux系統(tǒng)的時候,在下面的“SSH”-“認證”里,在“認證私鑰文件處”選擇剛才轉(zhuǎn)換的私鑰文件即可進行登陸。以上介紹CentOS Linux系統(tǒng)創(chuàng)建。

【編輯推薦】

  1. CentOS CDROM掛載使用mount命令
  2. CentOS yum配置安裝軟件與配置文件修改
  3. CentOS5.2 Apache搭建系統(tǒng)開發(fā)環(huán)境
  4. centos5.1遠程控制升級安裝ssl配置編譯
  5. centos4安裝oracle 10g創(chuàng)建帳戶與配置Linux內(nèi)核參數(shù)
責任編輯:佚名 來源: CSDN
相關(guān)推薦

2010-01-15 10:36:49

CentOS yum配

2011-01-13 16:27:26

Linux配置文件

2010-02-22 16:49:35

CentOS vsft

2010-02-04 13:43:26

Linux vsFTP

2010-01-13 13:50:53

CentOS Vsft

2010-01-08 17:32:11

Ubuntu samb

2010-01-14 16:35:42

CentOS 操作系統(tǒng)

2010-03-01 15:26:18

Linux配置文件

2009-08-18 10:56:40

Linux網(wǎng)卡配置Linux網(wǎng)卡配置

2010-03-01 10:14:01

Linux usera

2010-01-13 14:45:25

CentOS配置

2010-01-13 10:48:49

Centos設(shè)置

2010-02-22 15:59:48

2022-06-06 08:47:32

Ansible配置文件

2023-10-30 15:11:57

2010-01-07 17:16:19

Ubuntu MySQ

2010-03-01 14:46:41

Linux hostn

2010-01-12 16:50:07

Linux minig

2010-01-12 13:47:18

Linux grub

2010-03-03 14:25:37

Linux NTP
點贊
收藏

51CTO技術(shù)棧公眾號