
This will add the actions as NotActions for the role. Search for the microsoft.web/sites/basicPublishingCredentialsPolicies/ftp and microsoft.web/sites/basicPublishingCredentialsPolicies/scm operations. This will open a list of all the RBAC actions for App Service

On the left navigation panel, click Access Control (IAM).Open the subscription that you want to create the custom role in.To configure the custom role, follow the instructions below.

The API in the previous section is backed Azure Role-Based Access Control (RBAC), which means you can create a custom role to block users from using the API and assign lower-priveldged users to the role so they cannot enable basic auth on any sites. To confirm that the publish profile credentials are blocked on WebDeploy, try publishing a web app using Visual Studio 2019. Replace the placeholders with your resource group and site name.Īz resource update -resource-group -name scm -namespace Microsoft.Web -resource-type basicPublishingCredentialsPolicies -parent sites/ -set properties.allow = false To disable FTP access to the site, run the following CLI command. The corresponding CLI commandlet is under development at the time of writing. The following sections assume you have owner-level access to the site. Also, the API to disable or enable basic auth is backed by AAD and RBAC, so you can narrow which users or roles are able to re-enable basic auth for a site. This article shows how to disable basic authorization, monitor any attempted or successful logins, and how to use Azure Policy to ensure any new sites have basic authentication disabled. However, enterprises often need to meet security requirements and would rather disable this basic auth access, so that employees can only access the organization’s App Services through API’s that are backed by Azure Active Directory (AAD). These APIs are great for browsing your site’s file system, uploading drivers and utilities, and deploying with MsBuild. App Service provides access for FTP and WebDeploy clients to connect using the basic auth credentials found in the site’s publish profile.
