BugTraq
Re: Netscape 6/7 crashes by a simple stylesheet... Feb 25 2003 09:22PM
dwm (dwm althea taco com)

jux (at) beer (dot) com [email concealed] wrote:
> Hi, I'm new here so I don't know if I posted this in the correct list...
> I've found out that some simple CSS-code can crash Netscape 6 and 7.
> This is a simple html-page containing this code:

while we're on the subject...just this week I reported to Netscape that this simple
invalid (?) use of regex in "split" can also crash 7.x on windows.
Woopdidoo.

Tested:
Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.0.2) Gecko/20030208 Netscape/7.02

<html>
<head>
<title>test</title>
<--script-- language="JavaScript">
function reformatDate(someDate) {
var tokens = someDate.split(/(\/|-)/);
if (tokens[1].length == 1) tokens[1] = "0" + tokens[1];
if (tokens[0].length == 1) tokens[0] = "0" + tokens[0];
var result = tokens[2] + tokens[1] + tokens[0];
alert(result);
//return result;
}
</--script-->
</head>
<body>
<form action="" method="GET" name="form1" onSubmit="return reformatDate(this.dt.value);">
MM/DD/YYYY - <input type=text name=dt>
<input type=submit>
</form>
</body>
</html>

[ reply ]


 

Privacy Statement
Copyright 2010, SecurityFocus