Send User-Agent when confirming pingbacks with WordPress

Following discussions at the WordPress support forums, bug #1713, the bug was fixed by Changset #2933

In simple English, WordPress confirms pingbacks with a blank user-agent.

The latest version of Bad Behavior blocks sites with send a blank user agent, as this is a common technique being used by spammers to get through user agent filters.

I faced a similar problem with Silktide and added their IP to the whitelist. They plan on fixing this in a future release. I don’t know when that will be and if they will actually do it.

I’m glad WordPress developers have taken this seriously and fixed it. Though there isn’t a major release for this because this is just a minor bug fix, WordPress users please do go and apply the fix.

It isn’t very difficult. All you have to do is open functions.php.
$head = "HEAD $file HTTP/1.1rnHOST: $hostrnrn";
and replace it with
$head = "HEAD $file HTTP/1.1rnHOST: $hostrnUser-Agent: WordPress/" . $wp_version . " PHP/" . phpversion() . "rn";

1 thought on “Send User-Agent when confirming pingbacks with WordPress”

Leave a Reply to Michael Hampton Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.