Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: use system properties by default for proxy settings #813

Open
danielflower opened this issue Jul 13, 2024 · 3 comments
Open

Comments

@danielflower
Copy link

I have a use case where I need to control whether or not to use a proxy using system properties, without having access to the code.

If org.htmlunit.HttpWebConnection#createHttpClientBuilder() set builder.useSystemProperties(); ("Use system properties when creating and configuring default implementations") this works.

This sets more than just proxy config according to https://issues.apache.org/jira/browse/HTTPCLIENT-1128 it sets:

ssl.TrustManagerFactory.algorithm
javax.net.ssl.trustStoreType
javax.net.ssl.trustStore
javax.net.ssl.trustStoreProvider
javax.net.ssl.trustStorePassword
java.home
ssl.KeyManagerFactory.algorithm
javax.net.ssl.keyStoreType
javax.net.ssl.keyStore
javax.net.ssl.keyStoreProvider
javax.net.ssl.keyStorePassword
http.proxyHost
http.proxyPort
http.nonProxyHosts
http.keepAlive
http.maxConnections

Personally I would like this on by default in HtmlUnit. But having a config option to set this would be useful too.

@rbri
Copy link
Member

rbri commented Jul 28, 2024

@danielflower sorry this did not make it into the release, will work on this for the next one

@rbri
Copy link
Member

rbri commented Jul 28, 2024

just thinking about having our own properties and an similar implementation as in the http client. To be independent from the HttpClient - but maybe this is a bit overcomplicated.

@rbri
Copy link
Member

rbri commented Sep 5, 2024

Sorry for being not that responsive during the last days - was on a workshop and will be out for two more weeks to have a holiday break. Afterwards we can work together to get this finally done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants