Created
September 11, 2013 14:18
-
-
Save AlainODea/6524270 to your computer and use it in GitHub Desktop.
Revisions
-
AlainODea created this gist
Sep 11, 2013 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,13 @@ import java.net.Proxy; import java.net.ProxySelector; import java.net.URI; public class WhatIsMyProxy { public static void main(String[] args) { String website = args[0]; Proxy proxy = ProxySelector.getDefault().select(URI.create(website)).iterator().next(); System.out.format("proxy.address=%s%nproxy.type.name=%s%n", proxy.address(), proxy.type().name()); } }