Prev Next

Java / Microsoft Defender for Cloud Interview questions

Last updated

1. What is Microsoft Defender for Cloud? 2. What is a CNAPP in the context of Defender for Cloud? 3. What is Cloud Security Posture Management (CSPM)? 4. What is Secure Score in Defender for Cloud? 5. What are security recommendations in Defender for Cloud? 6. What is the Microsoft cloud security benchmark? 7. List the clouds and environments Defender for Cloud can protect? 8. List the main workload protection plans in Defender for Cloud? 9. What is Defender for Servers? 10. What is Defender for Containers? 11. What is Defender for Storage? 12. What is Defender for Databases? 13. What is Defender for Resource Manager? 14. What is Defender for APIs? 15. What is agentless scanning in Defender for Cloud? 16. What is Just-in-Time VM access? 17. What is the regulatory compliance dashboard? 18. What are security alerts in Defender for Cloud? 19. What is workflow automation in Defender for Cloud? 20. How do you enable Defender for Cloud plans on a subscription? 21. What is the difference between Foundational CSPM and Defender CSPM? 22. What is the difference between Defender for Servers Plan 1 and Plan 2? 23. How does agentless scanning work behind the scenes? 24. How do you connect AWS and GCP accounts to Defender for Cloud? 25. How does Defender for Cloud protect on-premises servers? 26. How is Secure Score calculated? 27. How does attack path analysis work? 28. What is the cloud security explorer used for? 29. When should you use JIT access instead of Azure Bastion? 30. How do you exempt a recommendation, and what changes? 31. How does continuous export work in Defender for Cloud? 32. How do you integrate Defender for Cloud with Microsoft Sentinel? 33. How does Defender for Containers protect Kubernetes clusters? 34. How does Defender for Storage detect malware? 35. What is the difference between an alert and an incident? 36. How do governance rules assign ownership for remediation? 37. How does Defender for Cloud support DevSecOps? 38. How does Defender for Cloud secure AI workloads? 39. How can you optimize Defender for Cloud costs? 40. Which is better: Defender for Cloud or Microsoft Sentinel? 41. How do you troubleshoot servers missing Defender for Endpoint protection? 42. Explain the lifecycle of a security alert from detection to response? 43. What is the difference between Fix, Enforce, and Deny on a recommendation? 44. How does data-aware security posture work in Defender CSPM? 45. How do you create custom recommendations and standards? 46. How does Defender for Cloud work with the Defender portal and XDR? 47. How do you query Defender for Cloud data with Azure Resource Graph? 48. How does risk prioritization rank recommendations? 49. How do you roll out Defender for Cloud across hundreds of subscriptions? 50. How do you reduce false-positive alerts without losing coverage?

1. What is Microsoft Defender for Cloud?

Microsoft Defender for Cloud is Microsoft's cloud-native application protection platform (CNAPP). It helps you find misconfigurations, harden resources and detect threats across Azure, AWS, Google Cloud and on-premises or hybrid servers from a single console.

It brings together two jobs. Posture management continuously checks your resources against security standards and tells you what to fix. Workload protection adds threat detection for servers, containers, storage, databases and more. It was formed from Azure Security Center and Azure Defender, which Microsoft merged under one name.

Basic posture features (Foundational CSPM) switch on automatically for Azure subscriptions at no charge. The paid Defender plans are enabled per resource type.

Take quiz
Defender for Cloud is best described as a:
Backup service for Azure virtual machines
Network firewall appliance
CNAPP covering posture management and workload protection
Identity provider for Azure users
Which two older Microsoft offerings were merged into Defender for Cloud?
Azure Monitor and Azure Advisor
Microsoft Intune and Azure Policy
Azure Firewall and Azure Bastion
Azure Security Center and Azure Defender

2. What is a CNAPP in the context of Defender for Cloud?

A CNAPP (cloud-native application protection platform) is a single product that secures cloud applications from code to runtime, instead of making you stitch together separate scanners. Defender for Cloud is Microsoft's answer to this category.

The capabilities it unifies map to the usual CNAPP building blocks:

  • CSPM - misconfiguration and compliance checks
  • CWPP - runtime protection for servers, containers and databases
  • DevSecOps - scanning code and infrastructure-as-code in GitHub, Azure DevOps and GitLab
  • Permissions management - spotting over-privileged identities (CIEM)
  • Data security posture - finding sensitive data and its exposure

The value is correlation: a vulnerable container image, the pipeline that built it and the cluster running it can be linked in one view.

Take quiz
What does a CNAPP provide that point tools usually do not?
A replacement for all firewalls
Only endpoint antivirus for laptops
Billing and cost reporting for cloud accounts
Code-to-runtime protection with correlated context in one platform
Which capability belongs to the DevSecOps part of Defender for Cloud?
Scanning infrastructure-as-code in repositories and pipelines
Rotating storage account keys
Managing Azure AD password policy
Resizing virtual machine disks

3. What is Cloud Security Posture Management (CSPM)?

CSPM is the practice of continuously checking cloud resources against security best practices and compliance rules, then reporting what is misconfigured. In Defender for Cloud it is the foundation everything else sits on.

Defender for Cloud evaluates resources against the Microsoft cloud security benchmark, produces recommendations, and rolls the results into a Secure Score. Typical findings are storage accounts open to the public internet, VMs with no endpoint protection, or databases without auditing.

There are two tiers: free Foundational CSPM and the paid Defender CSPM plan, which adds attack path analysis, agentless scanning, governance rules and more.

Take quiz
The output of CSPM in Defender for Cloud is mainly:
Recommendations and a Secure Score
Network packet captures
Backup restore points
Virtual machine images
CSPM checks are performed:
Only once during onboarding
Continuously against a security benchmark
Only when an incident is declared
Only on resources tagged as production

4. What is Secure Score in Defender for Cloud?

Secure Score is a percentage that summarises how well your environment follows the recommendations Defender for Cloud has assessed. A higher number means fewer open security gaps.

Recommendations are grouped into security controls, such as Enable MFA or Restrict unauthorized network access. Fixing every resource under a control earns that control's points. The score is shown per subscription, and you can view it across subscriptions to compare teams.

Treat it as a trend line, not a grade. It tells you where the biggest gaps are and lets you show progress to management over time.

Take quiz
A higher Secure Score indicates:
More virtual machines are running
Fewer unresolved security recommendations
Lower monthly Azure billing
A larger Log Analytics workspace
Secure Score points are earned by:
Dismissing alerts in the portal
Renaming subscriptions
Remediating affected resources under a security control
Adding more resource groups

5. What are security recommendations in Defender for Cloud?

A recommendation is an actionable finding that tells you which resource is misconfigured, why it matters, and how to fix it. Each one lists the affected resources, a severity, remediation steps and, for many, a Fix button that applies the change.

Resources show up as unhealthy, healthy or not applicable. You can assign an owner, set a due date, or exempt a resource if the risk is accepted.

In 2026 Microsoft moved the Azure portal to individual recommendations and scheduled the older grouped recommendation types for removal, so each finding is tracked and prioritised on its own.

Take quiz
An unhealthy resource in a recommendation means it:
Is currently powered off
Has been deleted
Does not meet the checked security requirement
Belongs to another tenant
Which element is part of a recommendation's detail page?
A copy of the VM disk
The customer's invoice
The tenant's sign-in logs only
Remediation steps and the list of affected resources

6. What is the Microsoft cloud security benchmark?

The Microsoft cloud security benchmark (MCSB) is Microsoft's set of prescriptive security controls for cloud workloads. It is the default standard Defender for Cloud assigns to every onboarded subscription, which is why recommendations appear without any setup.

Controls are organised into domains such as network security, identity management, privileged access, data protection, logging and threat detection, posture and vulnerability management, and DevOps security. The benchmark is mapped to well-known frameworks like CIS, NIST and PCI DSS, so one fix can support several audits.

Version 2 of the benchmark appeared in preview in late 2025, so check the current status before quoting it in an interview.

Take quiz
Which standard does Defender for Cloud apply by default?
PCI DSS only
HIPAA only
No standard until you create one
Microsoft cloud security benchmark
The benchmark's mappings to CIS, NIST and PCI DSS help you:
Reuse one remediation across several compliance frameworks
Skip audits entirely
Encrypt data automatically
Reduce the number of subscriptions

7. List the clouds and environments Defender for Cloud can protect?

Defender for Cloud covers more than Azure. The supported environments are:

  • Azure - subscriptions and their resources, protected natively
  • AWS - accounts or whole organizations, onboarded through a connector
  • Google Cloud (GCP) - projects or organizations, onboarded through a connector
  • On-premises and other clouds - servers connected through Azure Arc
  • DevOps platforms - GitHub, Azure DevOps and GitLab through connectors

Azure resources need no connector. AWS and GCP use connectors in Environment settings, and non-Azure machines are brought in through Azure Arc.

Take quiz
How are non-Azure servers typically brought under protection?
Through Azure Arc
By moving them into a VNet peering
By installing Azure Backup only
By joining them to Azure AD Domain Services
Which of these is configured in Environment settings with a connector?
An Azure subscription's default MCSB assignment
An AWS account
A Log Analytics query
An Azure Policy definition

8. List the main workload protection plans in Defender for Cloud?

Workload protection is sold as separate plans, each tied to a resource type. The main ones are:

Plan Protects
Defender for Servers Windows and Linux machines in Azure, AWS, GCP and on-premises
Defender for Containers Kubernetes clusters, nodes and container registries
Defender for Storage Blob, Files and Data Lake storage accounts
Defender for Databases Azure SQL, SQL Server on machines, open-source relational databases, Cosmos DB
Defender for App Service Azure App Service web apps
Defender for Key Vault Secrets, keys and certificates in Key Vault
Defender for Resource Manager Azure management-plane operations
Defender for APIs APIs published through Azure API Management

Plans are enabled per subscription, so you only pay for the resource types you actually run.

Take quiz
Which plan protects Kubernetes clusters and registries?
Defender for Storage
Defender for Containers
Defender for App Service
Defender for Key Vault
Defender for Resource Manager monitors:
Packets inside a VNet
Blob upload content
Management operations on Azure resources
Kubernetes pod logs

9. What is Defender for Servers?

Defender for Servers is the plan that protects Windows and Linux machines, whether they run in Azure, AWS, GCP or on-premises through Azure Arc. It adds threat detection and vulnerability management on top of the free posture checks.

It comes in two tiers. Plan 1 focuses on endpoint detection and response through the integrated Microsoft Defender for Endpoint. Plan 2 includes Plan 1 and adds extras such as just-in-time VM access, file integrity monitoring, agentless scanning and a free Log Analytics ingestion allowance per server.

Billing is per server per month, and you can set the plan on individual machines using resource-level configuration.

Take quiz
Defender for Servers Plan 1 is centred on:
Just-in-time VM access
Database vulnerability assessment
Endpoint detection and response via Defender for Endpoint
API discovery
Defender for Servers is billed:
Per API call only
Per gigabyte of blob storage
Once as a licence key
Per server per month

10. What is Defender for Containers?

Defender for Containers secures Kubernetes environments end to end: AKS, Amazon EKS, Google GKE and Arc-enabled clusters, plus the registries that hold your images.

It covers three areas: image vulnerability scanning in registries such as ACR, ECR and Google Artifact Registry, runtime threat detection on nodes and clusters, and hardening recommendations for cluster configuration. Alerts include things like a shell opened in a pod or a crypto-mining image.

Because it spans build, registry and runtime, it can show that a vulnerable image is both stored in a registry and currently running, which makes triage much easier.

Take quiz
Defender for Containers scans which asset for vulnerabilities?
Teams chat messages
Entra sign-in logs
Power BI reports
Container images in registries
Which Kubernetes services does the plan cover?
AKS, EKS, GKE and Arc-enabled clusters
Only AKS
Only on-premises clusters
Only Azure Container Instances

11. What is Defender for Storage?

Defender for Storage detects threats against Azure Storage accounts, including Blob Storage, Azure Files and Data Lake Storage. It is priced per storage account, with add-ons for malware scanning and sensitive data discovery.

Its three main capabilities are:

  • Activity monitoring - unusual access, such as access from a Tor exit node or a sudden spike in data extraction
  • Malware scanning - files are scanned as they are uploaded
  • Sensitive data threat detection - flags access patterns involving data classed as sensitive
Take quiz
Defender for Storage is priced:
Per storage account
Per virtual machine core
Per Kubernetes pod
Per Entra user
Malware scanning in Defender for Storage runs on:
Only on files older than a year
Files as they are uploaded
SQL table rows
Event Hub messages

12. What is Defender for Databases?

Defender for Databases bundles protection for several database types: Azure SQL Database and Managed Instance, SQL Server on machines (Azure, AWS, GCP and on-premises), open-source relational databases such as PostgreSQL, MySQL and MariaDB, and Azure Cosmos DB. In June 2026 Microsoft announced general availability for open-source relational databases on AWS RDS as well.

It detects behaviours such as SQL injection attempts, brute-force logins, access from unusual locations and potentially harmful queries, and raises alerts. SQL plans also include vulnerability assessment to find misconfigurations like excessive permissions or missing auditing.

Take quiz
Defender for Databases raises alerts for which kind of activity?
VM disk resizing
SQL injection and brute-force login attempts
Blob container deletion
DNS zone changes
Which database is covered by the plan?
Excel workbooks
Azure Table Storage only
Azure Cosmos DB
Redis running on laptops

13. What is Defender for Resource Manager?

Defender for Resource Manager watches the Azure management plane, meaning every operation sent through Azure Resource Manager from the portal, CLI, PowerShell, REST APIs or templates.

It looks for suspicious management activity, for example operations from anonymising IP addresses, use of known attack toolkits like MicroBurst, or sudden creation of many resources that suggests an attacker is establishing persistence. It is enabled at the subscription level and does not need an agent.

The alerts are especially useful for spotting an attacker who has stolen credentials, since their first moves, such as listing keys or changing permissions, show up as management operations.

Take quiz
Defender for Resource Manager analyses:
Traffic between pods
Rows inside a SQL table
Operations sent through Azure Resource Manager
Files in a Git repository
Does Defender for Resource Manager require an agent on VMs?
Yes, the Azure Monitor Agent
Yes, a Kubernetes DaemonSet
Yes, the Qualys agent
No, it monitors the management plane

14. What is Defender for APIs?

Defender for APIs protects APIs published through Azure API Management. It discovers and inventories your APIs, highlights posture problems and detects attacks aimed at them.

Typical findings include APIs that accept unauthenticated calls, APIs that are inactive but still exposed, and endpoints that return sensitive data. Threat detection uses machine learning to flag unusual patterns such as sudden spikes in calls or data exfiltration. Pricing is tiered by the volume of API calls, with overage charges beyond the plan limit.

Take quiz
Defender for APIs works with APIs published through:
Azure Front Door only
Azure Bastion
Azure DevTest Labs
Azure API Management
A typical posture finding from Defender for APIs is:
An API that accepts unauthenticated requests
A VM with too few CPU cores
A storage account in the wrong region
A DNS record without a TTL

15. What is agentless scanning in Defender for Cloud?

Agentless scanning inspects virtual machines without installing anything on them. Defender for Cloud takes a snapshot of the VM's disks, analyses the copy in a Microsoft-managed environment and then deletes it.

It finds installed software and known vulnerabilities, secrets stored on disk such as keys or passwords, and (with Defender for Servers Plan 2) malware. Because the workload is never touched, there is no performance impact and no agent to deploy or keep healthy. It works for Azure VMs, AWS EC2 and GCP instances, and is available through Defender CSPM and Defender for Servers Plan 2.

Take quiz
Agentless scanning analyses:
A snapshot copy of the VM disks
Live memory through a kernel driver
Only network flow logs
The VM's boot diagnostics screenshot
A main advantage of agentless scanning is:
It works only on powered-off VMs
No software to deploy on the machine
It replaces all firewalls
It requires a VPN gateway

16. What is Just-in-Time VM access?

Just-in-Time (JIT) access keeps management ports like RDP (3389) and SSH (22) closed by default and opens them only when someone requests access, for a limited time and from a specific IP address.

Defender for Cloud does this by adding temporary allow rules to the network security group or Azure Firewall. When the window ends, the rule is removed automatically. This shrinks the attack surface that brute-force and port-scanning attacks rely on. JIT requires Defender for Servers Plan 2.

Take quiz
JIT VM access mainly reduces exposure of:
Blob container names
Management ports such as RDP and SSH
Key Vault secrets
Entra group memberships
A JIT access request is granted:
Permanently once approved
Only to anonymous users
For a limited time and a specific source IP
Only during business hours automatically

17. What is the regulatory compliance dashboard?

The regulatory compliance dashboard shows how your environment measures up against a chosen standard, such as the Microsoft cloud security benchmark, PCI DSS, ISO 27001, SOC 2 or NIST SP 800-53.

Each standard is broken into controls, and each control is linked to the recommendations that support it. You see which controls pass, which fail, and which still need manual evidence. You can also download audit reports. Adding standards beyond the default usually requires a Defender plan, so confirm current licensing before relying on it.

Take quiz
Each control on the compliance dashboard is linked to:
Billing meters
Subscription tags
Recommendations that support it
VM extensions only
The dashboard is most useful during:
VM provisioning
DNS troubleshooting
Load balancer sizing
Audit preparation for standards like PCI DSS or ISO 27001

18. What are security alerts in Defender for Cloud?

A security alert is a notification that Defender for Cloud has detected suspicious activity against one of your resources. Alerts come from the paid Defender plans, not from the free posture checks.

Each alert has a severity, a description of what happened, the affected resource, the related MITRE ATT&CK tactic and recommended response steps. Examples include a possible brute-force attack on an SSH server, a suspicious process on a Linux node, or access to a storage account from a Tor exit node.

Take quiz
Security alerts are produced by:
Foundational CSPM alone
Azure Cost Management
Azure Advisor
The Defender workload protection plans
Alerts are mapped to which framework?
MITRE ATT&CK tactics
ITIL service tiers
TOGAF phases
COBIT domains

19. What is workflow automation in Defender for Cloud?

Workflow automation runs an Azure Logic App automatically when something happens in Defender for Cloud. You pick a trigger, a scope and the Logic App to run.

Supported triggers are a new security alert, a new or changed recommendation, and a change in regulatory compliance status. Common uses are posting a message to Microsoft Teams, opening a ServiceNow or Jira ticket, or emailing a resource owner. It saves analysts from copying details between tools by hand.

You can create the automation at subscription or management group scope, and it fires every time a matching event appears, so it works well for routing high-severity alerts to the on-call team.

Take quiz
Workflow automation executes:
An Azure Logic App
A PowerShell script on the VM
A Kubernetes CronJob
A Storage lifecycle policy
Which event can trigger a workflow automation?
A new billing invoice
A new security alert
A DNS query
A user sign-out

20. How do you enable Defender for Cloud plans on a subscription?

Foundational CSPM is already on for Azure subscriptions. To add paid protection, open Defender for Cloud > Environment settings, choose the subscription, switch the plans you need to On, and save.

For automation, use the CLI, Azure Policy or infrastructure as code. This example turns on Defender for Servers Plan 2:

az security pricing create --name VirtualMachines --tier Standard --subplan P2

Some plans have extensions, for example agentless scanning or malware scanning, that you can toggle separately in the same screen.

Take quiz
Where do you turn on Defender plans in the portal?
Cost Management budgets
Environment settings for the subscription
Azure Monitor alerts
Resource group locks
What is the CLI group used to set a plan's pricing tier?
az monitor metrics
az network vnet
az security pricing
az keyvault secret

21. What is the difference between Foundational CSPM and Defender CSPM?

Foundational CSPM is free and gives you the basics: continuous assessment, recommendations, Secure Score and the Microsoft cloud security benchmark. Defender CSPM is a paid plan that adds the context needed to prioritise risk and trace it back to code.

Capability Foundational CSPM Defender CSPM
Recommendations and Secure Score Yes Yes
Attack path analysis No Yes
Cloud security explorer No Yes
Agentless vulnerability and secrets scanning No Yes
Governance rules No Yes
Data-aware posture and code-to-cloud mapping No Yes

Pick Foundational CSPM to learn what is wrong. Pick Defender CSPM when you need to know which problems an attacker could actually chain together.

Take quiz
Which capability is available only with Defender CSPM?
Secure Score
The Microsoft cloud security benchmark
Attack path analysis
Basic recommendations
Foundational CSPM costs:
The same as Defender CSPM
A fee per attack path
A fee per recommendation
Nothing, it is free

22. What is the difference between Defender for Servers Plan 1 and Plan 2?

Plan 1 is the leaner option built around Defender for Endpoint. Plan 2 contains everything in Plan 1 and adds cloud-specific hardening and scanning features.

Area Plan 1 Plan 2
Endpoint detection and response Yes Yes
Vulnerability management Yes Yes
Just-in-time VM access No Yes
File integrity monitoring No Yes
Agentless scanning, including malware No Yes
Free Log Analytics ingestion per server (500 MB per day) No Yes

Microsoft adjusts the feature split over time, so confirm the current plan comparison page before choosing. A common pattern is Plan 2 for production servers and Plan 1 for dev and test.

Take quiz
Which feature is included in Plan 2 but not Plan 1?
Defender for Endpoint EDR
Billing per server
Azure Arc support
Just-in-time VM access
A sensible split of the two plans is:
Plan 2 for production and Plan 1 for dev and test
Plan 1 for production and no plan for dev
Plan 2 only for laptops
Plan 1 only for databases

23. How does agentless scanning work behind the scenes?

Defender for Cloud uses the cloud provider's snapshot APIs, so nothing runs inside the guest operating system. The flow is:

flowchart LR
  A["VM disks"] --> B["Snapshot taken"]
  B --> C["Copy to Microsoft-managed account in same region"]
  C --> D["Scan: software, vulnerabilities, secrets, malware"]
  D --> E["Findings sent to Defender for Cloud"]
  C --> F["Snapshot copy deleted"]

The snapshot is analysed in the same region as the VM, so data does not leave its geography. For AWS the equivalent is EBS snapshots, and for GCP it is disk snapshots. Results appear as recommendations and feed attack path analysis. Encrypted disks may need extra key permissions before the scanner can read them.

Take quiz
Where is the VM disk copy analysed?
In a Microsoft-managed environment in the same region
Inside the guest OS of the VM
On the administrator's laptop
In a customer-owned Kubernetes cluster
What happens to the snapshot copy after scanning?
It is kept for seven years
It is deleted
It is emailed to the owner
It becomes a VM image

24. How do you connect AWS and GCP accounts to Defender for Cloud?

Both clouds use security connectors created under Environment settings > Add environment. You choose the account or organization, select the plans, then run a generated template that creates the required access.

AWS GCP
Scope Single account or organization (management account) Single project or organization
Setup artifact CloudFormation or Terraform template Terraform or Cloud Shell script
Access method IAM role assumed through identity federation Service accounts with workload identity federation

Once connected, posture assessment starts without agents. For workload protection on EC2 or GCE machines, Defender for Servers uses Azure Arc, and the connector can auto-provision it. Onboarding at organization level means new accounts are picked up automatically.

Take quiz
AWS accounts are onboarded to Defender for Cloud through:
A manual copy of IAM access keys into Excel
A security connector using a CloudFormation or Terraform template
A site-to-site VPN only
An Azure Bastion host
What does organization-level onboarding give you?
Free Defender plans
Automatic deletion of old accounts
New accounts are included automatically
A separate Secure Score per VM

25. How does Defender for Cloud protect on-premises servers?

On-premises and other-cloud servers are projected into Azure with Azure Arc. You install the Connected Machine agent, and the server becomes an Arc-enabled resource in a subscription and resource group.

After that, Defender for Servers treats it much like an Azure VM: recommendations, Defender for Endpoint onboarding, vulnerability assessment and alerts all apply. Arc-enabled SQL Servers can be covered with the Defender for SQL on machines plan. The main requirement is outbound connectivity from the server to the Azure Arc and Defender endpoints.

This keeps one consistent view across hybrid estates, so a datacenter server and a cloud VM share the same Secure Score and recommendation workflow.

Take quiz
What brings an on-premises server under Defender for Servers?
Azure Site Recovery
Azure CDN
Azure Arc
Azure Lighthouse only
What network need does an Arc-enabled server have?
An inbound open RDP port from the internet
A dedicated ExpressRoute circuit
A public static IP
Outbound connectivity to Azure Arc and Defender endpoints

26. How is Secure Score calculated?

Each security control has a maximum score. A control's earned points depend on how many applicable resources are healthy:

Control score = max score x (healthy resources / total applicable resources)

The overall Secure Score is the sum of earned control points divided by the sum of the maximum points, shown as a percentage. For example, a control worth 6 points with 8 healthy resources out of 10 earns 4.8 points.

Resources marked not applicable or exempted are removed from the calculation, so exemptions can raise the score. Points are earned only when every recommendation in a control is fully addressed for a resource, which is why a partly fixed control shows little movement.

Take quiz
In the Secure Score formula, the ratio uses:
Alerts closed divided by alerts opened
Days since last scan divided by 30
Subscriptions divided by tenants
Healthy resources divided by total applicable resources
A control worth 6 points with 8 of 10 resources healthy earns:
4.8 points
8 points
6 points
0 points

27. How does attack path analysis work?

Defender CSPM builds a cloud security graph that records resources, identities, permissions, network exposure and vulnerabilities as connected nodes. Attack path analysis queries that graph for routes an attacker could realistically follow, starting at an entry point such as an internet-exposed VM and ending at something valuable, such as a database with sensitive data.

flowchart LR
  A["Internet-exposed VM"] --> B["Known vulnerability"]
  B --> C["Managed identity with broad rights"]
  C --> D["Storage account with sensitive data"]

Instead of hundreds of unrelated recommendations, you see one path and fixing any link, such as patching the VM or narrowing the identity, breaks it. Paths are ranked by risk so teams start with the ones that matter most. The feature requires the Defender CSPM plan.

Take quiz
An attack path connects:
An entry point to a high-value target through exploitable steps
Two subscriptions through billing
A user to their manager
A VM to its backup vault only
Fixing one link in an attack path:
Has no effect on risk
Breaks that path
Deletes the target resource
Moves the resource to another region

28. What is the cloud security explorer used for?

The cloud security explorer is a query builder on top of the cloud security graph. You build searches by picking resource types and conditions from menus, with no query language needed, and it returns matching resources.

It helps with hunting and investigation questions that recommendations alone cannot answer, such as:

  • Which internet-exposed VMs have high-severity vulnerabilities?
  • Which identities can read this Key Vault?
  • Which container images with critical findings are running in production clusters?

You can start from built-in templates and save your own. It is available with Defender CSPM.

It also acts as a quick incident-response aid: after a breach you can ask which resources an affected identity could reach, and scope the damage within minutes.

Take quiz
The cloud security explorer lets you:
Edit Azure Policy definitions
Query the security graph without writing code
Resize Kubernetes node pools
Block IP addresses at the firewall
Which question suits the explorer best?
What did we spend on storage last month?
Which users have not logged in for 90 days only?
Which exposed VMs have critical vulnerabilities and access to secrets?
How many subnets exist in this VNet?

29. When should you use JIT access instead of Azure Bastion?

They solve related but different problems. Azure Bastion gives browser-based RDP and SSH through a managed service, so the VM needs no public IP at all. JIT access keeps the VM's own management ports closed and opens them briefly for a named requester.

JIT access Azure Bastion
VM needs public IP Often yes, or reachable through a network path No
How access works Temporary NSG or firewall rule Proxy session in the portal
Best for Existing VMs reachable with native clients Private VMs, no inbound exposure

Use JIT when you must keep using native RDP or SSH clients and want time-limited, audited access. Use Bastion when you can remove public exposure entirely. They can also be combined.

Take quiz
Azure Bastion lets you reach a VM:
Only by opening port 3389 to the internet
Only from the same subnet
Without giving the VM a public IP
Only with a VPN client
JIT access is a better fit when you:
Want to remove all remote access
Need to copy files to blob storage
Want to scan container images
Need time-limited access using native RDP or SSH clients

30. How do you exempt a recommendation, and what changes?

Open the recommendation, select the affected resources and choose Exempt. You give a reason, either Waiver (risk accepted) or Mitigated (handled by another control), add an optional expiry date and save.

Exemptions can be scoped to a single resource, a resource group, a subscription or a management group. Once applied, the resource moves to not applicable for that recommendation, so it stops lowering your Secure Score and drops off the open list. The exemption is recorded for audit, and an expiry date makes sure it is reviewed later instead of lasting forever.

A common example is a legacy VM that cannot take an endpoint agent for compatibility reasons but sits behind compensating network controls. Record that justification in the exemption comment.

Take quiz
An exempted resource appears as:
Unhealthy with a red flag
Deleted from inventory
Healthy for every recommendation
Not applicable for that recommendation
Which two reasons does an exemption offer?
Waiver and Mitigated
Duplicate and Archived
Planned and Cancelled
Billing and Support

31. How does continuous export work in Defender for Cloud?

Continuous export streams Defender for Cloud data out of the portal to a destination you control. Configure it under Environment settings, choose the subscription, then pick the data types and the target.

  • Data types: security alerts, recommendations, Secure Score and regulatory compliance data
  • Targets: a Log Analytics workspace or an Azure Event Hub
  • Mode: streaming as events happen, or periodic snapshots of recommendation state

Log Analytics lets you query and build workbooks, while Event Hubs is the route to third-party SIEM tools such as Splunk. Because it is a policy-based setting, you can deploy it at scale with Azure Policy.

Take quiz
Continuous export can send data to:
A Log Analytics workspace or Event Hub
A USB drive
An Azure DevOps wiki
A Power Apps form
Which target would you choose for a third-party SIEM?
Azure Backup vault
Event Hub
Azure Static Web Apps
Azure Cache for Redis

32. How do you integrate Defender for Cloud with Microsoft Sentinel?

Sentinel needs Defender for Cloud's alerts and incidents so analysts can investigate them next to other data. Microsoft's current direction is to bring them in through the Defender XDR connector, which carries Defender for Cloud incidents with their correlated alerts. Older subscription-based and tenant-based Defender for Cloud connectors still exist in many workspaces.

Steps in practice:

  1. Enable the Defender for Cloud plans you need.
  2. In Sentinel, enable the relevant data connector.
  3. Check that alerts appear in the SecurityAlert table.
  4. Build analytics rules, automation rules and playbooks on top.

Avoid enabling several overlapping connectors, which creates duplicate incidents.

Once alerts flow, you can write analytics rules that combine them with identity or firewall logs, for example a Defender for Cloud brute-force alert plus a successful sign-in from the same IP address.

Take quiz
Sentinel's SecurityAlert table is used to confirm:
That VM disks are encrypted
That Defender for Cloud alerts are arriving
That backups finished
That a budget is not exceeded
A risk of enabling overlapping connectors is:
Loss of the Secure Score
Automatic plan deletion
Duplicate incidents
Slower VM boot times

33. How does Defender for Containers protect Kubernetes clusters?

Protection is layered across the container lifecycle:

  1. Discovery and posture: clusters are found agentlessly, and configuration issues become recommendations.
  2. Registry scanning: images in ACR, ECR, Google Artifact Registry and Docker Hub are scanned for vulnerabilities when pushed and rescanned as new CVEs appear.
  3. Runtime protection: a Defender sensor deployed as a DaemonSet watches node and pod behaviour and raises alerts.
  4. Admission control: Azure Policy for Kubernetes can enforce rules, such as blocking privileged containers, at deployment time.

This is why it reports both what could go wrong (image CVEs, risky configuration) and what is going wrong (a reverse shell in a running pod).

Take quiz
The Defender sensor on Kubernetes nodes is typically deployed as a:
Static Web App
Event Grid topic
DaemonSet
Logic App
Registry scanning finds:
Unused DNS records
Expired SSL certificates only
Unpatched Windows laptops
Vulnerabilities in container images

34. How does Defender for Storage detect malware?

When malware scanning is enabled, Defender for Storage scans blobs as they are uploaded using Microsoft Defender Antivirus technology. On-demand scanning is also available for existing data.

Each scan produces a verdict. You can see it as a blob index tag, as an Event Grid event or in Log Analytics, and a security alert is raised for malicious files. This lets you build a pipeline that automatically moves or deletes infected files. Scanning is configured per storage account and can be capped by a monthly gigabyte limit to control cost.

Remember that scanning covers content as it arrives, so pair it with least-privilege access and private endpoints rather than treating it as the only line of defense.

Take quiz
Where can a malware scan verdict appear?
In the VM boot log
In an Azure Policy definition
In the billing invoice
As a blob index tag or an Event Grid event
Why is a monthly scanning limit useful?
To control cost for heavy upload workloads
To speed up VM reboots
To rotate encryption keys
To increase the Secure Score

35. What is the difference between an alert and an incident?

An alert is a single detection, such as a suspicious process on one VM. An incident groups related alerts into one attack story, so an analyst sees the full chain rather than isolated events.

Alert Incident
Scope One detection on one entity Several correlated alerts
Source Defender plan detection logic Correlation across plans and Defender XDR
Used for Understanding a single event Triage, investigation and response

For example, a brute-force alert followed by a suspicious sign-in, then a new admin account, might be merged into one incident. Correlation reduces noise and shortens triage time.

In an interview, mention that you triage at the incident level and use individual alerts only for evidence, since that is how most SOC teams actually work.

Take quiz
An incident differs from an alert because it:
Groups related alerts into one attack story
Is always a false positive
Only exists in the free tier
Is created by Azure Advisor
Which scenario is best handled as one incident?
One VM rebooting
Brute force, then suspicious sign-in, then a new admin account
A disk being resized
A storage account renamed

36. How do governance rules assign ownership for remediation?

Governance rules let you stop chasing owners by hand. A rule says: for recommendations matching these criteria in this scope, automatically assign this owner and require a fix by this date. They are part of Defender CSPM.

A rule defines:

  • Scope - subscriptions, AWS accounts, GCP projects or a connector
  • Criteria - by severity, by specific recommendations or by security control
  • Owner - a named person or an owner taken from a resource tag
  • Remediation timeframe - a due date relative to assignment, with an optional grace period during which the item does not hurt the score

Owners and their managers receive email notifications and reminders, and a weekly digest lists overdue items. Rules are evaluated in priority order, so a specific rule for production should rank above a catch-all rule. The result is a clear accountability trail: every open recommendation has an owner and a deadline, and the Secure Score trend now reflects real team behaviour rather than a central team's effort.

Take quiz
A governance rule assigns:
A subnet to a VM
An owner and a due date to matching recommendations
A budget to a subscription
A TLS version to an App Service
If two governance rules match, which applies?
Both are deleted
The newest rule always wins
The one with the higher priority in the rule order
The one with the longest name

37. How does Defender for Cloud support DevSecOps?

It extends posture management to the pipeline so problems are caught before deployment. You connect GitHub, Azure DevOps or GitLab with a DevOps security connector, and Defender for Cloud starts scanning.

  • Infrastructure-as-code scanning for Terraform, ARM, Bicep, CloudFormation and Kubernetes manifests, with tools such as Checkov
  • Code and dependency scanning through GitHub Advanced Security or partner integrations
  • Pull request annotations that show developers the finding where they work
  • Code-to-cloud mapping that links a runtime resource back to the repository and pipeline that created it

Code-to-cloud mapping is the real payoff. When a container in production has a critical vulnerability, the finding can point to the exact repository and owner, so remediation goes to the team that can fix the source rather than only patching the running instance. Some of these capabilities need the Defender CSPM plan, so confirm licensing for your setup.

Take quiz
Code-to-cloud mapping helps you:
Resize a VM from a pull request
Delete unused subscriptions
Trace a runtime resource back to its source repository
Rotate certificates on a schedule
Where do infrastructure-as-code findings appear for developers?
In the VM serial console
In an invoice PDF
In a DNS zone file
As annotations on pull requests

38. How does Defender for Cloud secure AI workloads?

Two angles apply: posture and threat protection.

AI security posture management discovers generative AI resources and pipelines, such as Azure OpenAI and Azure AI services and, on AWS, Bedrock, then raises recommendations and includes them in attack path analysis. Threat protection for AI services raises alerts on abuse such as jailbreak attempts, prompt injection, credential theft and suspicious data access, with alerts flowing into Defender XDR.

Be aware that this area moves quickly. Reporting from July 2026 says that agent-focused capabilities, including discovery and posture for Microsoft Foundry agents, moved to the separate Agent 365 service from July 1, 2026, with different licensing. In an interview, say what you know and mention that you would verify the current licensing split before advising a customer.

Take quiz
Threat protection for AI services can alert on:
VM disk fragmentation
Subnet overlaps
Unused public IP addresses
Jailbreak and prompt injection attempts
Why should you verify AI feature licensing before advising a customer?
Some agent features moved to Agent 365 in July 2026
AI features are always free
They are only sold with Windows Server
They were removed from all clouds

39. How can you optimize Defender for Cloud costs?

