Incorrect tagging for rule: terraform:S6383

ALM used : GitHub

  • CI system used github actions
  • Scanner command used when applicable (private details masked)
  • Languages of the repository: Terraform
  • Private repository
  • Getting the rule terraform:S6383 to trigger on azurerm_key_vault
  • create an object of type azurerm_key_vault and assign it rbac_authorization_enabled= true. The name: enable_rbac_authorization has been depreciated and should not be used anymore
  • None that I found so far

Do not share screenshots of logs – share the text itself (bonus points for being well-formatted)!

1 Like

Hey @Stephane_Renou!

Thanks for the report.

Can you share a code snippet? It’s a bit easier for us to work with than a description of code :smiling_face_with_tear:

As you can see on the azure documentation: Terraform Registry

This code should be considered as valid as well:

```
resource "azurerm_key_vault" "kv" {  
  name = "kv"  
  location                    = azurerm_resource_group.example.location
  resource_group_name         = azurerm_resource_group.example.name  
  tenant_id                   = data.azurerm_client_config.current.tenant_id  
  rbac_authorization_enabled = true  
  sku_name                   = "standard"
}
```

where the name rbac_authorization_enabled should be considered as setting correctly the authorization

Hello Stéphane,
thank you very much for your report!

I was able to reproduce this behaviour and I created a ticket to adjust our detection logic to support rbac_authorization_enabled in the future.

Again, thank you very much for your contribution and for helping us improve our product.

Best regards,
Daniel

And that ticket is SONARIAC-2243 :smiley:

Hi again @Stephane_Renou,

Thanks to your report, this issue is now fixed and already solved on SonarQube Cloud.
The fix will also be part of our upcoming SonarQube Server 2025.5 release :tada:

Cheers,
Daniel

thanks for the quick fix

cheers,
Stéphane