This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
wiki:advanced:authentication:passwordless-ssh [2011/01/12 15:20] dali |
wiki:advanced:authentication:passwordless-ssh [2011/11/15 04:41] sunweaver wiki:authentication:passwordless-ssh renamed to wiki:advanced:authentication:passwordless-ssh (Namespace cleanup) |
||
---|---|---|---|
Line 1: | Line 1: | ||
====== Passwordless authentication using ssh-keys | ====== Passwordless authentication using ssh-keys | ||
- | ===== Linux ===== | + | ===== Linux client |
You'll need to generate a SSH key via the ssh-keygen command. Please choose which key you want to generate (we recommend dsa): | You'll need to generate a SSH key via the ssh-keygen command. Please choose which key you want to generate (we recommend dsa): | ||
Line 36: | Line 36: | ||
After the transfer you can add the path to the private part of the key to the session preferences inside x2goclient. x2goclient should now establish the connection without asking for a password by simply clicking on the session card view. | After the transfer you can add the path to the private part of the key to the session preferences inside x2goclient. x2goclient should now establish the connection without asking for a password by simply clicking on the session card view. | ||
- | ===== Windows ===== | + | ===== Windows |
Start a command prompt and navigate to the x2goclient folder, in this example it is **C: | Start a command prompt and navigate to the x2goclient folder, in this example it is **C: | ||
- | First we generate a DSA key pair (do not use a password phrase if you want SSO): | + | First we generate a DSA key pair (use an empty password phrase if you want SSO): |
<code dos> | <code dos> | ||
C:\Program Files\x2goclient> | C:\Program Files\x2goclient> | ||
</ | </ | ||
- | :!: ssh-keygen.exe prints the path to the key file(s), you will need that later. | + | :!: ssh-keygen.exe prints the path to the key file(s), you will need that in the next step. |
- | This will create following files: | + | You'll need to transfer the public key file to the wanted server. You can do this using the scp.exe command with the path that ssh-keygen.exe printed |
- | <code text> | + | |
- | id_dsa | + | |
- | id_dsa.pub | + | |
- | </ | + | |
- | + | ||
- | You'll need to transfer the public | + | |
<code dos> | <code dos> | ||
- | C:\Program Files\x2goclient> | + | C:\Program Files\x2goclient> |
</ | </ | ||
Line 64: | Line 58: | ||
</ | </ | ||
- | Go to your .ssh folder, add the public key to your authorized_keys2 | + | Go to your .ssh folder, add the contents of the public key file to your authorized_keys |
<code bash> | <code bash> | ||
cd ~/.ssh | cd ~/.ssh | ||
- | cat id_dsa.pub >> | + | cat ~/id_dsa.pub >> |
- | rm id_dsa.pub | + | rm ~/id_dsa.pub |
</ | </ | ||
You can now add the path to the id_dsa file (the private part of the key) to the session preferences inside x2goclient. x2goclient should now establish the connection without asking for a password by simply clicking on the session card view. | You can now add the path to the id_dsa file (the private part of the key) to the session preferences inside x2goclient. x2goclient should now establish the connection without asking for a password by simply clicking on the session card view. | ||
- | You can also create a desktop shortcut which starts session with the client window hidden; in x2goclient select Session -> Create session icon on desktop ... -> select session. | + | You can also create a desktop shortcut which starts |
:!: The path to x2goclient.exe in the shortcut may be wrong, edit the shortcut and remove " | :!: The path to x2goclient.exe in the shortcut may be wrong, edit the shortcut and remove " | ||