nerdexam
Microsoft

GH-500 · Question #52

As a developer, you need to configure a code scanning workflow for a repository where GitHub Advanced Security is enabled. What minimum repository permission do you need?

The correct answer is D. Write. Configuring a code scanning workflow requires creating or modifying workflow files (e.g., .github/workflows/*.yml) in the repository. Writing to a repository - including creating and modifying files - requires at minimum Write permission. Read access (A) only allows viewing…

Configure and use Code Scanning with CodeQL

Question

As a developer, you need to configure a code scanning workflow for a repository where GitHub Advanced Security is enabled. What minimum repository permission do you need?

Options

  • ARead
  • BAdmin
  • CNone
  • DWrite

How the community answered

(33 responses)
  • A
    3% (1)
  • C
    6% (2)
  • D
    91% (30)

Explanation

Configuring a code scanning workflow requires creating or modifying workflow files (e.g., .github/workflows/*.yml) in the repository. Writing to a repository - including creating and modifying files - requires at minimum Write permission. Read access (A) only allows viewing repository contents, not making changes. Admin access (B) provides full repository control but is more than the minimum needed. 'None' (C) means no access at all. Write permission is sufficient because it allows committing workflow files to the repository, which is all that is needed to set up code scanning. Admin is not required unless the task also involves changing repository settings or branch protection rules.

Topics

#Code Scanning#Repository Permissions#Workflow Configuration#GHAS

Community Discussion

No community discussion yet for this question.

Full GH-500 Practice