View Single Post
Posts: 3,401 | Thanked: 1,255 times | Joined on Nov 2005 @ London, UK
#4
Originally Posted by CelticDaddio View Post
I have been successful in installing xterm, openssh and then "ssh-ing" over to the 770 from my laptop using putty... but only as root. How can I use ssh to connect to my 770 as the default user. Is the default username "user". I see that as the only entry in /home.

Thanks,
Ed
Here's how...

Note: These instructions apply to both the 770 and N800 when using openssh
  1. Generate a public/private key on your PC using puttygen.exe (available for download from the place you got PuTTY). Select "SSH-2 DSA" then click on the "Generate" button and waggle your mouse to generate entropy...

    [direct link to x86 puttygen.exe => here]

  2. Next, save the generated public and private keys in your PuTTY program file directory (public.ppk and private.ppk respectively) - leave the passphrase blank unless you want to enter a passphrase each time you connect to your 770.

  3. On your 770, create a directory called "/home/user/.ssh" and make sure the permissions on this directory are 700 and that it is owned by user "user".

  4. In puttygen, copy the generated public key text which appears at the top of the window to the PC clipboard, then paste the text into a file called "/home/user/.ssh/authorized_keys" on your 770. Paste the key as one long line of text, no line breaks. Make sure the permissions on the authorized_keys file are 644 and that it is owned by user "user".

    The public key text will start with "ssh-dss" followed by gibberish and end with "dsa-key-yyyymmdd" where yyyymmdd is the current date - copy the whole text, start to finish!

  5. Finally, configure your PuTTY ssh session to use the private key you just generated and saved.

    Load your existing PuTTY session or create a new session, then make the following changes in the specified PuTTY categories:

    • Connection -> Data

      Enter "user" as the auto-login username (without quotes)

    • Connection -> SSH

      Select SSH2 as the preferred SSH protocol version.
      Encryption ciphers should be (top to bottom): AES, Blowfish, 3DES, DES.

    • Connection -> SSH -> Auth

      Enter the full path for your private key file

    • Session

      Set "Host name" to be the hostname or ip address of your 770
      Select Protocol as SSH
      Port should be 22
      Enter a suitable name in "Saved Sessions" (eg. "Nokia 770")
      Click "Save"

  6. You're done - no need to restart sshd or the device. Select your new session and click "Open" to login to your 770.

Now, whenever you open your new saved PuTTY session you will log in automatically (or be prompted for a passphrase if set) as user "user".

You can create a PuTTY desktop shortcut to load your new PuTTY session by appending -load "Nokia 770" to the end of the command line.

NOTE: Should you ever lose your authorized_keys file (eg. not backed up prior to a reflash) you can always recover the public key text by loading your private key file (private.ppk) into puttygen.

Last edited by Milhouse; 2007-09-06 at 18:34.
 

The Following 2 Users Say Thank You to Milhouse For This Useful Post: