Hi all,
We've written a custom login module, with some checks built in to determine if a user is allowed to logon (example if his current domain is included in a list of valid domains that are allowed to logon to the portal). The loginmodule works fine, but we want to give the users some usefull message regarding the reasen access is denied.
The class we use extends <a href="https://media.sdn.sap.com/javadocs/NW04/SPS15/en/com/sap/engine/interfaces/security/auth/AbstractLoginModule.html#throwNewLoginException(java.lang.String)">AbstractLoginModule</a>, which has some methods like
throwUserLoginException(Exception exception, byte cause) and throwUserLoginException(Exception exception)
Below a snippet of the code :
throwNewLoginException("current domain not contained in list of allowed domains", LoginExceptionDetails.USER_IS_CURRENTLY_NOT_VALID) ;
Also tried :
throwUserLoginException(new Exception ("current domain not contained in list of allowed domains"), (byte) 2) ;
All the user gets to see in the login screen when the logon is being denied is " Unknown message (ID = UNKNOWN_ERROR) ". How can we pass usefull info to the end- users?
Many thanks,
Kevin