Skip to content

Non-interactive sessions bypass disableBypassPermissionsMode managed setting #4528

Description

@im-aIex

Describe the bug

Non-interactive (-p / --prompt) with --allow-all / --yolo grant permissions automatically even when .github-private/copilot/managed-settings.json is configured with:

{
  "permissions": {
    "disableBypassPermissionsMode": "disable"
  }
}

Attempting to run /allow-all / /yolo within the interactive shell correctly states:

Bypass permissions mode has been disabled by policy. Contact your administrator for more information.

Affected version

1.0.80

Steps to reproduce the behavior

  1. Configure "disableBypassPermissionsMode": "disable".
  2. Pass --yolo -p {prompt} to copilot CLI.

Expected behavior

yolo mode is ignored and tool calls are denied.

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions