ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Handling userid and Password in WMB

Post new topic  Reply to topic
 Handling userid and Password in WMB « View previous topic :: View next topic » 
Author Message
shilpa.sabade
PostPosted: Mon Sep 10, 2012 5:53 am    Post subject: Handling userid and Password in WMB Reply with quote

Voyager

Joined: 23 Feb 2011
Posts: 76

Hello,

Below is my problem scenario , need your assistance here .

we are trying to consume a WEbservice , hosted in webmethod enviroment .
initially we tried to test this webservice using soap ui.

Here are observations .

1) when we pass user credentials using wsse header , it faults with auth error .
<wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd">
<wsse:UsernameToken wsu:Id="UsernameToken-2" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">
<wsse:Username>*******</wsse:Username>
<wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">***********</wsse:Password>
</wsse:UsernameToken>
</wsse:Security>

2) when we send same credential in soap ui Auth username and password fields , we get good response.

Here is my question , where does sopa ui include this info (user id and pwd) while calling webservice .

We need to implement this WEB service call in WMB 7003 , not understanding how to include user id and password.

I have tried constructing wsse security , it does not work (auth error same as SOAP UI)

I tried with Policy set and bindings , getting same auth error.
Back to top
View user's profile Send private message
lancelotlinc
PostPosted: Mon Sep 10, 2012 5:58 am    Post subject: Reply with quote

Jedi Knight

Joined: 22 Mar 2010
Posts: 4941
Location: Bloomington, IL USA

We answered this already last week.

Code:
OutputRoot.SOAP.Header.wsse:Security.wsse:UsernameToken.wsse:Password

_________________
http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER
Back to top
View user's profile Send private message Send e-mail
Vitor
PostPosted: Mon Sep 10, 2012 6:08 am    Post subject: Re: Handling userid and Password in WMB Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

shilpa.sabade wrote:
Below is my problem scenario , need your assistance here .


And no matter how many times you ask the same question (IIRC this is your 3rd time with this), you're going to get the same answer.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
shilpa.sabade
PostPosted: Mon Sep 10, 2012 11:13 pm    Post subject: Reply with quote

Voyager

Joined: 23 Feb 2011
Posts: 76

lancelotlinc wrote:
We answered this already last week.

Code:
OutputRoot.SOAP.Header.wsse:Security.wsse:UsernameToken.wsse:Password


Hi ,

I have tried this approach ,
SET OutputRoot.SOAP.Header.wsse:Security.wsse:UsernameToken.(SOAP.Attribute)wsu:Id='UsernameToken-2';
SET OutputRoot.SOAP.Header.wsse:Security.wsse:UsernameToken.wsse:Username=WSSEUSERNAME;
SET OutputRoot.SOAP.Header.wsse:Security.wsse:UsernameToken.wsse:Password.(SOAP.Attribute)Type='http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText';
SET OutputRoot.SOAP.Header.wsse:Security.wsse:UsernameToken.wsse:Password=WSSEPASSWORD;

I have also tried Default policy set and binding with ,

SET OutputRoot.Properties.IdentitySourceType = 'Usernameandpassword';
SET OutputRoot.Properties.IdentitySourceToken = 'XXXXX';
SET OutputRoot.Properties.IdentitySourcePassword = 'XXXXX';

But it doesnot work .

Please note my observations with SOAP UI .
1) when we pass user credentials using wsse header , it faults with auth error .
2) when we send same credential in soap ui Auth username and password fields , we get good response. Without WSSE in SOAP header.
Back to top
View user's profile Send private message
shilpa.sabade
PostPosted: Mon Sep 10, 2012 11:15 pm    Post subject: Re: Handling userid and Password in WMB Reply with quote

Voyager

Joined: 23 Feb 2011
Posts: 76

Vitor wrote:
shilpa.sabade wrote:
Below is my problem scenario , need your assistance here .


And no matter how many times you ask the same question (IIRC this is your 3rd time with this), you're going to get the same answer.



Hi ,

I think , this problem is slightly different . My other post was about setting wsse , and got it resolved .

Any guidance here?
Back to top
View user's profile Send private message
marko.pitkanen
PostPosted: Tue Sep 11, 2012 12:37 am    Post subject: Reply with quote

Chevalier

Joined: 23 Jul 2008
Posts: 440
Location: Jamsa, Finland

Hi shilpa.sabade,

