Microsoft Azure

For hands-on security assessment methodology, see Azure. For tool setup and authentication, see Cloud Audit Tools.


Overview

Azure is Microsoft’s cloud platform. Resources are organised into a management hierarchy: Management Groups > Subscriptions > Resource Groups > Resources. All access is governed by Azure RBAC and Entra ID (formerly Azure Active Directory).


Management Hierarchy

LevelDescription
Management GroupContainer for multiple subscriptions. Policies and RBAC applied here inherit down.
SubscriptionBilling and access boundary. Contains all resource groups and resources.
Resource GroupLogical container for related resources within a subscription.
ResourceIndividual service instances (VMs, storage accounts, Key Vaults, etc.).

RBAC assignments and Azure Policy can be applied at any level and inherit downward.


Entra ID (Azure Active Directory)

Entra ID is Azure’s identity platform — a separate global service, not scoped to a subscription.

Identity Types

TypeDescription
UserHuman identity with a UPN (user@tenant.onmicrosoft.com). Can be cloud-only or synced from on-prem AD.
GroupCollection of users. RBAC assigned to groups applies to all members.
Service PrincipalIdentity for an application or service. Created automatically when an App Registration is made.
App RegistrationRepresents an application in Entra ID. Has its own credentials (client secrets, certificates).
Managed IdentitySystem-assigned or user-assigned identity for Azure resources. No credentials to manage — Azure handles token issuance automatically.
External / GuestB2B guest accounts from other tenants.

Key Concepts

  • Tenant — A dedicated Entra ID instance for an organisation. Identified by a Tenant ID (GUID) and a domain (tenant.onmicrosoft.com).
  • App Registration vs Service Principal — App Registration is the definition (exists once per tenant). Service Principal is the instance (can be in multiple tenants for multi-tenant apps).
  • Managed Identity — Preferred for service-to-service auth. System-assigned is tied to the resource lifecycle; user-assigned is independent and can be shared.
  • PIM (Privileged Identity Management) — Just-in-time role activation. Eligible assignments require explicit activation (with optional MFA/approval) rather than being permanently active.
  • Conditional Access — Policy engine that evaluates sign-in conditions (user, location, device, app) and enforces controls (MFA, block, compliant device).

RBAC Model

Azure RBAC controls access to Azure resources (not Entra ID objects — that’s Entra ID roles).

Scope Hierarchy

Management Group
  └── Subscription
        └── Resource Group
              └── Resource

Permissions assigned at a higher scope are inherited by all child scopes.

Built-in Roles (Most Privileged)

RolePermissions
OwnerFull access + ability to assign roles to others
ContributorFull access to resources, cannot assign roles
ReaderRead-only across all resources in scope
User Access AdministratorManage role assignments only (no resource access)

Hundreds of service-specific built-in roles exist (e.g. Storage Blob Data Contributor, Key Vault Secrets User).

Custom Roles

Defined with specific Actions, NotActions, DataActions, and NotDataActions. Assigned at a defined scope.

Security Implications

  • Owner at subscription scope = full control including RBAC manipulation = privilege escalation pivot point
  • User Access Administrator alone can grant themselves Owner
  • Managed identities with Contributor or Owner on a subscription are high-value targets
  • Role assignments propagate down — check what’s assigned at Management Group level

Key Services

Compute

ServiceDescription
Virtual Machines (VMs)IaaS compute. Can have system-assigned managed identities.
Azure FunctionsServerless. Runs with an assigned managed identity or connection strings.
App ServiceManaged web app hosting. Can have managed identity and app settings (potential secret exposure).
AKS (Azure Kubernetes Service)Managed Kubernetes. Nodes use managed identities; pods can use Workload Identity.
Container Instances (ACI)Serverless containers.

Storage

ServiceDescription
Blob StorageObject storage. Containers can be set to public, private, or anonymous read.
Azure FilesManaged SMB/NFS file shares.
Azure SQLManaged relational database.
Cosmos DBManaged NoSQL.
Azure Data LakeHierarchical namespace storage for analytics workloads.

Networking

ServiceDescription
VNetVirtual network. Contains subnets.
NSG (Network Security Group)Stateful firewall rules attached to subnets or NICs.
Azure FirewallManaged L4/L7 firewall.
Private EndpointPrivate IP for a PaaS service within a VNet — removes public exposure.
VNet PeeringConnects VNets. Traffic stays on Microsoft backbone but crosses network boundaries.
Application GatewayL7 load balancer with WAF capability.
Azure Front DoorGlobal CDN + WAF.

Identity & Directory

ServiceDescription
Entra IDCloud identity platform (users, groups, service principals, app registrations).
PIMJust-in-time privileged role activation.
Conditional AccessPolicy-based access controls on sign-in.
Entra ID ConnectSync from on-prem AD to Entra ID. Hybrid identity.
External Identities (B2B)Guest users from other tenants.

Secrets & Key Management

ServiceDescription
Key VaultManaged secrets, keys, and certificates. Access via access policies or RBAC.
Managed HSMFIPS 140-2 Level 3 hardware-backed key management.

Logging & Monitoring

ServiceDescription
Azure MonitorCentralised metrics, logs, and alerting.
Activity LogAudit log of all ARM operations on a subscription.
Diagnostic SettingsPer-resource log forwarding to Log Analytics, Storage, or Event Hub.
Log AnalyticsManaged log aggregation and query (KQL).
Microsoft Defender for CloudSecurity posture management + threat detection across Azure resources.
SentinelCloud-native SIEM/SOAR.
Azure PolicyEnforce and audit compliance rules on resources.

Authentication Types

TypeDescription
Interactive (az login)Browser-based login for human users. Returns short-lived tokens.
Service Principal (client secret)App authenticates with a client ID + secret.
Service Principal (certificate)App authenticates with a client ID + certificate. More secure than secret.
Managed IdentityAzure-managed identity for resources. No credentials — platform issues tokens automatically via IMDS (http://169.254.169.254/metadata/identity/...).
Federated IdentityOIDC federation — workloads outside Azure (GitHub Actions, AWS) authenticate without secrets.
Azure AD tokensAccess tokens (JWT) issued by Entra ID, used against Microsoft Graph and ARM APIs.

ARM Resource ID Format

/subscriptions/<SubscriptionId>/resourceGroups/<ResourceGroup>/providers/<Provider>/<ResourceType>/<ResourceName>

Examples:

/subscriptions/aaaabbbb-cccc-dddd-eeee-ffffffffffff/resourceGroups/prod-rg/providers/Microsoft.Compute/virtualMachines/prod-vm-01
/subscriptions/aaaabbbb.../resourceGroups/prod-rg/providers/Microsoft.KeyVault/vaults/prod-kv

See Also