cloudfoundry / cloudfoundry/uaa-release
Unable to use proxy which requires authentication
Nobody has claimed this yet.
- Dominant language
- Ruby
- Stars
- 28
- Forks
- 77
- Avg merge
- 1d 3h
- Merged PRs (30d)
- 14
Description
In our environment we need to access an oidc1.0 identity provider over our corporate proxy.
This proxy requires authentication.
I have configured the proxy like so:
jobs:
- name: uaa
properties:
env:
http_proxy: http://user:password@example.com:8080
but I get the following error:
[2017-12-21 14:15:24.977] uaa - 23341 [https-jsse-nio-8443-exec-4] .... WARN --- ExpiringUrlCache: Unable to fetch metadata for https://idp.example.com/openid-configuration
org.springframework.web.client.ResourceAccessException: I/O error on GET request for "https://idp.example.com/openid-configuration": user: Name or service not known; nested exception is java.net.UnknownHostException: user: Name or service not known
at org.springframework.web.client.RestTemplate.doExecute(RestTemplate.java:666)
at org.springframework.web.client.RestTemplate.execute(RestTemplate.java:628)
at org.springframework.web.client.RestTemplate.getForObject(RestTemplate.java:303)
at org.cloudfoundry.identity.uaa.cache.ExpiringUrlCache.getUrlContent(ExpiringUrlCache.java:62)
at org.cloudfoundry.identity.uaa.provider.oauth.XOAuthProviderConfigurator.overlay(XOAuthProviderConfigurator.java:67)
at org.cloudfoundry.identity.uaa.provider.oauth.XOAuthProviderConfigurator.lambda$retrieveAll$2(XOAuthProviderConfigurator.java:167)
at java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:184)
at java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:175)
at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1382)
at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481)
at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471)
at java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:151)
at java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:174)
at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:418)
at org.cloudfoundry.identity.uaa.provider.oauth.XOAuthProviderConfigurator.retrieveAll(XOAuthProviderConfigurator.java:164)
at org.cloudfoundry.identity.uaa.login.LoginInfoEndpoint.getOauthIdentityProviderDefinitions(LoginInfoEndpoint.java:525)
at org.cloudfoundry.identity.uaa.login.LoginInfoEndpoint.login(LoginInfoEndpoint.java:315)
at org.cloudfoundry.identity.uaa.login.LoginInfoEndpoint.loginForHtml(LoginInfoEndpoint.java:267)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
I think it breaks here since the : gets replace by a space.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading jobs/uaa/templates/bin/configure_proxy.erb around line 21 and compare it with the authenticated proxy URL and UnknownHostException shown here. Reproduce the metadata request through an authenticated proxy; done when the configured proxy preserves the credentials and the oidc1.0 metadata can be fetched without that error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ruby
- Domain
- infrastructure
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100