Operating System - HP-UX
1826027 Members
2984 Online
109690 Solutions
New Discussion

SSH Public Key Authentication

 
Pedro Cirne
Esteemed Contributor

SSH Public Key Authentication

Hi,

Is there a way to make a private key valid only if used from a certain host?

In other words, I want to setup an authentication method in a way that the my private key only works if I'm using it to login a server from my PC. So if I (or someone else) copies my private key to another PC it won't work to login on the server.

Thks

Thks
3 REPLIES 3
Steven E. Protter
Exalted Contributor

Re: SSH Public Key Authentication

http://www.chiark.greenend.org.uk/~sgtatham/putty/

There is a key generator for Windows that should let you generate and distribute a private key that will only work for you.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Denver Osborn
Honored Contributor

Re: SSH Public Key Authentication

Yes, use from="hostname" in your ~/.ssh/authorized_keys file.


The from entry will be on the same line in front of the public key.

from="ip_address" ssh-dss ...

Hope this helps,
-denver
Pedro Cirne
Esteemed Contributor

Re: SSH Public Key Authentication

Hi,

Thank you all!

Enjoy :)

Pedro