You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "David Voit (Jira)" <ji...@apache.org> on 2021/03/02 09:21:00 UTC

[jira] [Updated] (CAMEL-16241) Endpoint DSL (http component) Properties are not correctly set for Basic Authentications

     [ https://issues.apache.org/jira/browse/CAMEL-16241?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

David Voit updated CAMEL-16241:
-------------------------------
    Description: 
Using the following endpoint to line with the endpoint configuration, the http request fails

 

.to(https("inline").authenticationPreemptive(true).authMethod("Basic").authUsername("{{prop.username}}").authPassword("{{prop.password}}"))

 

If I'm using the equivalent line of:

.to("https://inline?authMethod=Basic&authPassword={{prop.password}}&authUsername={{prop.username}}&authenticationPreemptive=true")

 

the request are working fine.

 

Debugging this one shows that with the endpoint setup, BasicAuthenticationHttpClientConfigurer is initialized with the properties, so here username="{{props.username}}".

 

With just the java dsl, the correct username is loaded in the constructor.

  was:
Using the following endpoint to line with the endpoint configuration, the http request fails

 

.to(https("inline").authenticationPreemptive(true).authMethod("Basic").authUsername("\{{prop.username}}").authPassword("\{{prop.password}}"))

 

If I'm using the equifallant line of:

.to("https://inline?authMethod=Basic&authPassword=\{{prop.password}}&authUsername=\{{prop.username}}&authenticationPreemptive=true")

 

the request are working fine.

 

Debugging this one shows that with the endpoint setup, BasicAuthenticationHttpClientConfigurer is initialized with the properties, so here username="\{{props.username}}".

 

With just the java dsl, the correct username is loaded in the constructor.


> Endpoint DSL (http component) Properties are not correctly set for Basic Authentications
> ----------------------------------------------------------------------------------------
>
>                 Key: CAMEL-16241
>                 URL: https://issues.apache.org/jira/browse/CAMEL-16241
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-core
>    Affects Versions: 3.8.0
>            Reporter: David Voit
>            Priority: Minor
>             Fix For: 3.9.0
>
>
> Using the following endpoint to line with the endpoint configuration, the http request fails
>  
> .to(https("inline").authenticationPreemptive(true).authMethod("Basic").authUsername("{{prop.username}}").authPassword("{{prop.password}}"))
>  
> If I'm using the equivalent line of:
> .to("https://inline?authMethod=Basic&authPassword={{prop.password}}&authUsername={{prop.username}}&authenticationPreemptive=true")
>  
> the request are working fine.
>  
> Debugging this one shows that with the endpoint setup, BasicAuthenticationHttpClientConfigurer is initialized with the properties, so here username="{{props.username}}".
>  
> With just the java dsl, the correct username is loaded in the constructor.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)