Skip to content

Logout configuration

LELEU Jérôme edited this page Nov 20, 2020 · 3 revisions

You need to define a logout endpoint using the LogoutController to handle logout.

>> Read the documentation to understand its behavior and the available options.

While getters/setters can be used to define the options, the pac4j.logout.* properties can also be used. The additional pac4j.logout.path property (optional) allows to define the path of which the logout controller is triggered (/logout by default).

The LogoutController must be defined by classpath scanning:

Spring context file:

<context:component-scan base-package="org.pac4j.springframework.web" />

Spring configuration class:

@ComponentScan(basePackages = "org.pac4j.springframework.web")

The default internal components of the LogoutController are: JEESessionStore.INSTANCE, JEEHttpActionAdapter.INSTANCE, DefaultLogoutLogic.INSTANCE and JEEContextFactory.INSTANCE.

Clone this wiki locally