I would like to set a Spring Boot 2 property to disable all tracking modes. Should it be server.servlet.session.tracking-modes=
# Session tracking modes (one or more of the following: "cookie", "url", "ssl").
I.e. leave it without a value?
This is a Spring Boot application that was running on JBoss, but now it will be running standalone (with built-in Tomcat server).
The old code to disable all tracking was as follows:
@SpringBootApplication(exclude = {
SecurityAutoConfiguration.class
})
@Import(WebAppConfiguration.class)
public class WebAppRunner extends SpringBootServletInitializer {
public static void main(String[] args) {
SpringApplication.run(WebAppRunner.class, args);
}
@Override
public void onStartup(ServletContext servletContext) throws ServletException {
servletContext.setSessionTrackingModes(emptySet());
super.onStartup(servletContext);
}
@Override
protected SpringApplicationBuilder configure(SpringApplicationBuilder application) {
return application.sources(getClass());
}
}
I expect there not to be any tracking, whether hidden or via jsessionid.