Question

Difficulty: EasySecure API Management Endpoints

A developer needs to configure security for a specific endpoint in Azure API Management. The endpoint must only accept requests from a partner's office network (subnet 198.51.100.0/24198.51.100.0/24) and must verify that the request contains a valid subscription key.

Which two configuration settings or policy definitions must be applied within Azure API Management to enforce these security controls?

  1. Define the `ip-filter` policy inside the `<inbound>` element of the API policy.Answer
  2. Select the 'Require subscription' check box in the settings of the API.Answer
  3. C
    Define the `ip-filter` policy inside the `<outbound>` element of the API policy.
  4. D
    Configure a system-assigned managed identity for the client application to bypass the IP restriction.
  5. E
    Create an Azure Key Vault access policy that allows the API Management gateway to read secrets.

Answer

Defining the `ip-filter` policy inside the `<inbound>` element of the API policy and selecting the 'Require subscription' check box in the settings of the API.
To restrict access by IP address, the `ip-filter` policy must be configured within the `<inbound>` block, which evaluates incoming requests before forwarding them to the backend. To enforce key validation, the 'Require subscription' setting must be enabled on the API, which ensures that Azure API Management validates the presence of a valid subscription key in the request headers or query parameters.

Step-by-Step Solution

1
Determine where to apply IP restrictions in the API gateway policy definition.
The restriction must be evaluated before the request reaches the backend service, which means using the `ip-filter` policy inside the `<inbound>` element.
Incoming requests need to be validated at the entry point of the gateway.
2
Determine how to enforce API key validation on incoming client requests.
Enable the 'Require subscription' property on the API or its containing product.
This configuration instructs the API Management gateway to verify that a valid subscription key is supplied in the request headers or query string.

Key Concept

Securing API Management endpoints using IP filtering and subscription key enforcement.
Rate this question