GHSA-JC42-994R-VVWP

Vulnerability from github – Published: 2026-11-19 00:50 – Updated: 2026-11-19 00:50
VLAI
Summary
cassandra-jdbc-wrapper: Authentication Token Exposed in Logs
Details

Summary

The fix for AIKIDO-2024-10565 (plaintext password logging) introduced two redaction helpers — DriverUtil.toStringWithoutSensitiveValues() and DriverUtil.redactSensitiveValuesInJdbcUrl() — but both helpers only redact the "password" property/parameter (JdbcUrlUtil.TAG_PASSWORD). The equally sensitive "token" property (JdbcUrlUtil.TAG_TOKEN), used for DataStax Astra and other token-based Cassandra authentication, is completely unredacted by both helpers. Applications using token-based authentication with DEBUG logging enabled will therefore log the live authentication token in plaintext via SessionHolder's calls to these same two helpers — the exact same exposure pattern that the original fix was intended to prevent.

Details

File: src/main/java/com/ing/data/cassandra/jdbc/utils/DriverUtil.java

// toStringWithoutSensitiveValues (lines 341-347) -- only redacts "password"
public static String toStringWithoutSensitiveValues(final Properties properties) {
    final Properties withRedactedSensitiveValues = (Properties) properties.clone();
    if (withRedactedSensitiveValues.containsKey(TAG_PASSWORD)) {
        withRedactedSensitiveValues.setProperty(TAG_PASSWORD, "***");
    }
    return withRedactedSensitiveValues.toString();
}

// redactSensitiveValuesInJdbcUrl (lines 355-378) -- only redacts "password"
final String redactedQuery = Arrays.stream(...)
    .map(param -> {
        if (param.startsWith(TAG_PASSWORD + "=")) {
            return TAG_PASSWORD + "=***";
        }
        return param;     // <-- "token=..." passes through unmodified
    })
    ...

JdbcUrlUtil.java defines TAG_TOKEN = "token" (line 407) as a separate, distinct connection property used when connecting with DataStax Astra-style token-based authentication. Neither redaction helper checks for this key.

File: src/main/java/com/ing/data/cassandra/jdbc/SessionHolder.java

Both helpers are called on connection-level properties at DEBUG log level:

// Line 150 — logs all connection properties including "token" unredacted
log.debug("Final Properties to Connection: {}",
    toStringWithoutSensitiveValues(this.properties));

// Lines 173, 190 — logs JDBC URL including "?token=..." unredacted
final String jdbcUrl = redactSensitiveValuesInJdbcUrl(this.cacheKey.get(URL_KEY));
log.debug("Released last reference to {}, closing Session.", jdbcUrl);
log.debug("Acquired reference to {}, new count = {}.", jdbcUrl, ref + 1);

DEBUG logging is commonly enabled in production troubleshooting and staging environments, meaning the token is logged in plain text every time a connection is acquired or released in such environments.

PoC

Environment: JDK 17+, Maven 3.x

pom.xml dependency:

<dependency>
    <groupId>com.ing.data</groupId>
    <artifactId>cassandra-jdbc-wrapper</artifactId>
    <version>5.0.1</version>
</dependency>

Exploit.java:

import com.ing.data.cassandra.jdbc.utils.DriverUtil;
import java.util.Properties;

public class Exploit {
    public static void main(String[] args) throws Exception {
        String secretToken = "AstraCS:SUPER_SECRET_TOKEN_VALUE_1234567890";

        // Test 1: redactSensitiveValuesInJdbcUrl()
        String urlWithToken = "jdbc:cassandra://host:9042/ks?token=" + secretToken;
        String redacted = DriverUtil.redactSensitiveValuesInJdbcUrl(urlWithToken);
        System.out.println("Token in 'redacted' URL: " + redacted.contains(secretToken)); // true

        // Test 2: toStringWithoutSensitiveValues()
        Properties props = new Properties();
        props.setProperty("token", secretToken);
        String redactedProps = DriverUtil.toStringWithoutSensitiveValues(props);
        System.out.println("Token in 'redacted' props: " + redactedProps.contains(secretToken)); // true

        // Control: password IS correctly redacted
        Properties propsWithPassword = new Properties();
        propsWithPassword.setProperty("password", "secret");
        System.out.println("Password redacted: " +
            !DriverUtil.toStringWithoutSensitiveValues(propsWithPassword).contains("secret")); // true
    }
}

Result (confirmed, 3/3 reproductions on cassandra-jdbc-wrapper 5.0.1, the latest release):

Token in 'redacted' URL:   true   <- token leaks through the URL redactor
Token in 'redacted' props: true   <- token leaks through the property redactor
Password redacted:         true   <- password IS correctly masked (control)

The "redacted" output for a token-based connection string is byte-for-byte identical to the unredacted original — the helpers have no effect on token.

Impact

Vulnerability type: Insertion of Sensitive Information into Log File (CWE-532).

An authentication token (functionally equivalent in sensitivity to a password — it grants full access to the Cassandra cluster) is written in plaintext to application log files whenever: - The application uses token-based authentication (e.g., DataStax Astra), AND - DEBUG logging is enabled (common in staging environments and during production troubleshooting sessions).

