jumaris / sshtunnel

Automatically exported from code.google.com/p/sshtunnel
GNU General Public License v3.0
1 stars 0 forks source link

Doesn't work on Roms that no redirect supported. #17

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Switch on sshtunnel, still can't connect to twitter,facebook, etc.
2.
3.

What is the expected output? What do you see instead?

What version of the product are you using? On what operating system?
0.7.10 (in market), 0.8.4.beta (the link in project homepage).
Huawei C8500, firmware 2.1-update1, kernel 2.6.29-perf. (I googled someone 
complained C8600 doesn't works either on internet.)

Server: Ubuntu sshd, squid.

Please provide any additional information below.

I have tried to executed the iptable commands, then got the following results:
iptables: No chain/target/match by that name.

Obviously, the REDIRECT target is unsupported. Fortunately, the DNAT target 
works. So the iptables command should a little change:
/data/data/org.sshtunnel/iptables_g1 -t nat -A OUTPUT -p tcp --dport 80 -j DNAT 
--to 127.0.0.1:8123
/data/data/org.sshtunnel/iptables_g1 -t nat -A OUTPUT -p tcp --dport 443 -j 
DNAT --to 127.0.0.1:8124
/data/data/org.sshtunnel/iptables_g1 -t nat -A OUTPUT -p udp --dport 53 -j DNAT 
--to 127.0.0.1:8153

I debugged it and did a patch in the attachment. The patch is relaxed, you may 
want to optimize it.

Thank you for your awesome work!

Original issue reported on code.google.com by phpxer on 7 Mar 2011 at 2:39

Attachments:

GoogleCodeExporter commented 9 years ago
Hence, my device is rooted.

Original comment by phpxer on 7 Mar 2011 at 2:40

GoogleCodeExporter commented 9 years ago
Thank you very much! I'll release a new edition ASAP

Original comment by max.c...@gmail.com on 7 Mar 2011 at 2:46

GoogleCodeExporter commented 9 years ago
Oh, typos in the issue. Actually, the correct commands in the patch are:
/data/data/org.sshtunnel/iptables_n1 -t nat -A OUTPUT -p tcp --dport 443 -j 
DNAT --to-destination 127.0.0.1:8124

Not as the demonstration in the issue description (--to 127.0.0.1:8124).

Original comment by phpxer on 7 Mar 2011 at 2:46

GoogleCodeExporter commented 9 years ago
ok, patch committed, stable branch update to 0.7.11. many thanks.

Original comment by max.c...@gmail.com on 7 Mar 2011 at 4:02