Bug 220416
| Summary: | WKWebView getUserMedia persistent permissions | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Kyle Dunn <kpd400> |
| Component: | WebRTC | Assignee: | Nobody <webkit-unassigned> |
| Status: | RESOLVED DUPLICATE | ||
| Severity: | Normal | CC: | animaonline, david.goelzhaeuser, dustin.greif, lwarlow, mauricio, rocketboy2015, webkit-bug-importer, youennf |
| Priority: | P2 | Keywords: | InRadar |
| Version: | Safari 14 | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
Kyle Dunn
Are there any plans to allow users the ability to persistently allow camera/microphone access to a particular host within WKWebView?
e.g. A users app-level permission persists indefinitely, but the web-level permission does not persist when reloading the page.
Even respecting the Safari setting for "Allow Camera Access on All Websites: ALLOW" would be an acceptable workaround to avoid the repetitive prompts.
Thanks in advance.
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Radar WebKit Bug Importer
<rdar://problem/72890455>
youenn fablet
Yes, the plan is to further improve WKWebView APIs to control this.
Kyle Dunn
(In reply to youenn fablet from comment #2)
> Yes, the plan is to further improve WKWebView APIs to control this.
Great, thank you for the quick response Youenn!
Dustin Greif
(In reply to youenn fablet from comment #2)
> Yes, the plan is to further improve WKWebView APIs to control this.
Is there any timeline for when this new API will be released? Even something as simple as "next couple months" vs "next year or two" would make a big impact on how we choose to develop our hybrid apps. Having getUserMedia available in WKWebView is a MASSIVE improvement, but it's still unusable in a production app with these recurring permission prompts. Really appreciate your teams continued improvements on this front!
Mauricio W
(In reply to Dustin Greif from comment #4)
> Is there any timeline for when this new API will be released? Even
> something as simple as "next couple months" vs "next year or two" would make
> a big impact on how we choose to develop our hybrid apps. Having
> getUserMedia available in WKWebView is a MASSIVE improvement, but it's still
> unusable in a production app with these recurring permission prompts.
> Really appreciate your teams continued improvements on this front!
Just mentioning this in case you didn't already know:
If you call getUserMedia, you can leave the stream open for up to 24 hours before the next request (or the user closes the app). It's definitely not a solution to the problem, but it does cut down the amount of requests a user gets.
There is the drawback that, even if you set track.enabled to false, the recording indicator remains on. I've had at least two users reach out asking about that.
Jurung Park
I think this should be resolved.
Is there any solution such as editing core(?) swift codes?
Even if that kind of solution is not simple, we feel like fixing this problem by self.
David Gölzhäuser
I think the permission handling should fallback to the host application if the Website is presented in a WKWebView. A DelegateCall or some kind of config could be used to configure this behavior.
Really appreciate the support of getUserMedia in WKWebView guys:)
Roman Alifanov
Any updates on this? This is more than needed now when WKWebView finally supports WebRTC on iOS.
youenn fablet
*** This bug has been marked as a duplicate of bug 223806 ***
Kyle Dunn
FYI - the fix for this appears to have landed in iOS 15. The particulars for this addition are demo'd @ 14:40 here: https://developer.apple.com/videos/play/wwdc2021/10032/