Error on session expire

Hi there,

I’m using vaadin 6.8.6, java 6 and virgo server. I have a problem when session expires: when it happens the user goes to the login page (and this is right) but the user has also the following error message on top of the login page:

(SyntaxError): missing ) in parenthetical  stack: EV@http://localhost:8080/model-admin/VAADIN/widgetsets
/com.vaadin.terminal.gwt.DefaultWidgetSet/EFBCD53474C520000C81368D71C7D299.cache.html:1781 RV@http://localhost:8080/model-admin/VAADIN
/widgetsets/com.vaadin.terminal.gwt.DefaultWidgetSet/EFBCD53474C520000C81368D71C7D299.cache.html:3226 tm@http://localhost:8080/model-
admin/VAADIN/widgetsets/com.vaadin.terminal.gwt.DefaultWidgetSet/EFBCD53474C520000C81368D71C7D299.cache.html:2452 
Tm@http://localhost:8080/model-admin/VAADIN/widgetsets/com.vaadin.terminal.gwt.DefaultWidgetSet
/EFBCD53474C520000C81368D71C7D299.cache.html:3223 @http://localhost:8080/model-admin/VAADIN/widgetsets
/com.vaadin.terminal.gwt.DefaultWidgetSet/EFBCD53474C520000C81368D71C7D299.cache.html:1763 Rb@http://localhost:8080/model-admin/VAADIN
/widgetsets/com.vaadin.terminal.gwt.DefaultWidgetSet/EFBCD53474C520000C81368D71C7D299.cache.html:1380 Ub@http://localhost:8080/model-
admin/VAADIN/widgetsets/com.vaadin.terminal.gwt.DefaultWidgetSet/EFBCD53474C520000C81368D71C7D299.cache.html:2697 @http://localhost:8080
/model-admin/VAADIN/widgetsets/com.vaadin.terminal.gwt.DefaultWidgetSet/EFBCD53474C520000C81368D71C7D299.cache.html:1913   fileName: 
http://localhost:8080/model-admin/VAADIN/widgetsets/com.vaadin.terminal.gwt.DefaultWidgetSet/EFBCD53474C520000C81368D71C7D299.cache.html  
lineNumber: 1781 - Original JSON-text: html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"

At first I thought it was a problem of xml validation but I solved all the errors and now the login page is w3c compliant.
It seems an obvious error because it is missing “)” in a EFB*.cache.html file but I’m not generating it.
When the user gets this error if he refresh the page the error disappears.

Web.xml is set with FORM authentication method and I have login page.
This is the web.xml file:

<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" id="WebApp_ID" version="2.5">
    <display-name>Model Administrator</display-name>

	<!-- VAADIN SERVLET -->
	<servlet>
		<servlet-name>ConsoleApplication</servlet-name>
		<servlet-class>com.myapp.core.vaaddin.servlet.VaadinServlet</servlet-class>
		<!--<servlet-class>com.myapp.model.admin.ui.DelegateServlet</servlet-class>-->
		
        <init-param>
            <param-name>ClassLoader</param-name>
            <param-value>com.myapp.model.admin.ui.ContextClassLoader</param-value>
        </init-param>
		
		<init-param>
			<description>Console</description>
			<param-name>application</param-name>
			<param-value>com.myapp.model.admin.ui.ConsoleApplication</param-value>
		</init-param>
	</servlet>	
	
	
	<!-- SERVLET MAPPING -->
	<servlet-mapping>
		<servlet-name>ConsoleApplication</servlet-name>
		<url-pattern>/ui/*</url-pattern>
	</servlet-mapping>	

   <servlet-mapping>
        <servlet-name>ConsoleApplication</servlet-name>
        <url-pattern>/VAADIN/*</url-pattern>
    </servlet-mapping>	

   	<filter>
		<filter-name>TenantFilter</filter-name>
		<filter-class>com.myapp.security.bridge.web.TenantFilter</filter-class>
		<init-param>
			<param-name>module.name</param-name>
			<param-value>admin</param-value>
		</init-param>
		<init-param>
			<param-name>service.name</param-name>
			<param-value>model</param-value>
		</init-param>
	</filter>
	
   <filter-mapping>
       <filter-name>TenantFilter</filter-name>
       <url-pattern>/ui/*</url-pattern>
   </filter-mapping>


    <security-constraint>
      <web-resource-collection>
        <web-resource-name>Protected Area</web-resource-name>
        <url-pattern>/ui/*</url-pattern>
      </web-resource-collection>
      <auth-constraint>
        <role-name>nauser</role-name>
      </auth-constraint>
    </security-constraint> 
    <!-- Default login configuration uses form-based authentication -->
    <login-config>
      <auth-method>FORM</auth-method>
      <realm-name>Example Form-Based Authentication Area</realm-name>
      <form-login-config>
        <form-login-page>/login/login.jsp</form-login-page>
        <form-error-page>/login/login.jsp?auth_error=true</form-error-page>
      </form-login-config>
    </login-config>     	
</web-app>

What can I do to solve this error ?

This is the login page:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
 <head>
 <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
   <title>Login</title>
</head>
<body>

<form method="post" action="j_security_check" class="form-1" >
  
 <p> Username: <input type="text" name="j_username" />  </p>
 <p> Password: <input type="password" name="j_password" /> </p>

 
 <p><input type="submit" value="login" /></p>
</form>

</body>
</html>

thanks for any help

The problem is that Vaadin tries to interpret the HTML of the login-page as UIDL-response. Add “Vaadin-Refresh” somewhere on your Login-page (e.g. as a comment) to force Vaadin to just load your page.