This has been cleared by Security Team for public due to Feeds not having a stable release

PuSHSubscriber.inc has print($_GET()) on 221
http://cgit.drupalcode.org/feeds/tree/libraries/PuSHSubscriber.inc?id=7....

elseif ($_GET['hub_mode'] == 'unsubscribe') {
$this->log('Verified "unsubscribe" request.');
$verify = TRUE;
}
if ($verify) {
header('HTTP/1.1 200 "Found"', NULL, 200);
print $_GET['hub_challenge'];
drupal_exit();
}

Comments

cashwilliams’s picture

Issue summary: View changes
greggles’s picture

Priority: Normal » Critical

As far as I can tell this is reflected XSS that requires no interaction or permissions to trigger.

Feels more like a critical.

twistor’s picture

Status: Active » Needs review
StatusFileSize
new4.46 KB

Alright, changed things around a bit. The pubsubhubbub standard has changed quite a bit. verify_token is gone. This patch makes the logic much easier to understand.

Uses drupal_random_key(40) for the hmac secret.
check_plains() the challenge. <- This should solve the problem. From what I can tell, there aren't any restrictions on what the verify token can be, but this is the only way to fix the problem.

I have never looked at this code, ugh.

Status: Needs review » Needs work

The last submitted patch, 3: feeds-pub-xss-2495145-3.patch, failed testing.

twistor’s picture

Version: 7.x-2.0-alpha8 » 7.x-2.x-dev
Status: Needs work » Needs review

Bumping to dev, since that bug that broke the test is already fixed.

Working on a test to verify the fix. Once it's done, I'll make a special release with just this patch in it.

twistor’s picture

The last submitted patch, 7: feeds-pub-xss-2495145-7-should-fail.patch, failed testing.

klausi’s picture

Status: Needs review » Reviewed & tested by the community

No direct print_r of $_GET anymore, looks good from a visual review.

  • twistor committed 211b7e7 on 7.x-2.x
    Issue #2495145 by twistor, cashwilliams, greggles, klausi: Possible XSS...
twistor’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.