<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>228317</bug_id>
          
          <creation_ts>2021-07-27 00:00:56 -0700</creation_ts>
          <short_desc>Permissions for Camera expires after some time</short_desc>
          <delta_ts>2022-02-13 10:55:43 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>WebRTC</component>
          <version>Safari 14</version>
          <rep_platform>iPhone / iPad</rep_platform>
          <op_sys>iOS 14</op_sys>
          <bug_status>NEW</bug_status>
          <resolution></resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>jakubesuszynski</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>ap</cc>
    
    <cc>eric.carlson</cc>
    
    <cc>jer.noble</cc>
    
    <cc>marek.aug</cc>
    
    <cc>webkit-bug-importer</cc>
    
    <cc>youennf</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1779697</commentid>
    <comment_count>0</comment_count>
    <who name="">jakubesuszynski</who>
    <bug_when>2021-07-27 00:00:56 -0700</bug_when>
    <thetext>I&apos;ve a case where I fetch HTML from the backend and load it in WKWebView. It ask&apos;s me for camera permission for the URL I set. This HTML also fetches a quite big script, so it&apos;s expensive operation. After that I don&apos;t kill the View Controller, only dismiss it, so when user open it again, HTML is still loaded and ready. However, after some time with camera activated (I&apos;m throwing a track&apos;s stream as a source for &lt;video /&gt; element) it just stops working - preview disappears. When I try to hit navigator.mediaDevices.getUserMedia() again, it just not resolve and quits script with no error. Is it intended? 

Also, Is is even possible to keep the permission after granting it once? App has camera permission, but WebView asks for it every time I init it</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1781558</commentid>
    <comment_count>1</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2021-08-03 00:01:17 -0700</bug_when>
    <thetext>&lt;rdar://problem/81447591&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1785784</commentid>
    <comment_count>2</comment_count>
    <who name="youenn fablet">youennf</who>
    <bug_when>2021-08-20 04:57:36 -0700</bug_when>
    <thetext>@jakube, do you have a repro case. Is it only happening in WKWebView or can you reproduce in Safari?

As of permission granting, you can use WKWebView delegates to grant persistent permissions available in latest iOS 15 betas.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>