Skip to content

Commit 4156d7c

Browse files
Merge pull request #233441 from dlepow/defend
[APIM] Defender for APIs preview
2 parents dd99912 + a2f15dd commit 4156d7c

File tree

8 files changed

+129
-5
lines changed

8 files changed

+129
-5
lines changed

articles/api-management/TOC.yml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,13 @@
8585
href: /security/benchmark/azure/baselines/api-management-security-baseline?toc=/azure/api-management/&bc=/azure/api-management/breadcrumb/toc.json
8686
- name: Authentication and authorization options
8787
href: authentication-authorization-overview.md
88+
- name: API security
89+
items:
90+
- name: Defender for APIs (preview)
91+
href: protect-with-defender-for-apis.md
92+
- name: Mitigate OWASP API threats
93+
href: mitigate-owasp-api-threats.md
94+
displayName: OWASP top 10, vulnerability, vulnerabilities
8895
- name: API authorizations
8996
href: authorizations-overview.md
9097
displayName: OAuth
@@ -298,10 +305,7 @@
298305
href: api-management-howto-manage-protocols-ciphers.md
299306
- name: Defend against DDoS attacks
300307
href: protect-with-ddos-protection.md
301-
- name: Mitigate OWASP API threats
302-
href: mitigate-owasp-api-threats.md
303-
displayName: OWASP top 10, vulnerability, vulnerabilities
304-
- name: Configure API authorizations for OAuth 2.0 backends
308+
- name: Manage API authorizations
305309
items:
306310
- name: Configure common authorization providers
307311
href: authorizations-configure-common-providers.md

articles/api-management/api-management-gateways-overview.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@ The following table compares features available in the managed gateway versus th
7676
| [TLS settings](api-management-howto-manage-protocols-ciphers.md) | ✔️ | ✔️ | ✔️ |
7777
| **HTTP/2** (Client-to-gateway) ||| ✔️ |
7878
| **HTTP/2** (Gateway-to-backend) ||| ✔️ |
79+
| API threat detection with [Defender for APIs](protect-with-defender-for-apis.md) | ✔️ |||
7980

8081
<sup>1</sup> Depends on how the gateway is deployed, but is the responsibility of the customer.<br/>
8182
<sup>2</sup> Connectivity to the self-hosted gateway v2 [configuration endpoint](self-hosted-gateway-overview.md#fqdn-dependencies) requires DNS resolution of the default endpoint hostname; custom domain name is currently not supported.<br/>
192 KB
Loading
233 KB
Loading
175 KB
Loading
170 KB
Loading

articles/api-management/mitigate-owasp-api-threats.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description: Learn how to protect against common API-based vulnerabilities, as i
44
author: mikebudzynski
55
ms.service: api-management
66
ms.topic: conceptual
7-
ms.date: 05/31/2022
7+
ms.date: 04/13/2023
88
ms.author: mibudz
99
---
1010

@@ -14,6 +14,9 @@ The Open Web Application Security Project ([OWASP](https://owasp.org/about/)) Fo
1414

1515
The OWASP [API Security Project](https://owasp.org/www-project-api-security/) focuses on strategies and solutions to understand and mitigate the unique *vulnerabilities and security risks of APIs*. In this article, we'll discuss recommendations to use Azure API Management to mitigate the top 10 API threats identified by OWASP.
1616

17+
> [!NOTE]
18+
> In addition to following the recommendations in this article, you can enable Defender for APIs (preview), a capability of [Microsoft Defender for Cloud](/azure/defender-for-cloud/defender-for-cloud-introduction), for API security insights, recommendations, and threat detection. [Learn more about using Defender for APIs with API Management](protect-with-defender-for-apis.md)
19+
1720
## Broken object level authorization
1821

1922
API objects that aren't protected with the appropriate level of authorization may be vulnerable to data leaks and unauthorized data manipulation through weak object access identifiers. For example, an attacker could exploit an integer object identifier, which can be iterated.
@@ -308,7 +311,10 @@ More information about this threat: [API10:2019 Insufficient logging and monito
308311

309312
## Next steps
310313

314+
Learn more about:
315+
311316
* [Authentication and authorization in API Management](authentication-authorization-overview.md)
312317
* [Security baseline for API Management](/security/benchmark/azure/baselines/api-management-security-baseline)
313318
* [Security controls by Azure policy](security-controls-policy.md)
314319
* [Landing zone accelerator for API Management](/azure/cloud-adoption-framework/scenarios/app-platform/api-management/landing-zone-accelerator)
320+
* [Microsoft Defender for Cloud](/azure/defender-for-cloud/defender-for-cloud-introduction)
Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
---
2+
title: Protect APIs in API Management with Defender for APIs
3+
description: Learn how to enable advanced API security features in Azure API Management by using Microsoft Defender for Cloud.
4+
services: api-management
5+
author: dlepow
6+
7+
ms.service: api-management
8+
ms.topic: how-to
9+
ms.date: 04/20/2023
10+
ms.author: danlep
11+
---
12+
# Enable advanced API security features using Microsoft Defender for Cloud
13+
<!-- Update links to D4APIs docs when available -->
14+
15+
Defender for APIs, a capability of [Microsoft Defender for Cloud](/azure/defender-for-cloud/defender-for-cloud-introduction), offers full lifecycle protection, detection, and response coverage for APIs that are managed in Azure API Management. The service empowers security practitioners to gain visibility into their business-critical APIs, understand their security posture, prioritize vulnerability fixes, and detect active runtime threats within minutes.
16+
17+
Capabilities of Defender for APIs include:
18+
19+
* Identify external, unused, or unauthenticated APIs
20+
* Classify APIs that receive or respond with sensitive data
21+
* Apply configuration recommendations to strengthen the security posture of APIs and API Management services
22+
* Detect anomalous and suspicious API traffic patterns and exploits of OWASP API top 10 vulnerabilities
23+
* Prioritize threat remediation
24+
* Integrate with SIEM systems and Defender Cloud Security Posture Management
25+
26+
This article shows how to use the Azure portal to enable Defender for APIs from your API Management instance and view a summary of security recommendations and alerts for onboarded APIs.
27+
28+
[!INCLUDE [api-management-availability-premium-dev-standard-basic](../../includes/api-management-availability-premium-dev-standard-basic.md)]
29+
30+
## Preview limitations
31+
32+
* Currently, Defender for APIs discovers and analyzes REST APIs only.
33+
* Defender for APIs currently doesn't onboard APIs that are exposed using the API Management [self-hosted gateway](self-hosted-gateway-overview.md) or managed using API Management [workspaces](workspaces-overview.md).
34+
* Some ML-based detections and security insights (data classification, authentication check, unused and external APIs) aren't supported in secondary regions in [multi-region](api-management-howto-deploy-multi-region.md) deployments. Defender for APIs relies on local data pipelines to ensure regional data residency and improved performance in such deployments. 
35+
36+
37+
## Prerequisites
38+
39+
* At least one API Management instance in an Azure subscription. Defender for APIs is enabled at the level of a subscription.
40+
* One or more supported APIs must be imported to the API Management instance.
41+
* Role assignment to [enable the Defender for APIs plan](/azure/defender-for-cloud/permissions).
42+
* Contributor or Owner role assignment on relevant Azure subscriptions, resource groups, or API Management instances that you want to secure.
43+
44+
## Onboard to Defender for APIs
45+
46+
Onboarding APIs to Defender for APIs is a two-step process: enabling the Defender for APIs plan for the subscription, and onboarding unprotected APIs in your API Management instances.  
47+
48+
> [!TIP]
49+
> You can also onboard to Defender for APIs directly in the Defender for Cloud interface, where more API security insights and inventory experiences are available.
50+
51+
52+
### Enable the Defender for APIs plan for a subscription
53+
54+
1. Sign in to the [portal](https://portal.azure.com), and go to your API Management instance.
55+
56+
1. In the left menu, select **Microsoft Defender for Cloud (preview)**.
57+
58+
1. Select **Enable Defender on the subscription**.
59+
60+
:::image type="content" source="media/protect-with-defender-for-apis/enable-defender-for-apis.png" alt-text="Screenshot showing how to enable Defender for APIs in the portal." lightbox="media/protect-with-defender-for-apis/enable-defender-for-apis.png":::
61+
62+
1. On the **Defender plan** page, select **On** for the **APIs** plan.
63+
64+
1. Select **Save**.
65+
66+
### Onboard unprotected APIs to Defender for APIs
67+
68+
> [!CAUTION]
69+
> Onboarding APIs to Defender for APIs may increase compute, memory, and network utilization of your API Management instance, which in extreme cases may cause an outage of the API Management instance. Do not onboard all APIs at one time if your API Management instance is running at high utilization. Use caution by gradually onboarding APIs, while monitoring the utilization of your instance (for example, using [the capacity metric](api-management-capacity.md)) and scaling out as needed.
70+
71+
1. In the portal, go back to your API Management instance.
72+
1. In the left menu, select **Microsoft Defender for Cloud (preview)**.
73+
1. Under **Recommendations**, select **Azure API Management APIs should be onboarded to Defender for APIs**.
74+
:::image type="content" source="media/protect-with-defender-for-apis/defender-for-apis-recommendations.png" alt-text="Screenshot of Defender for APIs recommendations in the portal." lightbox="media/protect-with-defender-for-apis/defender-for-apis-recommendations.png":::
75+
1. On the next screen, review details about the recommendation:
76+
* Severity 
77+
* Refresh interval for security findings
78+
* Description and remediation steps
79+
* Affected resources, classified as **Healthy** (onboarded to Defender for APIs), **Unhealthy** (not onboarded), or **Not applicable**, along with associated metadata from API Management
80+
81+
> [!NOTE]
82+
> Affected resources include API collections (APIs) from all API Management instances under the subscription.
83+
84+
1. From the list of **Unhealthy** resources, select the API(s) that you wish to onboard to Defender for APIs.
85+
1. Select **Fix**, and then select **Fix resources**.
86+
:::image type="content" source="media/protect-with-defender-for-apis/fix-unhealthy-resources.png" alt-text="Screenshot of onboarding unhealthy APIs in the portal." lightbox="media/protect-with-defender-for-apis/fix-unhealthy-resources.png":::
87+
1. Track the status of onboarded resources under **Notifications**.
88+
89+
> [!NOTE]
90+
> Defender for APIs takes 30 minutes to generate its first security insights after onboarding an API. Thereafter, security insights are refreshed every 30 minutes.
91+
>
92+
93+
## View security coverage
94+
95+
After you onboard the APIs from API Management, Defender for APIs receives API traffic that will be used to build security insights and monitor for threats. Defender for APIs generates security recommendations for risky and vulnerable APIs.
96+
97+
You can view a summary of all security recommendations and alerts for onboarded APIs by selecting **Microsoft Defender for Cloud (preview)** in the menu for your API Management instance:
98+
99+
1. In the portal, go to your API Management instance and select **Microsoft Defender for Cloud (preview**) from the left menu.
100+
1. Review **Recommendations** and **Security insights and alerts**.
101+
102+
:::image type="content" source="media/protect-with-defender-for-apis/view-security-insights.png" alt-text="Screenshot of API security insights in the portal." lightbox="media/protect-with-defender-for-apis/view-security-insights.png":::
103+
104+
For the security alerts received, Defender for APIs suggests necessary steps to perform the required analysis and validate the potential exploit or anomaly associated with the APIs. Follow the steps in the security alert to fix and return the APIs to healthy status.
105+
106+
## Offboard protected APIs from Defender for APIs
107+
108+
You can remove APIs from protection by Defender for APIs by using Defender for Cloud in the portal. For more information, see the Microsoft Defender for Cloud documentation.
109+
110+
## Next steps
111+
112+
* Learn more about [Defender for Cloud](/azure/defender-for-cloud/defender-for-cloud-introduction)
113+
* Learn how to [upgrade and scale](upgrade-and-scale.md) an API Management instance

0 commit comments

Comments
 (0)