You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: storage-access.bs
+9-6Lines changed: 9 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -176,7 +176,7 @@ When invoked on {{Document}} |doc|, the <dfn export method for=Document><code>ha
176
176
1. If |doc|'s [=Document/origin=] is [=same origin=] with the [=top-level origin=] of |doc|'s [=relevant settings object=], [=/resolve=] |p| with true and return |p|.
177
177
1. Let |key| be the result of [=generate a partitioned storage key|generating a partitioned storage key=] from |doc|.
178
178
1. If |key| is failure, [=resolve=] |p| with false and return |p|.
179
-
1. [=Resolve=]or [=reject=]|p| based on the result of running [=determine if a site has storage access=] with |key| and |doc|.
179
+
1. [=Resolve=] |p| with the result of running [=determine if a site has storage access=] with |key| and |doc|.
180
180
1. Return |p|.
181
181
182
182
ISSUE: Shouldn't step 8 be [=same site=]?
@@ -208,9 +208,12 @@ When invoked on {{Document}} |doc|, the <dfn export method for=Document><code>re
208
208
1. [=Determine the storage access policy=] with |key|, |doc| and |hasAccess|.
209
209
1. [=Queue a global task=] on the [=permissions task source=] given |global| to
210
210
1. Set |flag set|'s [=has storage access flag=].
211
-
1. Resolve or reject |p| based on the result of |hasAccess|.
211
+
1. If |hasAccess| is true, resolve |p|.
212
+
1. Reject |p| with a "{{NotAllowedError}}" {{DOMException}}.
212
213
1. Return |p|.
213
214
215
+
ISSUE(privacycg/storage-access#144): We shouldn't use the permissions task source here.
@@ -231,7 +234,7 @@ To <dfn type="abstract-op">determine the storage access policy</dfn> for [=parti
231
234
1. Let |implicitly granted| and |implicitly denied| (each a [=boolean=]) be the result of running an [=implementation-defined=] set of steps to determine if |key|'s [=partitioned storage key/embedded origin=]'s request for storage access on |key|'s [=partitioned storage key/top-level site=] should be granted or denied without prompting the user.
232
235
1. Let |global| be |doc|'s [=relevant global object=].
233
236
1. If |implicitly granted| is true, [=queue a global task=] on the [=permissions task source=] given |global| to [=/resolve=] |p|, and return.
234
-
1. If |implicitly denied| is true, [=queue a global task=] on the [=permissions task source=] given |global| to [=/reject=] |p| with a "{{NotAllowedError}}" {{DOMException}}, and return |p|.
237
+
1. If |implicitly denied| is true, [=queue a global task=] on the [=permissions task source=] given |global| to [=/reject=] |p| with a "{{NotAllowedError}}" {{DOMException}}, and return.
235
238
1. Let |permissionState| be the result of [=requesting permission to use=] "<a permission><code>storage-access</code></a>".
236
239
1. If |permissionState| is "granted", [=queue a global task=] on the [=permissions task source=] given |global| to [=/resolve=] |p|, and return.
@@ -287,7 +290,7 @@ The Storage Access API defines a [=powerful feature=] identified by the [=powerf
287
290
</dd>
288
291
<dt>[=powerful feature/permission key type=]</dt>
289
292
<dd>
290
-
A [=permission key=] of the "<a permission><code>storage-access</code></a>" feature has the type ([=site=], [=/origin=]).
293
+
A [=permission key=] of the "<a permission><code>storage-access</code></a>" feature is a [=tuple=] consisting of a [=site=]<dfn for="permission key">key site</dfn> and an [=/origin=]<dfn for="permission key">key origin</dfn>.
0 commit comments