All guides
Practice now
D1 · Identity and Access

Microsoft Entra ID

The central identity directory in Azure. The AZ-104 tests practical administration: creating users, groups, domains, syncing with on-premises AD, and managing licenses.

What Microsoft Entra ID is

is Microsoft's cloud-based identity and access service (formerly known as Azure Active Directory; the AZ-104 exam exclusively uses the name Microsoft Entra ID). It is the central directory that authenticates and authorizes access to Azure, Microsoft 365, SaaS applications, and custom apps.

Not to be confused with AD DS (Active Directory Domain Services) — these are distinct products with distinct protocols.

DimensionAD DS (on-premises)Microsoft Entra ID
ProtocolLDAP, Kerberos, NTLMOAuth 2.0, OIDC, SAML 2.0, WS-Fed
StructureOUs, GPOs, domain treesFlat: users, groups, apps, devices
DevicesDomain join (Windows)Azure AD Join, Hybrid Join, Register
Native MFANo (requires NPS Extension)Yes, built in
Conditional AccessNoYes
External accessCross-domain trustsNative B2B / B2C
ScalingManual (add DCs)Automatic, global, 99.99%
AdministrationADUC, PowerShell (RSAT)Azure Portal, MS Graph, Entra admin center

Tenant, directory, and subscription

Tenant (directory)

A dedicated Entra ID instance for your organization. Created when you sign up with Microsoft. Has a unique ID (GUID) and an initial *.onmicrosoft.com domain.

An org can have multiple tenants (e.g., one for prod, one for dev). A tenant can have multiple subscriptions.

Azure Subscription

Azure billing unit and resource limit boundary. Each subscription trusts exactly ONE Entra ID tenant for authentication.

You can move a to another tenant. The tenant is the parent of the subscription, not the other way around.

Management Group

A container that groups multiple subscriptions. Lets you apply policies and RBAC to all of them with a single assignment. They inherit from the tenant root.

Maximum depth of 6 levels. A root automatically exists in every .

Icon-identity-230

User types and bulk creation

User types in Entra ID

Member

Organization employees

A user created directly in the tenant. Has its own domain (e.g., user@contoso.com). Broader default permissions than guest accounts.

Guest

Partners, consultants, auditors

An external user invited via B2B. Their account exists in another tenant or provider (Google, email). The UPN includes #EXT#, e.g., user_extdomain.com#EXT#@contoso.onmicrosoft.com.

Service Principal

Applications that need to access Azure APIs

An identity for an application registered in Entra ID. Similar to a "service account" for apps. Has a Client ID + Client Secret or certificate.

Creating and managing users — admin tasks

Azure Portal

Entra ID → Users → New user → Create user / Invite external user

One at a time. Not recommended for bulk operations.

Bulk operations (CSV)

Users → Bulk operations → Bulk create / Bulk invite / Bulk delete → download the CSV template, fill it in, upload it

Up to 50,000 users per file. Asynchronous processing.

Microsoft Graph API

POST /users with a JSON body. Requires the User.ReadWrite.All permission on the app.

No practical limit. Ideal for automation.

PowerShell (Az module)

New-AzADUser or (via Graph SDK) New-MgUser -DisplayName ... -MailNickname ...

Scriptable. Can be combined with CSVs and loops.

Key user properties

UPNUser Principal Name — login identity. Format: user@domain.com
Display NameVisible name. Not the login.
Mail NicknameEmail alias, the part before the @.
Usage LocationCountry required to assign M365 licenses.
Object IDUnique GUID for the user in Entra ID. Immutable.
Icon-identity-223

Groups — types and management

Security Group

Control access to resources (RBAC, apps). CANNOT have an email address.

Allowed members

Users, other groups, service principals, devices

Microsoft 365 Group

Collaboration: has a shared mailbox, SharePoint, Teams. Visible in Exchange.

Allowed members

Users only (no service principals or devices)

Membership types

Assigned (manual)

The admin manually adds/removes members. Full control, but doesn't scale well.

When: Small groups, stable membership, exceptional access.

Dynamic User

Automatic membership based on user attributes (department, jobTitle, country, etc.). Uses rules with syntax like: (user.department -eq "Finance").

When: Automatic licensing, access based on department/HR role.

Dynamic Device

Like Dynamic User but for devices. Rules based on device attributes (OS, compliance, etc.).

When: Automatic Intune policies based on device type.

Entra ID licenses and SKUs

The Entra ID tier determines which features are available. Knowing what requires P1 vs P2 is critical for the exam.

FeatureFreeP1P2
Basic users and groups✓✓✓
SSO to SaaS apps✓✓✓
Per-user MFA (legacy)✓✓✓
✗✓✓
Dynamic Groups✗✓✓
SSPR (self-service password reset)✗✓✓
Entra Connect (hybrid)✗✓✓
App Proxy (on-prem apps via cloud)✗✓✓
Sign-in logs (30-day retention)✗✓✓
Identity Protection (risk policies)✗✗✓
Privileged Identity Management (PIM)✗✗✓
Access Reviews✗✗✓
Entitlement Management✗✗✓

