Application Delivery Management
Application Modernization & Connectivity
CyberRes
IT Operations Management
NAM Identity Provider authenticates the user based on configured contract, method and authentication class. NAM authentication classes are deployed in IDP servers and running as server-side code.
If you would like to update user’s profile or execute some business logic (post-processing) without stopping or delaying regular login process, follow this solution to create custom authentication class and run post-processing in a separate thread.
Write your own post-processing/business logic code inside executePostProcessing() method and create a JAR file from the JAVA Project. Copy the JAR file into /opt/novell/nids/lib/webapp/WEB-INF/lib location of IDP server. You need to restart IDP service after deploying the JAR file.
I have given a sample JAR file here to download. (remove .txt extension after download)
Download MyCustomAuthenticationClass.jar
Download attached project and open into eclipse.
Download MyCustomAuthenticationClass.zip
In my example, I have created a custom Authentication Class named MyCustomAuthenticationClass and a Thread class named MyPostProcessing. I have initiated the thread from doAuthenticate() method.
Now open Admin Console and follow the below steps to configure class, method, and contract in IDP cluster.
Open a proxy service in Access Gateway and assign the contract as an authentication procedure.
Try to access the protected URL and provide valid credentials.
Open IDP log file and you will find following logs:
<amLogEntry> 2018-01-10T22:50:16Z VERBOSE NIDS Application: Executing authentication method MyCustomAuthenticationMethod </amLogEntry>
*******Post Prcessing Thread Started for : kouhal *********
********** Inside Post Processing Class for user: kouhal ********
****************START POST Processing***************
Processing User Update
****************END POST Processing***************
<amLogEntry> 2018-01-10T22:50:16Z VERBOSE NIDS Application: Authentication method MyCustomAuthenticationMethod succeeded </amLogEntry>