1

When we are trying to deploy the serialized items into our production CM through Sitecore CLI using devops pipeline but get the below error:

You are not authorized to perform the task you are attempting. You may need to be assigned additional permissions.

As mentioned in another thread, I don't want to make "requireAuthentication" false. Is there any other alternative way?

2
  • Having a very similar issue here. Our dev and qa environments are fine, but the newly stood up prod environment is showing this same error. Did you come to a resolution on this that you may be able to share? Thanks.
    – Mark
    Commented Jan 13, 2022 at 20:59
  • @Mark We found out, there was a custom pipeline code written for userBuilder which was causing the issue. once we have removed it, started working. Commented Jan 18, 2022 at 7:15

2 Answers 2

0

I was also facing a similar issue. And by troubleshooting it, I found that the identityServerAuthority value in Sitecore.Owin.Authentication.IdentityServer.config was wrong. Correcting it resolved the issue.

0

I recently encountered the same issue and found the solution here.

To troubleshoot the issue, consider the following steps:

  • Check that the login command is correct. In particular, check hostnames of Content Management and Sitecore Identity instances and other parameters.

  • Check that --allow-write true parameter is present in the login command.

  • identityServerAuthority setting value and value of the --authority parameter in the Login command should be the same.

  • identityServerAuthority setting value in the runtime configuration should not contain a slash in the end. An example of an incorrect value:

    <sc.variable name="identityServerAuthority" value="https://sc1030id.com/" />

  • If the passwordStrengthRegularExpression attribute was added for the default SQL membership provider in web.config file, try to remove it temporarily and reproduce the issue.

  • If the externalUserBuilder node was overwritten, try to remove such customization temporarily and reproduce the issue. The default type is the following:

    type="Sitecore.Owin.Authentication.Services.DefaultExternalUserBuilder, Sitecore.Owin.Authentication"

  • Try using both interactive and non-interactive login methods to log in to a Sitecore instance and reproduce the issue.

  • Ensure that the environment where the CLI commands are executed has access to Content Management server. Try allowing all incoming traffic on Content Management and replicate the issue.

  • Open the User Manager and check if the CLI user (for example: sitecore\eRDfptzc8G) is not disabled and has the Administrator role.

Hope it helps!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.