New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bad Behaviour Wordpress plugin problems w/beta 19 #235
Comments
|
The following is a packet trace from a Vienna 3 Beta 19 client subscribing to http://asmaloney.com/feed. The gzip encoded response body decodes to: |
|
And a packet trace from a Vienna 3 Beta 18 client subscribing to http://asmaloney.com/feed. |
|
This is caused by the Wordpress plugin Bad Behaviour http://bad-behavior.ioerror.us/contact/ Others have had similar problems tripping either a string or regex based blacklist inadvertantly. i.e. https://bugzilla.mozilla.org/show_bug.cgi?id=932498 |
|
(I'm the one who reported the error on the forums.) Just to confirm, I deactivated Bad Behaviour and the feed worked in Vienna. Not sure if it's helpful but with it enabled, the Bad Behaviour logs on my site show this when I try to grab the feed: 2013-11-30 14:13:36 Required header 'Accept' missing GET /feed/ HTTP/1.1 If you need anything from me, or need me to try anything, please let me know. |
|
I have also noticed this upon upgrading to Vienna 3.0beta19. As a workaround, I've added the user-agent string to Bad Behaviour's whitelist, and that seems to make things work again. But please let me know if there's better, longer term solution to this (esp. if it's a bug which should not require whitelisting). Thanks! |
|
I've taken a further look at the plugin code of Bad Behaviour. SummaryFundamentally, Bad Behaviour is filtering based on incorrect assumptions made about the HTTP standards. I've tried reporting this in the Bad Behaviour bug tracker system with no luck so far, and will be looking to their developer to fix it in an upcoming release. In the mean time we should inform Vienna users that they have subscribed to a server which uses the Bad Behaviour plugin, and request the host contacts the developer of Bad Behaviour to have its code fixed. Technical detailsBad Behaviour plugin requires the use of an Accept HTTP header when certain strings are contained in the User-Agent, whereas the RFC 2616 clearly states Accept header is optional. http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html This standards compliant behaviour is not present in the current Bad Behaviour code (v2.2.14), as seen in browser.inc.php where all browsers which are Mozilla/5.0 compatible (i.e. pretty much every modern browser, not just Firefox) are falsely required to send an Accept header. // Analyze user agents claiming to be Mozilla
function bb2_mozilla($package)
{
// First off, workaround for Google Desktop, until they fix it FIXME
// Google Desktop fixed it, but apparently some old versions are
// still out there. :(
// Always check accept header for Mozilla user agents
if (strpos($package['headers_mixed']['User-Agent'], "Google Desktop") === FALSE && strpos($package['headers_mixed']['User-Agent'], "PLAYSTATION 3") === FALSE) {
if (!array_key_exists('Accept', $package['headers_mixed'])) {
return "17566707";
}
}
return false;
}Of course, our Vienna 3 Beta 18 elected to not use the Accept header as well, which was not an issue with standards compliant web servers. |
Without an "Accept" request header, we get error 403 with the Wordpress plugin Bad Behavior
http://www.cocoaforge.com/viewtopic.php?f=18&t=26414&sid=d462c4f3157cf38afda3e361e6e4057a
The text was updated successfully, but these errors were encountered: