• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Ron McLeod
  • paul wheaton
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
  • Himai Minh
Bartenders:

SSH remote log-in without private key

 
Ranch Hand
Posts: 10198
3
Mac PPC Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I used ssh-keygen to generate key value pairs, and uploaded the public key to the remote server to which I would log-on to. Now I moved the private key from the $HOME_FOLDER/.ssh/ to another location. Closed the terminal on my Mac and tried to re-login again. I was assuming that the log-in would fail because the private key is not to be found. But to my surprise it logged in successfully. Why is this?
 
Joe San
Ranch Hand
Posts: 10198
3
Mac PPC Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is the log-in credentials checked every time I make an SSH connection? I'm getting a bit confused here. I deleted the private key id_rsa from my /home/user/.ssh/ folder, but still I'm able to ssh log-in to my remote machine. Why is this?
 
Joe San
Ranch Hand
Posts: 10198
3
Mac PPC Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I got to know why!

http://superuser.com/questions/245635/why-does-rsa-authentication-work-after-deleting-private-key

Did an ssh-add -L and I get to see the key which is added to the ssh agent running on my machine. Now I need to figure that out to not cache it and check for the private key everytime I ssh to my remote machine.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic