Skip to content

[coverage] Conformance findings: CLOUDFETCH-213701 #618

Closed

Description

@oss-engineer-bot

Summary

Surfaced by the multi-language coverage fan-out while conformance-testing these SPEC-IDs against databricks/databricks-sql-nodejs. Each finding is committed as an expected-failure (xfail) test in the coverage PR — the test asserts the CORRECT (post-fix) behavior and stays red until THIS driver (databricks/databricks-sql-nodejs) is fixed, then flips green as a tripwire.

Findings

  • CLOUDFETCH-213701 [sea]: SEA CloudFetch retry warning leaks the presigned URL credential: the default-on WARN "Chunk N download failed (attempt i/n)" line copies the HTTP client's URL-bearing error text verbatim, so the full signed query (Azure SAS sig=, S3 X-Amz-Signature) reaches any log sink; log the URL only up to '?' and strip the query from the error before formatting (ES-2034600).
    • failing test: CLOUDFETCH-213701 failed download does not leak the presigned URL credential — neither the retry log nor the terminal error reproduces the signed query [sea] (see the coverage PR diff under tests/)

Reproduce & Expected

CLOUDFETCH-213701 — A CloudFetch presigned URL carries its credential IN THE QUERY STRING -- Azure SAS sig=, S3 X-Amz-Signature, GCS X-Goog-Signature.

Reproduce:

  • Install the harness's log capture before any CloudFetch traffic and keep it
    for the whole test, at the most verbose level the driver exposes to tests
    (DEBUG where available). The retry warning is default-on, but the
    per-request and chunk-download lines are debug and printed the URL too.
  • One shot: the first cloud-storage download is cut off, the retry succeeds.
    The failure is RECOVERED, so the retry warning is the only trace of it --
    which is exactly why a credential written there goes unnoticed.
  • Drain the whole result; it succeeds after the retry.
  • Now the download NEVER succeeds, so the driver exhausts its attempt budget
    and the failure reaches the application as an error -- the second surface.
  • Drain and expect the drain to fail.

Expected (per the shared spec):

  • completes without an exception
  • result has at least 1 row(s)
  • full assertion contract:
result:
- label: recovered_download
  no_exception: true
- label: recovered_download
  row_count_min: 1
- label: recovered_download
  log_output:
    not_contains:
    - sig=
    - X-Amz-Signature
    - X-Amz-Credential
    - X-Amz-Security-Token
    - X-Goog-Signature
    not_contains_observed: presigned_url_query
- label: terminal_download
  exception_thrown: true
- label: terminal_download
  error:
    not_contains:
    - sig=
    - X-Amz-Signature
    - X-Amz-Credential
    - X-Amz-Security-Token
    - X-Goog-Signature
    not_contains_observed: presigned_url_query
- label: terminal_download
  log_output:
    not_contains:
    - sig=
    - X-Amz-Signature
    - X-Amz-Credential
    - X-Amz-Security-Token
    - X-Goog-Signature
    not_contains_observed: presigned_url_query
- label: terminal_download
  elapsed_seconds_range:
    max: 180
protocol:
  thrift:
  - label: recovered_download
    cloud_downloads_min: 2
  - label: terminal_download
    cloud_downloads_min: 1
  sea:
  - label: recovered_download
    cloud_downloads_min: 2
  - label: terminal_download
    cloud_downloads_min: 1

Context

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions