Skip to content

Commit 2258ffc

Browse files
committed
update
1 parent 2edd767 commit 2258ffc

File tree

2 files changed

+72
-30
lines changed

2 files changed

+72
-30
lines changed

articles/security/fundamentals/antimalware-code-samples.md

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,17 @@ ms.date: 09/25/2024
1313
ms.author: mbaldwin
1414
ms.custom: devx-track-azurepowershell, devx-track-arm-template
1515
---
16-
# Enable and configure Microsoft Antimalware for Azure Resource Manager VMs
17-
You can enable and configure Microsoft Antimalware for Azure Resource Manager VMs. This article provides code samples using PowerShell cmdlets.
16+
17+
# Code samples to enable and configure Microsoft Antimalware for Azure
18+
19+
This article provides PowerShell code samples to enable and configure Microsoft Antimalware for different Azure services including:
20+
21+
- Azure Resource Manager VMs
22+
- Azure Service Fabric Clusters
23+
- Azure Cloud Services using Extended Support
24+
- Azure Arc-enabled servers
25+
26+
You can use these samples to deploy and configure the Microsoft Antimalware extension across your Azure environments.
1827

1928
## Deploy Microsoft Antimalware on Azure Resource Manager VMs
2029

@@ -220,4 +229,7 @@ New-AzConnectedMachineExtension -Name "IaaSAntimalware" -ResourceGroupName $reso
220229
```
221230

222231
## Next steps
223-
Learn more about [Microsoft Antimalware](antimalware.md) for Azure.
232+
233+
- [Microsoft Antimalware for Azure Cloud Services and Virtual Machines](antimalware.md)
234+
- [Microsoft Defender for Cloud](/azure/defender-for-cloud/)
235+
- [Microsoft Defender for Cloud - Microsoft Antimalware](/azure/defender-for-cloud/antimalware)

articles/security/fundamentals/antimalware.md

Lines changed: 57 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Microsoft Antimalware for Azure | Microsoft Docs
3-
description: Learn about Microsoft Antimalware for Azure Cloud Services and Virtual Machines. See information about topics like architecture and deployment scenarios.
3+
description: Learn about Microsoft Antimalware for Azure Cloud Services and Virtual Machines. See information about architecture and deployment scenarios.
44
services: security
55
author: msmbaldwin
66
manager: rkarlin
@@ -12,11 +12,12 @@ ms.topic: article
1212
ms.date: 04/24/2025
1313
ms.author: mbaldwin
1414
---
15-
# Microsoft Antimalware for Azure Cloud Services and Virtual Machines
15+
16+
# Microsoft Antimalware for Azure Cloud Services and Virtual Machines (VMs)
1617

1718
Microsoft Antimalware for Azure is a free real-time protection that helps identify and remove viruses, spyware, and other malicious software. It generates alerts when known malicious or unwanted software tries to install itself or run on your Azure systems.
1819

19-
The solution is built on the same antimalware platform as Microsoft Security Essentials (MSE), Microsoft Forefront Endpoint Protection, Microsoft System Center Endpoint Protection, Microsoft Intune, and Microsoft Defender for Cloud. Microsoft Antimalware for Azure is a single-agent solution for applications and tenant environments, designed to run in the background without human intervention. Protection may be deployed based on the needs of application workloads, with either basic secure-by-default or advanced custom configuration, including antimalware monitoring.
20+
The solution is built on the same antimalware platform as Microsoft Security Essentials (MSE), Microsoft Forefront Endpoint Protection, Microsoft System Center Endpoint Protection, Microsoft Intune, and Microsoft Defender for Cloud. Microsoft Antimalware for Azure is a single-agent solution for applications and tenant environments, designed to run in the background without human intervention. Protection can be deployed based on the needs of application workloads, with either basic secure-by-default or advanced custom configuration, including antimalware monitoring.
2021

2122
When you deploy and enable Microsoft Antimalware for Azure for your applications, the following core features are available:
2223

@@ -36,16 +37,35 @@ When you deploy and enable Microsoft Antimalware for Azure for your applications
3637
3738
## Architecture
3839

39-
Microsoft Antimalware for Azure includes the Microsoft Antimalware Client and Service, Antimalware classic deployment model, Antimalware PowerShell cmdlets, and Azure Diagnostics Extension. Microsoft Antimalware is supported on Windows Server 2008 R2, Windows Server 2012, and Windows Server 2012 R2 operating system families. It isn't supported on the Windows Server 2008 operating system, and also isn't supported in Linux.
40+
## Architecture
41+
42+
Microsoft Antimalware for Azure consists of several components:
43+
- The Microsoft Antimalware Client and Service
44+
- Antimalware classic deployment model
45+
- Antimalware PowerShell cmdlets
46+
- Azure Diagnostics Extension
47+
48+
### Platform Support and Deployment
49+
50+
**Virtual Machines:**
51+
- Not installed by default
52+
- Available as an optional security extension through the Azure portal or Visual Studio Virtual Machine configuration
53+
- Supported on Windows Server 2008 R2, Windows Server 2012, and Windows Server 2012 R2
54+
- Not supported on Windows Server 2008 and Linux operating systems
4055

41-
The Microsoft Antimalware Client and Service is installed by default in a disabled state in all supported Azure guest operating system families in the Cloud Services platform. The Microsoft Antimalware Client and Service isn't installed by default in the Virtual Machines platform and is available as an optional feature through the Azure portal and Visual Studio Virtual Machine configuration under Security Extensions.
56+
**Cloud Services:**
57+
- Installed by default in a disabled state on all supported Azure guest operating systems
58+
- Requires explicit activation to protect your cloud service
4259

43-
When using Azure App Service on Windows, the underlying service that hosts the web app has Microsoft Antimalware enabled on it. This is used to protect Azure App Service infrastructure and does not run on customer content.
60+
**Azure App Service:**
61+
- Enabled on the underlying service hosting Windows-based web apps
62+
- Limited to protecting Azure App Service infrastructure only, not customer content
63+
- Not sufficient for complete web application security (implement more security controls as outlined in the [Azure Web Application Security Best Practices](/azure/app-service/security-baseline))
4464

4565
> [!NOTE]
4666
> Microsoft Defender Antivirus is the built-in Antimalware enabled in Windows Server 2016 and above.
47-
> The Azure VM Antimalware extension can still be added to a Windows Server 2016 and above Azure VM with Microsoft Defender Antivirus. In this scenario, the extension applies any optional [configuration policies](antimalware.md#default-and-custom-antimalware-configuration) to be used by Microsoft Defender Antivirus The extension does not deploy any other antimalware services.
48-
> For more information, see the [Samples](antimalware.md#samples) section of this article for more details.
67+
> The Azure VM Antimalware extension can still be added to a Windows Server 2016 and above Azure VM with Microsoft Defender Antivirus. In this scenario, the extension applies any optional [configuration policies](antimalware.md#default-and-custom-antimalware-configuration) to be used by Microsoft Defender Antivirus. The extension does not deploy any other antimalware services.
68+
> For more information about Microsoft Defender Antivirus, see [Code samples to enable and configure Microsoft Antimalware for Azure](antimalware-code-samples.md).
4969
5070
### Microsoft antimalware workflow
5171

@@ -56,9 +76,15 @@ The Azure service administrator can enable Antimalware for Azure with a default
5676
* Virtual Machines and Cloud Services - Using the Antimalware [classic deployment model](/previous-versions/azure/ee460799(v=azure.100))
5777
* Virtual Machines and Cloud Services - Using Antimalware PowerShell cmdlets
5878

59-
The Azure portal or PowerShell cmdlets push the Antimalware extension package file to the Azure system at a predetermined fixed location. The Azure Guest Agent (or the Fabric Agent) launches the Antimalware Extension, applying the Antimalware configuration settings supplied as input. This step enables the Antimalware service with either default or custom configuration settings. If no custom configuration is provided, then the antimalware service is enabled with the default configuration settings. For more information, see the [Samples](antimalware.md#samples) section of this article for more details..
79+
The Azure portal or PowerShell cmdlets push the Antimalware extension package file to the Azure system at a predetermined fixed location. The Azure Guest Agent (or the Fabric Agent) launches the Antimalware Extension, applying the Antimalware configuration settings supplied as input. This step enables the Antimalware service with either default or custom configuration settings. If no custom configuration is provided, then the antimalware service is enabled with the default configuration settings. For more information about Antimalware configuration, see [Code samples to enable and configure Microsoft Antimalware for Azure](antimalware-code-samples.md).
6080

61-
Once running, the Microsoft Antimalware client downloads the latest protection engine and signature definitions from the Internet and loads them on the Azure system. The Microsoft Antimalware service writes service-related events to the system OS events log under the "Microsoft Antimalware" event source. Events include the Antimalware client health state, protection and remediation status, new and old configuration settings, engine updates and signature definitions, and others.
81+
After initialization, the Microsoft Antimalware client automatically retrieves the latest protection engine and signature definitions from the Internet and applies them to your Azure system. The service logs all activity to the operating system event log under the "Microsoft Antimalware" event source. These logs include information about:
82+
83+
* Client health status
84+
* Protection and remediation activities
85+
* Configuration changes
86+
* Engine and signature definition updates
87+
* Other operational events
6288

6389
You can enable Antimalware monitoring for your Cloud Service or Virtual Machine to have the Antimalware event log events written as they're produced to your Azure storage account. The Antimalware Service uses the Azure Diagnostics extension to collect Antimalware events from the Azure system into tables in the customer's Azure Storage account.
6490

@@ -67,13 +93,11 @@ The deployment workflow including configuration steps and options supported for
6793
![Microsoft Antimalware in Azure](./media/antimalware/sec-azantimal-fig1.PNG)
6894

6995
> [!NOTE]
70-
> You can however use PowerShell/APIs and Azure Resource Manager templates to deploy Virtual Machine Scale Sets with the Microsoft Anti-Malware extension. For installing an extension on an already running Virtual Machine, you can use the sample Python script [vmssextn.py](https://github.com/gbowerman/vmsstools#vmssextn). This script gets the existing extension config on the Scale Set and adds an extension to the list of existing extensions on the VM Scale Sets.
71-
>
72-
>
96+
> You can however use PowerShell/APIs and Azure Resource Manager templates to deploy Virtual Machine Scale Sets with the Microsoft Anti-Malware extension. For installing an extension on an already running Virtual Machine, you can use the sample Python script [vmssextn.py](https://github.com/gbowerman/vmsstools#vmssextn). This script gets the existing extension config on the Scale Set and adds an extension to the list of existing extensions on the Azure Virtual Machines Scale Sets.
7397
7498
### Default and Custom Antimalware Configuration
7599

76-
The default configuration settings are applied to enable Antimalware for Azure Cloud Services or Virtual Machines when you don't provide custom configuration settings. The default configuration settings have been pre-optimized for running in the Azure environment. Optionally, you can customize these default configuration settings as required for your Azure application or service deployment and apply them for other deployment scenarios.
100+
The default configuration settings are applied to enable Antimalware for Azure Cloud Services or Virtual Machines when you don't provide custom configuration settings. The default configuration settings are preoptimized for running in the Azure environment. Optionally, you can customize these default configuration settings as required for your Azure application or service deployment and apply them for other deployment scenarios.
77101

78102
The following table summarizes the configuration settings available for the Antimalware service. The default configuration settings are marked under the column labeled "Default."
79103

@@ -120,18 +144,18 @@ To enable and configure the Microsoft Antimalware service using Visual Studio:
120144

121145
3. Right-click **configure** to view the Virtual Machine configuration page
122146

123-
4. Select **Microsoft Antimalware** extension from the dropdown list under **Installed Extensions** and click **Add** to configure with default antimalware configuration.
147+
4. Select **Microsoft Antimalware** extension from the dropdown list under **Installed Extensions** and select **Add** to configure with default antimalware configuration.
124148
![Installed extensions](./media/antimalware/sec-azantimal-fig6.PNG)
125-
5. To customize the default Antimalware configuration, select (highlight) the Antimalware extension in the installed extensions list and click **Configure**.
149+
5. To customize the default Antimalware configuration, select (highlight) the Antimalware extension in the installed extensions list and select **Configure**.
126150

127-
6. Replace the default Antimalware configuration with your custom configuration in supported JSON format in the **public configuration** textbox and click OK.
151+
6. Replace the default Antimalware configuration with your custom configuration in supported JSON format in the **public configuration** textbox and select OK.
128152

129-
7. Click the **Update** button to push the configuration updates to your Virtual Machine.
153+
7. Select the **Update** button to push the configuration updates to your Virtual Machine.
130154

131155
![Virtual Machine configuration extension](./media/antimalware/sec-azantimal-fig7.PNG)
132156

133157
> [!NOTE]
134-
>The Visual Studio Virtual Machines configuration for Antimalware supports only JSON format configuration. For more information, see the [Samples](antimalware.md#samples) section of this article for more details.
158+
> The Visual Studio Virtual Machines configuration for Antimalware supports only JSON format configuration. For more information about sample configurations, see [Code samples to enable and configure Microsoft Antimalware for Azure](antimalware-code-samples.md).
135159
136160
#### Deployment Using PowerShell cmdlets
137161

@@ -143,7 +167,7 @@ To enable and configure Microsoft Antimalware using PowerShell cmdlets:
143167
2. Use the [Set-AzureVMMicrosoftAntimalwareExtension](/powershell/module/servicemanagement/azure/set-azurevmmicrosoftantimalwareextension) cmdlet to enable and configure Microsoft Antimalware for your Virtual Machine.
144168

145169
> [!NOTE]
146-
>The Azure Virtual Machines configuration for Antimalware supports only JSON format configuration. For more information, see the [Samples](antimalware.md#samples) section of this article for more details.
170+
>The Azure Virtual Machines configuration for Antimalware supports only JSON format configuration. For more information about sample configurations, see [Code samples to enable and configure Microsoft Antimalware for Azure](antimalware-code-samples.md).
147171
148172
### Enable and Configure Antimalware Using PowerShell cmdlets
149173

@@ -154,7 +178,7 @@ To enable and configure Microsoft Antimalware using PowerShell cmdlets:
154178
1. Set up your PowerShell environment - Refer to the documentation at <https://github.com/Azure/azure-powershell>
155179
2. Use the [Set-AzureServiceExtension](/powershell/module/servicemanagement/azure/set-azureserviceextension) cmdlet to enable and configure Microsoft Antimalware for your Cloud Service.
156180

157-
For more information, see the [Samples](antimalware.md#samples) section of this article for more details.
181+
For more information about sample PowerShell commands, see [Code samples to enable and configure Microsoft Antimalware for Azure](antimalware-code-samples.md).
158182

159183
### Cloud Services and Virtual Machines - Configuration Using PowerShell cmdlets
160184

@@ -170,7 +194,7 @@ To retrieve the Microsoft Antimalware configuration using PowerShell cmdlets:
170194

171195
### Remove Antimalware Configuration Using PowerShell cmdlets
172196

173-
An Azure application or service can remove the Antimalware configuration and any associated Antimalware monitoring configuration from the relevant Azure Antimalware and diagnostics service extensions associated with the Cloud Service or Virtual Machine.
197+
An Azure application or service can completely remove Microsoft Antimalware protection by uninstalling the relevant extensions from your Cloud Services or Virtual Machines. This process removes both the antimalware protection and associated monitoring settings, completely discontinuing malware protection and event collection for the specified resources.
174198

175199
To remove Microsoft Antimalware using PowerShell cmdlets:
176200

@@ -180,28 +204,30 @@ To remove Microsoft Antimalware using PowerShell cmdlets:
180204

181205
To **enable** antimalware event collection for a virtual machine using the Azure Preview Portal:
182206

183-
1. Click any part of the Monitoring lens in the Virtual Machine blade
184-
2. Click the Diagnostics command on Metric blade
207+
1. Select any part of the Monitoring section in the Virtual Machine details page
208+
2. Select the Diagnostics command in the Metrics section
185209
3. Select **Status** ON and check the option for Windows event system
186-
4. . You can choose to uncheck all other options in the list, or leave them enabled per your application service needs.
210+
4. You can choose to uncheck all other options in the list, or leave them enabled per your application service needs.
187211
5. The Antimalware event categories "Error", "Warning", "Informational", etc., are captured in your Azure Storage account.
188212

189213
Antimalware events are collected from the Windows event system logs to your Azure Storage account. You can configure the Storage Account for your Virtual Machine to collect Antimalware events by selecting the appropriate storage account.
190214

191215
![Metrics and diagnostics](./media/antimalware/sec-azantimal-fig8.PNG)
192216

193217
### Enable and configure Antimalware using PowerShell cmdlets for Azure Resource Manager VMs
218+
194219
To enable and configure Microsoft Antimalware for Azure Resource Manager VMs using PowerShell cmdlets:
195220

196221
1. Set up your PowerShell environment using this [documentation](https://github.com/Azure/azure-powershell) on GitHub.
197222
2. Use the [Set-AzVMExtension](/powershell/module/az.compute/set-azvmextension) cmdlet to enable and configure Microsoft Antimalware for your VM.
198223

199224
The following code samples are available:
200225

201-
- [Deploy Microsoft Antimalware on ARM VMs](antimalware-code-samples.md#enable-and-configure-microsoft-antimalware-for-azure-resource-manager-vms)
226+
- [Deploy Microsoft Antimalware on ARM template VMs](antimalware-code-samples.md#enable-and-configure-microsoft-antimalware-for-azure-resource-manager-vms)
202227
- [Add Microsoft Antimalware to Azure Service Fabric Clusters](antimalware-code-samples.md#add-microsoft-antimalware-to-azure-service-fabric-clusters)
203228

204229
### Enable and configure Antimalware to Azure Cloud Service Extended Support (CS-ES) using PowerShell cmdlets
230+
205231
To enable and configure Microsoft Antimalware using PowerShell cmdlets:
206232

207233
1. Set up your PowerShell environment - Refer to the documentation at <https://github.com/Azure/azure-powershell>
@@ -212,6 +238,7 @@ The following code sample is available:
212238
- [Add Microsoft Antimalware to Azure Cloud Service using Extended Support(CS-ES)](antimalware-code-samples.md#add-microsoft-antimalware-to-azure-cloud-service-using-extended-support)
213239

214240
### Enable and configure Antimalware using PowerShell cmdlets for Azure Arc-enabled servers
241+
215242
To enable and configure Microsoft Antimalware for Azure Arc-enabled servers using PowerShell cmdlets:
216243

217244
1. Set up your PowerShell environment using this [documentation](https://github.com/Azure/azure-powershell) on GitHub.
@@ -222,4 +249,7 @@ The following code samples are available:
222249
- [Add Microsoft Antimalware for Azure Arc-enabled servers](antimalware-code-samples.md#add-microsoft-antimalware-for-azure-arc-enabled-servers)
223250

224251
## Next steps
225-
See [code samples](antimalware-code-samples.md) to enable and configure Microsoft Antimalware for Azure Resource Manager (ARM) virtual machines.
252+
253+
- [Code samples to enable and configure Microsoft Antimalware for Azure](antimalware-code-samples.md)
254+
- [Microsoft Defender for Cloud](/azure/defender-for-cloud/)
255+
- [Microsoft Defender for Cloud - Microsoft Antimalware](/azure/defender-for-cloud/antimalware)

0 commit comments

Comments
 (0)