CVE-2024-35199
TorchServe vulnerability analysis and mitigation

Overview

TorchServe, a flexible tool for serving and scaling PyTorch models in production, was found to have a security vulnerability (CVE-2024-35199) where its two gRPC ports (7070 and 7071) were not bound to localhost by default. When TorchServe is launched, these interfaces are bound to all interfaces, potentially exposing them to unauthorized access. The vulnerability affects versions 0.3.0 to 0.10.0, though customers using PyTorch inference Deep Learning Containers (DLC) through Amazon SageMaker and EKS are not affected (GitHub Advisory, AWS Bulletin).

Technical details

The vulnerability stems from the default configuration of TorchServe's gRPC ports 7070 and 7071, which bind to all network interfaces (0.0.0.0) instead of being restricted to localhost (127.0.0.1). This configuration issue has been assigned a CVSS v3.1 base score of 8.2 (HIGH), with a vector string of CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:H, indicating network-level attack vector, low attack complexity, and no required privileges or user interaction (GitHub Advisory).

Impact

The exposure of gRPC ports to all interfaces could potentially allow unauthorized access to the TorchServe instance from any network interface, rather than restricting access to only the local machine. This could lead to unauthorized access to model serving capabilities and potential exploitation of the service (GitHub Advisory).

Mitigation and workarounds

The vulnerability has been fixed in TorchServe version 0.11.0, which now binds the gRPC ports to localhost by default. For Docker deployments, the gRPC address needs to be explicitly configured to 0.0.0.0 similar to HTTP management and inference addresses. Users are advised to upgrade to version 0.11.0 or later to address this security issue (GitHub PR, GitHub Release).

Additional resources


SourceThis report was generated using AI

Related TorchServe vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

GHSA-4mqg-h5jf-j9m7CRITICAL9.9
  • TorchServeTorchServe
  • torchserve
NoYesOct 02, 2023
CVE-2024-35198CRITICAL9.8
  • TorchServeTorchServe
  • torchserve
NoYesJul 19, 2024
CVE-2024-35199HIGH8.2
  • TorchServeTorchServe
  • torchserve
NoYesJul 19, 2024
CVE-2024-6577MEDIUM6.3
  • TorchServeTorchServe
  • torchserve
NoNoMar 20, 2025
CVE-2023-48299MEDIUM5.3
  • TorchServeTorchServe
  • torchserve
NoYesNov 21, 2023

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management