You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by tog <gu...@gmail.com> on 2007/12/08 18:13:18 UTC
Dynamic client & basic auth
Hi
I need basic auth to retrieve a wsdl.
I currently use the dynamic client. All the constructors take directly
a string for the wsdl url.
Is there a way to set username/passwd before actually calling the server ?
Thanks
--
Best Regards
Guillaume
http://cheztog.blogspot.com
Re: Dynamic client & basic auth
Posted by Daniel Kulp <dk...@apache.org>.
Guillaume,
Yep. This isn't implemented yet. It also affects trying to get the
WSDL via https.
The "easy" way (not really easy, but it should work) is to create a
instance of
org.apache.cxf.resource.ResourceResolver
that would get the bus injected in so that it could query (or get) the
HTTPConduit from the ApplicationContext (it could be
ApplicationContextAware so Spring injects that). Note: you would need
to do both the getResourceAsStream as well as handle getResource(name,
URL.class).
The trick is going to be that the HTTPConduit currently expects an
EndpointInfo to be available. Thus, it's not really generic enough for
this right now. You MIGHT need to also update the HTTPConduit to not
NPE if the EndpointInfo is null. Not really sure though.
If you have any questions, feel free to ask. I'll gladly help you out.
Dan
On Sunday 09 December 2007, tog wrote:
> Ok looking in the mailing list, it looks that this is not yet
> implemented (I mean for retrieving the wsdl)
> Dan,what would be the effort for adding this ? If you guide me,I might
> consider working on this as I did for the proxy auth in XFire.
> In order to avoit the problem,I retrieved the wsdl using wget.Once it
> is local and the AuthorizationPolicy has been set up,the subsequent
> calls are working fine
>
> Guillaume
>
> On Dec 9, 2007 5:22 PM, tog <gu...@gmail.com> wrote:
> > Hum I can believe this ...
> > What I am looking for is a way to set up the Authorization header in
> > the HTTP request (prior to get the wsdl).
> > I know how to set-up the Proxy-Authorization header and I found
> > AuthorizationPolicy
> >
> > AuthorizationPolicy auth =
> > conduit.getAuthorization(); auth.setUserName(username);
> > auth.setPassword(password);
> >
> > Will that do the job ?
> > Then the problem is to do this prior to the creation of the client
> > ... which is the first thing I do !
> >
> > Any thought ?
> >
> > Guillaume
> >
> > On Dec 9, 2007 3:34 AM, Glen Mazza <gl...@verizon.net> wrote:
> > > I'm not sure the Java artifacts would have a defined place for
> > > such information.
> > >
> > > Glen
> > >
> > > Am Sonntag, den 09.12.2007, 01:15 +0800 schrieb tog:
> > > > the same question apply for the wsdl2java. I did not see
> > > > anything for setting up username/passwd in the options
> > > >
> > > > On Dec 9, 2007 1:13 AM, tog <gu...@gmail.com> wrote:
> > > > > Hi
> > > > >
> > > > > I need basic auth to retrieve a wsdl.
> > > > > I currently use the dynamic client. All the constructors take
> > > > > directly a string for the wsdl url.
> > > > > Is there a way to set username/passwd before actually calling
> > > > > the server ?
> > > > >
> > > > > Thanks
> > > > >
> > > > > --
> > > > >
> > > > > Best Regards
> > > > > Guillaume
> > > > > http://cheztog.blogspot.com
> >
> > --
> >
> >
> > Best Regards
> > Guillaume
> > http://cheztog.blogspot.com
--
J. Daniel Kulp
Principal Engineer
IONA
P: 781-902-8727 C: 508-380-7194
daniel.kulp@iona.com
http://www.dankulp.com/blog
Re: Dynamic client & basic auth
Posted by Willem Jiang <ni...@iona.com>.
Hi Guillaume,
Here you are the calling stack of it.
ServiceImpl.initializePorts() -> WSDLServiceFactory ->
WSDLManagerImpl.loadDefinition() ->WSDLReader.readWSDL()
Cheers,
Willem.
tog wrote:
> Hi Willem,
>
> Thanks for the answer. Can you guide me to the location (source file)
> where the URL connection is used to get the wsdl (on the client side)
> ?
>
> Cheers
> Guillaume
>
> On Dec 10, 2007 11:29 AM, Willem Jiang <ni...@iona.com> wrote:
>
>> Hi Guillaume,
>>
>> Please see my comments in the mail.
>> tog wrote:
>>
>>> Hi Willem,
>>>
>>> Can you explain in details your sentence: "The AuthorizationPolicy
>>> only works for HTTP Conduit of HTTP Destination." as I am not familiar
>>> with CXF internals.
>>>
>>>
>>>
>> CXF http transport is implemented by two component HTTP Conduit (client
>> side) and
>> HTTP Destination (server side).
>> But in the Service creation phase these two component are not involved ,
>> because CXF
>> just use the URL connection to get the WSDL file.
>>
>> CXF delegate the WSDL creation to WSDL4J and it use the blow code to
>> create the WSDL
>> definition.
>> URL contextURL = (contextURI != null)
>> ? StringUtils.getURL(null, contextURI)
>> : null;
>> URL url = StringUtils.getURL(contextURL, wsdlURI);
>> InputStream inputStream = StringUtils.getContentAsInputStream(url);
>> InputSource inputSource = new InputSource(inputStream);
>> inputSource.setSystemId(url.toString());
>> Document doc = getDocument(inputSource, url.toString());
>>
>> I don't know if there is a way to set the basic authorization for the
>> url by using system properties.
>>
>>> In my case I am not using a proxy so the flag you are mentioning won't
>>> help much. My server is waiting for the following http header:
>>> "Authorization: Basic ..." and not "Proxy-Authorization"
>>>
>>>
>> OK, this is my mistake. I think you can write codes to get the WSDL from
>> the service which need use
>> HTTP basic authorization, and store this WSDL in the temp directory ,
>> then pass the temp WSDL file's URL
>> to the service.
>>
>>> I might need to dig a bit in order to see what is the effect on the
>>> http request of setting the username and password of
>>> AutorizationPolicy :-)
>>>
>>> Cheers
>>> Guillaume
>>>
>>>
>> Willem.
>>
>>
>>> On Dec 9, 2007 9:32 PM, Willem2 <ni...@iona.com> wrote:
>>>
>>>
>>>> Hi Guillaume
>>>>
>>>> The AuthorizationPolicy only works for HTTP Conduit of HTTP Destination.
>>>> In your case , I don't think this policy will take effect, since CXF just
>>>> uses URL to get wsdl when create the service from wsdl.
>>>>
>>>> Maybe you need to use JVM's proxy setting such as
>>>> -DproxySet=true -DproxyHost=PROXYSERVER -DproxyPort=PORT
>>>>
>>>> Willem.
>>>>
>>>>
>>>>
>>>> tog wrote:
>>>>
>>>>
>>>>> Hum I can believe this ...
>>>>> What I am looking for is a way to set up the Authorization header in
>>>>> the HTTP request (prior to get the wsdl).
>>>>> I know how to set-up the Proxy-Authorization header and I found
>>>>> AuthorizationPolicy
>>>>>
>>>>> AuthorizationPolicy auth = conduit.getAuthorization();
>>>>> auth.setUserName(username);
>>>>> auth.setPassword(password);
>>>>>
>>>>> Will that do the job ?
>>>>> Then the problem is to do this prior to the creation of the client ...
>>>>> which is the first thing I do !
>>>>>
>>>>> Any thought ?
>>>>>
>>>>> Guillaume
>>>>>
>>>>>
>>>>> On Dec 9, 2007 3:34 AM, Glen Mazza <gl...@verizon.net> wrote:
>>>>>
>>>>>
>>>>>> I'm not sure the Java artifacts would have a defined place for such
>>>>>> information.
>>>>>>
>>>>>> Glen
>>>>>>
>>>>>> Am Sonntag, den 09.12.2007, 01:15 +0800 schrieb tog:
>>>>>>
>>>>>>
>>>>>>
>>>>>>> the same question apply for the wsdl2java. I did not see anything for
>>>>>>> setting up username/passwd in the options
>>>>>>>
>>>>>>> On Dec 9, 2007 1:13 AM, tog <gu...@gmail.com> wrote:
>>>>>>>
>>>>>>>
>>>>>>>> Hi
>>>>>>>>
>>>>>>>> I need basic auth to retrieve a wsdl.
>>>>>>>> I currently use the dynamic client. All the constructors take
>>>>>>>>
>>>>>>>>
>>>>>> directly
>>>>>>
>>>>>>
>>>>>>>> a string for the wsdl url.
>>>>>>>> Is there a way to set username/passwd before actually calling the
>>>>>>>>
>>>>>>>>
>>>>>> server ?
>>>>>>
>>>>>>
>>>>>>>> Thanks
>>>>>>>>
>>>>>>>> --
>>>>>>>>
>>>>>>>> Best Regards
>>>>>>>> Guillaume
>>>>>>>> http://cheztog.blogspot.com
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>> --
>>>>>
>>>>> Best Regards
>>>>> Guillaume
>>>>> http://cheztog.blogspot.com
>>>>>
>>>>>
>>>>>
>>>>>
>>>> --
>>>> View this message in context: http://www.nabble.com/Dynamic-client---basic-auth-tp14230385p14238535.html
>>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>>
>>>>
>>>>
>>>>
>>>
>>>
>>>
>
>
>
>
Re: Dynamic client & basic auth
Posted by tog <gu...@gmail.com>.
Hi Willem,
Thanks for the answer. Can you guide me to the location (source file)
where the URL connection is used to get the wsdl (on the client side)
?
Cheers
Guillaume
On Dec 10, 2007 11:29 AM, Willem Jiang <ni...@iona.com> wrote:
> Hi Guillaume,
>
> Please see my comments in the mail.
> tog wrote:
> > Hi Willem,
> >
> > Can you explain in details your sentence: "The AuthorizationPolicy
> > only works for HTTP Conduit of HTTP Destination." as I am not familiar
> > with CXF internals.
> >
> >
> CXF http transport is implemented by two component HTTP Conduit (client
> side) and
> HTTP Destination (server side).
> But in the Service creation phase these two component are not involved ,
> because CXF
> just use the URL connection to get the WSDL file.
>
> CXF delegate the WSDL creation to WSDL4J and it use the blow code to
> create the WSDL
> definition.
> URL contextURL = (contextURI != null)
> ? StringUtils.getURL(null, contextURI)
> : null;
> URL url = StringUtils.getURL(contextURL, wsdlURI);
> InputStream inputStream = StringUtils.getContentAsInputStream(url);
> InputSource inputSource = new InputSource(inputStream);
> inputSource.setSystemId(url.toString());
> Document doc = getDocument(inputSource, url.toString());
>
> I don't know if there is a way to set the basic authorization for the
> url by using system properties.
> > In my case I am not using a proxy so the flag you are mentioning won't
> > help much. My server is waiting for the following http header:
> > "Authorization: Basic ..." and not "Proxy-Authorization"
> >
> OK, this is my mistake. I think you can write codes to get the WSDL from
> the service which need use
> HTTP basic authorization, and store this WSDL in the temp directory ,
> then pass the temp WSDL file's URL
> to the service.
> > I might need to dig a bit in order to see what is the effect on the
> > http request of setting the username and password of
> > AutorizationPolicy :-)
> >
> > Cheers
> > Guillaume
> >
>
> Willem.
>
> > On Dec 9, 2007 9:32 PM, Willem2 <ni...@iona.com> wrote:
> >
> >> Hi Guillaume
> >>
> >> The AuthorizationPolicy only works for HTTP Conduit of HTTP Destination.
> >> In your case , I don't think this policy will take effect, since CXF just
> >> uses URL to get wsdl when create the service from wsdl.
> >>
> >> Maybe you need to use JVM's proxy setting such as
> >> -DproxySet=true -DproxyHost=PROXYSERVER -DproxyPort=PORT
> >>
> >> Willem.
> >>
> >>
> >>
> >> tog wrote:
> >>
> >>> Hum I can believe this ...
> >>> What I am looking for is a way to set up the Authorization header in
> >>> the HTTP request (prior to get the wsdl).
> >>> I know how to set-up the Proxy-Authorization header and I found
> >>> AuthorizationPolicy
> >>>
> >>> AuthorizationPolicy auth = conduit.getAuthorization();
> >>> auth.setUserName(username);
> >>> auth.setPassword(password);
> >>>
> >>> Will that do the job ?
> >>> Then the problem is to do this prior to the creation of the client ...
> >>> which is the first thing I do !
> >>>
> >>> Any thought ?
> >>>
> >>> Guillaume
> >>>
> >>>
> >>> On Dec 9, 2007 3:34 AM, Glen Mazza <gl...@verizon.net> wrote:
> >>>
> >>>> I'm not sure the Java artifacts would have a defined place for such
> >>>> information.
> >>>>
> >>>> Glen
> >>>>
> >>>> Am Sonntag, den 09.12.2007, 01:15 +0800 schrieb tog:
> >>>>
> >>>>
> >>>>> the same question apply for the wsdl2java. I did not see anything for
> >>>>> setting up username/passwd in the options
> >>>>>
> >>>>> On Dec 9, 2007 1:13 AM, tog <gu...@gmail.com> wrote:
> >>>>>
> >>>>>> Hi
> >>>>>>
> >>>>>> I need basic auth to retrieve a wsdl.
> >>>>>> I currently use the dynamic client. All the constructors take
> >>>>>>
> >>>> directly
> >>>>
> >>>>>> a string for the wsdl url.
> >>>>>> Is there a way to set username/passwd before actually calling the
> >>>>>>
> >>>> server ?
> >>>>
> >>>>>> Thanks
> >>>>>>
> >>>>>> --
> >>>>>>
> >>>>>> Best Regards
> >>>>>> Guillaume
> >>>>>> http://cheztog.blogspot.com
> >>>>>>
> >>>>>>
> >>>>>
> >>>>>
> >>>>
> >>>
> >>> --
> >>>
> >>> Best Regards
> >>> Guillaume
> >>> http://cheztog.blogspot.com
> >>>
> >>>
> >>>
> >> --
> >> View this message in context: http://www.nabble.com/Dynamic-client---basic-auth-tp14230385p14238535.html
> >> Sent from the cxf-user mailing list archive at Nabble.com.
> >>
> >>
> >>
> >
> >
> >
> >
>
--
Best Regards
Guillaume
http://cheztog.blogspot.com
Re: Dynamic client & basic auth
Posted by Willem Jiang <ni...@iona.com>.
Hi Guillaume,
Please see my comments in the mail.
tog wrote:
> Hi Willem,
>
> Can you explain in details your sentence: "The AuthorizationPolicy
> only works for HTTP Conduit of HTTP Destination." as I am not familiar
> with CXF internals.
>
>
CXF http transport is implemented by two component HTTP Conduit (client
side) and
HTTP Destination (server side).
But in the Service creation phase these two component are not involved ,
because CXF
just use the URL connection to get the WSDL file.
CXF delegate the WSDL creation to WSDL4J and it use the blow code to
create the WSDL
definition.
URL contextURL = (contextURI != null)
? StringUtils.getURL(null, contextURI)
: null;
URL url = StringUtils.getURL(contextURL, wsdlURI);
InputStream inputStream = StringUtils.getContentAsInputStream(url);
InputSource inputSource = new InputSource(inputStream);
inputSource.setSystemId(url.toString());
Document doc = getDocument(inputSource, url.toString());
I don't know if there is a way to set the basic authorization for the
url by using system properties.
> In my case I am not using a proxy so the flag you are mentioning won't
> help much. My server is waiting for the following http header:
> "Authorization: Basic ..." and not "Proxy-Authorization"
>
OK, this is my mistake. I think you can write codes to get the WSDL from
the service which need use
HTTP basic authorization, and store this WSDL in the temp directory ,
then pass the temp WSDL file's URL
to the service.
> I might need to dig a bit in order to see what is the effect on the
> http request of setting the username and password of
> AutorizationPolicy :-)
>
> Cheers
> Guillaume
>
Willem.
> On Dec 9, 2007 9:32 PM, Willem2 <ni...@iona.com> wrote:
>
>> Hi Guillaume
>>
>> The AuthorizationPolicy only works for HTTP Conduit of HTTP Destination.
>> In your case , I don't think this policy will take effect, since CXF just
>> uses URL to get wsdl when create the service from wsdl.
>>
>> Maybe you need to use JVM's proxy setting such as
>> -DproxySet=true -DproxyHost=PROXYSERVER -DproxyPort=PORT
>>
>> Willem.
>>
>>
>>
>> tog wrote:
>>
>>> Hum I can believe this ...
>>> What I am looking for is a way to set up the Authorization header in
>>> the HTTP request (prior to get the wsdl).
>>> I know how to set-up the Proxy-Authorization header and I found
>>> AuthorizationPolicy
>>>
>>> AuthorizationPolicy auth = conduit.getAuthorization();
>>> auth.setUserName(username);
>>> auth.setPassword(password);
>>>
>>> Will that do the job ?
>>> Then the problem is to do this prior to the creation of the client ...
>>> which is the first thing I do !
>>>
>>> Any thought ?
>>>
>>> Guillaume
>>>
>>>
>>> On Dec 9, 2007 3:34 AM, Glen Mazza <gl...@verizon.net> wrote:
>>>
>>>> I'm not sure the Java artifacts would have a defined place for such
>>>> information.
>>>>
>>>> Glen
>>>>
>>>> Am Sonntag, den 09.12.2007, 01:15 +0800 schrieb tog:
>>>>
>>>>
>>>>> the same question apply for the wsdl2java. I did not see anything for
>>>>> setting up username/passwd in the options
>>>>>
>>>>> On Dec 9, 2007 1:13 AM, tog <gu...@gmail.com> wrote:
>>>>>
>>>>>> Hi
>>>>>>
>>>>>> I need basic auth to retrieve a wsdl.
>>>>>> I currently use the dynamic client. All the constructors take
>>>>>>
>>>> directly
>>>>
>>>>>> a string for the wsdl url.
>>>>>> Is there a way to set username/passwd before actually calling the
>>>>>>
>>>> server ?
>>>>
>>>>>> Thanks
>>>>>>
>>>>>> --
>>>>>>
>>>>>> Best Regards
>>>>>> Guillaume
>>>>>> http://cheztog.blogspot.com
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>
>>>
>>> --
>>>
>>> Best Regards
>>> Guillaume
>>> http://cheztog.blogspot.com
>>>
>>>
>>>
>> --
>> View this message in context: http://www.nabble.com/Dynamic-client---basic-auth-tp14230385p14238535.html
>> Sent from the cxf-user mailing list archive at Nabble.com.
>>
>>
>>
>
>
>
>
Re: Dynamic client & basic auth
Posted by tog <gu...@gmail.com>.
Hi Willem,
Can you explain in details your sentence: "The AuthorizationPolicy
only works for HTTP Conduit of HTTP Destination." as I am not familiar
with CXF internals.
In my case I am not using a proxy so the flag you are mentioning won't
help much. My server is waiting for the following http header:
"Authorization: Basic ..." and not "Proxy-Authorization"
I might need to dig a bit in order to see what is the effect on the
http request of setting the username and password of
AutorizationPolicy :-)
Cheers
Guillaume
On Dec 9, 2007 9:32 PM, Willem2 <ni...@iona.com> wrote:
>
> Hi Guillaume
>
> The AuthorizationPolicy only works for HTTP Conduit of HTTP Destination.
> In your case , I don't think this policy will take effect, since CXF just
> uses URL to get wsdl when create the service from wsdl.
>
> Maybe you need to use JVM's proxy setting such as
> -DproxySet=true -DproxyHost=PROXYSERVER -DproxyPort=PORT
>
> Willem.
>
>
>
> tog wrote:
> >
> > Hum I can believe this ...
> > What I am looking for is a way to set up the Authorization header in
> > the HTTP request (prior to get the wsdl).
> > I know how to set-up the Proxy-Authorization header and I found
> > AuthorizationPolicy
> >
> > AuthorizationPolicy auth = conduit.getAuthorization();
> > auth.setUserName(username);
> > auth.setPassword(password);
> >
> > Will that do the job ?
> > Then the problem is to do this prior to the creation of the client ...
> > which is the first thing I do !
> >
> > Any thought ?
> >
> > Guillaume
> >
> >
> > On Dec 9, 2007 3:34 AM, Glen Mazza <gl...@verizon.net> wrote:
> >> I'm not sure the Java artifacts would have a defined place for such
> >> information.
> >>
> >> Glen
> >>
> >> Am Sonntag, den 09.12.2007, 01:15 +0800 schrieb tog:
> >>
> >> > the same question apply for the wsdl2java. I did not see anything for
> >> > setting up username/passwd in the options
> >> >
> >> > On Dec 9, 2007 1:13 AM, tog <gu...@gmail.com> wrote:
> >> > > Hi
> >> > >
> >> > > I need basic auth to retrieve a wsdl.
> >> > > I currently use the dynamic client. All the constructors take
> >> directly
> >> > > a string for the wsdl url.
> >> > > Is there a way to set username/passwd before actually calling the
> >> server ?
> >> > >
> >> > > Thanks
> >> > >
> >> > > --
> >> > >
> >> > > Best Regards
> >> > > Guillaume
> >> > > http://cheztog.blogspot.com
> >> > >
> >> >
> >> >
> >> >
> >>
> >>
> >
> >
> >
> > --
> >
> > Best Regards
> > Guillaume
> > http://cheztog.blogspot.com
> >
> >
>
> --
> View this message in context: http://www.nabble.com/Dynamic-client---basic-auth-tp14230385p14238535.html
> Sent from the cxf-user mailing list archive at Nabble.com.
>
>
--
Best Regards
Guillaume
http://cheztog.blogspot.com
Re: Dynamic client & basic auth
Posted by Willem2 <ni...@iona.com>.
Hi Guillaume
The AuthorizationPolicy only works for HTTP Conduit of HTTP Destination.
In your case , I don't think this policy will take effect, since CXF just
uses URL to get wsdl when create the service from wsdl.
Maybe you need to use JVM's proxy setting such as
-DproxySet=true -DproxyHost=PROXYSERVER -DproxyPort=PORT
Willem.
tog wrote:
>
> Hum I can believe this ...
> What I am looking for is a way to set up the Authorization header in
> the HTTP request (prior to get the wsdl).
> I know how to set-up the Proxy-Authorization header and I found
> AuthorizationPolicy
>
> AuthorizationPolicy auth = conduit.getAuthorization();
> auth.setUserName(username);
> auth.setPassword(password);
>
> Will that do the job ?
> Then the problem is to do this prior to the creation of the client ...
> which is the first thing I do !
>
> Any thought ?
>
> Guillaume
>
>
> On Dec 9, 2007 3:34 AM, Glen Mazza <gl...@verizon.net> wrote:
>> I'm not sure the Java artifacts would have a defined place for such
>> information.
>>
>> Glen
>>
>> Am Sonntag, den 09.12.2007, 01:15 +0800 schrieb tog:
>>
>> > the same question apply for the wsdl2java. I did not see anything for
>> > setting up username/passwd in the options
>> >
>> > On Dec 9, 2007 1:13 AM, tog <gu...@gmail.com> wrote:
>> > > Hi
>> > >
>> > > I need basic auth to retrieve a wsdl.
>> > > I currently use the dynamic client. All the constructors take
>> directly
>> > > a string for the wsdl url.
>> > > Is there a way to set username/passwd before actually calling the
>> server ?
>> > >
>> > > Thanks
>> > >
>> > > --
>> > >
>> > > Best Regards
>> > > Guillaume
>> > > http://cheztog.blogspot.com
>> > >
>> >
>> >
>> >
>>
>>
>
>
>
> --
>
> Best Regards
> Guillaume
> http://cheztog.blogspot.com
>
>
--
View this message in context: http://www.nabble.com/Dynamic-client---basic-auth-tp14230385p14238535.html
Sent from the cxf-user mailing list archive at Nabble.com.
Re: Dynamic client & basic auth
Posted by tog <gu...@gmail.com>.
Ok looking in the mailing list, it looks that this is not yet
implemented (I mean for retrieving the wsdl)
Dan,what would be the effort for adding this ? If you guide me,I might
consider working on this as I did for the proxy auth in XFire.
In order to avoit the problem,I retrieved the wsdl using wget.Once it
is local and the AuthorizationPolicy has been set up,the subsequent
calls are working fine
Guillaume
On Dec 9, 2007 5:22 PM, tog <gu...@gmail.com> wrote:
> Hum I can believe this ...
> What I am looking for is a way to set up the Authorization header in
> the HTTP request (prior to get the wsdl).
> I know how to set-up the Proxy-Authorization header and I found
> AuthorizationPolicy
>
> AuthorizationPolicy auth = conduit.getAuthorization();
> auth.setUserName(username);
> auth.setPassword(password);
>
> Will that do the job ?
> Then the problem is to do this prior to the creation of the client ...
> which is the first thing I do !
>
> Any thought ?
>
> Guillaume
>
>
>
> On Dec 9, 2007 3:34 AM, Glen Mazza <gl...@verizon.net> wrote:
> > I'm not sure the Java artifacts would have a defined place for such
> > information.
> >
> > Glen
> >
> > Am Sonntag, den 09.12.2007, 01:15 +0800 schrieb tog:
> >
> > > the same question apply for the wsdl2java. I did not see anything for
> > > setting up username/passwd in the options
> > >
> > > On Dec 9, 2007 1:13 AM, tog <gu...@gmail.com> wrote:
> > > > Hi
> > > >
> > > > I need basic auth to retrieve a wsdl.
> > > > I currently use the dynamic client. All the constructors take directly
> > > > a string for the wsdl url.
> > > > Is there a way to set username/passwd before actually calling the server ?
> > > >
> > > > Thanks
> > > >
> > > > --
> > > >
> > > > Best Regards
> > > > Guillaume
> > > > http://cheztog.blogspot.com
> > > >
> > >
> > >
> > >
> >
> >
>
>
>
> --
>
>
> Best Regards
> Guillaume
> http://cheztog.blogspot.com
>
--
Best Regards
Guillaume
http://cheztog.blogspot.com
Re: Dynamic client & basic auth
Posted by tog <gu...@gmail.com>.
Hum I can believe this ...
What I am looking for is a way to set up the Authorization header in
the HTTP request (prior to get the wsdl).
I know how to set-up the Proxy-Authorization header and I found
AuthorizationPolicy
AuthorizationPolicy auth = conduit.getAuthorization();
auth.setUserName(username);
auth.setPassword(password);
Will that do the job ?
Then the problem is to do this prior to the creation of the client ...
which is the first thing I do !
Any thought ?
Guillaume
On Dec 9, 2007 3:34 AM, Glen Mazza <gl...@verizon.net> wrote:
> I'm not sure the Java artifacts would have a defined place for such
> information.
>
> Glen
>
> Am Sonntag, den 09.12.2007, 01:15 +0800 schrieb tog:
>
> > the same question apply for the wsdl2java. I did not see anything for
> > setting up username/passwd in the options
> >
> > On Dec 9, 2007 1:13 AM, tog <gu...@gmail.com> wrote:
> > > Hi
> > >
> > > I need basic auth to retrieve a wsdl.
> > > I currently use the dynamic client. All the constructors take directly
> > > a string for the wsdl url.
> > > Is there a way to set username/passwd before actually calling the server ?
> > >
> > > Thanks
> > >
> > > --
> > >
> > > Best Regards
> > > Guillaume
> > > http://cheztog.blogspot.com
> > >
> >
> >
> >
>
>
--
Best Regards
Guillaume
http://cheztog.blogspot.com
Re: Dynamic client & basic auth
Posted by Glen Mazza <gl...@verizon.net>.
I'm not sure the Java artifacts would have a defined place for such
information.
Glen
Am Sonntag, den 09.12.2007, 01:15 +0800 schrieb tog:
> the same question apply for the wsdl2java. I did not see anything for
> setting up username/passwd in the options
>
> On Dec 9, 2007 1:13 AM, tog <gu...@gmail.com> wrote:
> > Hi
> >
> > I need basic auth to retrieve a wsdl.
> > I currently use the dynamic client. All the constructors take directly
> > a string for the wsdl url.
> > Is there a way to set username/passwd before actually calling the server ?
> >
> > Thanks
> >
> > --
> >
> > Best Regards
> > Guillaume
> > http://cheztog.blogspot.com
> >
>
>
>
Re: Dynamic client & basic auth
Posted by tog <gu...@gmail.com>.
the same question apply for the wsdl2java. I did not see anything for
setting up username/passwd in the options
On Dec 9, 2007 1:13 AM, tog <gu...@gmail.com> wrote:
> Hi
>
> I need basic auth to retrieve a wsdl.
> I currently use the dynamic client. All the constructors take directly
> a string for the wsdl url.
> Is there a way to set username/passwd before actually calling the server ?
>
> Thanks
>
> --
>
> Best Regards
> Guillaume
> http://cheztog.blogspot.com
>
--
Best Regards
Guillaume
http://cheztog.blogspot.com