Skip to content

fix(telemetry): the profile span holds the command path and the argument count, never the argument values #2058

Closed

Description

@dan-petty

Problem

The telemetry.profile span of devops telemetry profile (_run_profiled_command in src/devops_cli/commands/telemetry.py) stores the profiled command in command.line exactly as the person typed it, with every argument value. A secret given to the profiled command goes to the trace backend. #1996, #2024 and #2025 removed the same data from the command, usage-error and subprocess spans.

Found while #2025 was built.

Proposed fix

Record the command path and the argument count on the profile span, and never the argument values. OpenTelemetry's semantic conventions make process.command_line and process.command_args Opt-In for this reason.

Acceptance criteria

  • A test profiles a command with a secret-like argument, and no exported attribute holds the value.

Activity

  1. added
    type/security
    scope/telemetry
    on Oct 24, 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

    scope/telemetrytype/security

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions