Bug 217570
| Summary: | navigator.mediaDevices.getUserMedia() fails on Safari on iPhone with NotAllowedError without explanation | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | jujjyl |
| Component: | New Bugs | Assignee: | Nobody <webkit-unassigned> |
| Status: | RESOLVED INVALID | ||
| Severity: | Normal | ||
| Priority: | P2 | ||
| Version: | Safari 14 | ||
| Hardware: | iPhone / iPad | ||
| OS: | iOS 13 | ||
jujjyl
Calling navigator.mediaDevices.getUserMedia() fails on Safari on iOS with error
navigator.mediaDevices.getUserMedia() failed: Unable to start video input! The request is not allowed by the user agent or the platform in the current context, possibly because the user denied permission.
but user was not even asked permission to use the webcam.
STR: Visit https://rexact.itch.io/safari-ios-webcam-test . The test page works on desktop Chrome, Firefox and Safari, and also on mobile Chrome and Firefox, but not in mobile Safari.
A locally examinable copy of the page can be downloaded from http://clb.confined.space/dump/safari-ios-webcam-test.zip
Expected: The user should be asked permission to use the webcam, or if due to some misconfigured security setting webcam access cannot be acquired, the error message should hint towards the reason (a searchable error identifier that would lead to Apple developer documentation for clear explanation, or error message should contain a direct link a web site that explains how to fix)
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
jujjyl
Nevermind, it turns out that in iOS settings I had Camera globally set to Deny. After resolving that, the NotAllowedError disappeared.
Sorry for the noise!
Alexey Proskuryakov
Thank you for the followup!