Open GoogleCodeExporter opened 9 years ago
Thanks for this patch. I will add you enhancements in the next days.
And ... this is a "sister-project" from "wireless tether" - so, I'm going to
take over these enhancements to wireless tether as well.
Original comment by harald....@gmail.com
on 7 Jan 2011 at 12:44
I recently tried this on a G2 and discovered that the "iptables -t mangle"
commands didn't work as the Vision's stock kernel (verified in source, and I
believe HTC devices in general) doesn't include Netfilter mangle support.
So you probably want to implement this such that the "iptables -t mangle"
operations are non-fatal on error and don't complain to the user. It would be
great to have on devices that do support NF mangle out of the box, but it's no
big deal otherwise.
And yes, wired-tether is my primary interest although I did recently modify
wireless-tether's edify script to clamp MSS as well. I can create an
issue/patch for that if you'd like, although the carryover is straight forward
and I figured it might be a bit redundant.
Original comment by mkas...@gmail.com
on 8 Jan 2011 at 6:58
Yes. A patch for edify would be nice!
Well ... a check if a certain kernel-option (for "-t mangle") was compiled into
the kernel will be needed.
Original comment by harald....@gmail.com
on 10 Jan 2011 at 11:29
So iptables returns "3" (internally called VERSION_PROBLEM) when one attempts
to use a feature unsupported by the kernel. Attached is an updated patch that
ignores "iptables -t mangle" errors if it returns value 3. This makes the MSS
clamp optional, it will work for phones that have mangle table support, and
it's ignored on phones that don't.
The patch isn't quite as clean as I would like. Unfortuately the multiple
tests of "returncode == 0" when an iptables error occurs prevents the patch
from being simpler. But that's OK.
There's two outstanding issues:
As mentioned previously, the iptables binary needs to be updated to support the
"--clamp-mss-to-pmtu" option, which it does in the Eclair & Froyo AOSP trees.
I'm guessing it doesn't in Donut and earlier.
Also, when I test new builds of wired-tether, I see that the binaries are not
automatically updated on a program update (although I keep the same version
code), and I have to uninstall/reinstall completely to get them to update. If
this is the case in update of the official version, then it will error for
everyone until they do a reinstall/binary update. So if it doesn't exist, a
mechanism to update the iptables binary on program update would be needed to
make this smooth.
And yes, I have a patch for wireless-tether that I'll commit shortly as an
"issue" in the appropriate place.
Original comment by mkas...@gmail.com
on 18 Jan 2011 at 8:38
Attachments:
Wireless-tether issue page/patch:
http://code.google.com/p/android-wifi-tether/issues/detail?id=816
Original comment by mkas...@gmail.com
on 18 Jan 2011 at 8:50
Original issue reported on code.google.com by
mkas...@gmail.com
on 19 Dec 2010 at 7:30Attachments: