GHSA-58QW-P7QM-5RVH
Vulnerability from github – Published: 2023-07-10 21:52 – Updated: 2024-09-10 17:16From the reporter
XmlParseris vulnerable to XML external entity (XXE) vulnerability. XmlParser is being used when parsing Jetty’s xml configuration files. An attacker might exploit this vulnerability in order to achieve SSRF or cause a denial of service. One possible scenario is importing a (remote) malicious WAR into a Jetty’s server, while the WAR includes a malicious web.xml.
Impact
There are no circumstances in a normally deployed Jetty server where potentially hostile XML is given to the XmlParser class without the attacker already having arbitrary access to the server. I.e. in order to exploit XmlParser the attacker would already have the ability to deploy and execute hostile code. Specifically, Jetty has no protection against malicious web application and potentially hostile web applications should only be run on an isolated virtualisation.
Thus this is not considered a vulnerability of the Jetty server itself, as any such usage of the jetty XmlParser is equally vulnerable as a direct usage of the JVM supplied SAX parser. No CVE will be allocated to this advisory.
However, any direct usage of the XmlParser class by an application may be vulnerable. The impact would greatly depend on how the application uses XmlParser, but it could be a denial of service due to large entity expansion, or possibly the revealing local files if the XML results are accessible remotely.
Patches
Ability to configure the SAXParserFactory to fit the needs of your particular XML parser implementation have been merged as part of PR #10067
Workarounds
Don't use XmlParser to parse data from users.
{
"affected": [
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 10.0.15"
},
"package": {
"ecosystem": "Maven",
"name": "org.eclipse.jetty:jetty-xml"
},
"ranges": [
{
"events": [
{
"introduced": "10.0.0-alpha0"
},
{
"fixed": "10.0.16"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 11.0.15"
},
"package": {
"ecosystem": "Maven",
"name": "org.eclipse.jetty:jetty-xml"
},
"ranges": [
{
"events": [
{
"introduced": "11.0.0-alpha0"
},
{
"fixed": "11.0.16"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 12.0.0.beta4"
},
"package": {
"ecosystem": "Maven",
"name": "org.eclipse.jetty:jetty-xml"
},
"ranges": [
{
"events": [
{
"introduced": "12.0.0.alpha0"
},
{
"fixed": "12.0.0"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 9.4.51"
},
"package": {
"ecosystem": "Maven",
"name": "org.eclipse.jetty:jetty-xml"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "9.4.52.v20230823"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [],
"database_specific": {
"cwe_ids": [
"CWE-611"
],
"github_reviewed": true,
"github_reviewed_at": "2023-07-10T21:52:39Z",
"nvd_published_at": null,
"severity": "LOW"
},
"details": "### From the reporter\n\n\u003e `XmlParser` is vulnerable to XML external entity (XXE) vulnerability.\n\u003e XmlParser is being used when parsing Jetty\u2019s xml configuration files. An attacker might exploit\n\u003e this vulnerability in order to achieve SSRF or cause a denial of service.\n\u003e One possible scenario is importing a (remote) malicious WAR into a Jetty\u2019s server, while the\n\u003e WAR includes a malicious web.xml.\n\n### Impact\nThere are no circumstances in a normally deployed Jetty server where potentially hostile XML is given to the XmlParser class without the attacker already having arbitrary access to the server. I.e. in order to exploit `XmlParser` the attacker would already have the ability to deploy and execute hostile code. Specifically, Jetty has no protection against malicious web application and potentially hostile web applications should only be run on an isolated virtualisation. \n\nThus this is not considered a vulnerability of the Jetty server itself, as any such usage of the jetty XmlParser is equally vulnerable as a direct usage of the JVM supplied SAX parser. No CVE will be allocated to this advisory.\n\nHowever, any direct usage of the `XmlParser` class by an application may be vulnerable. The impact would greatly depend on how the application uses `XmlParser`, but it could be a denial of service due to large entity expansion, or possibly the revealing local files if the XML results are accessible remotely.\n\n### Patches\nAbility to configure the SAXParserFactory to fit the needs of your particular XML parser implementation have been merged as part of PR #10067\n\n### Workarounds\nDon\u0027t use `XmlParser` to parse data from users.\n\n\n",
"id": "GHSA-58qw-p7qm-5rvh",
"modified": "2024-09-10T17:16:50Z",
"published": "2023-07-10T21:52:39Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/eclipse/jetty.project/security/advisories/GHSA-58qw-p7qm-5rvh"
},
{
"type": "WEB",
"url": "https://github.com/eclipse/jetty.project/pull/10067"
},
{
"type": "PACKAGE",
"url": "https://github.com/eclipse/jetty.project"
},
{
"type": "WEB",
"url": "https://github.com/eclipse/jetty.project/releases/tag/jetty-10.0.16"
},
{
"type": "WEB",
"url": "https://github.com/eclipse/jetty.project/releases/tag/jetty-11.0.16"
},
{
"type": "WEB",
"url": "https://github.com/eclipse/jetty.project/releases/tag/jetty-12.0.0"
},
{
"type": "WEB",
"url": "https://github.com/eclipse/jetty.project/releases/tag/jetty-9.4.52.v20230823"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:H/PR:H/UI:N/S:U/C:L/I:L/A:L",
"type": "CVSS_V3"
}
],
"summary": "Eclipse Jetty XmlParser allows arbitrary DOCTYPE declarations"
}
Sightings
| Author | Source | Type | Date |
|---|
Nomenclature
- Seen: The vulnerability was mentioned, discussed, or observed by the user.
- Confirmed: The vulnerability has been validated from an analyst's perspective.
- Published Proof of Concept: A public proof of concept is available for this vulnerability.
- Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
- Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
- Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
- Not confirmed: The user expressed doubt about the validity of the vulnerability.
- Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.