[Q] SSH port forwarding stopped working - Barnes & Noble Nook Tablet

I have been using Connectbot to forward a local port (higher than 1024) to a remote mail server, on my Android phone, and it has worked well. After I rooted my Nook Tablet, I used the same settings as on my phone and it worked, but today it no longer works. I can connect to the remote SSH server but Connectbot is not forwarding the ports. I suspect it is a problem with permissions. Is there a way to fix the permissions for Connectbot so it can forward ports?
Another possible problem is that my Nook does not (it seems) know what 'localhost' means. I even tried 127.0.0.1 in a terminal and the terminal could not find it. This might be the actual problem causing port forwarding to fail, but it was working earlier and just stopped working.
BTW the same setup still works on the phone so I know the remote host is not the issue.

OK for fix permissions you could try the option for that in CWM recovery if you have it installed. You could change permissions by using root explorer or ES file explorer apps too but im not sure which files you should fix, but you can try giving more permissions to the Connectbot app and change owner to root aswell if you dont know how to do it check this how to made by me.
About the localhost address adfree app that i use to get rid of advertisings use 127.0.0.1 ip to install hosts, make sure you have installed busybox that means open busybox app and verify that you have busybox 19.x.x installed, if not then install it.
~ Veronica

I will check but I am almost certain I have Busybox installed. I went to a cafe and my setup works, it just does not work at the library where they do NOT block port 443 and I am able to do port forwarding at the library on Linux (OpenSSH) and also Windows (with Proxifier).
I think it might be a DNS problem which can be addressed within ConnectBot, and this setup was working last week at the library. I will check the things you mentioned in your reply. Thanks
BTW, it does not appear to be permissions related, since I am able to do port forwarding on ConnectBot when at an open access point (no credentialed login required).

[SOLVED]
Thanks for your help. I installed the "Hosts" host file editor and then added the localhost to it. I suspect that the ROM Toobox app might have removed the localhost when it added 3 addresses to the hosts file (at my request). When I used the hosts file editor to add "localhost", it removed those additions made by the ROM Toolbox. I will have to look into this and make sure that when I add entries, the old entries do not disappear.
ConnectBot is now forwarding ports again at the library, after this fix.

Related

[Q] SSHD on tab, not able to connect

Hi!
I have tried SSHDroid, QuickSSHD and also Dropbear directly from the command line with logging to STD_ERR, but I am not able to connect to my GalaxyTab 10.1. Using nmap from WinXP I see the port, but it is filtered:
PORT STATE SERVICE
22/tcp filtered ssh
Using netstat on the tab shows that the connection has begun, but it stops with syn_recv and never get established. Using DropBear with logging it seems like no traffic is passed on to the server as no new log appears at the connection moment (or later).
The problem occured after rooting the device and has been persistent even though I have changed back to stock ROM and manager. Now I am using "recovery-cwm_4.0.0.4-sam-tab-10.1.tar.md5" and "Task650&Phantom_V5_Final.zip".
Using netcat I am able to send traffic both ways on the same ports.
I would really appreciate any suggestions on how to solve this as I have I feel lost without SSH
BR,
Henrik
It works okay for me with stock rom, rooted and SSHDroid. Set the superuser to grant automatic root permissions. Launch the SSHDroid and set - require wifi and password to yes.Check the port and make sure its 22 in the SSHDroid settings. Then start the server, you should see a confirmation saying the process is listening in port 22. You would also see a prompt stating the SSHDroid has been granted SU permissions. LEt me know if this helps!
SOLVED
Thanks for suggestions mango1122! I have for sure tried all those things too many times already But I got a breakthrough today by using the Overcome ROM and kernel (see galaxytabhacks).
Using this ROM, SSHDroid worked out of the box. I have unfortunately no clue why this works, but what made me try this ROM was this comment:
"For Custom roms: Be aware, I’ve put the wifi module right in the ramdisk (which is where it is on 10.1 stock). Please move over the modules folder in /system/lib prior to flashing, if this applies to you."
BR,
Henrik
Solved...again...
Update...had to take a long break as it didn't work when I got home from work that day in Nov...it was my home router that caused the problem, I guess combined with something in the Dropbear/SSHDroid application for Android 3.0 as there is no problem using SSHDroid on my smartphone with Android 2.3.3 on the same router. I assume it has something to do with the fact that it listens on tcp6?
Using another router solved the problem.
BR,
Henrik

