Welcome, Guest. Please login or register.
Did you miss your activation email?

Author Topic: [EN] How to set up ssh keys at login  (Read 2083 times)

hightime

  • Guest
[EN] How to set up ssh keys at login
« on: 2014/06/07, 17:46:05 »
What is the preferred way to set up ssh keys at login? In the past I've used something like this in either .bashrc or .profile:
Code: [Select]
keychain --quiet ~/.ssh/id_rsa With siduction this doesn't seem to be working. I also tried to use keychain's eval feature as mentioned in its man page. That didn't work either.

I get the prompt for my passphrase, but no keys are loaded.

Dan



Offline piper

  • User
  • Posts: 1.785
  • we are the priests ... of the temples of syrinx
Free speech isn't just fucking saying what you want to say, it's also hearing what you don't want to fucking hear

I either give too many fucks or no fucks at all, it's like I cannot find a middle ground for a moderate fuck distribution, it's like what the fuck

hightime

  • Guest
Re: How to set up ssh keys at login
« Reply #2 on: 2014/06/08, 21:28:31 »
Thanks, but those are all links to general information on installing and setting up an ssh client. My question is about keychain.

With Redhat, Archlinux and even my old Aptosid box you can add a couple of lines to .bash_profile, as per the keychain man page, to launch keychain at login. It calls ssh-askpass if it's a GUI login to prompt for your passphrase and add your keys to ssh-agent.

I've done some more experimenting and it appears that with lightdm as the login manager .bash_profile is not even being called. Is there some setting that controls this?  If I switch to using kdm it does call .bash_profile, but the keychain - ssh-askpass part is not working.

And to clarify my original post, if I do a console login -- no GUI desktop -- the keychain - ssh-askpass process works correctly.

Is anyone successfully using keychain with siduction linux?

Offline melmarker

  • User
  • Posts: 2.799
    • g-com.eu
Re: How to set up ssh keys at login
« Reply #3 on: 2014/06/10, 21:52:55 »
only a wild guess - the files you are mention are bash - debian uses dash as sh - in that case the profile would be $HOME/.profile

EDIT: i was wrong with my wild guess - but there is a good explanation here:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=636108
« Last Edit: 2014/06/10, 22:45:41 by melmarker »
Those who would give up essential Liberty, to purchase a little temporary Safety, deserve neither Liberty nor Safety. (Benjamin Franklin, November 11, 1755)
Never attribute to malice that which can be adequately explained by stupidity. (Hanlons razor)