Support for SermonSpeaker 4.x is canceled as it is for Joomla 2.5. I will gladly assist you with minor issues but I will not fix any bugs anymore in this releases.
The fix is to upgrade to SermonSpeaker 5.x and Joomla 3.x, which is better anyway.

Upload Error:400

More
20 Jan 2016 23:25 #5817 by Eric
Upload Error:400 was created by Eric
Hello,

I recently migrated my server to a new host(siteground), I had been using SermonSpeaker now for a few years with no issue. After the migration, When trying to upload a new audio file in the Add section (in backend) I am now receiving an "Upload Error:400" adn the upload fails.

Originally I thought it had to be a server setting of some sort. Upon investigating and working with the Siteground support, everything looks to be ok,

file size upload limit is fine
upload directory is writeable
tmp dir is writeable
I even fixed the "PHP upload temp dir issue in the PHP.ini

Thing is, I have another podcast extension (that I dont like near as much as Sermonspeaker) and it uploads .mp3's with absolutely no issue. so It isnt anything on the server configuration.

here is my joomla/server/php info
Code:
PHP Built On Linux serv01.c15132.sgvps.net 3.12.18-clouder0 #1 SMP Wed Dec 9 10:11:24 EET 2015 x86_64 Database Version 5.5.31-30.3-log Database Collation utf8_general_ci PHP Version 5.4.45 Web Server Apache/2.2.24 (Unix) mod_hive/5.0 mod_ssl/2.2.24 OpenSSL/1.0.0-fips mod_auth_passthrough/2.1 mod_bwlimited/1.4 mod_fastcgi/2.4.6 mod_fcgid/2.3.6 WebServer to PHP Interface cgi-fcgi Joomla! Version Joomla! 2.5.28 Stable [ Ember ] 10-December-2014 15:00 GMT

I updated SS to the latest compatible version. 4.5.4

I turned on Error Reporting, gave me nothing pertaining to uploads

I checked the PHP error log and I did find some notices:
Code:
PHP Strict Standards: Declaration of SermonspeakerControllerSermon::postSaveHook() should be compatible with JControllerForm::postSaveHook(JModel &$model, $validData = Array) in /home/theblitz/public_html/administrator/components/com_sermonspeaker/controllers/sermon.php on line 12
Code:
PHP Strict Standards: Declaration of SermonspeakerModelSermon::prepareTable() should be compatible with JModelAdmin::prepareTable(&$table) in /home/theblitz/public_html/administrator/components/com_sermonspeaker/models/sermon.php on line 13
Code:
PHP Notice: Undefined variable: hrs in /home/theblitz/public_html/components/com_sermonspeaker/helpers/id3.php on line 29 [19-Jan-2016 09:58:18 CST6CDT] PHP Notice: Undefined variable: min in /home/theblitz/public_html/components/com_sermonspeaker/helpers/id3.php on line 29 [19-Jan-2016 09:58:18 CST6CDT] PHP Notice: Undefined variable: sec in /home/theblitz/public_html/components/com_sermonspeaker/helpers/id3.php on line 29

I can usually troubleshoot this stuff on my own, but this one has me stumped, especially since the other extensions have no issue uploading .mp3s, so it is something with Sermonspeaker specifically not playing nice with my new server.

Any guidance you could give me would be great. Thank You

Please Log in or Create an account to join the conversation.

More
21 Jan 2016 10:07 #5818 by Thomas Hunziker
Replied by Thomas Hunziker on topic Upload Error:400
The errors should generate these issues, especially if you set the error reporting to "none" they should have no impact at all as PHP can deal with those sort of errors in the code (only notices and strict standards).

Error 400 indicates that the server rejected the requested as "bad request".
One could further check it using tools like Fiddler to see which request exactly triggered the error.
You may also want to try with smaller files if those work.

Please Log in or Create an account to join the conversation.

More
21 Jan 2016 15:43 - 21 Jan 2016 16:34 #5819 by Eric
Replied by Eric on topic Upload Error:400
Just as a follow up for anyone else having this issue, I resolved it.

Add to your .htaccess file this line:
SecFilterEngine Off

Make sure you add this to the .htaccess in your "administrator" folder.

** update ***
Upon further review, essentially what this does is disable mod_security which could possibly lead to security problems depending on the sever. I have traced it down to a "malformed content" rule in the modsecurity_crs_20_protocol_violations.conf.

commenting out the rule SecRule REQBODY_PROCESSOR_ERROR is a safer way to achieve this.
unfortunately , not everyone will have access to that file and may have to ask your host to accommodate.

On another note, this is specific to Sermonspeaker with this version of mod_security. The other extension does not have this issue, so whatever mechanism/code sermonspeaker is using to upload files is creating this error.

Hopefully this information helps others.
Last edit: 21 Jan 2016 16:34 by Eric. Reason: new information

Please Log in or Create an account to join the conversation.

More
21 Jan 2016 17:06 #5820 by Thomas Hunziker
Replied by Thomas Hunziker on topic Upload Error:400
It may be interesting what exactly the triggering rule is trying to prevent.
Obviously, we're uploading files here and there may be rules which would prevent uploading a file.

I would also be interested if this issue also exists in the latest version of SermonSpeaker.
You should update to Joomla 3 anyway :)

Please Log in or Create an account to join the conversation.

More
21 Jan 2016 17:11 #5821 by Eric
Replied by Eric on topic Upload Error:400
Well, Yes, I would imagine once I move to Joomla3, the issue may resolve itself, that is next step on my agenda.. as you know that is a daunting task in itself.

Im working with my host now to see if they would be so kind as to comment out that line and see if that does the trick...

just FYI here is the rule in the modsecurity_crs_20_protocol_violations.conf file

# Block request with malformed content.
# ModSecurity will not inspect these, but the server application might do so
#
SecRule REQBODY_PROCESSOR_ERROR "!@eq 0" "t:none,deny,log,auditlog,status:400,msg:'Request Body Parsing Failed. %{REQBODY_PROCESSOR_ERROR_MSG}',id:'960912',severity:'2'"

I will let you know if commenting that out actually does the trick (if they let me do it)

Thanks

Please Log in or Create an account to join the conversation.

More
21 Jan 2016 17:22 #5822 by Eric
Replied by Eric on topic Upload Error:400
Another option could be disabling the mod specifically for the upload php file itself, which would keep it intact for all other scripts. Could you tell me what php file specifically handles the upload? I may try that as well. It would be much safer I think.

for instance:

<ifmodule mod_security.c>
<files upload.php>
SecFilterEngine Off
SecFilterScanPOST Off
</files>
</ifmodule>

I looked thru the sermonspeaker files, but was not able to easily locate what .php file is handling that process.

Thanks

Please Log in or Create an account to join the conversation.

Time to create page: 0.180 seconds
Powered by Kunena Forum