Vulnerability Note VU#237257

Mozilla privilege escalation using addSelectionListener

Original Release date: 02 Jun 2006 | Last revised: 09 Feb 2007


A privilege escalation vulnerability exists in the Mozilla addSelectionListener method. This may allow a remote attacker to execute arbitrary code.



Web content can add a SelectionListener to the Selection object by using addSelectionListener method of the nsISelectionPrivate interface. This listener would be called when the user performs a "find" or "select all" command.

The problem

The notifications are created in a privileged context, which can be leveraged to execute arbitrary code. Mozilla Firefox and SeaMonkey are reported to be vulnerable.


By convincing a user to view a specially crafted HTML document (e.g., a web page, an HTML email message, or an HTML email attachment), an attacker may be able to execute arbitrary code with the privileges of the user.


Apply an update
Refer to Mozilla Foundation Security Advisory 2006-43 for fixed versions of Mozilla products.

Disable JavaScript

This vulnerability can be mitigated by disabling JavaScript.

Systems Affected (Learn More)

VendorStatusDate NotifiedDate Updated
Mozilla, Inc.Affected-02 Jun 2006
If you are a vendor and your product is affected, let us know.

CVSS Metrics (Learn More)

Group Score Vector
Base N/A N/A
Temporal N/A N/A
Environmental N/A N/A



Thanks to the Mozilla Foundation Security Advisory for reporting this vulnerability, who in turn credit moz_bug_r_a4.

This document was written by Will Dormann.

Other Information

  • CVE IDs: CVE-2006-2777
  • Date Public: 01 Jun 2006
  • Date First Published: 02 Jun 2006
  • Date Last Updated: 09 Feb 2007
  • Severity Metric: 18.36
  • Document Revision: 17


If you have feedback, comments, or additional information about this vulnerability, please send us email.