I think there is a synchronization issue in the proxy portlet.
 
In the ProxyPortlet.java, in the render method, the url generator
is well synchronized :
 
synchronized (urlGenLock) {
                // update url generator
                URLGenerator urlGenerator =
                        URLGeneratorImpl.getInstance(renderResponse,
                        getPortletConfig());
                URLTemplateComposer templateComposer =
                        consumerEnv.getTemplateComposer();
                if(templateComposer != null) {
                    templateComposer.setURLGenerator(urlGenerator);
                }
               
                consumerEnv.getURLRewriter().setURLGenerator(urlGenerator);
            }
 
It is needed because the url generator needs the current renderResponse.
 
But i think it is not enough.
 
The URLGenerator( the same instance ) is then used after getting the markup ( in the
PortletDriverImpl.java, method getMarkup() ) :
 
URLRewriter urlRewriter = consumerEnv.getURLRewriter();
String rewrittenMarkup = urlRewriter.rewriteURLs(response.getMarkupContext()
                  .getMarkupString());
 
 
So, a user A can modify the URLGenerator with it response, just before
a user B rewrites the URL in the markup.
 
Am i wrong ?
 
 
 


Laurent MICHENAUD
Intégrateur Web
[EMAIL PROTECTED]

 

Reply via email to