I am using Google Cloud Storage to store images for my Google App Engine application and I'm trying to access the images like so:
<img src="https://storage.googleapis.com/BUCKET_NAME/IMAGE_NAME">
However, this displays "Access Denied" or presents me with a Google login prompt. Then I tried using Signed URLs to grant the client access.
I generated the URL to be signed like so:
String HTTP_Verb = "GET";
String Expiration = "1361993085";
String Canonicalized_Resource = "/bucket_name/sub_directory";
String stringToSign = HTTP_Verb + "\n" + Expiration + "\n" + Canonicalized_Resource;
And then generated Base64 with the p12 file and compiled using Java, but I got this error:
The request signature we calculated does not match the signature you provided. Check your Google secret key and signing method.
What am I doing wrong here? Is there way I can access images from GCS without authentication?