简体   繁体   English

当 VPN 连接时,用户将能够进入应用程序,如果他们没有连接,他们将无法进入。 我怎么做?

[英]When the VPN is connected, user will be able to enter the app and if they are not connected, they will not be able to enter. How do I do that?

我在许多应用程序中看到,当 VPN 连接时,您可以进入应用程序,如果您未连接,则无法进入。我如何使用 Java 编程来做到这一点?

Write your program like it would access any other local network resource.像访问任何其他本地网络资源一样编写您的程序。 Once the user connects to the VPN, the network resource will become available and is handled further down the stack.一旦用户连接到 VPN,网络资源将变得可用并在堆栈中进一步处理。 No need to account for a VPN programmatically in your application.无需在您的应用程序中以编程方式考虑 VPN。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM