doFilter
doFilter is a Java Servlet API interface that allows for the interception and processing of requests and responses before they reach their ultimate destination or after they have been generated. It is a fundamental component of the Java EE (now Jakarta EE) web tier, enabling developers to implement cross-cutting concerns such as authentication, logging, character encoding, and data transformation.
A doFilter method is the core of a Filter implementation. This method receives a ServletRequest, a ServletResponse,
Filters are configured in the deployment descriptor (web.xml) or through annotations. They can be mapped to