Share via

Restricting Azure Resource Operations by IP After Azure Portal Authentication

U R 20 Reputation points
2026-03-17T00:20:20.9833333+00:00

It is possible to restrict IP addresses before authentication by using Conditional Access policies.

In this context, we would like to know whether it is possible to restrict resource operations by IP address after authentication (after logging in to the Azure Portal).

Is this possible?

Or is the only option to configure IP restrictions on the resource side through network settings? Alternatively, is it possible to implement this using Azure Policy?

Microsoft Security | Microsoft Entra | Microsoft Entra ID

1 answer

Sort by: Most helpful
  1. Q&A Assist
    2026-03-17T00:20:32.4766667+00:00
    AI generated content. This question contains an answer created with AI from Q&A Assist. Learn more

    Conditional Access can already evaluate IP/location both at initial sign-in and on refresh-token use, so it is the built‑in way to restrict access to Azure management endpoints (Azure portal, ARM, CLI, PowerShell) by IP at and after authentication.

    Specifically:

    • Conditional Access policies can be applied to the Azure management “cloud apps” (Azure portal, Azure Resource Manager APIs, Azure PowerShell, Azure CLI, etc.) and can require that users access them only from approved locations (IP ranges) and/or require MFA or compliant devices.
    • Location conditions are evaluated when the user signs in and again when a refresh token is used to get a new access token (by default about once an hour). This means a change in client IP is detected and enforced during the session lifecycle, not only at the very first sign‑in.

    However:

    • Conditional Access evaluates authentication and token issuance, not individual resource data‑plane operations.
    • For data‑plane or resource‑specific traffic (for example, Cosmos DB, storage, app backends), IP restrictions must be implemented on the resource side (firewalls, virtual networks, WAF rules, etc.).
    • Azure Policy is for governance/compliance of resource configuration (for example, enforcing that certain network/firewall settings are present), not for per‑request IP filtering at runtime.

    So, to restrict operations by IP after portal login:

    • Use Microsoft Entra Conditional Access to restrict and condition access to Azure management endpoints by IP/location (and other signals) across the session.
    • Use each resource’s own network/firewall features (IP firewall, VNet integration, WAF IP rules, etc.) to restrict data‑plane access.
    • Use Azure Policy only to enforce that those network/firewall configurations are in place, not as a runtime IP filter.

    References:

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.