@@ -0,0 +1,1015 @@
+package net.etalia.crepuscolo.auth;%0A%0Aimport java.io.IOException;%0A%0Aimport javax.servlet.Filter;%0Aimport javax.servlet.FilterChain;%0Aimport javax.servlet.FilterConfig;%0Aimport javax.servlet.ServletException;%0Aimport javax.servlet.ServletRequest;%0Aimport javax.servlet.ServletResponse;%0Aimport javax.servlet.http.HttpServletResponse;%0A%0Apublic class RefreshAuthTokenFilter implements Filter %7B%0A%0A%09@Override%0A%09public void init(FilterConfig filterConfig) throws ServletException %7B%0A%09%7D%0A%0A%09@Override%0A%09public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException %7B%0A%09%09chain.doFilter(request, response);%0A%09%09AuthData auth = AuthFilter.getAuthData();%0A%09%09if (auth.getCurrentToken() != null) %7B%0A%09%09%09if (response instanceof HttpServletResponse) %7B%0A%09%09%09%09String newToken = AuthData.produce(auth.getUserId(), auth.getUserPassword(), auth.getSystemId());%0A%09%09%09%09((HttpServletResponse) response).setHeader(%22X-Authorization%22, newToken);%0A%09%09%09%7D%0A%09%09%7D%0A%09%7D%0A%0A%09@Override%0A%09public void destroy() %7B%0A%09%7D%0A%0A%7D%0A

Add RefreshAuthTokenFilter