Skip to content
Heist/ feed
Back to feed
Medium

percent-encoded path separator in URL host

Type: advisorySources: OSV

The curl URL parser wrongly accepts percent-encoded URL separators like '/' when decoding the hostname part of a URL, making it a *different* URL using the wrong hostname when it is later retrieved. For example, a URL like `http://example.com%2F10.0.0.1/`, would be allowed by the parser and get transposed into `http://example.com/10.0.0.1/`. This flaw can be used to circumvent filters, checks and more.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2022-27780
Confirmed fixed CVEs
Not specified
Updated in this feed
1 Nov 2026, 09:37 UTC · Revision 1

Source evidence

percent-encoded path separator in URL host

core-osv · Original source

Published 11 May 2022, 08:00 UTC

The curl URL parser wrongly accepts percent-encoded URL separators like '/' when decoding the hostname part of a URL, making it a *different* URL using the wrong hostname when it is later retrieved. For example, a URL like `http://example.com%2F10.0.0.1/`, would be allowed by the parser and get transposed into `http://example.com/10.0.0.1/`. This flaw can be used to circumvent filters, checks and more.

osv:CURL-CVE-2022-27780
Complete source record
{
  "id": "720a041662fc1a3ed8239f9465b2450526759f4f3637edf74286a8d45b4c9877",
  "url": "https://osv.dev/vulnerability/CURL-CVE-2022-27780",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "percent-encoded path separator in URL host",
    "summary": "The curl URL parser wrongly accepts percent-encoded URL separators like '/' when decoding the hostname part of a URL, making it a *different* URL using the wrong hostname when it is later retrieved. For example, a URL like `http://example.com%2F10.0.0.1/`, would be allowed by the parser and get transposed into `http://example.com/10.0.0.1/`. This flaw can be used to circumvent filters, checks and more.",
    "evidence": "osv:CURL-CVE-2022-27780",
    "products": [],
    "severity": "medium",
    "structured": {
      "id": "CURL-CVE-2022-27780",
      "aliases": [
        "CURL-CVE-2022-27780",
        "CVE-2022-27780"
      ],
      "affected": [
        {
          "ranges": [
            {
              "type": "SEMVER",
              "events": [
                {
                  "introduced": "7.80.0"
                },
                {
                  "fixed": "7.83.1"
                }
              ]
            },
            {
              "repo": "https://github.com/curl/curl.git",
              "type": "GIT",
              "events": [
                {
                  "introduced": "9a8564a920188e49d5bd8c1c8573ddef97f6e03a"
                },
                {
                  "fixed": "914aaab9153764ef8fa4178215b8ad89d3ac263a"
                }
              ]
            }
          ],
          "versions": [
            "7.83.0",
            "7.82.0",
            "7.81.0",
            "7.80.0",
            "curl-7_83_0",
            "curl-7_82_0",
            "curl-7_81_0",
            "curl-7_80_0"
          ],
          "database_specific": {
            "source": "https://curl.se/docs/CURL-CVE-2022-27780.json",
            "vanir_signatures": [
              {
                "id": "CURL-CVE-2022-27780-5e408e0f",
                "digest": {
                  "length": 1399,
                  "function_hash": "175578244964680735291736576270402210988"
                },
                "source": "https://github.com/curl/curl.git/commit/914aaab9153764ef8fa4178215b8ad89d3ac263a",
                "target": {
                  "file": "lib/urlapi.c",
                  "function": "hostname_check"
                },
                "deprecated": false,
                "signature_type": "Function",
                "signature_version": "v1"
              },
              {
                "id": "CURL-CVE-2022-27780-fb7e3e79",
                "digest": {
                  "threshold": 0.9,
                  "line_hashes": [
                    "199957627763592549612385795254149834550",
                    "151428187081067779662697927472516771049",
                    "119160317506403307842112826299814095034",
                    "25289416254833179104566548130852379552"
                  ]
                },
                "source": "https://github.com/curl/curl.git/commit/914aaab9153764ef8fa4178215b8ad89d3ac263a",
                "target": {
                  "file": "lib/urlapi.c"
                },
                "deprecated": false,
                "signature_type": "Line",
                "signature_version": "v1"
              }
            ],
            "vanir_signatures_modified": "2026-10-25T01:04:42Z"
          }
        }
      ],
      "modified": "2026-10-25T01:04:42.522288749Z",
      "provider": "osv",
      "references": [],
      "provider_metadata": {
        "CWE": {
          "id": "CWE-177",
          "desc": "Improper Handling of URL Encoding"
        },
        "URL": "https://curl.se/docs/CVE-2022-27780.json",
        "www": "https://curl.se/docs/CVE-2022-27780.html",
        "award": {
          "amount": "2400",
          "currency": "USD"
        },
        "issue": "https://hackerone.com/reports/1553841",
        "affects": "both",
        "package": "curl",
        "severity": "Medium",
        "last_affected": "7.83.0"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2022-27780",
        "evidence": "/aliases"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/database_specific/severity"
  },
  "source_id": "core-osv",
  "document_id": 444278,
  "published_at": "2022-05-11T08:00:00+00:00"
}