Author Topic: Media Verification error  (Read 2492 times)

rburns

  • Full Member
  • **
  • Posts: 25
Media Verification error
« on: January 28, 2013, 11:30:18 pm »
I have Powerpress plugin version 4.06 and I am having a 403 error for media verification.

Diagnostics reveals this warning:
 Warning   
Your web server supports the PHP cURL library. Your web server is also configured with the php.ini setting 'allow_url_fopen' enabled, but the cURL library takes precedence.

Warning: The php.ini setting 'open_basedir' will prevent the cURL library from following redirects in URLs.

If you are still having problems detecting media information, check with your web hosting provider if there is a firewall blocking your server.

I understand it doesn't interfere with the podcast being submitted, but I don't like errors. I am self hosted and would like to know what you recommend.
The location of the podcast are within the Open_BaseDir settings, and I do not want to disable cURL, as I have other things associated with it.

Any ideas?
podcast URL:  http://mtrosemedia.tk/audio_podcast/
Media not verified: http://mtrosemedia.tk/wp-content/uploads/podcasts/040812-Yesterday-Is-Not-Today-Podcast.mp3
There are many others, but all are the same error.
 
I am self hosted, but I do not really know what to do. Any help is appreciated!

angelo

  • CIO, RawVoice
  • Administrator
  • Hero Member
  • *****
  • Posts: 4483
Re: Media Verification error
« Reply #1 on: January 29, 2013, 10:39:32 am »
You have one option: Remove the Open_BaseDir setting. If Open_BaseDir is set to anything, a known bug (or some say by design) cURL will not follow web links that have redirects in them. Just about any media link hosted via a CDN network will have a redirect, hence the problem.

rburns

  • Full Member
  • **
  • Posts: 25
Re: Media Verification error
« Reply #2 on: February 12, 2013, 03:55:43 pm »
http://forums.contribs.org/index.php/topic,49561.msg247787.html#msg247787

This option does not seem to be available to me. Any other possible suggestions?
Are you saying if I host my media on a CDN then it will work properly?

angelo

  • CIO, RawVoice
  • Administrator
  • Hero Member
  • *****
  • Posts: 4483
Re: Media Verification error
« Reply #3 on: February 12, 2013, 06:01:58 pm »
The page you link to explains how you can set up the open base dir to an empty parameter for your service. Am I missing something?

If you cannot change the open base dir setting, then simply manually enter your file size and duration information It is painful, but that's what's not working for you because of the security you have in place.

Does not matter where you host the media, so as long as the URL could possibly have headers in it that conflict with the basedir setting, then you're stuck.

I'm looking to see if there is a solution we can put into PowerPress, the problem though is we're using the curl Library built into WordPress, technically the problem should be fixed in WordPress but that will most likely never happen. Give me 3 days to research.

rburns

  • Full Member
  • **
  • Posts: 25
Re: Media Verification error
« Reply #4 on: February 13, 2013, 03:35:18 pm »
Thank you.
I understand the how to empty the registered location for Open BaseDir, however, I am using other web applets that need to access my /tmp/ and /usr/bin/ folder, which only have access through the set Open_BaseDir. Without them, I won't be able to properly cache some other sites I am hosting, such as my osCommerce web store.
Thanks again

rburns

  • Full Member
  • **
  • Posts: 25
Re: Media Verification error
« Reply #5 on: February 13, 2013, 03:43:19 pm »
Also, I have another question and a statement.

Question::
How do I follow this topic to receive emails for when there are any changes posted?

Statement::
I'm not sure how to properly read the thread at this link, http://php.net/manual/ro/function.curl-setopt.php#102121 , but there seems to be an answer somewhere in there.

angelo

  • CIO, RawVoice
  • Administrator
  • Hero Member
  • *****
  • Posts: 4483
Re: Media Verification error
« Reply #6 on: February 13, 2013, 03:55:02 pm »
I think you got the open_basedir setting confused. If it is not set, your PHP scripts can access all paths on your server (so as long as the folders have the correct permissions that is). With it set, it is limited to just those paths on your server.

angelo

  • CIO, RawVoice
  • Administrator
  • Hero Member
  • *****
  • Posts: 4483
Re: Media Verification error
« Reply #7 on: February 13, 2013, 03:55:33 pm »
Next to the "Reply" button is a button labelled "notify", click that to receive notifications.

angelo

  • CIO, RawVoice
  • Administrator
  • Hero Member
  • *****
  • Posts: 4483
Re: Media Verification error
« Reply #8 on: February 13, 2013, 04:10:21 pm »
I've double checked the logic in PowerPress and we do have logic in place to deal with this situation if the open_basedir setting is set.

