Closed Bug 503200 Opened 15 years ago Closed 14 years ago

Content-Type header is not preflighted with OPTIONS request in Cross-Site XMLHttpRequest calls (violates CORS)

Categories

(Core :: XML, defect, P2)

1.9.1 Branch
defect

Tracking

()

RESOLVED FIXED
mozilla1.9.2a1
Tracking Status
blocking2.0 --- betaN+

People

(Reporter: arun, Assigned: sicking)

References

()

Details

1. Visit the above URL
2. Click the button, and view TCP/HTTP traffic between client and server.
3. Observe all request headers that go across the wire after you click the button.

Current Behavior: You will notice that this script sets Content-Type using XMLHttpRequest, but that the Content-Type behavior is not preflighted with the initial OPTIONS request according to the CORS specification.

Expected Behavior: The Content-Type header should be preflighted using the Access-Control-Request-Headers CORS header along with the initial OPTIONS request.  Moreover, if server does not respond with Access-Control-Allow-Headers:CONTENT-TYPE the XMLHttpRequest call should fail.
not networking
Component: Networking: HTTP → XML
QA Contact: networking.http → xml
Flags: blocking1.9.2?
Flags: in-testsuite?
Flags: blocking1.9.2?
Flags: blocking1.9.2+
Priority: -- → P2
Not holding 1.9.2 for this.
blocking2.0: --- → alpha1
Flags: wanted-next+
Flags: blocking1.9.2-
Flags: blocking1.9.2+
This is not an alpha blocker.
blocking2.0: alpha1 → beta1
On Firefox 3.6 it works OK (the request is first preflight). Note that at the 2nd try no preflight is sent anymore thanks to the caching system.
blocking2.0: beta1+ → beta2+
jst: still blocking b2? or should this be betaN?
blocking2.0: beta2+ → betaN+
Hmm.. thought i had marked this as depending on bug 597301.

Anyhow, the patches in bug 597301 should have fixed this. Testcases are also checked in of course.
Status: NEW → RESOLVED
Closed: 14 years ago
Depends on: 597301
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.