The PyTorch model server contains multiple vulnerabilities that can be chained together to permit an unauthenticated remote attacker arbitrary Java code execution. The first vulnerability is that the management interface is bound to all IP addresses and not just the loop back interface as the documentation suggests. The second vulnerability (CVE-2023-43654) allows attackers with access to the management interface to register MAR model files from arbitrary servers. The third vulnerability is that when an MAR file is loaded, it can contain a YAML configuration file that when deserialized by snakeyaml, can lead to loading an arbitrary Java class.
Exploit database
Vulnerability
CVE-2022-1471
Vulnerability details
- Score
- 9.8
- Severity
- critical
CVSS 3.1 · NVD
Vector string
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:HDescription
SnakeYaml's Constructor() class does not restrict types which can be instantiated during deserialization. Deserializing yaml content provided by an attacker can lead to remote code execution. We recommend using SnakeYaml's SafeConsturctor when parsing untrusted content to restrict deserialization. We recommend upgrading to version 2.0 and beyond.
NVDExploit source choices
6 sourcesPyTorch Model Server Registration and Deserialization RCE
2023-10-03torchserver_cve_2023_43654.rb
cloudspannerecosystem/liquibase-spanner
cloudspannerecosystem/liquibase-spanner source repository
2020-08-04542 files · 28 stars
apimastery/snakeyaml-ext
A *copy* (not a mirror) of https://bitbucket.org/asomov/snakeyaml/ with extensions
2020-05-271,321 files · 0 stars
aykhan019/cve-2022-1471-jira-lab
aykhan019/cve-2022-1471-jira-lab source repository
2026-08-1512 files · 0 stars
bw0101/bee004
Spring Boot 3 and java 17 Application
2023-08-1214 files · 0 stars
codescope-dev/duckyaml
codescope-dev/duckyaml source repository
2023-01-0713 files · 0 stars