You need to restrict traffic from VMScaleSet1 to VMScaleSet2. The solution must meet the virtual networking requirements.
What is the minimum number of custom NSG rules and NSG assignments required? To answer, select the appropriate options in the answer area.
NOTE: Each correct selection is worth one point.

Show answerHide answer
Explanation

Summary:
To restrict traffic from VMScaleSet1 to VMScaleSet2 using Network Security Groups (NSGs) in Azure, a custom deny rule must be applied to block outbound traffic from VMScaleSet1. NSGs are assigned at the subnet or NIC level. The minimum configuration requires one custom NSG rule (deny outbound to VMScaleSet2) and one NSG assignment (to VMScaleSet1’s subnet or NICs), assuming both scale sets are in different subnets.
Correct Option:
Minimum number of custom NSG rules: 1
A single custom rule with priority lower than default allow rules (e.g., priority 100) can deny outbound traffic from VMScaleSet1 to VMScaleSet2’s IP range or subnet.
Default NSG rules allow intra-VNet traffic; one explicit deny rule overrides this for the specific destination.
No additional rules are needed if the goal is only to block VMScaleSet1 → VMScaleSet2.
Minimum number of NSG assignments: 1
Assigning the NSG to VMScaleSet1’s subnet (or all NICs) ensures the deny rule applies to all instances.
VMScaleSet2 does not require an NSG unless additional filtering is needed; the block is enforced at the source.
One assignment on the source (VMScaleSet1) is sufficient and minimal.
Incorrect Option:
Minimum number of custom NSG rules: 2, 3, 4, or 5
More than one rule is unnecessary; a single deny rule with proper source/destination and port settings fully restricts traffic.
Additional rules increase complexity without improving security for this requirement.
Default rules already handle other traffic; only one custom rule is needed to override allow behavior.
Minimum number of NSG assignments: 2, 3, 4, or 5
Assigning NSGs to both scale sets or multiple NICs is redundant; traffic is blocked at the source (VMScaleSet1).
Multiple assignments do not enhance restriction and violate the minimum requirement principle.
Effective deny is achieved with a single NSG on the sending scale set’s subnet or NICs.
Reference:
https://learn.microsoft.com/en-us/azure/virtual-network/network-security-groups-overview
https://learn.microsoft.com/en-us/azure/virtual-network/network-security-group-how-it-works

