Skip to content

Webhook URL leaked via println! in production code #568

Closed

Description

@pbeza

The webhook notification code in dstack/vmm/src/app/qemu.rs logs the full webhook URL including any embedded authentication tokens at the info log level, exposing secrets to anyone with log access.

Root Cause

The webhook-based auth API implementation uses println! to log the webhook URL in production code paths. Webhook URLs often contain authentication tokens or secrets in query parameters or path segments (e.g., Slack webhook URLs, GitHub webhook secrets).

// upgrade_authority.rs:100
println!("Webhook URL: {}", webhook_url);

Attack Path

  1. KMS is configured with a webhook auth API that uses a URL containing authentication tokens
  2. The webhook URL is printed to stdout via println!
  3. stdout may be captured by logging infrastructure, container orchestrators, or monitoring systems
  4. An attacker with access to logs obtains the webhook URL including its embedded secrets
  5. Attacker can call the webhook directly, potentially bypassing authorization checks

Impact

Information disclosure of potentially sensitive webhook URLs through stdout. The severity depends on whether the webhook URL contains authentication tokens. If it does, the attacker gains the ability to make authenticated webhook calls.

Suggested Fix

Replace println! with a structured logging call that redacts the URL:

tracing::debug!("Webhook auth API configured");
// Do NOT log the URL itself

If the URL must be logged for debugging, redact sensitive parts:

tracing::debug!("Webhook configured for host: {}", url.host_str().unwrap_or("unknown"));

Note: This issue was created automatically. The vulnerability report was generated by Claude and has not been verified by a human.

Activity

  1. kvinwang commented on Mar 18, 2026

    @kvinwang
    Collaborator

    This was already fixed in 79b8b8d — the println! was removed as part of the auth API error logging improvements.

  2. added
    securitySecurity-related issue, report, or hardening work
    security: reportPublic security report or already-public security finding
    security: fixedSecurity report addressed by a code or configuration change
    on Jun 30, 2026
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

    securitySecurity-related issue, report, or hardening worksecurity: fixedSecurity report addressed by a code or configuration changesecurity: reportPublic security report or already-public security finding

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions