1. Enable Extras repository.

Go into the Application manager.
Tap the menu > Tools > Application catalog...
Double-tap maemo Extras.
Uncheck Disabled.

2. Install rootsh.

3. Install OpenSSH (both server and client).

4. Next we have to set a password for the default user.

sudo gainroot
passwd user # user is the username of the default account
# enter your password when prompted

5. Start the ssh server

/etc/init.d/ssh restart # in case if it's already running

Access the phone remotely using ssh as user@the-ip-of-the-phone. You can find the IP address using the ifconfig command.