We have set up our own VPN Server and want to route all the traffic from our VOIP android app through this server.
But all the solutions I have seen thus far use the vpn service class http://developer.android.com/reference/android/net/VpnService.html, which creates a vpn tunnel for the whole device and not just my application. I want the other apps running on the phone to use the internet as normal while the traffic from our app is routed through our VPN server.
Is there anyway to do this? I am very grateful for any suggestions. Thanks
VpnService
does not need to apply to the whole device. See:VpnService.Builder.addAllowedApplication
(available with API 21 - 5.0):