You don't have to change a web resource, such as a JSP page, HTML page, or a servlet, to log users who come to that resource, to restrict access to it, to alter the data sent to it, or to alter the data that comes back from it. All you need is a filter. Creating a new filter isn't hard; it's just a Java class that implements the javax.servlet.Filter interface. You can see all the methods of this interface in Table 6.1.
|