Uploaded image for project: 'Sling'
  1. Sling
  2. SLING-1726

Namespace mangling is broken for path segments with a leading underscore

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • JCR Resource 2.0.8
    • JCR
    • None

    Description

      Consider a node at

      /content/_test/jcr:content

      With namespace mangling, this node should be accessible with the URL path

      /content/_test/_jcr_content

      where the "jcr" prefix is converted to the correct namespace prefix "jcr:" but the prefixed underscore "_" of the "_test" node must be left unmodified.

      The regular expression to find and replace the namespace prefixes – "/([^_]+)" – is setup to match anything enclosed with "/" and "". Thus the test path would match "/test/" and fail to convert this (of course test/ is not a valid, registered namespace prefix). But subsequently the real prefix – "jcr" – is actually missed.

      The regular expression must be modified to not match any slash characters, thus "/([^_/]+)"

      Attachments

        Activity

          People

            fmeschbe Felix Meschberger
            fmeschbe Felix Meschberger
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: