bugtraq
[Top] [All Lists]

Re: [Full-disclosure] Firefox onUnload + document.write() memory corrupt

To: Richard Moore <rich@westpoint.ltd.uk>
Subject: Re: [Full-disclosure] Firefox onUnload + document.write() memory corruption vulnerability (MSIE7 null ptr)
From: Michal Zalewski <lcamtuf@dione.ids.pl>
Date: Tue, 27 Feb 2007 14:29:11 +0100 (CET)
Cc: full-disclosure@lists.grok.org.uk, bugtraq@securityfocus.com, security@mozilla.org
Delivered-to: sp-com-lists@consult.net
Delivered-to: bugtraq-list@securepoint.com
Delivered-to: mailing list bugtraq@securityfocus.com
Delivered-to: moderator for bugtraq@securityfocus.com
In-reply-to: <45E42FCC.9030508@westpoint.ltd.uk>
List-help: <mailto:bugtraq-help@securityfocus.com>
List-id: <bugtraq.list-id.securityfocus.com>
List-post: <mailto:bugtraq@securityfocus.com>
List-subscribe: <mailto:bugtraq-subscribe@securityfocus.com>
List-unsubscribe: <mailto:bugtraq-unsubscribe@securityfocus.com>
Mailing-list: contact bugtraq-help@securityfocus.com; run by ezmlm
References: <Pine.LNX.4.58.0702230229090.21707@dione> <45E1BA08.7090901@cruzio.com> <122827b90702250857k7bcaac7eo6757fb1c45f95c2e@mail.gmail.com> <Pine.LNX.4.58.0702252330330.21707@dione> <45E42FCC.9030508@westpoint.ltd.uk>
On Tue, 27 Feb 2007, Richard Moore wrote:

> <html>
> <body onunload="location = self.location">
> <a href="http://slashdot.org/";>http://slashdot.org/</a>
> </body>
> </html>

Yeah, and the other way round: http://lcamtuf.coredump.cx/ietrap/, when
used with FF 2.0.0.2, puts you on a page that:

  1) Has URL bar data and favicon from the target site,
  2) Views source of what you added with document.write(),
  3) Displays as blank.

Moreover, repeatedly setting document.location = "xxx"; on departure may
land you at slashdot.org/xxx instead (meaning the update is being
performed in the context of the new page).

Although this looks like a Really Bad Thing (tm), I didn't succeed in
modifying /ietrap/ to display a malicious payload (though feels like it's
sooo close), nor in manipulating DOM in the latter example to do anything
other than annoying the user (because 2.0.0.1 kept crashing ;-). Still,
I'm not gonna sleep well until this is fixed.

/mz


<Prev in Thread] Current Thread [Next in Thread>