(Please refer this if you are not familiar with them)Step 1: Create a maven project in intelli J idea Step 2: Add the required dependencies to the Add the javax.servlet-api and tomcat7-maven-plugin into the and make the packaging as “war”. If there is a request for a path that starts with /admin without an existing session, this filter will log it as an unauthorized request and redirect to login
For example, consider a user logging into a website.
Use this API if, for example, you want to set the session cookie yourself instead of allowing Okta to set it, or want to hold the session ID in order to delete a session via the API instead of visiting the logout URL.
The application or container uses predictable session identifiers.
Okta provides a very rich Authentication API to validate a user’s primary credentials and secondary MFA factor.
A session token is returned after successful authentication which can be later exchanged for a session cookie using one of the following flows: Creates a new session for a user with a valid session token.