Ssh using kerberos

From CARMA
Revision as of 13:03, 9 July 2007 by Teuben (Talk | contribs)

Jump to: navigation, search

In the (simple) old-style ssh you would pass around your public key (from ~/.ssh: id_rsa.pub or id_dsa.pub as generated using the ssh-keygen program) and store it on the remote machine in a file ~/.ssh/authorized_keys. After this ssh would allow you to logon to that machine without the need to type your password.

Since GLUE is using kerberos, this won't work anymore. Your client machine will have to be modified to know about the GLUE kerberos system. On linux machines you should modify two files:

/etc/krb5.conf

   [libdefaults]
       default_realm = UMD.EDU
       dns_lookup_kdc = true
       dns_lookup_realm = true

/etc/ssh/ssh_config

   GSSAPIAuthentication          yes
   GSSAPIDelegateCredentials     yes


User setup

After this the kinit command is used to authenticate you, and whenever you logon to a GLUE machine, it will let you in. With one minor hickup, if you write shell scripts that do automated ssh logon, manually do this once, since you will see the usual question when it's a new machine and it be added to your ~/.ssh/known_hosts file.

Actually, isn't there another major hickup....??? Once you run klist, it is only good for 24 hours. Or if you set another lifetime, e.g. 2 days using

   kinit -l 2d

This could be a major nuisance for those wanting to run ssh in crontabs....

Personal tools