From my experience you can get close to what you want with Azure Policy, but you cannot reproduce that exact CSPM Advanced checkbox matrix one to one.
- CSPM is controlled by a single pricing object called CloudPosture on Microsoft.Security/pricings with pricingTier set to Standard. Some of the “advanced” options you see in the portal are just extensions on that same object such as AgentlessDiscoveryForKubernetes, ContainerRegistriesVulnerabilityAssessments and SensitiveDataDiscovery, and those can be driven by policy at subscription or management group scope. Microsoft Learn There is no supported way today to say “CSPM Standard but serverless protection off” in policy. Once you enable the paid CSPM plan you get the full bundle, serverless included, and there is no separate extension flag to turn only that part off. Microsoft Learn
- The Permissions Management or CIEM switch is tied to Entra Permissions Management which Microsoft is in the process of retiring in 2025, so I would not hard code that as a long-term dependency in a custom policy. Even if you see it in the portal now, the product is being phased out and support ends around October or November 2025. Microsoft Tech Community
- CWPP plans are the easy part. Each plan you listed is just another Microsoft.Security/pricings entry, for example VirtualMachines, AppServices, SqlServers, StorageAccounts, KeyVaults. You can absolutely enable only those by policy and simply never create pricing entries for Containers, KubernetesService, Api or Ai, so those stay on the Free tier. Microsoft Learn
In practice what I do for customers is assign one custom initiative at the root management group that deploys CloudPosture with the extensions we actually want and then separate pricing objects for the CWPP plans we care about, and I accept that some CSPM toggles like serverless are not granularly controllable via policy today.