Costs follow what you protect, so tuning is mostly about scoping and plan choice, not turning protection off.

  1. Match plan to risk. Use Defender for Servers Plan 2 for production and Plan 1, or none, for short-lived dev and test machines. Set the plan per resource with tags or resource-level configuration.
  2. Use the included benefits. Plan 2 includes a daily Log Analytics ingestion allowance (500 MB per server), so route Defender data there and avoid paying for it twice.
  3. Scope Defender CSPM. It is billed on billable resources, so apply it to production subscriptions first.
  4. Cap storage scanning. Set a monthly gigabyte limit for malware scanning and avoid enabling it on high-volume accounts without need.
  5. Pre-purchase commit units. The one-year pre-purchase plan gives discounts of up to 22 percent against pay-as-you-go prices.
  6. Review regularly. Remove protection for decommissioned subscriptions and orphaned resources.

Never cut cost by disabling a plan on critical assets. Reduce scope on low-risk ones instead.

Take quiz
Which action reduces cost without removing protection from critical assets?
Using Plan 1 or no plan on short-lived dev and test servers
Disabling Defender on production
Removing all Log Analytics workspaces
Deleting the security contact
The one-year pre-purchase of Defender for Cloud commit units offers:
Free unlimited alerts
Discounts against pay-as-you-go pricing
Automatic plan deletion
A fixed Secure Score

40. Which is better: Defender for Cloud or Microsoft Sentinel?

Neither is better, because they do different jobs and work best together.

Defender for Cloud Microsoft Sentinel
Primary role Posture management and workload protection SIEM and SOAR
Data source Your cloud resources and workloads Any log source, cloud or on-premises
Generates Recommendations and workload alerts Analytics-rule incidents and automations
Used by Cloud security and platform teams SOC analysts and threat hunters

Defender for Cloud tells you what is weak and detects attacks on workloads. Sentinel collects signals from everywhere, including firewalls, identity and SaaS, to correlate across your whole estate. A typical design feeds Defender for Cloud alerts into Sentinel. Choosing one only makes sense for a very small environment.

If an interviewer asks for a one-liner: Defender for Cloud is the sensor and posture engine for your cloud estate, while Sentinel is the central analysis and response layer.

Take quiz
Sentinel is primarily a:
Secure Score calculator
SIEM and SOAR platform
VM patching service
Container registry
The usual way to combine them is to:
Disable Defender when Sentinel is enabled
Use Sentinel to schedule VM backups
Feed Defender for Cloud alerts and incidents into Sentinel
Run Defender on-premises only

41. How do you troubleshoot servers missing Defender for Endpoint protection?

Work from licensing outward to the machine:

  1. Plan and setting: confirm Defender for Servers is on for the subscription and the Defender for Endpoint integration is enabled.
  2. Extension: on Azure and Arc machines check that the MDE extension is installed and healthy.
  3. Operating system: verify the OS version is supported, as older Windows Server versions need the unified solution.
  4. Connectivity: make sure the server can reach the Defender endpoints through any proxy or firewall.
  5. Conflicts: look for another antivirus product, especially on Linux.
  6. Portal view: check the device appears in the Defender portal device inventory.

A quick extension check on an Azure VM:

az vm extension list --resource-group rg-prod --vm-name vm01 --query "[].{name:name,state:provisioningState}" -o table

If the extension shows Failed, review its logs and reinstall after fixing the network or OS issue.

Take quiz
What do you verify first when a server lacks EDR coverage?
The VM's wallpaper
The disk SKU
That Defender for Servers and the MDE integration are enabled
The tag naming convention
A failed MDE extension is often caused by:
Too many resource groups
A missing billing alert
An expired domain name
Blocked connectivity or an unsupported OS

42. Explain the lifecycle of a security alert from detection to response?

An alert passes through five stages:

flowchart LR
  A["Telemetry collected"] --> B["Detection: analytics, ML, threat intelligence"]
  B --> C["Alert raised with severity and MITRE tactic"]
  C --> D["Correlated into an incident"]
  D --> E["Notify or automate: email, Logic App, Sentinel"]
  E --> F["Investigate, contain, remediate, close"]

Detection runs on signals from agents, platform logs and snapshots, using behavioural analytics, machine learning and Microsoft threat intelligence. The alert then carries severity, affected resources and recommended steps.

Related alerts are merged into an incident, and notifications or workflow automations start the response. Analysts investigate, contain the threat, for example by isolating a machine or revoking a key, and then fix the root cause, which often links back to a recommendation. Closing the alert with a classification, such as true or false positive, helps tune detection later.

Take quiz
In which stage are related alerts merged?
Telemetry collection
Closing the alert
Plan enablement
Incident correlation
What should follow containment of a real threat?
Fixing the root cause, often tied to a recommendation
Disabling all alerts
Deleting the subscription
Resetting the Secure Score

43. What is the difference between Fix, Enforce, and Deny on a recommendation?

They are three levels of response to a misconfiguration, and they act on different timelines.

Option What it does When it acts
Fix Applies the remediation to chosen existing resources One-time, on current resources
Enforce Assigns a policy that auto-remediates new resources Going forward, after creation
Deny Blocks deployment of non-compliant resources At creation time, before the resource exists

Fix is a quick clean-up for resources that already exist. Enforce relies on a deploy if not exists Azure Policy, so new resources get corrected automatically. Deny uses an Azure Policy deny effect and stops bad resources entering your environment.

Deny is the strongest and can break pipelines, so try it in audit mode first. Not every recommendation supports all three options.

Take quiz
Which option blocks non-compliant resources at creation time?
Deny
Fix
Exempt
Dismiss
Enforce relies on which Azure mechanism?
Azure Backup schedules
A deploy-if-not-exists Azure Policy
A Kubernetes network policy
A Logic App only

44. How does data-aware security posture work in Defender CSPM?

Defender CSPM discovers where sensitive data lives and uses that fact to rank risk. Sensitive data discovery covers Azure storage and databases and, for multicloud, resources such as AWS S3 buckets and RDS databases.

The scanner samples data in place and identifies sensitive information types, such as credit card or national ID numbers, and can use sensitivity labels from Microsoft Purview. Results do not require copying the data out of your environment. The findings appear as recommendations and, crucially, feed the security graph.

A storage account with sensitive data and public access ranks above one with no sensitive data, and an attack path ending at it is rated higher. This turns a long list of misconfigurations into a priority order based on the value of what is at stake.

