[RTC EWM] How to login to a server built with WAS Liberty? , Using Msxml2.ServerXMLHTTP from VBA
How to login to a server built with WAS Liberty? , Using Msxml2.ServerXMLHTTP from VBA
|
2 answers
Thank you for your replies.
Comments I use that option in Postman, because the Form based authentication provides information if the authentication succeeded as URI in the Location header. If you are redirected in Postman, you can not check the Location header.
HIROAKI JOSAKO
commented Jun 29 '21, 4:33 a.m.
Thanks.
My Python code uses a requests session which automatically follows redirects and logs in perfectly well on Liberty. Don't try to log in explicitly, it's cleaner to only log in when the result from a request indicates login is needed. On the initial access to a protected resource the result (after redirection, because you don't see the 302s) is 200 and there's a header in the response X-com-ibm-team-repository-web-auth-msg: authrequired - if both conditions are true then ignore the data in the response and do the login and (at least for DOORS Next) the login automatically redirects to GET the original protected resource; I've not tried recently on EWM but I imagine it would be the same - if it's not then after successful login retry the original GET. If you weren't doing a GET originally (e.g. POST) then you always have to explicitly retry the request. |
Ralph Schoon (63.1k●3●36●45)
| answered Jun 25 '21, 4:35 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER Please be a ware of https://jazz.net/wiki/bin/view/Deployment/CLMProductAPILanding and have a look at Authentication of a native client with a Jazz-based application.
Your simplest options are Form Based Auth or Basic Auth. Form based auth requires cookies, basic auth, requires the Auth header to be sent with each request. I have tried to explain this here: https://rsjazz.wordpress.com/2019/05/13/using-a-rest-client-to-authenticate-to-elm-clm-applications/
I do not know, if anyone here can comment on the MS tools in use, but I am very certain, that authentication should work the same for any of the supported application servers.
Comments
HIROAKI JOSAKO
commented Jun 28 '21, 4:11 a.m.
Thanks! Ralph.
|
Comments
See this article, for Liberty local auth under the heading FORM Challenge https://jazz.net/wiki/bin/view/Main/NativeClientAuthentication , for JAS under the Open ID Connect heading. I'm sure the Jazz auth details don't change based on the client library you're using; you'll have to translate your code using the one you have had working before into the API/concepts of the one you want to use now.
Thanks! Ian
add Question Under Comment
Please reply