Microsoft 365 Endpoint AdministratorManage devices and apps (55-60%)Hard

A Microsoft 365 Endpoint Administrator needs to deploy a custom PowerShell script to all corporate-owned Windows 11 devices. The script will configure a specific application setting that requires administrative privileges to run successfully. The script should run once upon deployment and report its status back to Intune. Which method for deploying PowerShell scripts in Intune should be used?

  1. ADevice configuration profile (Custom OMA-URI) with a script payload.
  2. BSecurity baseline with a custom script extension.
  3. CScripts policy under 'Devices > Windows > PowerShell scripts'.
  4. DWin32 app deployment with a custom install command.
Show answer & explanation

Correct answer: C. Scripts policy under 'Devices > Windows > PowerShell scripts'.

Intune's dedicated 'PowerShell scripts' feature (under Devices > Windows) is designed precisely for deploying custom scripts. It handles execution with administrative privileges, execution frequency (once or repeatedly), and provides detailed reporting on script status, making it the ideal solution for this scenario.

Why the other options are wrong

  • A. OMA-URI is for configuring CSPs/registry, not for executing complex PowerShell scripts directly.
  • B. Security baselines are for predefined security settings and do not directly support custom script execution.
  • D. While a Win32 app can run scripts, it's overkill for a standalone script and lacks the direct reporting features of the dedicated script policy.

Intune PowerShell Scripts Policy

The PowerShell scripts policy in Microsoft Intune allows administrators to deploy and run custom PowerShell scripts on Windows devices, providing options for execution context (user/system), frequency, and detailed reporting.

  • Dedicated feature for script deployment.
  • Supports running with administrative privileges.
  • Provides detailed success/failure reporting in Intune.

Memory trick: PowerShell Scripts: The direct line for custom commands.

More Manage devices and apps (55-60%) questions