ssh using public key
fedora core - 2
i want to login to a remote server thru ssh using public key authentication. The remote server is on suse. suppose the username on the remote box is "user1" .
# ssh-keygen -t dsa -b 2048
i created one user with same username "user1" in my box.
i used the above command & placed the private key file in /home/user1/.ssh in my machine & placed the public key file in /home/user1/.ssh in remote machine.
now i try to login using
# ssh firstname.lastname@example.org where x.x.x.x is the IP add of the remote box.
the reply is
permission denied : public key
Can anyone guide me ????
though i'm never dealing with the ssh-keygen, but maybe you can try what i do with ssh
1. remove .ssh/ directory on your home directory
2. now connect your computer to our linux box, this will create a new key again
3. have you open port 22 from your firewall, (make sure it first)
hope this help
Ok, you want to login and not be prompted with password, right?
Then you'll have to create the key localy on the computer you are connecting from, and import the key into the keyfile at remote host $HOME/user1/.ssh
That should do it. Since the public/private key negotiation is made upon that you trust each and other host, the host-key has to be done from each host you wish to logon from.