I'm curious as to what security rules/filters are being triggered by your requests to async-upload.php
I experienced an error as well when using WP 2.5 to upload to the media gallery. After some debugging I found the reason for this error is simply because async-upload.php is sent the uploaded file via a POST from an swfupload.swf file, which doesn't have support builtin to send HTTP Basic Authorization.
I am really curious how the above code fixes the problem, I haven't had any problems with my mod_security. Could you please do this to help me out?
- create a file called
modsec_audit.log and chmod 666
- add the code below to your
- try to upload an image to make the image occur again
Now the modsec_audit.log will explain what rule the request is matching.
Or you can just upgrade to the newer version and see if it works for you.