Skip to content

Contrast workload secrets leak to logs on INFO level

High severity GitHub Reviewed Published May 27, 2025 in edgelesssys/contrast • Updated May 28, 2025

Package

gomod github.com/edgelesssys/contrast (Go)

Affected versions

<= 1.8.0

Patched versions

1.8.1

Description

Impact

When the Contrast initializer is configured with a CONTRAST_LOG_LEVEL of info or debug, the workload secret is logged to stderr and written to Kubernetes logs.

Since info is the default setting, this affects all Contrast installations that don't customize their initializers' log level.

The following audiences are intended to have access to workload secrets (see https://docs.edgeless.systems/contrast/1.7/architecture/secrets#workload-secrets):

  • Contrast Coordinator (can derive all workload secrets)
  • Contrast Initializer (obtains only the secret configured in the manifest)
  • Seedshare owner (can derive all workload secrets)
  • Workload owner (can update manifests to obtain secrets)

This vulnerability allows the following parties unintended access to workload secrets issued by a Coordinator:

  • Kubernetes users with get or list permission on pods/logs.
  • Others with read access to the Kubernetes log storage (most notably, the cloud provider).

This vulnerability does not affect scenarios where workload secrets are not used by the application (directly or with secure persistence). Applications designed for workload owner exclusion can't use workload secrets and are thus unaffected.

Patches

N/A

Workarounds

This vulnerability can be mitigated by adding an environment variable CONTRAST_LOG_LEVEL=warn to the initializer after running contrast generate, and then running contrast generate again.

References

N/A

References

@katexochen katexochen published to edgelesssys/contrast May 27, 2025
Published to the GitHub Advisory Database May 28, 2025
Reviewed May 28, 2025
Last updated May 28, 2025

Severity

High

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v3 base metrics

Attack vector
Adjacent
Attack complexity
Low
Privileges required
Low
User interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
None

CVSS v3 base metrics

Attack vector: More severe the more the remote (logically and physically) an attacker can be in order to exploit the vulnerability.
Attack complexity: More severe for the least complex attacks.
Privileges required: More severe if no privileges are required.
User interaction: More severe when no user interaction is required.
Scope: More severe when a scope change occurs, e.g. one vulnerable component impacts resources in components beyond its security scope.
Confidentiality: More severe when loss of data confidentiality is highest, measuring the level of data access available to an unauthorized user.
Integrity: More severe when loss of data integrity is the highest, measuring the consequence of data modification possible by an unauthorized user.
Availability: More severe when the loss of impacted component availability is highest.
CVSS:3.1/AV:A/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N

EPSS score

Weaknesses

CVE ID

No known CVE

GHSA ID

GHSA-h5f8-crrq-4pw8

Source code

Credits

Loading Checking history
See something to contribute? Suggest improvements for this vulnerability.