License assignment — best practices

  • →Assign licenses to GROUPS, not individual users — scales better and is auditable.
  • →The user must have Usage Location configured before assigning an M365 license.
  • →Group-based licensing requires Entra ID P1 at minimum.
  • →Both security groups and M365 Groups can receive licenses (not only security groups).

Custom domains and UPN

Adding a custom domain

1Entra ID → Custom domain names → Add custom domain
2Enter the domain (e.g., contoso.com)
3Azure gives you a TXT or MX record to verify at your DNS registrar
4Add the record to your public DNS and wait for propagation (TTL)
5Verify in the portal — the domain moves to "Verified" status
6Optional: mark as Primary domain so it becomes the default UPN suffix

UPN Suffix and alternates

The UPN (User Principal Name) is the login identifier. The suffix is the domain after the @.

Initial domaincontoso.onmicrosoft.com (cannot be removed)
Custom domaincontoso.com (after verification)
User UPNjohn.doe@contoso.com
Guest UPNext_user_gmail.com#EXT#@contoso.onmicrosoft.com

Gotcha: You cannot delete the initial *.onmicrosoft.com domain. And you cannot change the domain of a tenant that's already been created.

Entra Connect — hybrid synchronization

Entra Connect syncs identities from on-premises Active Directory Domain Services to Entra ID. It's the bridge for hybrid scenarios.

Synchronization modes

Password Hash Sync (PHS)

Syncs the password hash from AD DS to Entra ID. The user authenticates directly against Entra ID. Simplest mode with the best resiliency (works without on-prem connectivity).

✓ Recommended for most

Pass-through Authentication (PTA)

Entra ID forwards authentication to the on-premises AD DS in real time via lightweight agents. The password never leaves the domain. Requires continuous connectivity.

✓ If the hash cannot leave for compliance reasons

Federation (AD FS)

All authentication redirects to on-premises AD FS. Maximum control and options. Higher complexity: requires highly available AD FS infrastructure.

⚠ Only if there are very specific requirements

Synced object vs cloud-only

SourceOn-premises AD DSEntra ID portal / Graph
AdministrationAD DS only (portal is read-only)Entra ID portal / PowerShell
UPNComes from AD DS (can be mapped)Defined in Entra ID
Password resetRequires Password WritebackNative SSPR
DeleteDelete in AD DS → gets deleted in Entra IDDelete directly
■ Synced■ Cloud-only

Writeback — reverse direction

Password Writeback: SSPR writes the new password back to on-prem AD DS. Requires P1.

Group Writeback: M365 Groups are synced back to AD DS as distribution groups.

Device Writeback: Devices registered in Entra ID are written back to AD DS.

Administrative Units — admin scoping

Administrative Units (AUs) let you restrict the scope of Entra ID roles to a subset of users, groups, or devices. A global User Administrator can manage ALL users; with AUs you can create a "User Administrator for the HR department only."

How to configure

1Entra ID → Administrative Units → New administrative unit
2Add members: users, groups, and/or devices (manual or dynamic membership with a rule)
3Roles → Add assignments → select the role (e.g., User Administrator) and the admin
4The assigned admin can only manage users/groups WITHIN that AU

Roles that can be scoped to an AU

User AdministratorCreate/edit/delete users in the AU
Groups AdministratorManage groups assigned to the AU
Password AdministratorReset passwords for users in the AU
Helpdesk AdministratorReset passwords and revoke sessions (AU scope)
Authentication AdministratorRegister/clear auth methods in the AU
License AdministratorAssign/remove licenses for users in the AU

Important limitations

  • • Azure RBAC roles (Owner, Contributor) CANNOT be scoped to an AU — only Entra ID roles
  • • A Global Administrator always has global scope and cannot be restricted to an AU
  • • Requires Entra ID P1 for Dynamic AU membership

Real case: a company with 4 regions

You create 4 AUs (EMEA, AMERICAS, APAC, LATAM). Each AU has a local helpdesk with a "Helpdesk Administrator" role scoped only to its AU. The LATAM helpdesk can only reset passwords for the 200 users in its AU — it cannot see or touch the 2,000 global users.

Icon-identity-230

External Identities — B2B Collaboration

B2B Collaboration lets you invite external users (partners, auditors, customers) to access resources in your tenant using their own credentials (Entra ID, Google, email OTP).

B2B invitation flow

