azure-sdk-for-go: GetBlob for blob names contain spaces fail
Hi.
I confused. I try to execute this code:
basicClient, _ := storage.NewBasicClient(accountName, accountKey)
storageClient := basicClient.GetBlobService()
listOfBlobs, err := storageClient.ListBlobs("user1", storage.ListBlobsParameters{})
if err != nil { // PASS OK
panic(err)
}
for idx, blob := range listOfBlobs.Blobs {
blobEntity, err := storageClient.GetBlob("user1", blob.Name);
if err != nil { // GET ERROR
panic(err)
}
}
Invokes two API methods the ListBlobs and GetBlob. ListBlobs’s execution result is OK, but when I execute GetBlob, I get error:
storage: service returned error: StatusCode=403, ErrorCode=AuthenticationFailed, ErrorMessage=Server failed to authenticate the request. Make sure the value of Authorization header is formed correctly including the signature. RequestId:0a99ee7e-0001-0117-222e-d584a8000000
Could you help me, please? Thank’s.
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 17 (10 by maintainers)
Also having this problem - really need a fix for it. I am passing in the name that Azure gives me:
NOTE: the above code uses github.com/cheekybits/is for testing.