Courseiva
mediumMultiple ChoiceObjective-mapped

MS-102 Practice Question: Automatically assign Microsoft 365 E5 licenses to…

A company wants to automatically assign Microsoft 365 E5 licenses to all users in the Sales department. The department is identified by the department attribute in Microsoft Entra ID. The administrator needs to configure a method where licenses are assigned based on group membership, and the group membership is automatically updated based on user attributes. Which licensing approach should the administrator use?

⚠ Common exam trap

Many candidates confuse group-based licensing with assigned groups (Option D) and overlook the dynamic group requirement, assuming any group-based licensing approach automatically updates membership, when in fact only dynamic groups provide attribute-driven automatic membership updates.

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

Group-based licensing with a dynamic group that uses the department attribute.

Group-based licensing in Microsoft Entra ID allows automatic license assignment based on group membership, and a dynamic group can automatically update its membership using the department attribute rule (e.g., `user.department -eq "Sales"`). This meets the requirement for both automated license assignment and attribute-driven membership updates without manual intervention.

Answer analysis

Option-by-option breakdown

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

  • Per-user licensing with a PowerShell script.

    Why it's wrong here

    Although PowerShell can automate license assignment in bulk, it is not event-driven by Azure AD attribute changes. A script must be scheduled or manually run to compare current department values and assign or remove licenses, adding operational overhead and failure risk. This does not meet the stated requirement for automatic, attribute-triggered provisioning.

  • Group-based licensing with a dynamic group that uses the department attribute.

    Why this is correct

    With Azure AD group-based licensing, you can attach Microsoft 365 E5 licenses to a dynamic security group whose membership rule is based on the department attribute. When a user's department changes, Azure AD automatically updates group membership and then applies or removes the E5 license without manual scripting. This directly satisfies the requirement for automatic license assignment to all users in a given department.

  • Subscription-based licensing via the Microsoft 365 admin center.

    Why it's wrong here

    'Subscription-based licensing via the Microsoft 365 admin center' is not an actual provisioning mechanism in Microsoft 365. The admin center is a management portal for purchased subscriptions and lets admins manually assign licenses per user or configure group-based licensing, but it does not continuously scan attributes and auto-assign based on subscription state. Therefore, this option offers no automated, attribute-driven assignment.

  • Group-based licensing with an assigned group that must be manually updated.

    Why it's wrong here

    An assigned (static) group's membership is fixed and must be edited by an administrator, so it does not react when a user's department attribute changes. If a user changes departments, the group owner must manually add or remove them before group-based licensing can assign or revoke the E5 license. This fails the automatic aspect of the requirement and creates a maintenance burden.

About these practice questions

Courseiva writes every MS-102 question from scratch — 241 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 →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This MS-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 MS-102 exam.