views:

951

answers:

2

I have been using the Zend_Service_Amazon_S3 library to access Amazon S3, but have been unable to find anything that correctly deals with generating the secure access URLs.

My issue is that I have multiple objects stored in my bucket with an ACL permission of access to owner only. I need to be able to create URLs that allow timed access. However, the documentation for Amazon S3 is very brief on the subject.

Could someone elaborate, or provide a link to something that explains how I might achieve this in PHP?

+2  A: 

The documentation located in the authenticating REST requests section deals with generating the signature required for the URLs. It would be a simple case of implementing a PHP function that can generate this type of signature.

tombazza
+1 - Thanks, this just saved me a bunch of Google searching! I love StackOverflow :-)
Topher Fangio
A: 

and what would be the code logic in that php function? are we going to send the actual AWS key? encode it? where is that mentioned? how do i get the signature? what code logic would go into that function? hash it ? mash it? splash it?

Pinapila
I suggest you have a look at the documentation in the link I provided which describes how to create the signature string, which would then allow you to create signed URLs.
tombazza