Uploaded image for project: 'Maven SCM'
  1. Maven SCM
  2. SCM-907

GitScmProviderRepository#parseUrl() does not comply with RFC 3986 and RFC 8089

    XMLWordPrintableJSON

Details

    Description

      This issue was been found on one of Jenkins slaves. Consider the following path: F:\jenkins\jenkins-slave\workspace\maven-box_maven-scm_SCM-906-3AXCXWOA5KAAL37TCEKGJUQCHVU3HMOGCVV63JP76C24C3X6DHOA@2\m\maven-scm-providers\maven-scm-providers-git\maven-scm-provider-gitexe\target. THe aforementioned class outputs:

      file:///F:/jenkins/jenkins-slave/workspace/maven-box_maven-scm_SCM-906-3AXCXWOA5KAAL37TCEKGJUQCHVU3HMOGCVV63JP76C24C3X6DHOA@2/m/maven-scm-providers/maven-scm-providers-git/maven-scm-provider-gitexe/target
      file://2/m/maven-scm-providers/maven-scm-providers-git/maven-scm-provider-gitexe/target
      

      The parse logic incorrectly assumes that the last @ is for the user info. According to RFC 8089 a file URL may contain this information, but our parser would still fail becuase it uses lastIndexOf. It must stop searching to the first slash.

      Attachments

        There are no Sub-Tasks for this issue.

        Activity

          People

            Unassigned Unassigned
            michael-o Michael Osipov
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: