古いものをクリアする方法SSHknown_hosts からの公開キー
63620
Created On 04/03/19 06:02 AM - Last Modified 10/03/24 03:46 AM
Objective
ときfirewall~のクライアントとして使用されますSSHリモート システム上 (例:SCPファイルをコピーするため)、対応するリモート システムの公開証明書の記録を保持します。IP住所。
リモート システムの証明書が変更されると、おそらく自己署名証明書から公開署名証明書への移行、または新しい証明書とキーのペアの生成が原因で、古い証明書が変更されます。SSHに保存されている公開証明書firewallを削除する必要があります。
新しい公開証明書をIP上記の変更に対処するため。
Environment
- PAN-OS 10.1.5
- パロアルト Firewall
admin@firewall> scp export log traffic start-time equal 2019/02/01@00:00:00 end-time equal 2019/02/27@23:59:00 to admin@10.129.128.68:/test.csv The authenticity of host '10.129.128.68 (10.129.128.68)' can't be established. ECDSA key fingerprint is 53:7e:05:8e:15:e3:98:1b:4f:61:50:43:97:af:a2:bc. Are you sure you want to continue connecting (yes/no)? yes Warning: Permanently added '10.129.128.68' (ECDSA) to the list of known hosts. admin@10.129.128.68's password: Marking log as exported successfully...
上記のフィンガープリントが変更されると、エラーが発生します下:
admin@firewall> scp export log traffic start-time equal 2019/02/01@00:00:00 end-time equal 2019/02/27@23:59:00 to admin@10.129.128.68:/test.csv @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ @ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY! Someone could be eavesdropping on you right now (man-in-the-middle attack)! It is also possible that a host key has just been changed. The fingerprint for the RSA key sent by the remote host is f0:70:ae:18:1c:5e:2f:02:0d:c5:4e:59:ab:ea:cc:72. Please contact your system administrator. Add correct host key in /opt/pancfg/home/admin/.ssh/known_hosts to get rid of this message. Offending RSA key in /opt/pancfg/home/admin/.ssh/known_hosts:1 RSA host key for 10.129.128.68 has changed and you have requested strict checking. Host key verification failed. Log export failure.
Procedure
- を保存するユーザー ディレクトリを決定します。SSH指紋。 これは、ホーム ディレクトリの後ろから決定できます (この例では admin です)。
admin@firewall> scp export log traffic start-time equal 2019/02/01@00:00:00 end-time equal 2019/02/27@23:59:00 to admin@10.129.128.68:/test.csv @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ @ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY! Someone could be eavesdropping on you right now (man-in-the-middle attack)! It is also possible that a host key has just been changed. The fingerprint for the RSA key sent by the remote host is f0:70:ae:18:1c:5e:2f:02:0d:c5:4e:59:ab:ea:cc:72. Please contact your system administrator. Add correct host key in /opt/pancfg/home/admin/.ssh/known_hosts to get rid of this message. Offending RSA key in /opt/pancfg/home/admin/.ssh/known_hosts:1 . <<<<<<<<<<<<<<<<<<<<<<<<<<< RSA host key for 10.129.128.68 has changed and you have requested strict checking. Host key verification failed. Log export failure.
- 問題のあるものを削除しますSSHコマンドを使用したフィンガープリント認証ユーザーファイルの削除 ssh-known-hosts ユーザー IP
admin@firewall> delete authentication user-file ssh-known-hosts user ip 10.129.128.68 username admin Entry for 10.129.128.68 in ssh-known-hosts file removed for admin