Package net.ltgt.oidc.servlet
Class LoginServlet
java.lang.Object
jakarta.servlet.GenericServlet
jakarta.servlet.http.HttpServlet
net.ltgt.oidc.servlet.LoginServlet
- All Implemented Interfaces:
Servlet,ServletConfig,Serializable
This servlet starts the authentication workflow and redirects back to a given URL afterward.
The target page is given in the Utils.RETURN_TO_PARAMETER_NAME request parameter. It
should be given as an absolute path (possibly with a query string), though a full URL would be
accepted as long as it's the same origin.
- See Also:
-
Field Summary
Fields inherited from class jakarta.servlet.http.HttpServlet
LEGACY_DO_HEAD -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidConfigures the authentication request when redirecting to the OpenID Provider.protected voiddoGet(HttpServletRequest req, HttpServletResponse resp) protected voiddoPost(HttpServletRequest req, HttpServletResponse resp) voidinit()Methods inherited from class jakarta.servlet.http.HttpServlet
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, init, service, serviceMethods inherited from class jakarta.servlet.GenericServlet
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, log, log
-
Constructor Details
-
LoginServlet
public LoginServlet()
-
-
Method Details
-
init
- Overrides:
initin classGenericServlet- Throws:
ServletException
-
doGet
protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException - Overrides:
doGetin classHttpServlet- Throws:
ServletExceptionIOException
-
doPost
protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException - Overrides:
doPostin classHttpServlet- Throws:
ServletExceptionIOException
-
configureAuthenticationRequest
@ForOverride protected void configureAuthenticationRequest(HttpServletRequest req, AuthenticationRequest.Builder builder) Configures the authentication request when redirecting to the OpenID Provider.
-