19

I have an iOS app where I upload objects to an Amazon S3 bucket and want to retrieve from CloudFront distribution.

I am using CloudFront with private distributions for my Amazon S3 bucket and when I generate a signed URL it does not work, in Safari it returns AccessDenied AccessDenied and some random alphanumeric string, My Signed URL I just generated (Expiration date in 24 hours) -- should be expired by now

I read the following site to get all my security credentials in place and I have also setup a private distribution with my S3 Bucket by reading the documentation and I have setup the trusted signers which is basically just my account

I have used code from this site to generate the signed URL

But again I have had absolutely no luck, when I put the link in Safari it returns AccessDeniedAccessDenied and some random alphanumeric string. Why? Any problem? Any step I am not following?

Thanks for any help! I appreciate it, this is important for me as I need to create an app where CloudFront would be very important for speed and international distribution...


Thanks everyone for upvoting, I figured out my problem. I didn't follow the step of create an access origin identity. Now it works like a charm. Woohoo!

Bill the Lizard
  • 398,270
  • 210
  • 566
  • 880
MCKapur
  • 9,127
  • 9
  • 58
  • 101
  • Can you please list all the steps that you have done? It is difficult to go through the links and figure out what you have missed. This is a solved problem, so it is obvious you are missing something, so you need to list step by step what you have tried for someone to help you! – d33pika Dec 26 '12 at 05:52
  • @d33pika Thanks, I will do this and update the question in a few hours.. got a lot to do first! – MCKapur Dec 26 '12 at 06:10
  • Have you tried posting in the aws forums? I usually get pretty useful answers from people there. – Anand Mar 19 '13 at 06:44
  • I actually solved my problem. I didn't follow the step of creating an access origin identity. I answered my own question with this detail, but a moderator deleted it due to lack of quality. After that I just got lazy to answer my own question so.... – MCKapur Mar 19 '13 at 06:57
  • I see this question is relatively old... but I've recently experienced similar issue - the problem was related to the KeyPair used to sign the URL - you can find more details [in my original post](https://stackoverflow.com/questions/54803307/how-to-generate-signed-urls-for-amazon-s3-exposed-by-cloudfront-using-net/54901185#54901185) – ChiTec Feb 28 '19 at 09:42

0 Answers0