I guess --based on how you described the phenomenon- that the WS you are trying to use expects Http Basic Authentication.

--
Marko
Back to top
View user's profile Send private message Visit poster's website
McueMart
PostPosted: Tue Sep 11, 2012 12:46 am    Post subject: Reply with quote

Chevalier

Joined: 29 Nov 2011
Posts: 490
Location: UK...somewhere

Use a proxy and/or Wireshark to compare the exact message sent by soupUI and compare it to the message sent from Broker. That should clear up the issue you are having (Although I do suspect it might be Basic Auth as mentioned above!)
Back to top
View user's profile Send private message
shilpa.sabade
PostPosted: Tue Sep 11, 2012 4:44 am    Post subject: Reply with quote

Voyager

Joined: 23 Feb 2011
Posts: 76

marko.pitkanen wrote:
Hi shilpa.sabade,

I guess --based on how you described the phenomenon- that the WS you are trying to use expects Http Basic Authentication.

--
Marko



Thank you so much .. This hint helped me .
Now am able to hit WS , by setting HTTPREquestHeader properties .

I also read through SOAP UI , how it handles this situation. They aslo talk about HTTP basic authentication.

http://www.robert-nemet.com/2011/10/soapui-http-authentications-part-one.html#!/2011/10/soapui-http-authentications-part-one.html
Back to top
View user's profile Send private message
paustin_ours
PostPosted: Wed Oct 17, 2012 5:04 am    Post subject: Reply with quote

Yatiri

Joined: 19 May 2004
Posts: 667
Location: columbus,oh

Can you please let us know where and how you set up the username and password? Did you use a httpheader node to add the username and password?
Back to top
View user's profile Send private message Yahoo Messenger
mqjeff
PostPosted: Wed Oct 17, 2012 5:09 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

paustin_ours wrote:
Can you please let us know where and how you set up the username and password? Did you use a httpheader node to add the username and password?


You don't need to do that.

You can use the mapped fields in Identity and default propagation on the HTTPRequest node.
Back to top
View user's profile Send private message
lancelotlinc
PostPosted: Wed Oct 17, 2012 5:10 am    Post subject: Reply with quote

Jedi Knight

Joined: 22 Mar 2010
Posts: 4941
Location: Bloomington, IL USA

There is a tutorial in developerWorks that explains this. If you were skilled at using Google, you would find it.
_________________
http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER
Back to top
View user's profile Send private message Send e-mail
shilpa.sabade
PostPosted: Wed Oct 24, 2012 10:52 pm    Post subject: Reply with quote

Voyager

Joined: 23 Feb 2011
Posts: 76

paustin_ours wrote:
Can you please let us know where and how you set up the username and password? Did you use a httpheader node to add the username and password?




Here is the code for compute node , which worked for us :
SET OutputRoot.HTTPRequestHeader."Content-Type"= 'text/xml';
SET OutputRoot.HTTPRequestHeader."Authorization" = 'Basic '||BASE64ENCODE(CAST('userid'||':'||'pwd' as BLOB CCSID 1208));
Back to top
View user's profile Send private message
McueMart
PostPosted: Wed Oct 24, 2012 11:59 pm    Post subject: Reply with quote

Chevalier

Joined: 29 Nov 2011
Posts: 490
Location: UK...somewhere

You are doing it the hard way because as mqjeff said:
Quote:
You can use the mapped fields in Identity and default propagation on the HTTPRequest node.
Back to top
View user's profile Send private message
shilpa.sabade
PostPosted: Thu Oct 25, 2012 6:04 am    Post subject: Reply with quote

Voyager

Joined: 23 Feb 2011
Posts: 76

McueMart wrote:
You are doing it the hard way because as mqjeff said:
Quote:
You can use the mapped fields in Identity and default propagation on the HTTPRequest node.


Hi ,


Am not able to recall complete error screnario which i faced , while using Source Identity.
when we use default propagation , it was explicitly looking for policy set and binding

when i created policy set and binding with username token i was not getting result .

not sure , what i missed here but default propagation source identity.

Thank you
Back to top
View user's profile Send private message
mqjeff
PostPosted: Thu Oct 25, 2012 6:21 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

Policy Sets and Policy Set Bindings are specific to WS-Security.

Identity Propagation is determined from the Security Profile.

Policy Sets and Policy Bindings are used to inform the Security Profile about the WS-Security mechanisms in use.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Handling userid and Password in WMB
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.