AnsweredAssumed Answered

dot symbol causes site roll failure.  Labs 3 Stable

Question asked by ofrxnz on Jan 30, 2009
Latest reply on Feb 5, 2009 by ofrxnz
In Labs 3 Stable, when i have a user with the user name "firstname.lastname" various roll based functions fail. 

So far i have tracked all the issues i have found back to the membership.get.js script in alfresco proper and  the json data returned it returns.
I am going to play with it bypassing url.extension.split and see if i cant sterilize the . with a /. or something when i get a chance. 
when this script is called without a user name /alfresco/service/api/sites/{shortname}/memberships/ it works great just not when called as /alfresco/service/api/sites/{shortname}/memberships/{username} and user has a dot in their username

So, user Firstname.lastname creates site test.
This user has roll of manager. 

The first place i noticed this was the permission bar that, for a manager normally contains "Invite" "Leave Edit" "Site Details" "Customize Site" "Customize Dashboard"

When a user has a dot in their username (firstname.last name) they only have the "join" even if they are a manager

when i add administrator to the manager group through alfresco user "administrator" has the full bar

The second place i noticed this was on the Site-Members page.  User "administrator" worked fine user "firstname.lastname" received the following error

Web Script Status 500 - Internal Error

The Web Script /share/service/components/site-members has responded with a status of 500 - Internal Error.

500 Description: An error inside the HTTP server which prevented it from fulfilling the request.
 
