![]() |
accessing N9 thru SSH over wifi
accessing N9 thru SSH over wifi
how do you do it? Ive activated developer mode, run SDK connect, got IP and password and attempted to gain access. What user name do you use? I tried root and user. No go. -------------------------------------------------------------------------------- Post PR1.1, to enable remote root login again (or rather make it controllable via /etc/ssh/sshd_config like before): Code:
echo -e 'mkdir -m 0755 -p /var/run/sshd\nexec /usr/sbin/sshd $SSHD_OPTS' >> /etc/default/ssh |
Re: accessing N9 thru SSH over wifi
Quote:
Code:
devel-su (password is rootme) EDIT: Not sure you need to be root for that, simple 'passwd' as user could work too. |
Re: accessing N9 thru SSH over wifi
thanks!.......
|
Re: accessing N9 thru SSH over wifi
Any problems connecting over 3G? Wifi seems to work fine for me, but attempting to connect to an N9 that is on 3G connection fails.
|
Re: accessing N9 thru SSH over wifi
Quote:
|
Re: accessing N9 thru SSH over wifi
Quote:
i've added the ip address that my putty is on to the N9 openssh config as an allowed host (previously only the common intranet addresses were there) I think i had this working before i started messing with some of the settings, which is why it would be nice if someone confirmed that they can connect normally over 3G via SSH |
Re: accessing N9 thru SSH over wifi
You don't normally get a public IP when on 2G/3G, in which case you won't be able to connect from a device outside of that network.
|
Re: accessing N9 thru SSH over wifi
Quote:
Also: if you do a passwd without devel-su then it refuses to change the password. |
Re: accessing N9 thru SSH over wifi
Quote:
|
Re: accessing N9 thru SSH over wifi
Quote:
From terminal on N9: Code:
devel-su Code:
$ scp ~/.ssh/id_dsa.pub root@[N9's IP]:.ssh/authorized_keys Now all you need to do is copy /root/.ssh/authorized_keys to /home/developer/.ssh/ and make sure you chown it to the right user/group. The easiest way to do that is copy it as root to a temporary file in /home/developer/.ssh/ and then switch to the developer user and then cp it to authorized_keys file. I tried doing the same thing with the "user" user, but for some reason it would not let me log in via ssh afterwards. But seeing as though the user "developer" has the same userid it doesn't really matter. :-) Another good thing to do is to create a SSH key pair for the N9's user, "user". Then you can put the .pub on any machine you want to ssh to from your N9. It is very handy being able to log into my desktop at home no matter where I am in the world. :-) |
Re: accessing N9 thru SSH over wifi
Quote:
|
Re: accessing N9 thru SSH over wifi
OK. At least in my case I get a 10.*.*.* address from my provider. Of course this lets me connect to Internet, or to my laptop via SSH (otherwise it wouldn't be an "internet" connection).
The problem is when you want to make a connection TO your N900/N9 from the OUTSIDE. The public IP that I get is (probably) shared by other devices on the same network (NAT). |
Re: accessing N9 thru SSH over wifi
Quote:
I use the same sim card that, until it got chopped to fit N9, worked lately with N900. I am able connect to SSH with wifi, though. 3g data seems to yield good speed and throughput (10 Mbps), so it doesn't seem to be plain badly working data connection. Until your comment I just though that gprs0 interface was blocked in iptables (don't know how to check that) while wlan0 was not. EDIT: With not getting connection through 3g I meant timeout, not restriction to log in (as is configured in /etc/sshd_config). |
Re: accessing N9 thru SSH over wifi
Quote:
Wondering if i mistakenly did something else too.. could someone post the default sshd config from N9? |
Re: accessing N9 thru SSH over wifi
Quote:
On your PC it'd be an incoming packet and you can't filter on interface for incoming. At least I don't think you can. Code:
iptables -S Quote:
|
Re: accessing N9 thru SSH over wifi
1 Attachment(s)
Quote:
------------------------------------------------------------------------ |
Re: accessing N9 thru SSH over wifi
Quote:
After replacing mine with yours, and rebooting the phone, the problem still persists.. I'm not able to connect over the 3G public IP address. I should probably stick my SIM card back into N900 for a moment when I get back home, and verify that the problem is not caused by it. |
Re: accessing N9 thru SSH over wifi
terminal:
devel-su passwd -u developer Then you can connect with "developer" user, and then use devel-su for root over ssh :) |
Re: accessing N9 thru SSH over wifi
Please note that the internal password security of the N9 like the N900 is very very weak !
Passwords are stored in /etc/passwd with a very simple "Traditional DES" encryption which makes cracking password from the N9 a matter of minutes to hours. So please don't use passwords but use ssh keys like described earlier in this thread and then change your /etc/ssh/sshd_config to read: Code:
PasswordAuthentication no |
Re: accessing N9 thru SSH over wifi
Uh, guys, if you're on 3G you're almost certainly under a NAT. You simply cannot reliably ssh (or connect in any other way without a proxy or some trick) to your phone or any other device if you're on 3G. If you can you're probably lucky enough to be currently assigned exclusively to a public IP. Don't expect that to be reliably repeatable. That's what services like dyndns are for.
|
Re: accessing N9 thru SSH over wifi
ssh over 3g is blocked by a script that drops connections over gprs to port 22. The script is aegis protected so you can't just go and change it. This is how I solved the problem:
http://talk.maemo.org/showpost.php?p...7&postcount=56 It's a workaround, but it works. |
Re: accessing N9 thru SSH over wifi
How do I shut off sshd?
|
Re: accessing N9 thru SSH over wifi
Quote:
|
Re: accessing N9 thru SSH over wifi
Quote:
You can also easily remove the iptables rule that it adds with: Code:
/sbin/iptables -D INPUT -i gprs0 -p tcp -m tcp --dport 22 |
Re: accessing N9 thru SSH over wifi
Aerlier SSH connection worked but not after OpenSSH updated.
I only get error "Connection refused". Any ideas how this problem could be solved? |
Re: accessing N9 thru SSH over wifi
|
Re: accessing N9 thru SSH over wifi
Quote:
|
Re: accessing N9 thru SSH over wifi
Quote:
Outgoing SSH (from the N9) is unaffected by this iptables rule, so for my usage at least, never need to touch the iptables for SSH. |
Re: accessing N9 thru SSH over wifi
Have someone tried to just put the N9 into AP mode (Mobile Hotspot) and then connect over SSH? Always worked with the N900. ;)
Cheers, J4ZZ |
Re: accessing N9 thru SSH over wifi
Quote:
you can login as user, or edit the sshd_config to allow root login again. |
Re: accessing N9 thru SSH over wifi
i made a step by step tutorial here ;)
http://www.youtube.com/watch?v=wccMF2lDH5A |
Re: accessing N9 thru SSH over wifi
Quote:
|
Re: accessing N9 thru SSH over wifi
Quote:
Perhaps you need to use `devel-su' from root now too? |
Re: accessing N9 thru SSH over wifi
yes, with pr1.1 theyve disabled root access in another config file. found the fix on meego forum.
Post PR1.1, to enable remote root login again (or rather make it controllable via /etc/ssh/sshd_config like before): Code:
echo -e 'mkdir -m 0755 -p /var/run/sshd\nexec /usr/sbin/sshd $SSHD_OPTS' >> /etc/default/ssh |
Re: accessing N9 thru SSH over wifi
Quote:
|
Re: accessing N9 thru SSH over wifi
Quote:
sshfs user@N9ip:/home/user/MyDocs/share /home/myuser/share SSHFS runs over SSH, so nothing further is needed on the N9 side. You can now access the N9 from the Linux box under share. On a Windows system, there is a Dokan SSHFS client. With this you can mount something on the N9 as a logical drive. So N: is /home/user/MyDocs/share on Windows, for example. Now I just need a Samba and SSHFS client for the N9, to access Linux and Windows servers from the N9 . . . |
Re: accessing N9 thru SSH over wifi
Quote:
|
Re: accessing N9 thru SSH over wifi
For windows you'll probably need to install cygwin first.
|
Re: accessing N9 thru SSH over wifi
Quote:
Download: DokanInstall_0.6.0.exe dokan-sshfs-0.6.0.zip dokan-sshfs-0201226.zip Microsoft Visual C++ 2005 SP1 Redistributable Package (I can't post all the links, since I am a new member) 1) Unpack the zipped files into separate directories. Install the Microsoft Visual C++ 2005 SP1 Redistributable Package first. 2) Run the DokanInstall_0.6.0.exe to install the Dokan libraries. 3) In the dokan-sshfs-0201226 directory, run the installer to install the older 0.2 version. This is necessary because the 0.6 version does not have an installer. This will probably ask for a reboot. 4) From the 0.6 unzipped directory, copy (overwrite )DokanNet.dll and DokanSSHFS.exe in the installed location, C:\Program Files\Dokan\DokanSSHFS. 5) Start the Dokan GUI from the desktop Icon or from Windows Start. Everthing is pretty much self explanatory: Host: N9ip User: User Password: xxxx (I haven't figured out how to use the "identity" yet) Server Root: /home/user/MyDocs/share Drive: N Oh, I forgot to mention in my first post. You might also be interested in using VNC. This allows you to have your phone interface as a window on Windows or Linux. The VNC server is on the Nokia shop for free called "Netview." VNC clients are available for Windows and Linux called vncviewer. This is nice if you are configuring something on the phone with a GUI, but want to use a full size keyboard to type in the text fields on the GUI. Just start Netview on the N9, and use "vncviewer N9ip." Have fun! |
Re: accessing N9 thru SSH over wifi
Quote:
|
All times are GMT. The time now is 00:08. |
vBulletin® Version 3.8.8