cant make REST on Android device

hi im developing an app with eclipse and ADT, my app woks fine in the emulator, just connect via REST (post) to a localserver and execute some service.
the problem apears when I want to execute my app in my cellphone, basically it can't connect to the server, when I put the server IP etc etc...a timeout error is all I get...
android has any problem with the dns or something like that? I can't find the problem

SSHFS for Android Help setting up

Hi,
So I am trying to setup the below SSHFS app for Android on my phone:
https://play.google.com/store/apps/details?id=com.chaos9k.sshfsandroid
The dev has not responded to my emails and provides next to no instructions...
Here is what I have done on my own:
On my Pc:
1. Setup Cygwin SSH modules
2. Am able to connect via putty to my home PC through both my internal and external IPs (basically yes SSH server is working as a service on my PC and I can connect from my own network and off of it on another windows PC)
3. Port 22 is forwarded in my router
So prereq one to one this app of needing SSH server setup on home computer is met
Next up on my phone:
1. I am rooted on a Samsung Galaxy S4
2. Have Busy Box
3. Phone is 4.2 which the app experimentally supports
4. I have FUSE module support on my phone
So I believe from the above my phone meets the prereqs to mount SSHFS shares.
On to the app itself:
To setup a share I have specified the following:
1.Name : has no bearing just for user ease
2.Host: using my external IP
3.Remote Path: Have tried all sorts of paths to files on my PC (including just basic /\ and blanks)
4.Mount Point:\mnt\SSH (have confirmed this works as previously it would not accept my mount point. This folder is mounted and the app can see it)
5. Automount (checked)
7. User name and Passwords...used the same ones I used in putty to connect to my server
So with all of the above I keep getting the below error:
/SH:<stdin>[1]:readlink:not found:No such file or directory.
I believe the above error is because I am not properly inputting my remote path I would like to mount....I ideally would like to mount my entire D drive....but for the sake of getting this started I would like to be able to mount anything just to prove it works.
Like I mentioned I can use a laptop on a different WIFI network to connect to my SSH server and browse files...so in theory this should work...If anyone can help me sort out the proper remote path syntax I would really appreciate the help.

[Q] How to setup an WLAN with static IP in Ubuntu Touch?

Hi everyone,
since a while i try to set up an WiFi Network with static IP adresses on my Nexus 5 with Multirom and Ubuntu Touch-rtm installed, but it seems i'm a bit dumb. :silly:
i followed the instructions from an website wich url i can't post, because i am an new user and i don't have written 10 posts ...
but nevertheless, all i get after saving the configuration file and reconnecting is an new configuration file - of course without my changes.
So, what did i do wrong?
You could try doing the following before the reboot:
Code:
sudo stop ofono
sudo stop urfkill
sudo stop network-manager
sudo rm /var/lib/urfkill/saved-states
# Your changes to the config file
sudo reboot
(This will, among other things, stop the network connection services in the background, so you cannot run these commands via SSH. You need to use adb for that. )
That's the only idea I have right now. Let's hope that your files won't get overridden again.
thanks for the tip, but that also does not help anything.
meanwhile i think i got something wrong in the config syntax, but i don't know where. I also took the configuration of my Linux Mint pc for comparison, but without success. when i try to reconnect the wlan, a new file will created and the "old"-changed one simply be ignored.
@the_Pan Have you tried simply copying over the file from your PC? Make sure it has the same name on your phone which it also has on your desktop.
Sent from my awesome Ubuntu Touch device using the Forum Browser app
Only copying wouldn't work, my pc is in LAN, but yes i used the same parameters for IPv4 as in this file (except from the IP).
The only idea i got for now, is that something went wrong with the file permissions when i edit the file on pc with the adb shell, but if i take a look with "ls -l" everything seems alright.
EDIT: nope, has nothing to do with editing on pc. it also happens if i edit the file within the terminal directly on the phone.

