Question

So i'm creating services with jmdns and i can access them from local area network from aadress 192.168.0.101:9999/servicename (note that 192.168.0.101 is my android phone localIP). Now if i want to access them from wide area network i'd have to do port forwarding in my router right? Is there a way to do one forwarding for 192.168.0.101:9999 so i could access from wide area netowrk routerPublicIP:9999/servicename my services that are on my phone?

Was it helpful?

Solution

You should use upnp protocol. It allows you to create port forwarding mappings, provided that your router supports upnp.

This is what various torrent clients do in order to accept connections from other peers.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top