CertSafari
    Snowflake SnowPro Advanced: Security Engineer (SEA-C01)· Lessons

    Domain 1 · Lesson 3/21

    Snowflake network rules and network policies

    Implement network security controls.

    16 min read
    5.5% of exam
    2 sources
    Published 20 Oct 2026
    Docs as of 18 Oct 2026

    What you will be able to do

    • Choose the right network rule TYPE and MODE for ingress, internal-stage and egress traffic
    • Predict whether a request is allowed when a network policy has both allowed and blocked rules
    • Work out which network policy applies when policies are set on the account, a user and a security integration
    • Build a policy that allows only a private endpoint and blocks all public traffic on AWS, Azure or Google Cloud

    Key concept

    Network rule versus network policy — A network rule is a schema-level object that only groups network identifiers of one TYPE, such as IPv4 ranges or VPC endpoint IDs. Whether those identifiers are allowed or blocked is decided by the network policy that lists the rule, and the policy has no effect until it is activated on an account, user or security integration.

    1.Why inbound traffic needs a network policy

    A new Snowflake account accepts connections from anywhere. With no network policy in place, a stolen password works just as well from an unknown laptop as from the corporate office, because nothing checks where a request comes from. A network policy closes that gap. It controls inbound access to the Snowflake service and to the internal stage, and only a security administrator (or a higher role) can use one.

    A policy is built in three steps, and the third step is the one people forget:

    1. Create network rules that group identifiers by purpose and by type.
    2. Create a network policy that lists those rules in its allowed list or its blocked list.
    3. Activate the policy on the account, a user or a security integration.

    A policy that has been created but not activated restricts nothing. When you troubleshoot a policy that seems to be ignored, first check whether it was ever attached to anything.

    Network policies govern traffic coming into Snowflake. Traffic going out, such as a UDF calling an external API, is handled by a different feature, external network access. That feature also uses network rules, but it uses them in a different mode.

    Checkpoint 1 of 9· Put it in order

    A security administrator wants to stop logins from outside the corporate office. Put the steps for controlling inbound traffic with a network policy in the correct order.

    1. 1.Activate the network policy on the account, a user or a security integration
    2. 2.Create a network policy that lists those network rules in its allowed list or blocked list
    3. 3.Create network rules that group the allowed office IP ranges by purpose and identifier type

    Sources1

    2.Network rule TYPE and MODE

    TYPE says what kind of identifier a rule holds, and a single rule never mixes kinds. A rule with TYPE = IPV4 takes addresses or CIDR ranges such as 192.168.1.0/24. IPV6 takes IPv6 addresses and is available only on AWS. AWSVPCEID takes AWS VPC endpoint IDs, and plain VPC IDs are not accepted. AZURELINKID takes the LinkIDs of Azure private endpoints. GCPPSCID takes the pscConnectionIDs of Google Cloud Private Service Connect endpoints. COMPUTE_POOL takes Snowpark Container Services compute pool names. For outbound traffic, HOST_PORT takes domains with an optional port. The port defaults to 443, and example.com:0 allows every port.

    MODE says which traffic the feature using the rule controls. For network policies, MODE also sets how far the protection reaches. The same IPv4 rule can protect only the service, or the service and the AWS internal stage as well, depending on an account parameter.

    Network rule modes and what each one protects
    MODEUsed byWhat it controlsConditions
    INGRESSNetwork policySnowflake service. With IPV4 it can also cover an AWS internal stageStage coverage needs ENFORCE_NETWORK_RULES_FOR_INTERNAL_STAGES. IPV6, AWSVPCEID, AZURELINKID and GCPPSCID rules protect the service only
    INTERNAL_STAGENetwork policyAWS internal stage, without restricting the serviceENFORCE_NETWORK_RULES_FOR_INTERNAL_STAGES enabled and TYPE must be AWSVPCEID
    SNOWFLAKE_MANAGED_STORAGE_VOLUMENetwork policyAWS Snowflake-managed storage volume, without restricting the serviceENFORCE_NETWORK_RULES_FOR_SNOWFLAKE_MANAGED_STORAGE_VOLUME enabled and TYPE must be AWSVPCEID
    EGRESSExternal access integrationRequests sent from Snowflake by a UDF or procedureNot used to restrict inbound connections

    Network rules are schema objects, so creating one needs the CREATE NETWORK RULE privilege on the schema. By default only ACCOUNTADMIN, SECURITYADMIN and the schema owner have that privilege. To delegate the work, grant it to a custom role, as in the example below. Keep rules small and purpose-built, for example one per region or one for privileged service users, and record each rule's purpose in COMMENT. SHOW NETWORK RULES then lists every rule with its comment.

    A custom role creating an IPv4 ingress rulesql
    GRANT CREATE NETWORK RULE ON SCHEMA securitydb.myrules TO ROLE network_admin; USE ROLE network_admin; CREATE NETWORK RULE cloud_network TYPE = IPV4 MODE = INGRESS VALUE_LIST = ('47.88.25.32/27');

    Checkpoint 2 of 9· Check yourself

    On an AWS-hosted account, a network policy already allows a network rule with TYPE = AWSVPCEID and MODE = INGRESS. The team now also wants the internal stage reachable only through that same VPC endpoint. What do they need to do?

    Checkpoint 3 of 9· Exam question

    Which statement correctly describes network rule modes when building a network policy that restricts who can connect to the Snowflake service?

    Sources2

    3.How the allowed and blocked lists are evaluated

    An allowed list blocks everything else of the same type. If the only IPv4 rule in ALLOWED_NETWORK_RULE_LIST holds a single address, every other IPv4 address is refused. You do not need to add a blocked rule for the rest of the internet. The blocked list exists to cut exceptions out of a range you have allowed.

    The blocked list wins. When an address matches both lists, Snowflake applies the blocked values first and refuses the request. It makes no difference that the address sits inside an allowed range. The example below uses this to allow a /24 range except for one host. Addresses outside the /24 are refused too, because the allowed list already excludes them.

    Allow a range, carve out one addresssql
    CREATE NETWORK RULE allow_access_rule
      MODE = INGRESS
      TYPE = IPV4
      VALUE_LIST = ('192.168.1.0/24');
    
    CREATE NETWORK RULE block_access_rule
      MODE = INGRESS
      TYPE = IPV4
      VALUE_LIST = ('192.168.1.99');
    
    CREATE NETWORK POLICY public_network_policy
      ALLOWED_NETWORK_RULE_LIST = ('allow_access_rule')
      BLOCKED_NETWORK_RULE_LIST=('block_access_rule');

    A policy that has both IPv4 and IPv6 rules evaluates each type on its own. A request that arrives over IPv6 when the policy has no IPv6 rules is checked against the IPv4 rules only. IPv6 clients can connect at all only after ENABLE_DUAL_STACK_LOAD_BALANCER is set to TRUE.

    Older policies built with ALLOWED_IP_LIST and BLOCKED_IP_LIST still work, and the blocked-first behaviour applies to them too. New policies should use network rules, and one policy should not mix the two methods. Pre-rule policies also can no longer be edited in Snowsight. Use ALTER NETWORK POLICY for them.

    Checkpoint 4 of 9· Check yourself

    A network policy has one IPv4 rule in ALLOWED_NETWORK_RULE_LIST. That rule holds only the office address 203.0.113.10, and the blocked list is empty. The policy is active on the account. An engineer wants to add a blocked rule for 0.0.0.0/0 so that the rest of the internet is refused. What should you tell them?

    Checkpoint 5 of 9· Exam question

    A network policy lists rule corp_allowed (TYPE IPV4, MODE INGRESS, 10.20.0.0/16) in ALLOWED_NETWORK_RULE_LIST and rule quarantine (TYPE IPV4, MODE INGRESS, 10.20.5.0/24) in BLOCKED_NETWORK_RULE_LIST. A user connects from 10.20.5.9. What is the outcome?

    Sources1

    4.Account, user and security integration: which policy applies

    The most specific policy replaces the more general ones. It does not stack on top of them. You can activate a policy on the account, on a user or on a security integration. When more than one applies to a request, Snowflake uses only the most specific one. A user-level policy overrides the account policy. A security-integration policy overrides both.

    Order of precedence for activated network policies
    Activated onOverridesOverridden by
    AccountNothing (most general)User and security integration policies
    UserAccount policySecurity integration policy
    Security integrationAccount and user policiesNothing (most specific)

    Here is a worked case. The account policy allows only the office range 203.0.113.0/24. A service user has its own policy that allows 198.51.100.0/24. When that user connects from 198.51.100.17, the login succeeds. For this user the account policy is never read, so the user's address does not need to appear in it. The same override solves a common problem with integrations. If an identity provider's calls through a security integration are refused by a strict account policy, attach a policy to that integration. You do not need to loosen the account policy.

    Two exceptions are easy to miss. For Snowflake OAuth, client-to-Snowflake traffic such as token requests ignores the user-level policy. Only the integration-level and account-level policies apply, except for the built-in SNOWFLAKE$LOCAL_APPLICATION integration, which also enforces the user policy. The other exception is MINS_TO_BYPASS_NETWORK_POLICY. This user property temporarily bypasses a policy, it is visible in DESCRIBE USER, and only Snowflake Support can set it.

    Checkpoint 6 of 9· Match them up

    Match each place a network policy can be activated, plus one special case, to how Snowflake decides which policy applies.

    Tap a term, then the definition that fits it.

    Checkpoint 7 of 9· Exam question

    An account-level network policy allows only the corporate range 203.0.113.0/24 through an ingress network rule. The service user svc_etl has its own user-level network policy that allows 198.51.100.0/24, and no other policies exist. What happens when svc_etl connects from 198.51.100.17?

    Sources1

    5.Private endpoint rules and blocking public access

    For requests that arrive over private connectivity, private endpoint rules take precedence over IP rules. Suppose a request comes in over private connectivity and the allowed list contains an AWSVPCEID or AZURELINKID rule. Snowflake then ignores every IPV4 and IPV6 rule in the policy, whether the rule holds public or private ranges.

    The reverse is not true. A private endpoint rule has no effect on public traffic. Allowing a VPCE ID does not block the public internet, so a team that only adds the endpoint rule has left public logins open. To allow only the endpoint, you need two rules: the endpoint rule in the allowed list, and an IPv4 rule for 0.0.0.0/0 in the blocked list.

    Allow one VPC endpoint and block all public IPv4 trafficsql
    CREATE NETWORK RULE block_public_access
      MODE = INGRESS
      TYPE = IPV4
      VALUE_LIST = ('0.0.0.0/0');
    
    CREATE NETWORK RULE allow_vpceid_access
      MODE = INGRESS
      TYPE = AWSVPCEID
      VALUE_LIST = ('vpce-0fa383eb170331202');
    
    CREATE NETWORK POLICY allow_vpceid_block_public_policy
      ALLOWED_NETWORK_RULE_LIST = ('allow_vpceid_access')
      BLOCKED_NETWORK_RULE_LIST=('block_public_access');

    Shared endpoints need a finer filter. When several VPCs, VNets or business units reach Snowflake through one endpoint or transit gateway, an INGRESS rule of type AWSVPCEID, AZURELINKID or GCPPSCID can use the tuple form {private_link_id:ip_or_cidr,...}. Snowflake then matches the endpoint ID and the private IP together. This still works when private ranges overlap. If each endpoint maps to exactly one VPC, a plain endpoint rule is enough.

    Snowpark Container Services services that use customer-provided credentials are a separate case. Their requests are checked only against COMPUTE_POOL rules, so even 0.0.0.0/0 in the allowed list does not let them in. Without a matching compute pool rule they fail with error 390422.

    Checkpoint 8 of 9· Fill the gap

    This policy should let in only traffic from one VPC endpoint and refuse every public IPv4 address. Which keyword completes the last line?

    CREATE NETWORK RULE block_public_access
      MODE = INGRESS
      TYPE = IPV4
      VALUE_LIST = ('0.0.0.0/0');
    
    CREATE NETWORK RULE allow_vpceid_access
      MODE = INGRESS
      TYPE = AWSVPCEID
      VALUE_LIST = ('vpce-0fa383eb170331202');
    
    CREATE NETWORK POLICY allow_vpceid_block_public_policy
      ALLOWED_NETWORK_RULE_LIST = ('allow_vpceid_access')
       ? =('block_public_access');

    Sources12

    6.Enforcing the same policy design on AWS, Azure and Google Cloud

    The pattern is the same on every cloud. What changes is the identifier type and how far each rule reaches. An organization with accounts on all three clouds can apply one standard everywhere: allow the private endpoint, block 0.0.0.0/0, and activate the policy narrowly. Each account then needs the endpoint type for its own cloud, and the internal stage needs separate handling on each.

    Per-cloud differences in network rule enforcement
    CloudPrivate endpoint TYPEWhere to find the IDInternal stage restriction by network rule
    AWSAWSVPCEID (VPC IDs not supported)VPCE ID of the VPC endpointYes: INTERNAL_STAGE mode, or IPV4 INGRESS once ENFORCE_NETWORK_RULES_FOR_INTERNAL_STAGES is enabled
    AzureAZURELINKIDSYSTEM$GET_PRIVATELINK_AUTHORIZED_ENDPOINTSNo: you can only block all public traffic to the stage
    Google CloudGCPPSCIDpscConnectionID from gcloud compute forwarding-rules describeNot via INGRESS: GCPPSCID rules protect the service only

    IPv6 is a further AWS-only difference. IPv6 rules support only INGRESS mode and never protect internal stages, so a policy that copies IPv6 rules into an Azure or Google Cloud account protects nothing there.

    Checkpoint 9 of 9· Match them up

    An organization uses the same policy design on Snowflake accounts in all three clouds: allow the private endpoint and block 0.0.0.0/0. For each cloud or rule, pick the statement that describes how it behaves.

    Tap a term, then the definition that fits it.

    Sources2

    Sources

    (2)

    Every claim above is drawn from one of these pages, quoted as it was written on the date shown.

    1. 1.
      “By default, Snowflake allows users to connect to the service and internal stage from any computer or device.”
      ↩︎ Why inbound traffic needs a network policy
      “A network policy doesn’t restrict network traffic until it is activated.”
      ↩︎ Why inbound traffic needs a network policy
      “if you add an IPv4 network rule with a single IP address to the allowed list, all other IPv4 addresses are blocked.”
      ↩︎ How the allowed and blocked lists are evaluated
      “Snowflake applies the values in the BLOCKED_IP_LIST parameter first. This behavior also applies to the ALLOWED_NETWORK_RULE_LIST and the BLOCKED_NETWORK_RULE_LIST parameters.”
      ↩︎ How the allowed and blocked lists are evaluated
      “If a request arrives over IPv6 and no IPv6 network rules are present in the policy, the request is evaluated against IPv4 rules only.”
      ↩︎ How the allowed and blocked lists are evaluated
      “all new network policies should use network rules, not the ALLOWED_IP_LIST and BLOCKED_IP_LIST parameters, to control access from IP addresses.”
      ↩︎ How the allowed and blocked lists are evaluated
      “the most specific network policy overrides more general network policies”
      ↩︎ Account, user and security integration: which policy applies
      “Network policies applied to a security integration are the most specific network policies. They override both accounts and users.”
      ↩︎ Account, user and security integration: which policy applies
      “For Snowflake OAuth, the user-level network policy is not considered for client-to-Snowflake traffic such as token requests.”
      ↩︎ Account, user and security integration: which policy applies
      “Only Snowflake can set the value for this object property.”
      ↩︎ Account, user and security integration: which policy applies
      “Whenever possible, narrowly scope a network policy to a group of users or a security integration rather than an entire account.”
      ↩︎ Account, user and security integration: which policy applies
      “then all IPV4 and IPV6 network rules that contain public or private IP ranges are ignored.”
      ↩︎ Private endpoint rules and blocking public access
      “you must create two separate network rules, one for the allowed list and another for the blocked list.”
      ↩︎ Private endpoint rules and blocking public access
      “are evaluated only against network rules of type COMPUTE_POOL.”
      ↩︎ Private endpoint rules and blocking public access
      “Network policies applied to a user override network policies applied to the account”
      ↩︎ Exam trap 1
      “to restrict access has no effect on requests coming from the public network”
      ↩︎ Exam trap 2
      “Activate the network policy for an account, user, or security integration. A network policy doesn’t restrict network traffic until it is activated.”
      ↩︎ Checkpoint
      “This behavior also applies to the ALLOWED_NETWORK_RULE_LIST and the BLOCKED_NETWORK_RULE_LIST parameters.”
      ↩︎ Prediction
      “Network policies applied to a user override network policies applied to the account, but are overridden by a network policy applied to a security integration.”
      ↩︎ Checkpoint
    2. 2.
      “If TYPE=IPV4, by default the network rule controls access to the Snowflake service only.”
      ↩︎ Network rule TYPE and MODE
      “The TYPE property of the network rule must be AWSVPCEID.”
      ↩︎ Network rule TYPE and MODE
      “By default, only the ACCOUNTADMIN and SECURITYADMIN roles, along with the schema owner, have this privilege.”
      ↩︎ Network rule TYPE and MODE
      “Snowflake evaluates the combination of the PrivateLink ID and private IP, not the IP alone, to allow or block traffic.”
      ↩︎ Private endpoint rules and blocking public access
      “If TYPE=AWSVPCEID, TYPE=AZURELINKID, or TYPE=GCPPSCID, then the network rule controls access to the Snowflake service only.”
      ↩︎ Enforcing the same policy design on AWS, Azure and Google Cloud
      “Execute the SYSTEM$GET_PRIVATELINK_AUTHORIZED_ENDPOINTS function to retrieve the LinkID associated with an account.”
      ↩︎ Enforcing the same policy design on AWS, Azure and Google Cloud
      “IPv6 network rules only support the INGRESS mode and don’t protect internal stages.”
      ↩︎ Enforcing the same policy design on AWS, Azure and Google Cloud
      “A network rule does not define whether its identifiers should be allowed or blocked.”
      ↩︎ Key concept
      “For accounts on Microsoft Azure, you cannot use a network rule to restrict access to the internal stage.”
      ↩︎ Exam trap 3
      “the EGRESS mode indicates the network rule will be used with an external access integration to restrict outgoing requests”
      ↩︎ Exam trap 4
      “you must create a separate network rule by using the INTERNAL_STAGE mode.”
      ↩︎ Checkpoint
      “For accounts on Microsoft Azure, you cannot use a network rule to restrict access to the internal stage.”
      ↩︎ Checkpoint

    Continue to part 2 of 2

    Private connectivity and storage integrations in Snowflake

    Spotted a mistake, or was something unclear? Tell us.