Message: Failed to load script '/org/alfresco/components/site-members/site-members.get.js (in classpath store file:C:/Alfresco/tomcat/webapps/share/WEB-INF/classes/alfresco/site-webscripts)': TypeError: Cannot parse XML: Scanner State 24 not Recognized (file:C:/Alfresco/tomcat/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/site-members/site-members.get.js#6(eval)#1)
  
Exception: org.mozilla.javascript.EcmaError - TypeError: Cannot parse XML: Scanner State 24 not Recognized (file:C:/Alfresco/tomcat/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/site-members/site-members.get.js#6(eval)#1)
  
org.mozilla.javascript.ScriptRuntime.constructError(ScriptRuntime.java:3350)
org.mozilla.javascript.ScriptRuntime.constructError(ScriptRuntime.java:3340)
org.mozilla.javascript.ScriptRuntime.typeError(ScriptRuntime.java:3356)
org.mozilla.javascript.xmlimpl.XMLLibImpl.parse(XMLLibImpl.java:411)
org.mozilla.javascript.xmlimpl.XMLLibImpl.ecmaToXml(XMLLibImpl.java:433)
org.mozilla.javascript.xmlimpl.XMLObjectImpl.ecmaToXml(XMLObjectImpl.java:779)
org.mozilla.javascript.xmlimpl.XML.jsConstructor(XML.java:250)
org.mozilla.javascript.xmlimpl.XMLObjectImpl.execIdCall(XMLObjectImpl.java:570)
org.mozilla.javascript.IdFunctionObject.call(IdFunctionObject.java:127)
org.mozilla.javascript.BaseFunction.construct(BaseFunction.java:313)
org.mozilla.javascript.Interpreter.interpretLoop(Interpreter.java:3281)
org.mozilla.javascript.Interpreter.interpret(Interpreter.java:2394)
org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:162)
org.mozilla.javascript.ScriptRuntime.evalSpecial(ScriptRuntime.java:2280)
org.mozilla.javascript.ScriptRuntime.callSpecial(ScriptRuntime.java:2143)
org.mozilla.javascript.optimizer.OptRuntime.callSpecial(OptRuntime.java:165)
org.mozilla.javascript.gen.c29._c0(file:C:/Alfresco/tomcat/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/site-members/site-members.get.js:6)
org.mozilla.javascript.gen.c29.call(file:C:/Alfresco/tomcat/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/site-members/site-members.get.js)
org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:393)
org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:2834)
org.mozilla.javascript.gen.c29.call(file:C:/Alfresco/tomcat/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/site-members/site-members.get.js)
org.mozilla.javascript.gen.c29.exec(file:C:/Alfresco/tomcat/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/site-members/site-members.get.js)
org.alfresco.web.scripts.PresentationScriptProcessor.executeScriptImpl(PresentationScriptProcessor.java:256)
org.alfresco.web.scripts.PresentationScriptProcessor.executeScript(PresentationScriptProcessor.java:148)
org.alfresco.web.scripts.AbstractWebScript.executeScript(AbstractWebScript.java:800)
org.alfresco.web.scripts.DeclarativeWebScript.execute(DeclarativeWebScript.java:90)
org.alfresco.web.scripts.PresentationContainer.executeScript(PresentationContainer.java:60)
org.alfresco.web.scripts.LocalWebScriptRuntimeContainer.executeScript(LocalWebScriptRuntimeContainer.java:169)
org.alfresco.web.scripts.AbstractRuntime.executeScript(AbstractRuntime.java:261)
org.alfresco.web.scripts.AbstractRuntime.executeScript(AbstractRuntime.java:139)
org.alfresco.web.scripts.WebScriptProcessor.executeBody(WebScriptProcessor.java:329)
org.alfresco.web.framework.render.AbstractProcessor.execute(AbstractProcessor.java:85)
org.alfresco.web.framework.render.RenderHelper.processComponent(RenderHelper.java:332)
org.alfresco.web.framework.render.RenderUtil.renderRawComponent(RenderUtil.java:451)
org.alfresco.web.framework.render.RenderUtil.renderRawComponent(RenderUtil.java:434)
org.alfresco.web.framework.render.bean.ComponentRenderer.body(ComponentRenderer.java:135)
org.alfresco.web.framework.render.RenderUtil.renderRegionComponents(RenderUtil.java:328)
org.alfresco.web.site.taglib.RegionIncludeTag.doStartTag(RegionIncludeTag.java:43)
org.alfresco.tools.TagUtil.execute(TagUtil.java:142)
org.alfresco.tools.TagUtil.execute(TagUtil.java:78)
org.alfresco.web.scripts.FreemarkerTagSupportDirective.executeTag(FreemarkerTagSupportDirective.java:89)
org.alfresco.web.scripts.GenericFreemarkerTagDirective.execute(GenericFreemarkerTagDirective.java:127)
freemarker.core.Environment.visit(Environment.java:261)
freemarker.core.UnifiedCall.accept(UnifiedCall.java:126)
freemarker.core.Environment.visit(Environment.java:208)
freemarker.core.MixedContent.accept(MixedContent.java:92)
freemarker.core.Environment.visit(Environment.java:208)
freemarker.core.Environment.process(Environment.java:188)
freemarker.template.Template.process(Template.java:237)
org.alfresco.web.scripts.PresentationTemplateProcessor.process(PresentationTemplateProcessor.java:146)
org.alfresco.web.scripts.FreemarkerProcessor.executeBody(FreemarkerProcessor.java:240)
org.alfresco.web.framework.render.AbstractProcessor.execute(AbstractProcessor.java:85)
org.alfresco.web.framework.render.RenderHelper.processRenderable(RenderHelper.java:276)
org.alfresco.web.framework.render.bean.ChromeRenderer.body(ChromeRenderer.java:60)
org.alfresco.web.framework.render.AbstractRenderer.render(AbstractRenderer.java:105)
org.alfresco.web.framework.render.bean.RegionRenderer.body(RegionRenderer.java:134)
org.alfresco.web.framework.render.AbstractRenderer.render(AbstractRenderer.java:105)
org.alfresco.web.framework.render.RenderUtil.startRegionRenderer(RenderUtil.java:273)
org.alfresco.web.framework.render.RenderUtil.renderRegion(RenderUtil.java:213)
org.alfresco.web.framework.render.PresentationUtil.renderRegion(PresentationUtil.java:124)
org.alfresco.web.site.taglib.RegionTag.doStartTag(RegionTag.java:109)
org.alfresco.tools.TagUtil.execute(TagUtil.java:142)
org.alfresco.tools.TagUtil.execute(TagUtil.java:78)
org.alfresco.web.scripts.FreemarkerTagSupportDirective.executeTag(FreemarkerTagSupportDirective.java:89)
org.alfresco.web.scripts.RegionFreemarkerTagDirective.execute(RegionFreemarkerTagDirective.java:128)
freemarker.core.Environment.visit(Environment.java:261)
freemarker.core.UnifiedCall.accept(UnifiedCall.java:126)
freemarker.core.Environment.visit(Environment.java:208)
freemarker.core.MixedContent.accept(MixedContent.java:92)
freemarker.core.Environment.visit(Environment.java:208)
freemarker.core.Environment.visit(Environment.java:393)
freemarker.core.BodyInstruction.accept(BodyInstruction.java:93)
freemarker.core.Environment.visit(Environment.java:208)
freemarker.core.MixedContent.accept(MixedContent.java:92)
freemarker.core.Environment.visit(Environment.java:208)
freemarker.core.Macro$Context.runMacro(Macro.java:164)
freemarker.core.Environment.visit(Environment.java:601)
freemarker.core.UnifiedCall.accept(UnifiedCall.java:106)
freemarker.core.Environment.visit(Environment.java:208)
freemarker.core.MixedContent.accept(MixedContent.java:92)
freemarker.core.Environment.visit(Environment.java:208)
freemarker.core.Environment.process(Environment.java:188)
freemarker.template.Template.process(Template.java:237)
org.alfresco.web.scripts.PresentationTemplateProcessor.process(PresentationTemplateProcessor.java:146)
org.alfresco.web.scripts.FreemarkerProcessor.executeBody(FreemarkerProcessor.java:240)
org.alfresco.web.framework.render.AbstractProcessor.execute(AbstractProcessor.java:85)
org.alfresco.web.framework.render.RenderHelper.processTemplate(RenderHelper.java:376)
org.alfresco.web.framework.render.bean.TemplateInstanceRenderer.body(TemplateInstanceRenderer.java:135)
org.alfresco.web.framework.render.AbstractRenderer.render(AbstractRenderer.java:105)
org.alfresco.web.framework.render.bean.PageRenderer.body(PageRenderer.java:81)
org.alfresco.web.framework.render.AbstractRenderer.render(AbstractRenderer.java:105)
org.alfresco.web.framework.render.RenderUtil.startPageRenderer(RenderUtil.java:144)
org.alfresco.web.framework.render.RenderUtil.renderPage(RenderUtil.java:117)
org.alfresco.web.framework.render.PresentationUtil.renderPage(PresentationUtil.java:85)
org.alfresco.web.site.servlet.DispatcherServlet.dispatchPage(DispatcherServlet.java:459)
org.alfresco.web.site.servlet.DispatcherServlet.dispatch(DispatcherServlet.java:336)
org.alfresco.web.site.servlet.DispatcherServlet.service(DispatcherServlet.java:153)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845)
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
java.lang.Thread.run(Thread.java:619)
  