1Admin invites the external user: Entra ID → Users → Invite external user, or via API/PowerShell
2The user receives an invitation email with a redemption link
3The user accepts the invitation → consents to the access permissions for the tenant
4A Guest object is created in the inviting tenant (UPN with #EXT#)
5The admin assigns access (RBAC roles, groups, apps) to the guest user
6The user can access it using their own organization's credentials

Cross-tenant access settings

Inbound (who can access YOUR tenant):

• B2B collaboration: which users/groups from other tenants can be invited

• B2B direct connect: access without invitation to shared resources (e.g., Teams Connect)

• Trust settings: trust MFA and compliant devices from the external tenant

Outbound (what YOUR users can do in other tenants):

• Control whether your users can be invited into external tenants

Default guest restrictions

Guests have restricted directory permissions by default:

• Cannot enumerate all directory users

• Cannot see groups they don't belong to

• Cannot register apps (unless explicitly allowed)

• Configurable in Entra ID → External Identities → External collaboration settings

Identity providerDescriptionAuthentication flow
Entra ID (another tenant)The user has an account in another Azure tenantRedirect to source tenant → authentication → SAML/OIDC token → access
Microsoft Account (MSA)Outlook, Hotmail, LiveRedirect to login.live.com → authentication → token → access
GoogleGmail, Google WorkspaceFederated with Google Identity → OAuth → token → access
Email OTPAny email without Entra ID or GoogleAzure sends a 6-digit code to the email → user enters it → temporary access
SAML/WS-Fed (custom)Own corporate IdP with SAMLRedirect to the configured federated IdP → SAML assertion → access

Device join types in Entra ID

The join type determines how the device identifies itself to Entra ID, which policies it receives, and what the user can do from that device.

DimensionEntra ID RegisteredEntra ID JoinedHybrid Entra Joined
ScenarioBYOD — personal deviceCloud-only — new corporate devicesDevices already joined to on-prem AD DS
Supported OSWindows 10+, iOS, Android, macOSWindows 10+ and 11Windows 10/11 (and Server 2016+)
RequiresJust registering — the user adds their corporate accountWindows Out-of-box Experience (OOBE) or AutopilotEntra Connect + an active AD DS domain
Login withDevice's personal account + registered corporate accountEntra ID account as the device principalAD DS domain account (accesses cloud resources via token)
Intune policiesPartial (optional MDM enrollment)Full (Intune MDM + MAM)Full if enrolled in Intune
SSO to cloud resourcesWith Authenticator app or registered SSPRNative via PRT (Primary Refresh Token)Native via PRT (requires line of sight to a DC or Entra Connect)
On-prem resource accessWith corporate VPNCloud only (no on-prem domain join)Yes — has a Kerberos ticket from AD DS
Typical caseEmployee uses their personal iPhone or Mac for corporate email.Cloud-native company with no on-prem AD DSCompany with legacy on-prem apps that also wants cloud access

Primary Refresh Token (PRT)

The PRT is a special token issued by Entra ID to Entra Joined and Hybrid Joined devices. It lasts up to 14 days and renews automatically. It enables silent SSO to all apps integrated with Entra ID without re-authenticating. It's like Kerberos's "TGT" but for the cloud world. If a CA policy requires a compliant device, it's verified using the PRT.

Entra Connect Cloud Sync vs classic Connect

Microsoft offers two tools for syncing on-premises AD DS with Entra ID. The AZ-104 tests when to use each one.

DimensionEntra Connect (classic)Entra Connect Cloud Sync
ArchitectureFull sync server (Windows Server) with an internal sync engineLightweight agent (~150 MB) installed on Windows Server, sync logic in the cloud
Multiple forestsSupports multiple forests but from the same serverMultiple disconnected forests — one independent agent per forest
Staging server (HA)Yes — you can have a staging-mode server for failoverMultiple agents in the same forest for automatic HA
Password hash syncYesYes
Password writebackYes (configured in the wizard)Yes (via configuration in the cloud portal)
Group writebackYes — M365 Groups → AD DS distribution groupsYes (v2 — security groups too)
Exchange hybridYes — full Exchange attributesLimited support — not all Exchange attributes
Custom sync rulesYes — very flexible with the Synchronization Rules EditorLimited — basic transformations in the portal
On-demand provisioningNo (full sync cycle)Yes — sync a specific user on demand for testing
Best forComplex environments: Exchange hybrid, custom sync rules, single large forestSimple scenarios, multiple disconnected forests, new deployments

Which to choose? — quick decision tree

→ Do you have on-premises Exchange and need hybrid? → Classic Entra Connect

→ Do you have multiple disconnected AD DS forests? → Cloud Sync

→ Do you need complex sync rules or transformations? → Classic Entra Connect

→ New deployment with no specific Exchange requirements? → Cloud Sync

→ Need to migrate gradually from classic Entra Connect? → You can coexist, using Cloud Sync for new OUs/forests

Did you get this topic?

Test what you just learned

What is the main difference between Microsoft Entra ID and traditional Active Directory Domain Services (AD DS)?

Ready to test "Microsoft Entra ID (Azure AD)"?

Put what you learned to the test with original AZ-104 exam questions.

Start AZ-104 mock exam

Unlimited mock exams with the Pro plan

Log in to track your progress.