Uploaded image for project: 'Artifactory Binary Repository'
  1. Artifactory Binary Repository
  2. RTFACT-17178

VGO - Case-encoding of module paths produces 404s

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 6.2.0
    • Component/s: None
    • Labels:
      None

      Description

      vgo introduced the following change:

      from vgo [documentation|https://github.com/golang/vgo/blame/20939850793927db78c179dcfcd5d4d6f44f2c01/vendor/cmd/go/internal/module/module.go#L368-L461

      https://github.com/jfrog/jfrog-cli-go/issues/194
       
      In general we cannot rely on file systems to be case-sensitive, nor can we rely on web servers, since they read from file systems. That is, we cannot rely on the file system to keep rsc.io/QUOTE and rsc.io/quote separate. Instead, we must never require two different casings of a file path. Because we want the download cache to match the proxy protocol, and because we want the proxy protocol to be possible to serve from a tree of static files (which might be stored on a case-insensitive file system), the proxy protocol must never require two different casings of a URL path either.
       
      Their solution is:
      The safe encoding is this:
       replace every uppercase letter with an exclamation mark followed by the letter's lowercase equivalent.
      for example:
      github.com/Azure/azure-sdk-for-go -> github.com/!azure/azure-sdk-for-go.
      github.com/GoogleCloudPlatform/cloudsql-proxy -> github.com/!google!cloud!platform/cloudsql-proxy
      github.com/Sirupsen/logrus -> github.com/!sirupsen/logrus.

        Attachments

          Activity

            People

            • Assignee:
              tamirh Tamir Hadad
              Reporter:
              lizad Liza Dashevski (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: