Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-62261

URL validation in RepositoryBrowser is too strict / *.corp URLs should be valid

    Details

    • Type: Bug
    • Status: Open (View Workflow)
    • Priority: Minor
    • Resolution: Unresolved
    • Component/s: git-plugin
    • Labels:
      None
    • Similar Issues:

      Description

      The URL validation in the the repository browser settings is too strict and it treats e.g *.corp domains as invalid.

      Steps to reproduce:

      1. Configure repository browser 'gittiles' for a job
      2. Enter https://somehost.myorg.corp/foo/bar as URL
      3. -> "Invalid URL"

      This is due to the way org.apache.commons.validator.routines.UrlValidator treats domain names and the fact that .corp, .home, and .mail domains are officially declared as "off limits" to be part of the global DNS system.

      In the light of arbitrary top-level domains these days it makes no sense anymore to have such strict domain validation.

      Also, local hostnames should be valid, too. Locally-hosted SCM instances is nothing unusual.

      For these reasons, UrlValidator.ALLOW_LOCAL_URLS should be used to relax host/domain name validation.

        Attachments

          Issue Links

            Activity

            There are no comments yet on this issue.

              People

              • Assignee:
                Unassigned
                Reporter:
                sratz Sebastian Ratz
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated: