Skip to content

Add credential and role assignment warning for creating service principal#2400

Merged
dbradish-microsoft merged 2 commits intoMicrosoftDocs:masterfrom
jiasli:sp-warning
Feb 16, 2021
Merged

Add credential and role assignment warning for creating service principal#2400
dbradish-microsoft merged 2 commits intoMicrosoftDocs:masterfrom
jiasli:sp-warning

Conversation

@jiasli
Copy link
Member

@jiasli jiasli commented Jan 19, 2021

Context

The credential and role assignment warning currently only exists in the command help of az ad sp create-for-rbac, but not in Create an Azure service principal with the Azure CLI.

Azure PowerShell has this warning in both docs:

Changes

@opbld30
Copy link

opbld30 commented Jan 19, 2021

Docs Build status updates of commit b54a2bb:

✅ Validation status: passed

File Status Preview URL Details
docs-ref-conceptual/create-an-azure-service-principal-azure-cli.md ✅Succeeded View

For more details, please refer to the build report.

Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.

For any questions, please:

Comment on lines +32 to +33
There are two types of authentication available for service principals: Password-based authentication, and certificate-based authentication.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just want to put [!NOTE] and [!WARNING] together, hence the change.

@opbld32
Copy link

opbld32 commented Jan 19, 2021

Docs Build status updates of commit 70d30be:

✅ Validation status: passed

File Status Preview URL Details
docs-ref-conceptual/create-an-azure-service-principal-azure-cli.md ✅Succeeded View

For more details, please refer to the build report.

Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.

For any questions, please:

>
> By default, `az ad sp create-for-rbac` assigns the [Contributor](/azure/role-based-access-control/built-in-roles#contributor) role to the service principal at the subscription scope. To reduce your risk of a compromised service principal, assign a more specific role and narrow the scope to a resource or resource group. See [Steps to add a role assignment](/azure/role-based-access-control/role-assignments-steps) for more information.
>
> In a future release, `az ad sp create-for-rbac` will NOT create a **Contributor** role assignment by default. If needed, use the `--role` argument to explicitly create a role assignment.
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

According to the preview, hyperlink Contributor is rendered as bold text, so mark the second Contributor as bold text too.

image

Meanwhile, az ad sp create-for-rbac uses single quotes as it will be shown in az ad sp create-for-rbac --help when run in a terminal.

WARNING: In a future release, this command will NOT create a 'Contributor' role assignment by default.

@dbradish-microsoft
Copy link
Collaborator

@jiasli, I'm not sure who you are talking to in your comments. :-) Is this PR ready to merge?

@jiasli
Copy link
Member Author

jiasli commented Feb 4, 2021

@jiasli, I'm not sure who you are talking to in your comments. :-) Is this PR ready to merge?

I am not talking to anyone. Just some comment. 😉

@dbradish-microsoft dbradish-microsoft merged commit 5207bee into MicrosoftDocs:master Feb 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants