POST to digest authenticated resource fails with event handler on XMLHTTPRequest upload

Originator:aaron
Number:rdar://28827900 Date Originated:18-Oct-2016 12:29 PM
Status:Duplicate of 7719503 (Open) Resolved:
Product:Safari Product Version:10.0+
Classification: Reproducible:Yes
 
Summary:
On Safari 10.0 if an event handler is specified on JavaScript's XMLHTTPRequest upload object during a POST to a digest protected resource, the POST fails and is not completed. It appears to happen on Mobile Safari on the latest version of iOS as well.

Basic authentication works OK. This only fails with Digest authentication.

See attached file "xhr-upload-event.html". Removing the req.upload.onerror function allows the POST to be made successfully.

Steps to Reproduce:
1) Create an HTTP digest protected resource
2) Write an XHR request with an event handler on upload to the digest protected resource
3) Attempt to run the request using Safari

Expected Results:
The POST is made, or an error is returned

Actual Results:
The POST hangs

Version:
Mac Mini, MacOS Sierra 10.12, Safari 10.0 (12602.1.50.0.10)
iPad model MD513B/A, version 10.0.2 (14A456)

Notes:


Configuration:
Regular setup of Safari and Mobile Safari on iOS

Comments

This also affects Mobile Chrome on iOS.


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!