Hi,
I have unzipped the demo to my server and it doesn't work out of the box (as one would hope to AT LEAST see the demo work).
My configuration is probably to blame so:
SSL only (only accepting requests on 443)
Windows 2000 Server
Apache 2.0.59
PHP 4.4.7
Apache HTDocs is on a FAT32 volume, Windows 2k Server is on an NTFS volume.
Now from that I'm sure someone could point out what the problem is:
I fill in the classic demo information, and without any delay or progress information it says file rejected.
Debug Says:
SWF DEBUG: SWFUpload Init Complete
SWF DEBUG:
SWF DEBUG: ----- SWF DEBUG OUTPUT ----
SWF DEBUG: Build Number: SWFUPLOAD 2.0.1 FP9 2007-12-05 0001
SWF DEBUG: movieName: SWFUpload_0
SWF DEBUG: Upload URL: ../formsdemo/upload.php
SWF DEBUG: File Types String: *.*
SWF DEBUG: Parsed File Types:
SWF DEBUG: File Types Description: All Files (*.*)
SWF DEBUG: File Size Limit: 1024000
SWF DEBUG: File Upload Limit: 0
SWF DEBUG: File Queue Limit: 1
SWF DEBUG: Post Params:
SWF DEBUG: ----- END SWF DEBUG OUTPUT ----
SWF DEBUG:
Flash called back and is ready.
SWF DEBUG: Event: fileDialogStart : Browsing files. Single Select. Allowed file types: *.*
SWF DEBUG: Select Handler: Files Selected from Dialog. Processing file list
SWF DEBUG: Event: fileQueued : File ID: SWFUpload_0_0
SWF DEBUG: Event: fileDialogComplete : Finished adding files
SWF DEBUG: StartUpload(): Starting Upload: First file in queue
SWF DEBUG: StartFile: First file in queue
SWF DEBUG: Event: uploadStart : File ID: SWFUpload_0_0
SWF DEBUG: startFile(): File Reference found. File accepted by startUpload event. Starting upload to ../formsdemo/upload.php for File ID: SWFUpload_0_0
SWF DEBUG: Event: uploadError : IO Error : File ID: SWFUpload_0_0. IO Error.
SWF DEBUG: Event: uploadComplete : Upload cycle complete.
Some help would be appreciated. Thanks,
-Josh
January 1, 2008 - 8:54pm
SSL has been reported not to work for some users (although it has worked for me).
You may be having a problem with the Apache mod_security module. This post might help: http://www.swfupload.org/forum/generaldiscussion/176
You might also look at your server logs to see if it reports anything helpful. The Flash Player is performing the upload and isn't as friendly as it should be. Usually a server configuration can be found that is compatible with SWFUpload.
I would be interested to know if you were able to make other Flash based upload tools work where SWFUpload didn't.
January 10, 2008 - 4:59am
I'm using version SWFUpload v2.0 in my site and it works perfectly on my non-SSL apache server. When I transfer the site to an SSL-enabled server, I get the IO error described above.
The thing I noticed was that when I used the swfupload_f8.swf file I only got the IO error in Firefox and Opera, not IE (6 or 7). If I switched to the swfupload_f9.swf file, I get the error message in all browsers.
I'm going to look at the mod_security solution above and see if it helps, but I thought I'd share these observations first.
January 18, 2008 - 11:34am
Are you using a self-signed certificate by any chance? If it works of http and fails over https before sending any data, then Flash is not completing the SSL handshake.
If you are using a self-signed certificate on your development server, like me, then you need to install that certificate to both the Firefox and IE certificate stores.
Ours is not to reason why...
February 13, 2008 - 7:38am
Hi,
Yes the problem seems to be Self-Signed Certificates. I have an issue with this since I would need to be able to use swfupload with a server using SSC without having the users to have to install the certificates.
I have never developed any flash components myself but I guess this is a security issue in flash. Is there by any chance an option in flash to allow self signed certificates? And have this as a parameter sent to swfupload?
br, Kim
February 13, 2008 - 8:34pm
I cannot find any work around for this in the Flash Docs. It looks like a bug in the Flash Player. I'll add it to the Known Issues in the docs.
Sorry I don't have a better solution for you.
February 28, 2008 - 3:29pm
It looks like this bug is a dead end (not SWFUpload's problem, but Flash's), but here's a little more info in case others run into it...
We have an SSL site that uses a self-signed certificate as well as a client-side certificate for authentication. (Our users install our own root CA and the client certificate in order to access the site.) In Win IE6, SWFUpload works. In Win/Mac FF2, it doesn't -- instead, debug output shows the #2038 IO error.
So it seems that under IE, Flash is correctly handshaking with the SSL server and passing the client certificate. But in Firefox, it fails (even though the browser itself is communicating with the SSL server just fine).
By the way, we're using SWFUpload 0.8.3 Revision 6.2 (July 2007).
April 15, 2008 - 4:51am
hi all. maybe I have something to help you.
I posted this also in the self signing certificate defect ( http://code.google.com/p/swfupload/issues/detail?id=27 )
===>
I have too problems with self signing certificates. As I found out, it is not a flash
bug. In flash 7, the security model was renewed, and the consequence is, that flash
cannot access scripts or resources from another domain ( http://foo.bar.com and
http://www.bar.com are treated as different domains ).
=> http://www.adobe.com/devnet/flash/articles/fplayer_security.html
I found a possible solution to this problem. You have to call the flash internal
method System.security.loadPolicy with an xml file, that specifies which domain on
which port is allowed.
=> http://www.powersdk.com/ted/2005/11/using-flash-player-under-https-with....
My problem is, that I don't know, how i can call the System method in action script.
I can call methods on the swf upload object, after the uploader is created, but I
cannot access the system methods. It seems to me, that SWFU has to be extended, to
consume a policy file in configuration.
Or does anybody know, how to call the System.security.loadPolicy method from
javascript?
April 15, 2008 - 1:22pm
I've created a code branch to test this code
http://code.google.com/p/swfupload/source/browse/swfupload/branches/load...
You need the new SWF file (swfupload_f9.swf or swfupload_f8.swf) and the new swfupload.js file.
A new function called loadPolicyFile has been added to the SWFUpload object. Here is a sample:
var swfu = new SWFUpload(settings);
swfu.loadPolicyFile("https://www.example.com/policy.xml");
If you would please test this and let us know if it works (if it should be added to the SWFUpload codebase) and, if so, contribute a sample XML policy file.
Thanks.
April 17, 2008 - 2:31am
Thank you for the quick created branch... I was trying around with it, but still couldn't get the upload running with firefox and opera...
there is one little issue with the added method loadPolicyFile... i have to call it with a timeout, otherwise it happens, that the flash movie element isn't loaded and the loadPolicyFile method isn't available.
but anyway, after some testing, I think I've come to a solution (that was much easier than I thought). The problem was my created certificate and the way I accessed the test server.
).
I created the certificate for my computers host name (because i'm testing on my machine), but I did the testing on the localhost (because i'm testing on my machine, again
I could accept the SSL certificate manually, when I called the page. but the upload failed always. but then I tried to test the web application over my host name ( so http://zrh-tom-001 instead of http://localhost ) and it worked...
we now still want to test the whole thing, but I think that we have our solution to that problem...
silly me, sorry if I bothered you, but I hope this information helps some others with SSL issues
thank you
April 17, 2008 - 11:32am
Any work you need to do on SWFUpload after you've initialized the object should happen in the swfupload_loaded event. That way you know that it has been added to the page and is ready. That's more sure than using a setTimeout.
Are you using self-sign certificates? I'm sure several other users would be interested to know if you get them to work. Whether you had to use policy files. Which browsers it worked in, etc.