Bug 14833
Summary: | XMLHttpRequest with incorrect credentials raises an exception on Windows | ||
---|---|---|---|
Product: | WebKit | Reporter: | Jesse Costello-Good <jesse> |
Component: | XML | Assignee: | Nobody <webkit-unassigned> |
Status: | RESOLVED WORKSFORME | ||
Severity: | Normal | CC: | ap, aroben |
Priority: | P2 | Keywords: | InRadar, PlatformOnly |
Version: | 523.x (Safari 3) | ||
Hardware: | All | ||
OS: | Windows XP | ||
Bug Depends on: | |||
Bug Blocks: | 10489 |
Jesse Costello-Good
The following works on the MacOS X nightly but not on Intel. On Intel, r.status is 401 (access denied).
var r = new XMLHttpRequest();
r.open("GET", "http://gi.tibco.com/tests/auth/data1.xml", false, "gi", "gi");
r.send();
assertEquals(200, r.status);
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Matt Lilek
(In reply to comment #0)
> The following works on the MacOS X nightly but not on Intel. On Intel, r.status
> is 401 (access denied).
Just to clarify - by Intel do you mean Windows (assuming this is the case from the Platform field) or is there a difference between a PPC nightly and an Intel nightly on Mac OS X?
Matt Lilek
s/Platform/OS
Jesse Costello-Good
Sorry, my post is confusing. I'm on a MacBook Pro running 10.4 and Parallels with Windows XP. On Windows XP the status code is 401, on MacOS X it is 200.
David Kilzer (:ddkilzer)
(In reply to comment #3)
> Sorry, my post is confusing. I'm on a MacBook Pro running 10.4 and Parallels
> with Windows XP. On Windows XP the status code is 401, on MacOS X it is 200.
Are you running (roughly) the same WebKit Nightly build on both?
David Kilzer (:ddkilzer)
Implicitly confirmed by ap. :)
Mark Rowe (bdash)
<rdar://problem/5376650>
Alexey Proskuryakov
Explicitly confirming with Safari beta 3.0.3 and r24749 (also under Parallels, but that shouldn't matter).
Jesse Costello-Good
Yes, r24749 in both cases.
Brady Eidson
The success case now works on both Mac and Windows. I just tried both with ToT builds from today.
Using the code -
<html>
<head>
<script>
var r = new XMLHttpRequest();
r.open("GET", "http://gi.tibco.com/tests/auth/data1.xml", false, "gi", "gi");
r.send();
alert(r.status);
</script>
</head>
</html>
Both Mac and Windows alert "200"
However there still seems to be some form of bug, as if I change the un/pw to something incorrect, like "sdufghwueg", "wheuhw", Mac alerts "401", and Windows alerts nothing. The Javascript console on Windows shows
"Error: NETWORK_ERR: XMLHttpRequest Exception 101"
So Windows now can successfully login using HTTP auth, but it's failed credential case is broken
Alexey Proskuryakov
I cannot reproduce this with xmlhttprequest/failed-auth.html regression test now.
Note that requests from file:// are treated as cross-origin on Windows now, so the original test case doesn't work.