CVE-2026-8596: Sagemaker Cleartext Storage Of HMAC Signing Vulnerability

HIGH
Advisory Identifier: GHSA-7hh5-prp2-mfh5
CVSS 7.2
CWE-312
Published
Advisory Summary

CVE-2026-8596 is a HIGH (CVSS 7.2) cleartext storage of hmac signing vulnerability (CWE-312: Cleartext Storage of Sensitive Information) affecting Sagemaker libraries in the PyPI ecosystem. The issue involves cleartext storage of hmac signing key in amazon sagemaker python sdk modelbuilder/serve path. Remediation is available by upgrading affected packages to version 2.257.2, 3.8.0.

CVE-2026-8596 at a Glance

CVE Identifier CVE-2026-8596
GHSA Identifier GHSA-7hh5-prp2-mfh5
Severity HIGH
CVSS v3.1 Base Score 7.2
CWE Classification CWE-312: Cleartext Storage of Sensitive Information
Affected Product Sagemaker
Package Ecosystem PyPI
Published Date
Last Updated

Security Impact

CVSS: 7.2

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

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

How to Fix CVE-2026-8596

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

sagemaker fixed: 2.257.2
pip install sagemaker>=2.257.2
sagemaker fixed: 3.8.0
pip install sagemaker>=3.8.0
Verify Direct and Transitive Dependencies

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

pip show sagemaker

How to Check if You Are Affected

To determine whether your Python environment is affected by CVE-2026-8596, inspect your installed packages using pip:

pip show sagemaker

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

Note: The pip show sagemaker command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-312: Cleartext Storage of Sensitive Information, where the product stores sensitive information in cleartext within a resource that might be accessible to another control sphere. In Sagemaker, 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 Amazon SageMaker Python SDK is an open-source library for training and deploying machine learning models on Amazon SageMaker. An issue exists where, under certain circumstances, the ModelBuilder/Serve component stores an HMAC signing key in cleartext as a container environment variable, which is returned in plaintext by SageMaker describe APIs. ## Impact When using ModelBuilder to build and deploy models with affected model servers (TorchServe, Multi-Model Server, TensorFlow Serving, SMD, or Triton), the SDK generates an HMAC secret key for model artifact integrity verification and stores it as the SAGEMAKER_SERVE_SECRET_KEY environment variable in the SageMaker model container configuration. This environment variable is returned in plaintext by the DescribeModel, DescribeEndpointConfig, and DescribeModelPackage APIs. A remote authenticated actor with permissions to call these describe APIs and S3 write access to the model artifact path could extract the key, forge valid integrity signatures for specially crafted model artifacts, and achieve code execution in inference containers with the SageMaker execution role's IAM permissions. **Impacted versions:** >= v2.199.0 AND <= v2.257.1, >= v3.0.0 AND <= v3.7.1 ## Patches This issue has been addressed in Amazon SageMaker Python SDK v2.257.2 and v3.8.0. AWS recommend upgrading to the latest version and rebuilding any models previously created with ModelBuilder using the updated SDK. Models created with affected versions may still have the HMAC key stored in their container environment variables until they are rebuilt with the patched SDK. Ensure any forked or derivative code is patched to incorporate the new fixes. ## Workarounds If upgrading is not immediately possible, users can manually remove the SAGEMAKER_SERVE_SECRET_KEY environment variable from existing SageMaker models by recreating the model without this variable in the container environment configuration. ## References If there any questions or comments about this advisory, contact AWS Security via the [vulnerability reporting page](https://aws.amazon.com/security/vulnerability-reporting) or directly via email to [aws-security@amazon.com](mailto:aws-security@amazon.com). Please do not create a public GitHub issue.

CVE-2026-8596 Affected Sagemaker Versions

2 component(s)
Fixed Versions:
2.257.23.8.0
Product / Package Ecosystem Affected Versions Fixed Version
sagemaker
PyPI
≥ 2.199.0
< 2.257.2
2.257.2
sagemaker
PyPI
≥ 3.0.0
< 3.8.0
3.8.0

References

Frequently Asked Questions

