2

我正在尝试使用 Azure node.js sdk 连接到博客存储服务。这就是我所说的:

var blobService = azure.createBlobService(nconf.get("BlobStorage.account"),
                                          nconf.get("BlobStorage.key"));

blobService.createContainerIfNotExist(
    "test1"
    , {publicAccessLevel : 'blob'}
    , function(error){
        if(error){
            console.log(error);
        }
});

这是我得到的错误:

code: 'AuthenticationFailed',
message: 'Server failed to authenticate the request. Make sure the value of Authorization header is formed correctly including the signature.\nRequestId:7ff326e7-2bc6-47ad-898e-2235dc26c03d\nTime:2013-03-15T19:45:25.0167404Z',
authenticationerrordetail: 'The MAC signature found in the HTTP request \'xg3cY11YCPo3mYPxDF5UV7cTPOErleERogcozwGVm6s=\' is not the same as any computed signature. Server used following string to sign: \'PUT\n\n\n0\n\n\n\n\n\n\n\n\nx-ms-blob-public-access:blob\nx-ms-date:Fri, 15 Mar 2013 19:45:25 GMT\nx-ms-version:2011-08-18\n/[containername removed for post]/test1%3Frestype=container\'.'

谁能指出我正确的方向来解决这个问题?

额外细节:

  • 在本地机器上运行,访问云中的 azure blobstorage
  • 操作系统:Mountain Lion 和 Windows 8
  • 节点版本:0.10.0
  • Azure NodeJS SDK 版本:0.6.10

更新 - 2013 年 3 月 15 日下午 1:23

azure nodejs sdk 0.6.10 和 node 0.10 似乎存在问题。 https://github.com/WindowsAzure/azure-sdk-for-node/issues/645

4

2 回答 2

1

仅供参考 Azure NodeJS SDK 目前支持最高 0.8.x 的 nodeJS。

于 2013-03-15T21:43:07.563 回答
0

@user1144313 我们知道它不起作用并正在调查它。http://codebetter.com/glennblock/2013/03/18/node-0-10-compat-issues-with-the-azure-sdk-and-cli/

现在请使用节点 0.8.x。一旦我们有修复程序,我们将发布更新版本。您还可以在https://github.com/windowsazure/azure-sdk-for-nodehttps://github.com/windowsazure/azure-sdk-tools查看 wiki ,我们将在发布更新后立即更新.

任何不便敬请谅解。

于 2013-03-18T02:21:08.363 回答