Exception: org.alfresco.web.scripts.WebScriptException - TypeError: Cannot parse XML: Scanner State 24 not Recognized (file:C:/Alfresco/tomcat/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/site-members/site-members.get.js#6(eval)#1)
  
org.alfresco.web.scripts.PresentationScriptProcessor.executeScriptImpl(PresentationScriptProcessor.java:261)
  
Exception: org.alfresco.web.scripts.WebScriptException - Failed to load script '/org/alfresco/components/site-members/site-members.get.js (in classpath store file:C:/Alfresco/tomcat/webapps/share/WEB-INF/classes/alfresco/site-webscripts)': TypeError: Cannot parse XML: Scanner State 24 not Recognized (file:C:/Alfresco/tomcat/webapps/share/WEB-INF/classes/alfresco/site-webscripts/org/alfresco/components/site-members/site-members.get.js#6(eval)#1)
  
org.alfresco.web.scripts.PresentationScriptProcessor.executeScript(PresentationScriptProcessor.java:152)
  
Server: Alfresco Labs v3.0.0 (Stable 1526) schema 1,002
Time: Jan 30, 2009 4:07:29 PM
  
Diagnostics: Inspect Web Script (org/alfresco/components/site-members/site-members.get)


aside from these two everything else appears to work beautifully.

Anyone have a work around?

Server:
Windows 2K3 R2
Labs 3 Stable full installer.
Auth: NTLM agains Active Directory without SSO

Outcomes