An attacker who can read log files — via log aggregation system access, misconfigured log storage, or a separate log-reading vulnerability — can extract a live authentication token and use it to authenticate directly to the Cassandra cluster, accessing all data the token is authorized to read or write.

This is exactly the same impact class as the original AIKIDO-2024-10565 fix was intended to prevent — the fix simply missed a second sensitive credential type that was already present in the codebase.

Show details on source website

{
  "affected": [
    {
      "package": {
        "ecosystem": "Maven",
        "name": "com.ing.data:cassandra-jdbc-wrapper"
      },
      "ranges": [
        {
          "events": [
            {
              "introduced": "5.0.0"
            },
            {
              "fixed": "5.0.2"
            }
          ],
          "type": "ECOSYSTEM"
        }
      ]
    },
    {
      "database_specific": {
        "last_known_affected_version_range": "\u003c= 4.16.3"
      },
      "package": {
        "ecosystem": "Maven",
        "name": "com.ing.data:cassandra-jdbc-wrapper"
      },
      "ranges": [
        {
          "events": [
            {
              "introduced": "0"
            },
            {
              "fixed": "4.16.4"
            }
          ],
          "type": "ECOSYSTEM"
        }
      ]
    }
  ],
  "aliases": [
    "CVE-2026-73504"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-532"
    ],
    "github_reviewed": true,
    "github_reviewed_at": "2026-11-19T00:50:28Z",
    "nvd_published_at": "2026-11-18T20:19:12Z",
    "severity": "MODERATE"
  },
  "details": "### Summary\nThe fix for [AIKIDO-2024-10565](https://intel.aikido.dev/cve/AIKIDO-2024-10565) (plaintext password logging) introduced two\nredaction helpers \u2014 `DriverUtil.toStringWithoutSensitiveValues()` and\n`DriverUtil.redactSensitiveValuesInJdbcUrl()` \u2014 but both helpers only redact\nthe `\"password\"` property/parameter (`JdbcUrlUtil.TAG_PASSWORD`). The equally\nsensitive `\"token\"` property (`JdbcUrlUtil.TAG_TOKEN`), used for DataStax\nAstra and other token-based Cassandra authentication, is completely unredacted\nby both helpers. Applications using token-based authentication with DEBUG\nlogging enabled will therefore log the live authentication token in plaintext\nvia `SessionHolder`\u0027s calls to these same two helpers \u2014 the exact same\nexposure pattern that the original fix was intended to prevent.\n\n### Details\n**File:** `src/main/java/com/ing/data/cassandra/jdbc/utils/DriverUtil.java`\n\n```java\n// toStringWithoutSensitiveValues (lines 341-347) -- only redacts \"password\"\npublic static String toStringWithoutSensitiveValues(final Properties properties) {\n    final Properties withRedactedSensitiveValues = (Properties) properties.clone();\n    if (withRedactedSensitiveValues.containsKey(TAG_PASSWORD)) {\n        withRedactedSensitiveValues.setProperty(TAG_PASSWORD, \"***\");\n    }\n    return withRedactedSensitiveValues.toString();\n}\n\n// redactSensitiveValuesInJdbcUrl (lines 355-378) -- only redacts \"password\"\nfinal String redactedQuery = Arrays.stream(...)\n    .map(param -\u003e {\n        if (param.startsWith(TAG_PASSWORD + \"=\")) {\n            return TAG_PASSWORD + \"=***\";\n        }\n        return param;     // \u003c-- \"token=...\" passes through unmodified\n    })\n    ...\n```\n\n`JdbcUrlUtil.java` defines `TAG_TOKEN = \"token\"` (line 407) as a separate,\ndistinct connection property used when connecting with DataStax Astra-style\ntoken-based authentication. Neither redaction helper checks for this key.\n\n**File:** `src/main/java/com/ing/data/cassandra/jdbc/SessionHolder.java`\n\nBoth helpers are called on connection-level properties at DEBUG log level:\n\n```java\n// Line 150 \u2014 logs all connection properties including \"token\" unredacted\nlog.debug(\"Final Properties to Connection: {}\",\n    toStringWithoutSensitiveValues(this.properties));\n\n// Lines 173, 190 \u2014 logs JDBC URL including \"?token=...\" unredacted\nfinal String jdbcUrl = redactSensitiveValuesInJdbcUrl(this.cacheKey.get(URL_KEY));\nlog.debug(\"Released last reference to {}, closing Session.\", jdbcUrl);\nlog.debug(\"Acquired reference to {}, new count = {}.\", jdbcUrl, ref + 1);\n```\n\nDEBUG logging is commonly enabled in production troubleshooting and staging\nenvironments, meaning the token is logged in plain text every time a\nconnection is acquired or released in such environments.\n\n### PoC\n**Environment:** JDK 17+, Maven 3.x\n\n**pom.xml dependency:**\n```xml\n\u003cdependency\u003e\n    \u003cgroupId\u003ecom.ing.data\u003c/groupId\u003e\n    \u003cartifactId\u003ecassandra-jdbc-wrapper\u003c/artifactId\u003e\n    \u003cversion\u003e5.0.1\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\n**Exploit.java:**\n```java\nimport com.ing.data.cassandra.jdbc.utils.DriverUtil;\nimport java.util.Properties;\n\npublic class Exploit {\n    public static void main(String[] args) throws Exception {\n        String secretToken = \"AstraCS:SUPER_SECRET_TOKEN_VALUE_1234567890\";\n\n        // Test 1: redactSensitiveValuesInJdbcUrl()\n        String urlWithToken = \"jdbc:cassandra://host:9042/ks?token=\" + secretToken;\n        String redacted = DriverUtil.redactSensitiveValuesInJdbcUrl(urlWithToken);\n        System.out.println(\"Token in \u0027redacted\u0027 URL: \" + redacted.contains(secretToken)); // true\n\n        // Test 2: toStringWithoutSensitiveValues()\n        Properties props = new Properties();\n        props.setProperty(\"token\", secretToken);\n        String redactedProps = DriverUtil.toStringWithoutSensitiveValues(props);\n        System.out.println(\"Token in \u0027redacted\u0027 props: \" + redactedProps.contains(secretToken)); // true\n\n        // Control: password IS correctly redacted\n        Properties propsWithPassword = new Properties();\n        propsWithPassword.setProperty(\"password\", \"secret\");\n        System.out.println(\"Password redacted: \" +\n            !DriverUtil.toStringWithoutSensitiveValues(propsWithPassword).contains(\"secret\")); // true\n    }\n}\n```\n\n**Result (confirmed, 3/3 reproductions on cassandra-jdbc-wrapper 5.0.1, the latest release):**\n\n```\nToken in \u0027redacted\u0027 URL:   true   \u003c- token leaks through the URL redactor\nToken in \u0027redacted\u0027 props: true   \u003c- token leaks through the property redactor\nPassword redacted:         true   \u003c- password IS correctly masked (control)\n```\n\nThe \"redacted\" output for a token-based connection string is byte-for-byte\nidentical to the unredacted original \u2014 the helpers have no effect on `token`.\n\n### Impact\n**Vulnerability type:** Insertion of Sensitive Information into Log File (CWE-532).\n\nAn authentication token (functionally equivalent in sensitivity to a password\n\u2014 it grants full access to the Cassandra cluster) is written in plaintext to\napplication log files whenever:\n- The application uses token-based authentication (e.g., DataStax Astra), AND\n- DEBUG logging is enabled (common in staging environments and during\n  production troubleshooting sessions).\n\nAn attacker who can read log files \u2014 via log aggregation system access,\nmisconfigured log storage, or a separate log-reading vulnerability \u2014 can\nextract a live authentication token and use it to authenticate directly to\nthe Cassandra cluster, accessing all data the token is authorized to read or\nwrite.\n\nThis is exactly the same impact class as the original AIKIDO-2024-10565 fix\nwas intended to prevent \u2014 the fix simply missed a second sensitive credential\ntype that was already present in the codebase.",
  "id": "GHSA-jc42-994r-vvwp",
  "modified": "2026-11-19T00:50:28Z",
  "published": "2026-11-19T00:50:28Z",
  "references": [
    {
      "type": "WEB",
      "url": "https://github.com/ing-bank/cassandra-jdbc-wrapper/security/advisories/GHSA-jc42-994r-vvwp"
    },
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-73504"
    },
    {
      "type": "WEB",
      "url": "https://github.com/ing-bank/cassandra-jdbc-wrapper/commit/0b7ea0322e538304119f58f1214e4171312b245b"
    },
    {
      "type": "WEB",
      "url": "https://github.com/ing-bank/cassandra-jdbc-wrapper/commit/ace58f7cf5c981d8dfe302f1a514ae4c6f827f38"
    },
    {
      "type": "PACKAGE",
      "url": "https://github.com/ing-bank/cassandra-jdbc-wrapper"
    },
    {
      "type": "WEB",
      "url": "https://github.com/ing-bank/cassandra-jdbc-wrapper/releases/tag/v4.16.4"
    },
    {
      "type": "WEB",
      "url": "https://github.com/ing-bank/cassandra-jdbc-wrapper/releases/tag/v5.0.2"
    }
  ],
  "schema_version": "1.4.0",
  "severity": [
    {
      "score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N",
      "type": "CVSS_V3"
    }
  ],
  "summary": "cassandra-jdbc-wrapper: Authentication Token Exposed in Logs"
}



Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Forecast uses a logistic model when the trend is rising, or an exponential decay model when the trend is falling. Fitted via linearized least squares.

Sightings

Author Source Type Date Other

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.

Loading…

Loading…

Loading…

Related by attack behaviour

Vulnerabilities whose description is nearest to this one in the vector space of the CIRCL/vulnerability-attack-technique-biencoder model. This is a similarity search over the bi-encoder space (plain cosine), not a classification, and it has no measured accuracy.


Loading…