MD-102 Protect devices Practice Question
Your organization uses Microsoft Intune to manage Windows 11 devices. You need to deploy a custom PowerShell script that runs during enrollment to configure network settings. What should you use?
⚠ Common exam trap
Many candidates confuse the ability to run custom scripts with device configuration profiles (Option B), mistakenly thinking OMA-URI can execute arbitrary code, when in reality OMA-URI only sets specific policy values and cannot run scripts.
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
✓
PowerShell scripts in Microsoft Intune
Microsoft Intune's built-in PowerShell scripts feature allows you to upload and run PowerShell scripts during device enrollment or on a schedule, which is exactly what is needed to configure network settings on Windows 11 devices. This feature executes scripts in the system context, making it suitable for network configuration tasks that require administrative privileges.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Device compliance policy
Why it's wrong here
Compliance policies do not run scripts.
- ✗
Device configuration profile with custom OMA-URI
Why it's wrong here
OMA-URI can set registry keys but not run complex scripts.
- ✓
PowerShell scripts in Microsoft Intune
Why this is correct
Intune has a dedicated 'PowerShell scripts' section for running scripts.
- ✗
Endpoint security policy
Why it's wrong here
Endpoint security policies do not support custom scripts.
Go deeper
Related to this question
Learn chapter
Introduction to Endpoint Management in Microsoft 365
Key term
Device enrollment
Device enrollment is the process of registering a device with a management system so that it can receive policies, apps, and security settings under organizational control.
Key term
Windows 11
Windows 11 is Microsoft's latest desktop operating system, offering a redesigned interface, enhanced security features, and improved support for modern hardware.
About these practice questions
Courseiva writes every MD-102 question from scratch — 942 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This MD-102 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 MD-102 exam.