I have to set the AWS S3 C++ SDK to using signature_v2,I know how to set it in PHP SDK,but I did't found the method in C++ SDK.Is anybody know ,thx!
Asked
Active
Viewed 1,127 times
1
-
Why do you need V2? All services in all regions should support V4, so... what problem are you trying to solve? – Michael - sqlbot Jun 03 '17 at 05:01
-
1Because we use the third-part service which compatible with S3.And it only support to signature version 2 now. – cnwalker Jun 05 '17 at 01:47
-
@cnwalker, the signers are injectable. You can create a sigv2 signer if you'd like and inject that into the s3 client constructor. A better course of action though is to get the third-party service updated, as sigv2 is unsecure, and is on a path to deprecation across Amazon. – Jonathan Henson Jun 05 '17 at 16:50
1 Answers
1
Signature Version 2 has been deprecated in favor of the more secure version 4. We don't support it, and the only reason it is supported in other sdks is for backwards compatibility. For Amazon S3, you can turn off body signing for v4. This is the default option for the S3 Client in the C++ SDK.

Jonathan Henson
- 8,076
- 3
- 28
- 52
-
Commit https://github.com/aws/aws-sdk-cpp/commit/31a09d2ef2bd644791f38cf5905a4d54adaab3e1#diff-b85e8661a69528c45f96e352b3745537 removed (working ?) implementation of V2 signature from the c++ sdk. – Étienne Mar 07 '18 at 11:25
-
@Étienne I wrote one when I was prototyping the SDK years ago because the transition to sigv4 everywhere was ongoing, and since I wasn't on the AWS SDKs team at the time didn't know it was happening. Before we went Developer Preview we removed it, because we didn't want customers to use it if they weren't already. FWIW, that code was never actually tested against a live service. – Jonathan Henson Mar 07 '18 at 20:39
-
Indeed, I had to change it to make it work. I submitted a [pull request](https://github.com/aws/aws-sdk-cpp/pull/822) even if I understand Amazon does not like the idea of including this deprecated process in the SDK. – Étienne Mar 09 '18 at 17:28