Hello @Integrity Construction Enterprise,
Thank you for posting your query on Microsoft Q&A.
It looks like, this is an RBAC issue related to setting a secret in Azure Key Vault. The error indicates insufficient permissions for the operation.
Here are steps to resolve the issue:
1.Check Role Assignments
· Ensure the user or service principal performing the action has the appropriate role assigned.
· For setting secrets, the recommended roles are: Key Vault Administrator or Key Vault Secrets Officer
2.Verify Permissions Scope
· Make sure the role assignment is at the correct scope—subscription, resource group, or specific resource.
· Note that roles assigned at a higher scope (e.g., subscription) might not always trickle down correctly.
3.Access Control (IAM)
· In the Azure portal, navigate to your Key Vault.
· Go to Access Control (IAM) and check the assigned roles for the relevant users or service principals.
4.Propagation Time
· If role assignments were recently updated, allow a few minutes for changes to propagate. Retry the operation afterward.
For more info, please refer to https://learn.microsoft.com/en-us/azure/key-vault/general/rbac-guide?tabs=azure-cli
I hope this information is helpful. Please feel free to reach out if you have any further questions.
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".