m8s (suspected clone) IP/MAC address change for eth0 on reboot bug.(other issues too)

Good morning everyone. As per the thread title, My girlfreind has a TV box that I suspect is a clone (the update ROMs from chinagadget review wont flash from TWRP).
This device is connected to her ADSL router/modem via a LAN cable and everytime the device boots, the MAC address for the LAN interface is randomised, causing the router to issue a new IP address via DHCP. (I cannot get the device to communicate with static IP)
it's running a lollipop based ROM at the moment (LMY47V.20160505 TEST-KEYS) is reported in settings.
I haven't removed the case yet, to investigate the circuitboard/RAM manufacturer (and don;t know how to check via software, if the wifi/bt module is made by broadcom/atheros) but my gut feeling is screaming "it's a clone". (If it helps, the TWRP backup I performed has saved to a sub-folder called "k200")
She purchased the device from Amazon UK and the majority of apps on Play Store give "version isn;t compatible with this device" error. I've tried to spoof other device in build.prop and with an app called "market helper" but no joy yet.
Any help appreciated
Has anyone got any advoce for me?
CAn anyone point me to messages/threads on hoiw to spoof a MAC address on ethernet adaptor?
does anyone know how to spoof my device type so I can get Play Store to allow me to download/install apk's without needing to sicdeload
wodgey said:
Has anyone got any advoce for me?
CAn anyone point me to messages/threads on hoiw to spoof a MAC address on ethernet adaptor?
does anyone know how to spoof my device type so I can get Play Store to allow me to download/install apk's without needing to sicdeload
Click to expand...
Click to collapse
I also have this issue with my Kata Box 2 (Amlogic S905)
I was also very frustrated when I learned that the mac address was always set at random every time I reboot.
I've read that you need to use USB burning tool to hard code the mac address for your android box.
Here's what I did to solve this.
you need:
a rooted android box
busy box
Terminal emulator
1st method:
Make sure that the ethernet cable is unplugged.
Run terminal emulator.
Run these commands in lower case:
su
ip link set eth0 down
ip link set eth0 address 01:23:45:67:89:10 (change the values of your desired mac address)
ip link set eth0 up
2nd method:
su
busybox ifconfig eth0 down
busybox ifconfig eth0 hw ether 01:23:45:67:89:10 (change the values of your desired mac address)
busybox ifconfig eth0 up
You can run run these on startup using Script Manager.
I tried both method 1 and 2 and works very well.
To verify the if everything was set properly you can run these commands:
ip link show
And
busybox ifconfig
so far on my end its working great. Im now able to reserve the IP address via MAC address.
aperture;68526292Here's what I did to solve this..[/QUOTE said:
Thanks dude. I'll try this and report back.
Click to expand...
Click to collapse
aperture said:
I tried both method 1 and 2 and works very well.
Click to expand...
Click to collapse
For me, method 2 works. 1st method didn't change anything that I could see.
I have also added start/stop adbd and setprop tcp port to my script also so I can have adb over tcp upon boot, shich I was struggling to set as persistent.
Thanks again.
wodgey said:
For me, method 2 works. 1st method didn't change anything that I could see.
I have also added start/stop adbd and setprop tcp port to my script also so I can have adb over tcp upon boot, shich I was struggling to set as persistent.
Thanks again.
Click to expand...
Click to collapse
I'm glad it worked out well for you. :victory:

Categories

Resources