on 10-30-2007 2:10 PM
Hello,
i have an Java WebDynpro Application and want to read the user-id / sap-name of the user visiting the Java WD site. The Java WD application is public and on an application server where the visitor has no user in the system! I want to read the user-id, which the user has on the portal (another application server), or for example from the single sign on SSO.
Is there any possibility to read the user-id from SSO or via a cookie or something else? I just need the user-id or the sap-name. No password and no authorization needed!
Kind Regards,
Thomas
Hi Thomas,
Did you try:
IWDClientUser clientUser = WDClientUser.getLoggedInClientUser();
IUser user = clientUser.getSAPUser();
Hope this helps.
Eneko.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Thomas,
I've checked the cookie MYSAPSSO2 and found it to be an encrypted value. But, I think i've found another way to get the user-id. Please try this and let me know.
IWDClientUser clientUser = WDClientUser.forceLoggedInClientUser(TaskBinder.getCurrentTask().getProtocolAdapter().getRequestObjectInternal().getProtocolRequest(), TaskBinder.getCurrentTask().getProtocolAdapter().getResponseObjectInternal().getProtocolResponse());
String userId = clientUser.getClientUserID();
Also, set the application property "authentication" to true (if applicable).
Please let me know.
Regards,
Rajit
Hi Thomas,
If my previous post doesnt help you, there's one more you can try. Its SAPSSOEXT. For one, it can be used to verify the cookie as well as decrypt it to get the userID (as I understand).
Get it from:
Downloads -> Search Support Packages and Patches (search for SAPSSOEXT). I'm trying to download it as we speak and will let you know if I find anything.
Also, check this thread.
Regards,
Rajit
UPDATE:
I've tried with SAPSSOEXT and was able to get the user-id from SSO cookie.
Get SAPSSOEXT and SECULIB54 (this has sapsecu.dll) from Service Market place.
Place both dlls in PATH.
Get the verify.pse certificate file from the portal server issuing SSO ticket and run the sample Java class file from SAPSSOEXT.
Let me know if you've trouble.
Regards,
Message was edited by:
Rajit Srinivas
User | Count |
---|---|
84 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.