0

I need to apply all proxy system settings in my Java program.

It needs to happen in certain conditions so I can't use the JVM argument method (-D).

I'm using the accepted answer from Setting JVM/JRE to use Windows Proxy Automatically and it works for HTTP, HTTPS and FTP.

But it simply won't work for SOCKS.

How can I detect SOCKS settings from the OS? Alternatively, how can I can apply all OS proxy settings blindly?

Philippe Carriere
  • 3,712
  • 4
  • 25
  • 46

1 Answers1

0

Found it: The protocol label for HTTP is "HTTP".

HTTPS: "HTTPS"

FTP: "FTP"

SOCKS? "SOCKET"

Philippe Carriere
  • 3,712
  • 4
  • 25
  • 46