PSRule.Rules.Azure icon indicating copy to clipboard operation
PSRule.Rules.Azure copied to clipboard

[RULE] Disable local auth for Redis Cache instances

Open BernieWhite opened this issue 1 year ago • 0 comments

Existing rule

No response

Suggested rule

Redis Cache supports disabling access key-based access by setting the disableAccessKeyAuthentication propety to true.

e.g.

{
    "name": "sfvgsfdfsfsd",
    "type": "Microsoft.Cache/redis",
    "apiVersion": "2024-04-01-preview",
    "location": "eastus",
    "dependsOn": [],
    "properties": {
        "sku": {
            "name": "Standard",
            "family": "C",
            "capacity": 0
        },
        "redisConfiguration": {
            "aad-enabled": "true"
        },
        "enableNonSslPort": false,
        "redisVersion": "6",
        "disableAccessKeyAuthentication": true
    }
}

Pillar

Security

Additional context

Similar rules: https://azure.github.io/PSRule.Rules.Azure/en/rules/Azure.Cosmos.DisableLocalAuth/

  • https://learn.microsoft.com/azure/azure-cache-for-redis/cache-azure-active-directory-for-authentication#disable-access-key-authentication-on-your-cache

BernieWhite avatar Oct 13 '24 23:10 BernieWhite