Hello!

Attached is a patch that upgrades the mixpanel Javascript to the latest version and fixes an XSS vulnerability. Basically, anyone with 'access administration pages' could set the Mixpanel token to something like: ");alert("hey!

This would, of course, throw up an alert on every page!

I'd also recommend creating a new permission for administering Mixpanel, because 'access administration pages' is frequently given to site managers, and you might not want to let them mess with it. But that's an entirely different issue.

Thanks!
David.

Comments

dsnopek’s picture

Status: Active » Needs work
dsnopek’s picture

Status: Needs work » Needs review

Gah! Trying to set to 'needs review'.

wundo’s picture

Re-rolling the patch only with the XSS fix.

dsnopek’s picture

The patch you attached appears to be for something else entirely. Also, what is your rationale for keeping the old mixpanel Javascript library? Is that what the Drupal module for version 1.x is going to be pinned at? Should we make a 2.x branch which uses the latest Javascript library or something similar?

dsnopek’s picture

StatusFileSize
new940 bytes

I've attached a patch which is just the XSS fix out of the original. I also updated the issue on security.drupal.org. I assume you wanted to split it for the security team?

dsnopek’s picture

Title: Fixes to Javascript: upgrade library and XSS vulnerability! » Fix to Javascript XSS vulnerability!

Changing this issue to only be about the XSS vulnerability.

I created a new issue to track upgrading the Mixpanel Javascript library to version 2: #1849574: Upgrade Mixpanel Javascript to version 2.0

dsnopek’s picture

Status: Needs review » Fixed

Committed patch.

Status: Fixed » Closed (fixed)

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

Anonymous’s picture

Security issue -- unpublishing

avpaderno’s picture

Issue summary: View changes