Hi,

on the "new" HTTP provider, the BasicAuthCredentials is not yet supported (it's commented in the source code). It means that you need to implement the authentication in your custom marshaler. Your marshaler implements HttpProviderMarshaler interface. So in the createRequest() method, you need to work with on the SmxHttpExchange/HttpExchange to add authentication data.

Anyway, I raised jira tasks (SMXCOMP-698, SMXCOMP-623) and I'm going to work on it.

Regards
JB

ranarula wrote:
I am a ESB and serviceMix newbie.

I am trying to interact with a http endpoint which requires basic
authentication and want to get hold of the response headers from the
endpoint.

I am not able to get the response headers if I use the <http:endpoint> in my
http-su xbean. Here is the xbean that I use. I am able to successfully get
the response.

<http:endpoint service="e:httpGateway"
            endpoint="Outbound"
            role="provider"
            locationURI="http://endpoint.abc.com/";
            soap="false">
            <http:basicAuthentication>
                <http:basicAuthCredentials username="abc" password="123" />
            </http:basicAuthentication>
</http:endpoint>
To get to the response headers I tried using the <http:provider> with the
marshaler which gets me the HTTP headers but in this case I am not able to
get the basic authentication work. Here is the xbean config for the same

<http:provider service="e:httpGateway2"
            endpoint="Outbound"
            locationURI="http://endpoint.abc.com/";
            marshaler="#myMarshaler">
      </http:provider>
   <bean id="myMarshaler"
class="com.adobe.aws.esb.marshaller.myCustomHTTPMarshaler" />

Please help me with this ?

Thanks

--
Jean-Baptiste Onofré (Nanthrax)
BuildProcess/AutoDeploy Project Leader
http://buildprocess.sourceforge.net
[email protected]
PGP : 17D4F086

Reply via email to