|
Page 6 of 7
Well now we have the SSH daemon activated if all went to plan and we need to test it out. To do this you need to download Putty and try to connect to 192.168.10.1 , and you should get a prompt for a login.
Log in as root, with the password admin, or whatever you chose as the password to access the management console on La Fonera. After that you should be greeted by this:
Now, what we have done is only temporary, it will be changed back to normal when you reset La Fonera. To make this change permanent we need to edit some files on La Fonera. First off, we need to tell La Fonera to run dropbear at startup so, in the putty console type:
mv /etc/init.d/dropbear /etc/init.d/S50dropbear
Then we need to edit the firewall rules to allow for connections to port 22. For this we need to run:
vi /etc/firewall.user
Vi is the standard text editor for the linux CLI. Its kinda clunky unless your used to it. To go into the editing mode you need to press "I" on your keyboard. Then you need to uncomment (remove the # in front of) the lines:
#iptables -t nat -A prerouting_rule -i $WAN -p tcp --dport 22 -j ACCEPT
#iptables -A input_rule -i $WAN -p tcp --dport 22 -j ACCEPT
To make it look like this:
Notice the second iptables is lowercase, I don't know if it was a type by the programmers at FON or not, but on my La Fonera the I in the second iptables was capitalized. After you have changed these lines, press ESC, and then type :wq you will notice it on the bottom of the screen, this tells VI to write and quit. Now lets test to see if those changes were successful. Go ahead and type at the prompt:
/etc/init.d/S50dropbear
/etc/firewall.user
If "nothing" happened or was printed out besides the prompt, it was a success!
Doing all this enables the SSH daemon at boot. On the next page we will show a method for stopping FON from executing code on your La Fonera.
|