Java access to external networks through proxy

xiaoxiao2021-03-06  38

In a environment where you must access the external network by proxy, the program written by Java will not be able to connect properly, and the proxy implementation accesses is set in the code. The agent settings are set by several system.getProperties (). Put ("proxyset", "true"); system.getproperties (). PUT ("proxyhost", "host"); system.getproperties (). PUT ("Proxyport", "Port"); if it is an FTP agent, as follows: system.getProperties (). put ("ftpproxyset", "true"); system.getproperties (). put ("ftpproxyhost", "host" ); System.getproperties (). PUT ("ftpproxyport", "port");

转载请注明原文地址:https://www.9cbs.com/read-67859.html

New Post(0)