I already have two filters, which typically checks for a valid session. If session is valid it ll redirect to the ExpenseDetailsManagement.html
else ExpenseManagementLogin.html
. The web.xml config looks like,
<filter>
<filter-name>ExpenseAuthentication</filter-name>
<filter-class>com.pricar.hibernate.ExpenseAuthentication</filter-class>
</filter>
<filter>
<filter-name>ExpenseAuthenticationFilter</filter-name>
<filter-class>com.pricar.hibernate.ExpenseAuthenticationFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>ExpenseAuthentication</filter-name>
<url-pattern>*/ExpenseDetailsManagement.html</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>ExpenseAuthenticationFilter</filter-name>
<url-pattern>*/ExpenseManagementLogin.html</url-pattern>
</filter-mapping>
The above two were working fine.
The application path looks like
http://localhost:8080/Hibernate/ExpenseManagementLogin.html
If i tries with http://localhost:8080/Hibernate
, then ExpenseManagementLogin.html
is loading
even if i have a valid session.
For that i tried some url-mapping-patterns like Hibernate/
, /Hibernate/
, /*
then
its ends with infinite looping or resource not found error.
My web-app just have two html pages, one for login and another for app-stuff.
Any suggestions!!!