Win a copy of Java EE 8 High Performance this week in the Java/Jakarta EE forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Https post, through Proxy settings  RSS feed

Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello all,

I hope I picked the right forum for this.
I am trying to open a good old url connection to a https URL. I have to do it through a proxy however.
Environment is java 1.6 and Weblogic 10.3.4.

There are may ways to try this but I need some clarifications.
There is a java option (http.proxyHost and its friends). Does this apply to attempts to connect to https URLS as well or do I have to set the https.proxy options also? The https.proxy setting will simply override the http.proxy setting when connecting through https?

I can also do this through java code without using the java system properties. Which of the following would be correct?

Or maybe it makes no difference with which of the above 3 cases I open the connection? Please note that I must request with POST method and access output and input stream as well.
Also is it safe to assume that such code (opening connection with Proxy object parameter) overrides the system properties?

Many questions for sure. Please take a shot at whichever you could help!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!