How to configure the virtual router in front of the android emulator in ubuntu

230 views
Skip to first unread message

eric

unread,
Dec 12, 2008, 9:13:05 AM12/12/08
to android-platform
Hi,

I compiled XSTUNT and run it on the android emulator.
It works but the XSTUNT detect the virtual router in front of the
android emulator
is the type of TCP none port preswerving random symmetric NAT.
How do I configure it as a FULL CONE NAT in ubuntu 8.10?
Thanks for any help.

Eric

David Turner

unread,
Dec 12, 2008, 8:48:11 PM12/12/08
to android-...@googlegroups.com
I'm sorry but I don't really understand your question.
Maybe reading the related documentation might help though:
http://code.google.com/android/reference/emulator.html#emulatornetworking

Chun-Kai Hwang

unread,
Dec 19, 2008, 10:21:29 AM12/19/08
to android-...@googlegroups.com
Hi,

XSTUNT is similar to STUN but it is for TCP to do port prediction and hole punching
on a NAT. The question is that if the NAT is RANDOM SYMMETRIC type,
then the port prediction will be definitely failed.
Here is the link of XSTUNT
http://www.cis.nctu.edu.tw/~gis87577/xDreaming/XSTUNT/index.html
But there is no description about how to configure the virtual router of android
emulator in the link http://code.google.com/android/reference/emulator.html#emulatornetworking
Does any one have any idea?
Thanks

David Turner

unread,
Dec 19, 2008, 10:55:48 AM12/19/08
to android-...@googlegroups.com
there is no way to configure the NAT implementation to do what you want.
I even doubt that it is possible to implement STUN/STUNT on this environment due to the very special way the QEMU user-mode network stack is implemented.

may I suggest you to have a look at android/external/qemu/slirp for details.

Chun-Kai Hwang

unread,
Dec 30, 2008, 10:55:00 AM12/30/08
to android-...@googlegroups.com
Hi

I found in /external/qemu/android_console.c
function static int do_redir_add( ControlClient client, char* args ) is calling
slirp_redir of slirp.c.
Is it possible that I modified slirp_redirfunction so that the redirection of port is fixed
to mimic a FULL CONE NAT ?

Thanks for any help,

Eric  

David Turner

unread,
Dec 31, 2008, 5:18:56 AM12/31/08
to android-...@googlegroups.com
I don't know if this is going to be easy, but it sounds possible.
I suspect that it is going to need more than modifying the slirp_redir function(s)
Reply all
Reply to author
Forward
0 new messages