Allowing public IP ranges in Azure Redis Cache firewall rules exposes the cache to unauthorized internet access, increasing the risk of data exfiltration and lateral movement.
The Ansible modules azure.azcollection.azure_rm_rediscachefirewallrule and azure_rm_rediscachefirewallrule must set start_ip_address and end_ip_address to private IP ranges (RFC1918). Tasks missing these properties or specifying non-private or public IPs are flagged.
If access should be limited to Azure resources, prefer virtual network rules or service endpoints instead of broad IP ranges, and ensure any IP range only includes trusted internal addresses.
Secure configuration example:
- name:allow internal subnet to access redisazure.azcollection.azure_rm_rediscachefirewallrule:name:allow-internalresource_group:my-rgredis_name:my-redisstart_ip_address:10.0.0.1end_ip_address:10.0.0.255
Compliant Code Examples
- name:Create a Firewall rule for Azure Cache for Redisazure_rm_rediscachefirewallrule:resource_group:myResourceGroupcache_name:myRedisCachename:myRulestart_ip_address:192.168.1.1end_ip_address:192.168.1.4
Non-Compliant Code Examples
---- name:Create a Firewall rule for Azure Cache for Redisazure_rm_rediscachefirewallrule:resource_group:myResourceGroupcache_name:myRedisCachename:myRulestart_ip_address:1.2.3.4end_ip_address:2.3.4.5
1
2
rulesets:- Ansible / Azure # Rules to enforce / Azure.
個別デモのリクエスト
Datadogを開始
Ask AI
AI-generated responses may be inaccurate. Verify important info.