Courseiva
Secure Windows Server InfrastructuremediumMultiple ChoiceObjective-mapped

AZ-802 Secure Windows Server Infrastructure Practice Question

Exhibit

Scope          ExecutionPolicy
-----          ---------------
MachinePolicy  Undefined
UserPolicy     Undefined
Process        Bypass
CurrentUser    Undefined
LocalMachine   AllSigned

Refer to the exhibit. An administrator is attempting to run a locally created, unsigned PowerShell script named 'Update-Config.ps1' on a Windows Server 2022. Based on the output of 'Get-ExecutionPolicy -List', what will happen when the administrator attempts to run the script in the current session?

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

The script will run successfully without any prompts.

PowerShell execution policies follow a specific order of precedence. In this exhibit, the 'Process' scope is set to 'Bypass', which takes precedence over the 'LocalMachine' scope's 'AllSigned' setting. When an execution policy is set to 'Bypass', nothing is blocked and there are no warnings or prompts, allowing unsigned scripts to execute freely.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • The script will fail to run because the LocalMachine policy is set to AllSigned.

    Why it's wrong here

    The 'LocalMachine' scope is lower in the precedence hierarchy than the 'Process' scope. Although 'AllSigned' usually requires scripts to be digitally signed, the 'Bypass' setting at the 'Process' level overrides this restriction for the duration of the current PowerShell session, allowing any script to run regardless of its signature.

  • The script will run successfully without any prompts.

    Why this is correct

    Because the 'Process' scope is set to 'Bypass', PowerShell ignores all security restrictions for the current process. This scope has higher priority than 'LocalMachine'. Therefore, the unsigned script will execute immediately. This is often used by automated tasks or administrators who need to run scripts without changing permanent system settings.

  • The script will prompt the user for confirmation before executing.

    Why it's wrong here

    A prompt for confirmation typically occurs when the policy is set to 'RemoteSigned' and a script is downloaded from the internet without being unblocked. However, 'Bypass' explicitly suppresses all prompts and warnings. The user will not be asked for permission, and the script will proceed to execute as soon as the command is entered.

  • The script will only run if the administrator executes it from an elevated prompt.

    Why it's wrong here

    Elevation (Running as Administrator) does not change how the execution policy is applied. If the policy blocks a script, it will be blocked regardless of whether the prompt is elevated or not. In this case, the 'Bypass' policy at the 'Process' level is what allows the execution, not the administrative status of the user.

About these practice questions

One of 116 original AZ-802 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written and reviewed by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

Last reviewed September 2026 · checked against the official Microsoft exam blueprint

This AZ-802 practice question is part of Courseiva's free Microsoft certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the AZ-802 exam.