Thinking about what you first said with the URL returning a 403 error message, I tested and confirmed the URL (http://mtrosemedia.tk/wp-content/uploads/podcasts/040812-Yesterday-Is-Not-Today-Podcast.mp3) returned error 403 from our sandbox as well. This means the problem is not within you WordPress/PHP nor the open_basedir setting. You can stop looking into changing your open_basedir settings.

This does appear to be an issue with your web hosting dealing with media files. It appears to be reporting the file as text/plain, which I'm guessing is the issue, or at least 1 of possibly more issues. You can bring this issue back to your web hosting and ask them to add support for mp3 files (by adding its content type and handling media appropriately by your server, supporting byte serving, etc...) or you can host your media else where. Have them refer to this page for details what is necessary for media hosting to support podcasting: http://www.podcastfaq.com/creating-podcast/audio/mp3-mpeg-layer-3-tips/

rburns

  • Full Member
  • **
  • Posts: 25
Re: Media Verification error
« Reply #9 on: February 13, 2013, 04:34:18 pm »
Ok.
I'm self-hosted, and I'm not 100% sure of what you mean when you say that there needs to be support for my file type. Is this an Apache setting, or possible .htaccess option? I have the file type adjusted from within my WordPress MultiSite installation, and it is uploaded to my WordPress uploads folder through the media management.

EDIT::::
I have made the change to my .htaccess file accordingly. There has been no change

<code>
AddType audio/mp4a-latm .m4a
AddType video/vnd.mpegurl .m4u
AddType audio/mpeg .mp3
AddType video/mp4 .mp4
AddType audio/mpeg .mp2
AddType video/mpeg .mpe
AddType video/mpeg .mpeg
AddType video/mpeg .mpg
</code>
« Last Edit: February 13, 2013, 04:54:47 pm by rburns »

angelo

  • CIO, RawVoice
  • Administrator
  • Hero Member
  • *****
  • Posts: 4483
Re: Media Verification error
« Reply #10 on: February 13, 2013, 11:06:25 pm »
Your asking the wrong folks now, who ever setup that server can tell you how to set content types and double check byte serving works correctly. What you have may work but it may not depending if htaccess files can set those settings.

rburns

  • Full Member
  • **
  • Posts: 25
Re: Media Verification error
« Reply #11 on: February 20, 2013, 07:00:00 pm »
I am continuing to get a 403 error. I have confirmed that my server Apache 2 supports byte serving, and media files are being handle correctly through an .htaccess addition
<code>
AddType audio/mp4a-latm .m4a
AddType video/vnd.mpegurl .m4u
AddType audio/mpeg .mp3
AddType video/mp4 .mp4
AddType audio/mpeg .mp2
AddType video/mpeg .mpe
AddType video/mpeg .mpeg
AddType video/mpeg .mpg
</code>

Any other suggestions?

angelo

  • CIO, RawVoice
  • Administrator
  • Hero Member
  • *****
  • Posts: 4483
Re: Media Verification error
« Reply #12 on: February 20, 2013, 11:57:25 pm »
Okay, this is getting rather technical, sorry. This information you will need to send to your hosting provider.

It appears HTTP HEAD requests are being rejected by your web server with a 403 Forbidden response. GET requests do not exhibit this problem. To replicate the problem outside of PowerPress, use Firefox with the Live HTTP Headers plugin, using the "Replay" option when viewing the HTTP headers, change the method from GET to HEAD by typing HEAD in the field, then click 'Replay'. The result from the server is 403 hidden.

From my searching, it could be mod_security that is setup to block HEAD requests, so it may not be a simple fix if the web hosting is using mod_security.

You will need to support HTTP HEAD requests in order to be complaint with iTunes, as iTunes first uses a HEAD request in order to get the file size and content type on mobile devices. It's also necessary for the get headers function call that PowerPress makes to get your file size and check your content type from your web server.

rburns

  • Full Member
  • **
  • Posts: 25
Re: Media Verification error
« Reply #13 on: February 21, 2013, 08:58:55 am »
THANKS!!
Bulletproof security plugin for WordPress was blocking all HEAD request. Changed the filter types for Bulletproof Security to exclude HEAD request, and now verification works perfectly!
Will repost information if possible to still filter HEAD request, but exclude request from specific requester.

angelo

  • CIO, RawVoice
  • Administrator
  • Hero Member
  • *****
  • Posts: 4483
Re: Media Verification error
« Reply #14 on: February 22, 2013, 10:34:19 am »
Awesome. We can add a warning in powerpress for that plugin, wasn't aware it was intercepting non PHP page views, that may cause other issues for you as your podcast grows. Processing large media downloads through PHP scripts is very inefficient and can cause your web site to load slowly/come to a crawl.