Take quiz
Data-aware posture helps you:
Reduce VM sizes
Rank risk higher when sensitive data is exposed
Rotate DNS records
Block outbound email
Sensitive data discovery inspects data:
By exporting it to a USB drive
Only in on-premises file servers
In place, without copying it out
By emailing samples to the owner

45. How do you create custom recommendations and standards?

The approach depends on the cloud.

Cloud Custom recommendations Custom standards
Azure Create a custom Azure Policy definition Group definitions into a custom initiative and add it as a standard
AWS and GCP Write a KQL query against cloud resources in Defender CSPM, with severity and remediation text Group custom recommendations into a custom standard

This is useful when your company has a rule the benchmark does not cover, for example every storage account must carry a cost-centre tag, or only approved regions are allowed. The custom item then appears in the dashboard and compliance view like a built-in one, and can be assigned owners by governance rules. Check current documentation for the exact licensing and preview status of the multicloud KQL feature.

Take quiz
A custom recommendation for an Azure-only rule is built from:
A Logic App
An Event Hub
A custom Azure Policy definition
A VNet peering
Custom recommendations for AWS and GCP use:
Windows PowerShell DSC
Ansible playbooks
SQL stored procedures
KQL queries in Defender CSPM

46. How does Defender for Cloud work with the Defender portal and XDR?

Defender for Cloud's alerts and incidents flow into Microsoft Defender XDR, where they are correlated with endpoint, identity, email and app signals. This gives a single incident for an attack that spans, say, a phishing email and a compromised cloud VM.

Defender XDR advanced hunting also exposes cloud data, including tables for cloud storage events, so you can hunt with KQL across domains. Since a preview announced in late 2025, the cloud security experience has been moving into the unified Defender portal as well, while the Azure portal view continues to exist.

Practically, SOC teams work the incident queue in the Defender portal, and cloud posture teams still use Defender for Cloud for recommendations and plan management. Check the current rollout state before describing where each feature lives.

Take quiz
Defender XDR gives Defender for Cloud alerts:
A lower price
A separate billing tenant
Automatic deletion
Correlation with endpoint, identity and email signals
Advanced hunting in Defender XDR uses which language?
KQL
T-SQL only
Bash
YAML

47. How do you query Defender for Cloud data with Azure Resource Graph?

Defender for Cloud writes its assessments, alerts and Secure Score into the securityresources table in Azure Resource Graph, so you can query them across all subscriptions in seconds with KQL. This example counts unhealthy assessments by recommendation name:

securityresources
| where type == "microsoft.security/assessments"
| extend status = tostring(properties.status.code)
| where status == "Unhealthy"
| summarize count() by tostring(properties.displayName)
| order by count_ desc

Run it in the Azure portal Resource Graph Explorer or with az graph query. It is handy for custom reports and compliance evidence. Sub-assessments, such as individual vulnerability findings, have their own type under the same table.

You can also join assessments with the resources table to add tags or resource names, which makes reports for specific application owners straightforward.

Take quiz
Defender for Cloud assessments are stored in which Resource Graph table?
securityresources
advisorrecommendations
networkresources
authorizationresources
The query above returns:
VM CPU usage per hour
Unhealthy assessments counted by recommendation name
Storage cost per region
Sign-in failures per user

48. How does risk prioritization rank recommendations?

With Defender CSPM, recommendations are ranked by risk level rather than only by static severity. Risk takes into account how likely a weakness is to be exploited and how much damage would follow.

Factors include whether the resource is exposed to the internet, whether a known vulnerability is exploitable, how valuable the resource is (for example, it holds sensitive data), and whether it has privileged access or a path to other assets. A medium-severity issue on an exposed server with sensitive data can outrank a high-severity one on an isolated test machine.

The practical benefit is a short, ordered work queue. Teams fix the handful of items that open real attack paths first, instead of working through a Secure Score checklist item by item.

Take quiz
Risk-based ranking favours issues that are:
Alphabetically first
Exposed, exploitable and tied to valuable assets
Oldest in the list
On the smallest VM size
Why might a medium-severity finding outrank a high-severity one?
It was created later
It has a shorter name
It sits on an exposed resource that holds sensitive data
It belongs to a free plan

49. How do you roll out Defender for Cloud across hundreds of subscriptions?

Avoid clicking through each subscription. Standardise through management groups and code.

Step Approach
Scope Assign settings at the management group so new subscriptions inherit them
Enable plans Use the built-in Azure Policy initiatives that configure Defender plans (deploy if not exists)
Multicloud Onboard AWS organizations and GCP organizations with a connector, not account by account
Contacts and export Deploy security contacts and continuous export through policy
Access Use RBAC and cloud scopes so each team sees only its own environment
Monitor Track policy compliance for the plans and a Secure Score trend

Pilot on a few subscriptions, review the cost and alert volume, then widen the scope. Keep the configuration in Bicep or Terraform so drift is easy to detect. Plans that need extensions, such as agentless scanning, should be set in the same code.

Take quiz
Why assign settings at a management group?
It disables Defender for older subscriptions
It removes the need for RBAC
New subscriptions inherit them automatically
It makes plans free
What is a sound rollout pattern?
Enable everything everywhere on day one
Enable only on Fridays
Skip cost review
Pilot on a few subscriptions, review cost and alerts, then widen

50. How do you reduce false-positive alerts without losing coverage?

Tune, do not switch off. The steps in order are:

  1. Investigate first. Confirm the alert really is benign, for example a known admin tool or a penetration test.
  2. Create a suppression rule scoped as tightly as possible: one alert type, specific entities such as a host or account, and an expiry date.
  3. Fix the cause. If a vulnerability scanner triggers port-scan alerts, allow-list that scanner's address in the suppression rule rather than ignoring the alert type everywhere.
  4. Classify alerts as false positive or benign true positive when closing them, which gives you data to tune later.
  5. Review regularly. Expired or stale suppression rules should not hide real attacks.

Never suppress by severity alone or tenant-wide. In Sentinel or Defender XDR, automation rules can auto-close known-benign patterns with an audit trail. A broad suppression is the quickest way to create a blind spot an attacker can use.

Take quiz
What is the safest way to suppress a noisy alert?
Disabling the whole Defender plan
Suppressing by severity across the tenant
Deleting the alert history
A narrowly scoped suppression rule with an expiry date
Why classify closed alerts as false positive or benign?
It gives data to tune detections later
It raises the Secure Score
It deletes the resource
It changes the billing tier
«
»

Comments & Discussions