GHSA-4rgc-5g6r-2rjf: Github.com/treeverse/lakefs LakeFS Logs S3 Credentials Vulnerability

HIGH
CVSS 8.4
CWE-312
Published
Advisory Summary

GHSA-4rgc-5g6r-2rjf is a HIGH (CVSS 8.4) lakefs logs s3 credentials vulnerability (CWE-312: Cleartext Storage of Sensitive Information) affecting Github.com/treeverse/lakefs libraries in the Go ecosystem. The issue involves lakefs logs s3 credentials in plain text. Remediation is available by upgrading affected packages to version 0.101.0.

GHSA-4rgc-5g6r-2rjf at a Glance

CVE Identifier N/A
GHSA Identifier GHSA-4rgc-5g6r-2rjf
Severity HIGH
CVSS v3.1 Base Score 8.4
CWE Classification CWE-312: Cleartext Storage of Sensitive Information
Affected Product Github.com/treeverse/lakefs
Package Ecosystem Go
Published Date
Last Updated

Security Impact

CVSS: 8.4

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

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

How to Fix GHSA-4rgc-5g6r-2rjf

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

github.com/treeverse/lakefs fixed: 0.101.0
Upgrade github.com/treeverse/lakefs to 0.101.0
Verify Direct and Transitive Dependencies

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

inspect dependencies for github.com/treeverse/lakefs

How to Check if You Are Affected

To determine whether your application is affected by GHSA-4rgc-5g6r-2rjf, inspect your project dependencies for Github.com/treeverse/lakefs:

inspect dependencies for github.com/treeverse/lakefs

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

Note: Verify declared build manifests and deployed runtime container environments.

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 Github.com/treeverse/lakefs, 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

### Impact S3 credentials are logged in plain text ``` S3Creds:{Key:AKIAIOSFODNN7EXAMPLE Secret:wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY ``` appears as part of the log message: ``` time="2023-05-12T13:51:52Z" level=error msg="failed to perform diff" func="pkg/plugins/diff.(*Service).RunDiff" file="build/pkg/plugins/diff/service.go:124" error="rpc error: code = Canceled desc = stream terminated by RST_STREAM with error code: CANCEL" host="localhost:8000" method=GET operation_id=OtfDiff params="{TablePaths:{Left:{Ref:data_load@ Path:aggs/agg_variety/} Right:{Ref:data_load Path:aggs/agg_variety/} Base:{Ref: Path:}} S3Creds:{Key:AKIAIOSFODNN7EXAMPLE Secret:wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY Endpoint:http://0.0.0.0:8000} Repo:example}" path="/api/v1/repositories/example/otf/refs/data_load%40/diff/data_load?table_path=aggs%2Fagg_variety%2F&type=delta" request_id=d3b6fdc7-2544-4c12-8e05-376f16e35a80 service_name=rest_api type=delta user=docker ``` Discovered when investigating [#5862](https://github.com/treeverse/lakeFS/issues/5862) ### Patches _Has the problem been patched? What versions should users upgrade to?_ No ### Workarounds _Is there a way for users to fix or remediate the vulnerability without upgrading?_ disable all logging? ### References _Are there any links users can visit to find out more?_

GHSA-4rgc-5g6r-2rjf Affected Github.com/treeverse/lakefs Versions

1 component(s)
Fixed Versions:
0.101.0
Product / Package Ecosystem Affected Versions Fixed Version
github.com/treeverse/lakefs
Go
< 0.101.0
0.101.0

References

Frequently Asked Questions

What is GHSA-4rgc-5g6r-2rjf?
GHSA-4rgc-5g6r-2rjf is a security vulnerability in Github.com/treeverse/lakefs involving lakeFS logs S3 credentials in plain text under CWE-312: Cleartext Storage of Sensitive Information.
Which Github.com/treeverse/lakefs versions are affected?
Affected versions include releases prior to 0.101.0 across affected packages: github.com/treeverse/lakefs.
What version fixes GHSA-4rgc-5g6r-2rjf?
Upgrading to 0.101.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is github.com/treeverse/lakefs affected?
Yes, github.com/treeverse/lakefs is affected in releases prior to 0.101.0. Upgrade your dependency to 0.101.0 or later.
What is the CVSS score of GHSA-4rgc-5g6r-2rjf?
GHSA-4rgc-5g6r-2rjf has a CVSS v3.1 base score of 8.4 (HIGH) with vector string CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H.
What CWE is associated with GHSA-4rgc-5g6r-2rjf?
GHSA-4rgc-5g6r-2rjf 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 Go dependencies for GHSA-4rgc-5g6r-2rjf?
Run the dependency tree command: 'inspect dependencies for github.com/treeverse/lakefs'. 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-4rgc-5g6r-2rjf",
  "modified" : "2023-12-12T00:58:29Z",
  "published" : "2023-12-12T00:58:29Z",
  "aliases" : [ ],
  "summary" : "lakeFS logs S3 credentials in plain text",
  "details" : "### Impact\n\nS3 credentials are logged in plain text\n\n```\nS3Creds:{Key:AKIAIOSFODNN7EXAMPLE Secret:wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY\n```\n\nappears as part of the log message: \n\n```\ntime=\"2023-05-12T13:51:52Z\" level=error msg=\"failed to perform diff\" func=\"pkg/plugins/diff.(*Service).RunDiff\" file=\"build/pkg/plugins/diff/service.go:124\" error=\"rpc error: code = Canceled desc = stream terminated by RST_STREAM with error code: CANCEL\" host=\"localhost:8000\" method=GET operation_id=OtfDiff params=\"{TablePaths:{Left:{Ref:data_load@ Path:aggs/agg_variety/} Right:{Ref:data_load Path:aggs/agg_variety/} Base:{Ref: Path:}} S3Creds:{Key:AKIAIOSFODNN7EXAMPLE Secret:wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY Endpoint:http://0.0.0.0:8000} Repo:example}\" path=\"/api/v1/repositories/example/otf/refs/data_load%40/diff/data_load?table_path=aggs%2Fagg_variety%2F&type=delta\" request_id=d3b6fdc7-2544-4c12-8e05-376f16e35a80 service_name=rest_api type=delta user=docker\n```\n\nDiscovered when investigating [#5862](https://github.com/treeverse/lakeFS/issues/5862)\n\n\n### Patches\n_Has the problem been patched? What versions should users upgrade to?_\n\nNo\n\n### Workarounds\n_Is there a way for users to fix or remediate the vulnerability without upgrading?_\n\ndisable all logging? \n\n### References\n_Are there any links users can visit to find out more?_\n\n",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/treeverse/lakefs"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.101.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/treeverse/lakeFS/security/advisories/GHSA-4rgc-5g6r-2rjf"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/treeverse/lakeFS"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-312" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2023-12-12T00:58:29Z",
    "nvd_published_at" : null
  }
}