DirectUpload not working at hosted site, but working on dev environment.

Jul 29, 2009 at 4:44 PM

Hi Vlad,

  I've got the DIrect Uploader working on my local web server.  ANd originally it was working on a remotely hosted site as well.  But as soon as I redeployed my project to the remote hosted site it no longer works.  The DLLs get recognized and the file upload control comes up, but when I click upload after choosing a file in IE, nothing happens.  The filename is just highlighted in yellow and sits there.  Sometimes I get a "waiting for" message on the status bar.  But no file is uploaded.  Some things I've noted are the remote site is running SSL, so I made sure to set the secure="true" property on the crossdomain.xml I uploaded to Amazon.  I also made sure to set the read permissions for everyone on that file.  Note, that this uploader works fine when hosted on my own web server.  So the problem here may be with the hosting company. 

My question is more along the lines of- is there any way to get good detailed debugging from the Amazon Direct Upload control to see what is going on?  I tried Fiddler, even turned on the "decrypt HTTPS traffic" option, but I'm afraid I don't see anything useful there.

Jul 29, 2009 at 5:12 PM

I don't know what is the problem but the symptoms point to wrong Amazon configuration. check your key and securiity key.

Also check if you have crossdomain.xml readable from outside in the root of your bucket as described here:

Jul 29, 2009 at 6:06 PM

I have verified that the crossdomain.xml is publicly accessible (read permissions for everyone).  I also verified that the key and security key is good- in fact I use the same key for other operations such as delete/download and it works fine from the same site.

Is there some debugging I can enable from the fileupload or direct amazon uploader controls to see what is gong on?


Jul 29, 2009 at 6:32 PM

You can enable Flash trace by setting IsDebug property of the FileUploader control to true. Then place on the same site the file that can be found at /flash/ServerTracer.swf of the FileUploader source. Open that file in one browser window and the uploader in another.

The source for the file uploader is available at


Jul 29, 2009 at 6:38 PM
Edited Jul 29, 2009 at 6:43 PM

Hey Vlad I just verified something.  If I use the hosted site without SSL the upload works fine.  However if I host the Amazon Direct File Uploader control on a site running SSL it does not seem to work.  I already changed the crossdomain.xml to reflect the following:

  <?xml version="1.0" ?>
  <!DOCTYPE cross-domain-policy (View Source for full doctype...)>
- <cross-domain-policy>
  <allow-access-from domain="*" secure="true" />

However it still doesn't work when hosted on an SSL site.  Any ideas on how to debug this?
Jul 29, 2009 at 10:36 PM

Sorry I missed your response earlier on the debugging.  For some reason the Forum board did not send me an email saying someone had replied.  I will try out your suggestion tonight and let you know.  Thanks for your help!


Jul 30, 2009 at 3:02 AM


  I ran it in debug mode first in SSL, then secondly without SSL.  I compared the debug output and I noticed that they are using different URL's for getFileUploadRequests.    The SSL one uses and the non-SSL hosted control uses

The targetUrl property under doInitialize also has the same https and http, respectively. 


 The targetUrl property under doInitialize is also using https for amazon s3 when hosted on an SSL site and http for non-SSL site.

 Could this have an effect?  Otherwise the debug outputs are the same, except for the fact that I don't get the final output of the getFileUploadRequest in the SSL hosted control since the file does not upload.

The only other discernible difference I see is each one has a different value for Signature which I would expect since one request was made some time after the first, and some property called "d" in the doInitialize section which has some sort of long hash key.


Jul 30, 2009 at 3:31 AM
Edited Jul 30, 2009 at 6:01 AM


  I figured out the problem!  my bucket name is and as another forum member noted in an earlier thread, when using SSL, using dots in the bucket name doesn't seem to work.  You should change the bucket name to my-bucket-com or just a single word (in my case, just to be safe).  I don't know if this is a bug in the product as Amazon supports bucket names like:

  At any rate, this bug is only exposed when hosting the Direct Amazon Uploader on a site that is running SSL.  With SSL turned off, it works fine.

  Hope this helps anyone else out there.  I had actually read that post from last April earlier in the day describing this same issue and was boneheaded enough to think it didn't apply to me.

  I appreciate your responsiveness throughout the day.  Thanks for a very useful product.


Jul 30, 2009 at 6:03 AM

P.S. -- if this indeed is a bug, are there any plans to address this issue?  An awful lot of people have xxx.yyy.zzz bucket names out there on Amazon S3.

Jul 30, 2009 at 7:17 AM

Thank you for sharing your experience Sauropod,

If this is a bug it is on the side of Amazon and I would prefer not to try to change it on my side as I am not sure if they will change it on their side at any time and thus break my change.

But I will add this in the docs so to help other know what to do.

Thanks again for your time.