View Single Post
Posts: 3 | Thanked: 0 times | Joined on Dec 2009
#3
Originally Posted by fabien View Post
There is another approach to your problem, if you do not want to involve the kernel/iptables even though it is *THE* cleanest solution, you may consider proxies.
Apache with a modules & Squid.

You can create rules to rewrite part of the query or to route it where ever you want. The only drawback is that the client application need to support HTTP proxy and only TCP connection is supported (yes even non web traffic via 'CONNECT')

The second proxy standard is sock v4 or v5 and support UDP traffic. You can install a sockify application on the client end if this one does not support sock.

Rewriting all the packets on the fly using scapy would be the best solution for this even if I would be really interested to know if it's running on the n900.
Thanks for your advice, however I've heard that there's no ip forwarding kernel module present in N900, or in maemo generally... But I'm not such a lucky guy who already have a N900, so I can't test...
Installing a squid/apache on a phone would be, IMO, a bit tricky, especially I guess it's not compiled for ARM processors, and even if it was, I can use a huge amount a resources, and are you sure this do not involves routing functions ? I mean both side of the proxy won't be on the same subnets...
I'll try scapy if python, libpcap, and libnet are compatible with maemo (but In this case maybe a C Program would do it faster, but anyway there won't be a huge throughput to handle)