I am trying to make a REST call to Azure Storage using the following code.
But It shows following error:
<?xml version="1.0" encoding="UTF-8"?>
<Error>
<Code>AuthenticationFailed</Code>
<Message>Server failed to authenticate the request. Make sure the value of Authorization header is formed correctly including the signature.\n' +
'RequestId:11c07be7-301e-0003-556f-42091d000000\n' +
'Time:2021-05-06T11:59:40.1049759Z</Message>
<AuthenticationErrorDetail>Audience validation failed. Audience did not match.</AuthenticationErrorDetail>
</Error>
I have already assigned roles:
But still this error. Can anyone help?
The audience of your access token is not correct. The aud
(audience) should look like https://xxxx.blob.core.windows.net
.
Make sure the scope
is https://{account-name}.blob.core.windows.net/user_impersonation
when requesting for access token.