Questions tagged [known-hosts]
The known-hosts tag has no usage guidance.
36
questions
1
vote
1
answer
612
views
Is it ok if I deleted the known_hosts file from .ssh folder?
I set up SFTP server in my local PC (Windows 10) but I made a mistake and deleted the "known_hosts" and "known_hosts.old" file in ".ssh" folder. When I check Recycle Bin, ...
0
votes
1
answer
309
views
Why did GitHub site change?
Some time ago (long enough that I have forgotten the details), I successfully set up SSH authentication for my GitHub repository (along with corresponding keys in RStudio). It worked fine.
But ...
1
vote
1
answer
77
views
scp doesn't trigger initial prompt even though known_hosts is empty or deleted
I have a bash script to copy a file to a remote server using scp and expect. The script is as follows:
#!/usr/bin/expect -f
set port [lindex $argv 0]
set file_to_send [lindex $argv 1]
set login [...
2
votes
1
answer
3k
views
What are the restrictions to ssh StrictHostKeyChecking=no?
When running ssh with StrictHostKeyChecking=no, it should always accept CHANGED keys.
However it does not in my case. This is documented in the man page (ssh-config):
StrictHostKeyChecking
...
1
vote
1
answer
548
views
When is a new SSH host key generated?
I copied an EC2 instance from an AMI image and brought it back up. After that I had to remove the entry in my known_hosts file because the SSH host key fingerprint changed. However, I thought that the ...
0
votes
0
answers
1k
views
Getting message "The authenticity of host can't be established" but host is in known_hosts
I've just tried to connect to an SSH server to which I've connected before, but I'm getting this message:
The authenticity of host '[HOST]:PORT ([IP]:PORT)' can't be established.
D25519 key ...
0
votes
1
answer
850
views
Script SCP with public key
I need to configure a script to copy some files from one Ubuntu server to another.
The key uses is allowed in the authorized_keys on remote server.
I'm trying to configure this script:
#!/bin/sh
#...
0
votes
1
answer
804
views
Known_Hosts File
I have a couple of Raspberry Pis connected to an HP Windows 10 computer via an Ethernet LAN. When I ssh to either of the Pis from the HP I get the standard "ECDSA host key" warning. But the ...
0
votes
1
answer
3k
views
When is it better to use ssh-keyscan instead of ssh to manage known_hosts?
When is executed
ssh -i id_rsa_something [email protected]
appears:
The authenticity of host '192.168.1.2 (192.168.1.2)' can't be established.
ECDSA key fingerprint is SHA256:ABCABC [fixed/...
0
votes
0
answers
243
views
ssh known_hosts seems to be ignored if using ssh as a launchd agent on MacOS
I have a service that acquires data with ssh. This works on linux in systemd, but in trying to do the equivalent on mac, I don't think the ~/.ssh/known_hosts file is being respected, because an ...
3
votes
0
answers
200
views
What is this entry in my ssh known_hosts file?
I was taking a look at my ssh known_hosts file, and it only included 2 entries. The first line was the GitHub keys, so nothing weird there. However, the second line had a bunch of Chinese text, which ...
7
votes
2
answers
30k
views
How to see the list of known hosts Ubuntu
When I sshed into a remote client, I got a warning :
Warning: Permanently added 'xx.xx.xx.xx' (ECDSA) to the list of known hosts.
Where can I see the list of known hosts?
I tried cat ~/.ssh/...
0
votes
1
answer
629
views
How to write a Know_hosts file with md5 format?
I am trying to make a program that automates ssh connections. It can also be used in Windows, so as Putty only accepts MD5 fingerprint format for the hostkey I am trying to make ssh accept MD5 too:
...
0
votes
1
answer
84
views
can I group the servers inside known_hosts file?
I was wondering if there is a way to group servers inside the known_hosts file
something like this:
[AWS]
11.xx.x.1 ecdsa-sha2-nistp256 xxxx=
11.xx.x.2 ecdsa-sha2-nistp256 yyyy=
11.xx.x.3 ecdsa-sha2-...
0
votes
1
answer
72
views
force scenario about REMOTE HOST IDENTIFICATION HAS CHANGED
everyone know the following message
"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@\r",
"@ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @\r",
"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@...
11
votes
3
answers
40k
views
SSH - How to add host to ssh/known_host file
The known_hosts file looks like this :-
[localhost]:8001 ssh-dss AAAAB3NzaC1kc3MAAACBAP1/U4EddRIpU
[10.18.60.198]:8001 ssh-dss AAAAB3NzaC1kc3MAAACBAP1/U4EddRIpUt9
// key are trimmed at the end
...
35
votes
2
answers
49k
views
Configure ssh-key path to use for a specific host
When connecting via SSH my terminal wants to use id_rsa by default. I don't want to use that key for this particular server. So I am forced to specify the proper key path when connecting:
This works ...
0
votes
1
answer
3k
views
Automate adding host and IP to known hosts
I wanted to get rid of some warnings I'm getting when running an automated builds environment (Scrutinizer-CI, to be precise).
Digging here, I've found this solution I can add to the script which ...
4
votes
2
answers
29k
views
How to add SSH known host to known host file on Windows?
The known_hosts file does not look trivial. On Windows I see it contains hostname, ip address and some RSA key.
On linux I see it contains several keys separated by bar.
Who manages this file on ...
18
votes
1
answer
34k
views
Differing SSH known_hosts formats
I've been having issues with my CI server's deployment lately due to the client (CI) rejecting the remote's host key (despite it being present in known_hosts). I was stumped until today, when I ...
1
vote
1
answer
353
views
how to correct two host names in known_hosts
I'm trying to use ssh-keygen -R to remove a host line. However, each time I attempt this I get a zsh: no matches found:. When I look at the known_hosts file the line I want to modify starts like this [...
0
votes
1
answer
3k
views
SSH Multiple lines for the same public key in known_hosts?
Recently, after some time, I have tried to login to my ssh server on the LAN, and I got this warning:
$ ssh [email protected]
Warning: Permanently added the RSA host key for IP address '192....
0
votes
1
answer
44
views
Cloning Ubuntu "clusters" with ssh access
I have a "cluster" with multiple Ubuntu (12.04) machines, all with the same accounts. From any machine, I need to ssh to any other machine.
I set up ssh, generated keys, known_hosts file, and tested ...
0
votes
2
answers
6k
views
How to display the mac address of known host by ssh
I want to know the MAC address of a machine that I don't have access to at the moment. However, I have a known_hosts file from ssh with a valid entry, and given that I get warnings about changing MAC ...
1
vote
1
answer
250
views
protect the known_host file from writing - good or bad idea?
I want to protect the known_host file from writing
So I want to perform the following steps on my Linux red-hat server
Cp /dev/null /root/.ssh/known_hosts
chattr +i /root/.ssh/known_hosts
I want ...
2
votes
1
answer
349
views
Known hosts file keeps getting deleted
Have a weird issue where my known_hosts file is getting deleted periodically. Is there any way I can watch the file to see what may be deleting it? Any OSX logs that can be monitored to see what might ...
0
votes
1
answer
553
views
Host angularjs.org not found: 3(NXDOMAIN)
My MacBook Pro OSX 10.9.4 has network problems now, and I cannot figure it out what is causing the problem.
Today I am not able to access angularjs.org with any browser, but I can access other ...
0
votes
2
answers
2k
views
Cent OS 6 - Do I need to restart a service after updating .ssh/known_hosts
After updating my .ssh/known_hosts file do I need to restart a service? I tried service ssh restart but it gives ssh: unrecognized service.
4
votes
0
answers
2k
views
How to convert Putty registry entry to known_hosts format?
Using Putty, I connected to a remote host. As this was a first time me doing so, as expected, ssh key was added.
Google helped me find registry entry, but it is not in a known_hosts format.
How can ...
15
votes
2
answers
8k
views
SSH: known host with dynamic address
I need to connect to a host with a dynamic IP address.
Every time its IP changes, SSH prompts me the fingerprint validation thing:
The authenticity of host '...' can't be established.
RSA key ...
4
votes
2
answers
5k
views
Copying known_hosts between computers?
Connect to a server using OpenSSH_5.9p1 OpenSSL 1.0.1, and it stores a .ssh/known_hosts that's of the format:
|1|wwwwwwwwwwwwwww=|wwwwwwwwww= ecdsa-sha2-nistp256 AAAAAAAAAA+AAAAA=
Then copy that ...
90
votes
1
answer
31k
views
How do I extract fingerprints from .ssh/known_hosts?
My laptop has a well-populated ~/.ssh/known_hosts file. I'd like to leverage that when connecting to remote hosts from my desktop, since tracking down the fingerprints can be a real chore. However, I ...
1
vote
2
answers
13k
views
Create a new known_hosts file for openSSH in windows
So i have OpenSSH in windows 7 at a university and i am basicly having this problem:
When i first use SSH it is trying to create the known_hosts file on my university network drive H:
But this is ...
3
votes
1
answer
1k
views
known_hosts file doesn't get populated anymore
I had a populated known_hosts file. I was editing it and for a split second I saw a permission error when I saved it. I went to check what the error was and the known_hosts file was blank.
Now if I ...
132
votes
3
answers
174k
views
Where does Putty store known_hosts information on Windows?
How do I tell if Putty already knows about and has cached credentials for specific ssh servers?
Another way to ask this question is what is the Windows/Putty equivalent of a unix/ssh known_hosts file?...
4
votes
3
answers
4k
views
Can I use ssh host key verification with a round-robin DNS?
I'm logging into a server based on a round-robin DNS hostname -- "login.example.com" could go to any of a number of servers. Ideally, I'd like to be able to update my known_hosts file such that ...