What is CVE-2026-8596?
CVE-2026-8596 is a security vulnerability in Sagemaker involving Cleartext storage of HMAC signing key in Amazon SageMaker Python SDK ModelBuilder/Serve path under CWE-312: Cleartext Storage of Sensitive Information.
Which Sagemaker versions are affected?
Affected versions include releases prior to 2.257.2, 3.8.0 across affected packages: sagemaker.
What version fixes CVE-2026-8596?
Upgrading to 2.257.2, 3.8.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is sagemaker affected?
Yes, sagemaker is affected in releases prior to 2.257.2, 3.8.0. Upgrade your dependency to 2.257.2, 3.8.0 or later.
What is the CVSS score of CVE-2026-8596?
CVE-2026-8596 has a CVSS v3.1 base score of 7.2 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H.
What CWE is associated with CVE-2026-8596?
CVE-2026-8596 is classified under CWE-312: Cleartext Storage of Sensitive Information (The product stores sensitive information in cleartext within a resource that might be accessible to another control sphere.).
How can I check PyPI dependencies for CVE-2026-8596?
Run the dependency tree command: 'pip show sagemaker'. 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-7hh5-prp2-mfh5",
  "modified" : "2026-05-21T17:42:40Z",
  "published" : "2026-05-21T17:42:40Z",
  "aliases" : [ "CVE-2026-8596" ],
  "summary" : "Cleartext storage of HMAC signing key in Amazon SageMaker Python SDK ModelBuilder/Serve path",
  "details" : "## Summary\nAmazon SageMaker Python SDK is an open-source library for training and deploying machine learning models on Amazon SageMaker. An issue exists where, under certain circumstances, the ModelBuilder/Serve component stores an HMAC signing key in cleartext as a container environment variable, which is returned in plaintext by SageMaker describe APIs.\n\n## Impact\nWhen using ModelBuilder to build and deploy models with affected model servers (TorchServe, Multi-Model Server, TensorFlow Serving, SMD, or Triton), the SDK generates an HMAC secret key for model artifact integrity verification and stores it as the SAGEMAKER_SERVE_SECRET_KEY environment variable in the SageMaker model container configuration. This environment variable is returned in plaintext by the DescribeModel, DescribeEndpointConfig, and DescribeModelPackage APIs. A remote authenticated actor with permissions to call these describe APIs and S3 write access to the model artifact path could extract the key, forge valid integrity signatures for specially crafted model artifacts, and achieve code execution in inference containers with the SageMaker execution role's IAM permissions.\n\n**Impacted versions:** >= v2.199.0 AND <= v2.257.1, >= v3.0.0 AND <= v3.7.1\n\n## Patches\nThis issue has been addressed in Amazon SageMaker Python SDK v2.257.2 and v3.8.0. AWS recommend upgrading to the latest version and rebuilding any models previously created with ModelBuilder using the updated SDK. Models created with affected versions may still have the HMAC key stored in their container environment variables until they are rebuilt with the patched SDK. Ensure any forked or derivative code is patched to incorporate the new fixes.\n\n## Workarounds\nIf upgrading is not immediately possible, users can manually remove the SAGEMAKER_SERVE_SECRET_KEY environment variable from existing SageMaker models by recreating the model without this variable in the container environment configuration.\n\n## References\nIf there any questions or comments about this advisory, contact AWS Security via the [vulnerability reporting page](https://aws.amazon.com/security/vulnerability-reporting) or directly via email to [aws-security@amazon.com](mailto:aws-security@amazon.com). Please do not create a public GitHub issue.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H"
  }, {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:H/VI:N/VA:N/SC:H/SI:H/SA:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "sagemaker"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.199.0"
      }, {
        "fixed" : "2.257.2"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 2.257.1"
    }
  }, {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "sagemaker"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "3.0.0"
      }, {
        "fixed" : "3.8.0"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 3.7.1"
    }
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/aws/sagemaker-python-sdk/security/advisories/GHSA-7hh5-prp2-mfh5"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-8596"
  }, {
    "type" : "WEB",
    "url" : "https://aws.amazon.com/security/security-bulletins/2026-031-aws"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/aws/sagemaker-python-sdk"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/aws/sagemaker-python-sdk/releases/tag/v2.257.2"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/aws/sagemaker-python-sdk/releases/tag/v3.8.0"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-312" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-05-21T17:42:40Z",
    "nvd_published_at" : "2026-05-14T20:17:21Z"
  }
}