Closed jinyunshaobing closed 2 years ago
我也尝试过另一种写法,就是在创建request时不传入meta,在创建后再添加,但是还是会有同样的问题:
AlibabaCloud::OSS::PutObjectRequest request(this->bucket, path, stream);
request.MetaData().addUserHeader();
我解决了……对于metaData而言,一定不要在key中包含_
,只能用-
,这种限制也太难注意到了
I solved it, use -
instead of _
will solve the SignatureDoesNotMatch
caused by metaData.
有无样例代码呢?我现在创建ObjectMetaData后直接传给PutObjectRequest会导致SignatureDoesNotMatch错误