iOS: Create pre-signed URL using Sigv4 in Swift

时间:2017-06-15 10:30:23

标签: ios swift authentication pre-signed-url

I would like to create a pre-signed URL using Sigv4 in Swift 3.0 and iOS 10.

Any suggestion on how to get started? I found this Amazon documentation but I am unable to find a way to do the signing process in iOS. The AWS classes that do this seem to be internal only (e.g. AWSIoTMQTTClient.h).

I found some Objective-c code in this answer but when I try to import it in my project some of the constructs are not recognised.

Hence I thought I ask here to see if anyone did this directly using Swift.

The URL format that I'd like is:

https://blabla/blabla?blabla-SHA256&X-Amz-Date=20170615T081418Z&X-Amz-SignedHeaders=host&X-Amz-Expires=3599&X-Amz-Credential=blabla%blabla%2Faws4_request&X-Amz-Signature=blabla

0 个答案:

没有答案