WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED DUPLICATE of
bug 293089
275479
Geolocation Permissions API on iOS does not report 24h grant as `GRANTED`
https://bugs.webkit.org/show_bug.cgi?id=275479
Summary
Geolocation Permissions API on iOS does not report 24h grant as `GRANTED`
smoser
Reported
2024-06-14 04:10:50 PDT
After accepting a geolocation prompt twice within a short time frame on iOS, geolocation calls return location without additional prompts for the next 24h. During this time, the permission API reports `PROMPT`, not `GRANTED` Using [this testing site](
https://permission.site/permission-status
), I tested the behavior of the permission API on iOS. I took these steps: 1. Enable Location Services in iOS settings 2. Enable Location Services for Safari in settings 3. Get a geolocation prompt -> Allow 4. Reload the page 5. Get a geolocation prompt -> Allow 6. Reload the page Expected behavior In step 6, `navigator.permissions.query({ name: 'geolocation' })`, i.e. "Permission Status" reports `GRANTED` Observed behavior: In step 6, `navigator.permissions.query({ name: 'geolocation' })`, i.e. "Permission Status" still reports `PROMPT` We want to provide a consistent end-to-end experience between content-area UI and browser-side UX. To do that, we need to understand how the browser UX will behave if (for example) we call the browser’s geolocation API -- will a permission prompt be shown? Or is the permission already granted or denied?
Attachments
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2024-06-21 04:11:13 PDT
<
rdar://problem/130269340
>
rupin
Comment 2
2025-05-27 10:11:31 PDT
This is indeed a bug. The Permissions API should reported a 24h grant as granted. We also believe the Permissions API should only return the true permissions state of the Geolocation if the site has requested to use the Geolocation API since the page load. So the correct behavior here is: After step 6, navigator.permissions.query({ name: 'geolocation' }) will report GRANTED BUT only after the page attempts to use the Geolocation API again (call getCurrentLocation for example). Until the site does that, navigator.permissions.query({ name: 'geolocation' }) will report PROMPT This was fixed in
https://bugs.webkit.org/show_bug.cgi?id=293089
as well as a different change in another repository.
rupin
Comment 3
2025-06-06 19:43:13 PDT
*** This bug has been marked as a duplicate of
bug 293089
***
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug