GHSA-464C-974J-9XM6

GHSA-464C-974J-9XM6 is a low-severity security vulnerability in aws-cdk-lib (npm), affecting versions < 2.253.0. It is fixed in 2.253.0.

Does this CVE actually affect you?

Kodem shows which CVEs are reachable and running in your applications, so you fix what's exploitable, not just what's listed.

Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.

Runtime intelligence, not another scanner.

Summary

AWS CDK CodeBuild S3 Log Encryption Boolean Inversion

The AWS Cloud Development Kit (AWS CDK) is an open-source software development framework for defining cloud infrastructure in code and provisioning it through AWS CloudFormation. We identified an issue in which explicitly setting encrypted: true on the S3LoggingOptions property of an AWS CodeBuild project construct produces the opposite of the intended behavior, disabling encryption on CodeBuild build logs stored in S3.

Workarounds

Users who are unable to immediately upgrade to version 2.253.0 should omit the encrypted property from their S3LoggingOptions configuration entirely. When the property is omitted, the value is not passed to CloudFormation, and CodeBuild applies its default behavior of encrypting build logs using AWS managed keys.

References

If you have any questions or comments about this advisory, contact AWS Security via our issue reporting page [1] or directly via email to [email protected]. Please do not create a public GitHub issue.

[1] https://aws.amazon.com/security/vulnerability-reporting/

Acknowledgement

AWS thanks AISafe for collaborating on this issue through the coordinated disclosure process.

Impact

The S3LoggingOptions.encrypted property in the aws-codebuild module uses positive polarity (true = encryption ON), but is mapped directly to the CloudFormation S3LogsConfig.EncryptionDisabled field, which uses negative polarity (true = encryption OFF). Because the value is not negated before being passed to CloudFormation, any explicit assignment produces inverted behavior:

  • Setting encrypted: true (intending encryption ON) causes CloudFormation to receive EncryptionDisabled: true, disabling encryption.

  • Setting encrypted: false (intending encryption OFF) causes CloudFormation to receive EncryptionDisabled: false, enabling encryption.

Users who omit the property entirely are not affected, as undefined passes through to CloudFormation, which defaults to encryption enabled.

Users affected by this issue could have CodeBuild S3 build logs stored using SSE-S3 (Amazon S3-managed keys, AES-256) rather than the AWS managed keys that CodeBuild applies by default. Since January 5, 2023, Amazon S3 automatically encrypts all new object uploads with SSE-S3, so logs written after that date remain encrypted at rest. However, logs written prior to that date to buckets that did not have default encryption configured at the time are potentially not encrypted at rest.

Impacted versions: >= 1.75.0 and <= 2.252.0

GHSA-464C-974J-9XM6 has a CVSS score of 3.3 (Low). The vector is requires local access, no privileges required, and user interaction required. A CVSS score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether this affects your application depends on whether the vulnerable code is present and reachable in your environment. A fixed version is available (2.253.0); upgrading removes the vulnerable code path.

Affected versions

aws-cdk-lib (< 2.253.0) Amazon.CDK.Lib (< 2.253.0) software.amazon.awscdk:aws-cdk-lib (< 2.253.0) github.com/aws/aws-cdk-go/awscdk/v2 (< 2.253.0) @aws-cdk/aws-codebuild (>= 1.75.0, <= 1.204.0) Amazon.CDK.AWS.CodeBuild (>= 1.75.0, <= 1.204.0) software.amazon.awscdk:codebuild (>= 1.75.0, <= 1.204.0) github.com/aws/aws-cdk-go/awscdk (>= 1.175.0-devpreview, <= 1.204.0-devpreview) aws-cdk-lib (< 2.253.0) aws-cdk.aws-codebuild (>= 1.75.0, <= 1.204.0)

Security releases

aws-cdk-lib → 2.253.0 (npm) Amazon.CDK.Lib → 2.253.0 (nuget) software.amazon.awscdk:aws-cdk-lib → 2.253.0 (maven) github.com/aws/aws-cdk-go/awscdk/v2 → 2.253.0 (go) aws-cdk-lib → 2.253.0 (pip)

Kodem intelligence

Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.

Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.

Already deployed Kodem?

See it in your environmentNew to Kodem? Get a demo →

Remediation advice

This issue has been addressed in aws-cdk-lib version 2.253.0. Upgrade to the latest version and ensure any forked or derivative code is patched to incorporate the new fixes.

Frequently Asked Questions

  1. What is GHSA-464C-974J-9XM6? GHSA-464C-974J-9XM6 is a low-severity security vulnerability in aws-cdk-lib (npm), affecting versions < 2.253.0. It is fixed in 2.253.0.
  2. How severe is GHSA-464C-974J-9XM6? GHSA-464C-974J-9XM6 has a CVSS score of 3.3 (Low). This score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether it represents real risk in your environment depends on whether the vulnerable code is present and reachable.
  3. Which packages are affected by GHSA-464C-974J-9XM6?
    • aws-cdk-lib (npm) (versions < 2.253.0)
    • Amazon.CDK.Lib (nuget) (versions < 2.253.0)
    • software.amazon.awscdk:aws-cdk-lib (maven) (versions < 2.253.0)
    • github.com/aws/aws-cdk-go/awscdk/v2 (go) (versions < 2.253.0)
    • @aws-cdk/aws-codebuild (npm) (versions >= 1.75.0, <= 1.204.0)
    • Amazon.CDK.AWS.CodeBuild (nuget) (versions >= 1.75.0, <= 1.204.0)
    • software.amazon.awscdk:codebuild (maven) (versions >= 1.75.0, <= 1.204.0)
    • github.com/aws/aws-cdk-go/awscdk (go) (versions >= 1.175.0-devpreview, <= 1.204.0-devpreview)
    • aws-cdk.aws-codebuild (pip) (versions >= 1.75.0, <= 1.204.0)
  4. Is there a fix for GHSA-464C-974J-9XM6? Yes. GHSA-464C-974J-9XM6 is fixed in 2.253.0. Upgrade to this version or later.
  5. Is GHSA-464C-974J-9XM6 exploitable, and should I be worried? Whether GHSA-464C-974J-9XM6 is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
  6. What actually determines whether GHSA-464C-974J-9XM6 is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
  7. How do I fix GHSA-464C-974J-9XM6?
    • Upgrade aws-cdk-lib to 2.253.0 or later
    • Upgrade Amazon.CDK.Lib to 2.253.0 or later
    • Upgrade software.amazon.awscdk:aws-cdk-lib to 2.253.0 or later
    • Upgrade github.com/aws/aws-cdk-go/awscdk/v2 to 2.253.0 or later
    • Upgrade aws-cdk-lib to 2.253.0 or later

Other vulnerabilities in aws-cdk-lib

Stop the waste.
Protect your environment with Kodem.