Open condor47times opened 2 months ago
Hi @condor47times, thanks for opening this issue.
These two publicNetworkAccess
should have the same values, no matter which is changed, it will sync to another. If your scanner works on Azure resources, it should be ok.
For the duplicate keys, we have an in-progress working to turn to use Microsoft.Web/publicNetworkAccess
instead of Microsoft.Web/sites/publicNetworkAccess
. motivation could be found on document
However this will take some more time since we need to upgrade the API version, to invovle Microsoft.Web/publicNetworkAccess
property.
Foy any other questions please leave comments. Thanks
Is there an existing issue for this?
Community Note
Terraform Version
1.5.4
AzureRM Provider Version
3.108
Affected Resource(s)/Data Source(s)
azurerm_logic_app_standard
Terraform Configuration Files
Debug Output/Panic Output
Expected Behaviour
Using Terraform, I expect to be able to configure both Microsoft parameters described below. Especially since policy or best practice scanners may check both parameters.
Microsoft has 2 parameters regarding "publicNetworkAccess" for Logic App Standard:
Using Powershell: you can see the 2 parameters. (get-azresource -id "/subscriptions/xxxxxxxxxxxxxxxx/resourceGroups/xxxxxxxx/providers/Microsoft.Web/sites/xxxxxx").properties.siteConfig.publicNetworkAccess (get-azresource -id "/subscriptions/xxxxxxxxxxxxxxxx/resourceGroups/xxxxxxxx/providers/Microsoft.Web/sites/xxxxxx").properties.publicNetworkAccess
AND
Examination of the JSON exported template from a LogicApp in Azure Portal will also show these 2 parameters.
UNFORTUNATELY, I could not find a way to see 'both' parameters with Azure CLI This AZ CLI command only shows #1, properties.siteConfig.publicNetworkAccess, it does not give us #2, properties.publicNetworkAccess. Get-AzWebApp -ResourceGroupName "xxxxxx" -Name "xxxxxx"
ALSO, Looking in Azure Portal > Logic app > settings > Networking > Inbound traffic configuration | Public network access This configuration setting seems to be related only to #2, "Microsoft.Web/sites" (properties.publicNetworkAccess). NOT #1.
because when I changed the value here in portal, the deployment JSON shows: "value": "Microsoft.Web/sites/write", "localizedValue": "Update website"
Actual Behaviour
azurerm_logic_app_standard currently only has 1 argument, and it is for "Microsoft.Web/sites/config" exposed inside the site_config block. It does not have an argument for "Microsoft.Web/sites/"
Steps to Reproduce
terraform apply
Important Factoids
na
References
na