Closed Bug 2069310 Opened 2 months ago Closed 2 months ago

[wpt-sync] Sync PR 62348 - Credential Management: test opaque-origin rejection for origin-bound credentials

Categories

(Core :: DOM: Credential Management, task, P4)

task

Tracking

()

RESOLVED FIXED
158 Branch
Tracking Status
firefox158 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 62348 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/62348
Details from upstream follow.

Marcos Caceres <caceres_m@apple.com> wrote:

Credential Management: test opaque-origin rejection for origin-bound credentials

Tests that get(), create() and store() reject with SecurityError when an origin-bound credential is requested from an opaque origin, and that a sandboxed frame with allow-same-origin is not caught by that check. Uses PasswordCredential, since it and FederatedCredential are the origin-bound types Credential Management declares itself.

For https://github.com/w3c/webappsec-credential-management/pull/304. Chrome currently fails six of the nine subtests: get() and store() reject with NotAllowedError rather than SecurityError, and create() from an opaque origin does not reject at all.

Component: web-platform-tests → DOM: Credential Management
Product: Testing → Core

CI Results

Ran 9 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 16 tests and 1 subtests

Status Summary

Firefox

OK : 3[GitHub] 11[Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt]
PASS : 75
FAIL : 49
PRECONDITION_FAILED: 15

Chrome

OK : 3
PASS : 6
FAIL : 9

Safari

OK : 3
PRECONDITION_FAILED: 15

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Details

New Tests That Don't Pass

  • /credential-management/federatedcredential-framed-get.sub.https.html [wpt.fyi]: SKIP
  • /credential-management/otpcredential-get-basics.https.html [wpt.fyi]: SKIP
  • /credential-management/otpcredential-iframe.https.html [wpt.fyi]: SKIP
  • /credential-management/otpcredential-store.https.html [wpt.fyi]: SKIP
  • /credential-management/passwordcredential-framed-get.sub.https.html [wpt.fyi]: SKIP
  • /credential-management/credentialscontainer-create-basics.https.html [wpt.fyi]: OK [Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt], SKIP [Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview]
    • navigator.credentials.create() with valid PasswordCredentialData: FAIL
    • navigator.credentials.create() with valid HTMLFormElement: FAIL
    • navigator.credentials.create() with bogus password data: FAIL
    • navigator.credentials.create() with valid FederatedCredentialData: FAIL
    • navigator.credentials.create() with bogus federated data: FAIL
    • navigator.credentials.create() with bogus password and federated data: FAIL
    • navigator.credentials.create() rejects when aborted after the promise creation: FAIL
  • /credential-management/credentialscontainer-frame-basics.https.html [wpt.fyi]: OK [Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt], SKIP [Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview]
    • navigator.credentials should be undefined in documents generated from data: URLs.: FAIL
  • /credential-management/credentialscontainer-get-basics.https.html [wpt.fyi]: OK [Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt], SKIP [Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview]
    • Calling navigator.credentials.get() with invalid combinations of credential types.: FAIL
    • Calling navigator.credentials.get() with valid combination (password + federated).: FAIL
    • navigator.credentials.get() rejects when aborted after the promise creation: FAIL
  • /credential-management/credentialscontainer-prevent-silent-access.https.html [wpt.fyi]: OK [Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt], SKIP [Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview]
  • /credential-management/historical.https.html [wpt.fyi]: OK [Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt], SKIP [Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview]
  • /credential-management/idlharness.https.window.html [wpt.fyi]: OK [Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt], SKIP [Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview]
    • Credential interface: operation isConditionalMediationAvailable(): FAIL
    • PasswordCredential interface: existence and properties of interface object: FAIL
    • PasswordCredential interface object length: FAIL
    • PasswordCredential interface object name: FAIL
    • PasswordCredential interface: existence and properties of interface prototype object: FAIL
    • PasswordCredential interface: existence and properties of interface prototype object's "constructor" property: FAIL
    • PasswordCredential interface: existence and properties of interface prototype object's @@unscopables property: FAIL
    • PasswordCredential interface: attribute password: FAIL
    • PasswordCredential interface: attribute name: FAIL
    • PasswordCredential interface: attribute iconURL: FAIL
    • PasswordCredential must be primary interface of passwordCredential: FAIL
    • Stringification of passwordCredential: FAIL
    • PasswordCredential interface: passwordCredential must inherit property "password" with the proper type: FAIL
    • PasswordCredential interface: passwordCredential must inherit property "name" with the proper type: FAIL
    • PasswordCredential interface: passwordCredential must inherit property "iconURL" with the proper type: FAIL
    • Credential interface: passwordCredential must inherit property "id" with the proper type: FAIL
    • Credential interface: passwordCredential must inherit property "type" with the proper type: FAIL
    • Credential interface: passwordCredential must inherit property "isConditionalMediationAvailable()" with the proper type: FAIL
    • FederatedCredential interface: existence and properties of interface object: FAIL
    • FederatedCredential interface object length: FAIL
    • FederatedCredential interface object name: FAIL
    • FederatedCredential interface: existence and properties of interface prototype object: FAIL
    • FederatedCredential interface: existence and properties of interface prototype object's "constructor" property: FAIL
    • FederatedCredential interface: existence and properties of interface prototype object's @@unscopables property: FAIL
    • FederatedCredential interface: attribute provider: FAIL
    • FederatedCredential interface: attribute protocol: FAIL
    • FederatedCredential interface: attribute name: FAIL
    • FederatedCredential interface: attribute iconURL: FAIL
    • FederatedCredential must be primary interface of federatedCredential: FAIL
    • Stringification of federatedCredential: FAIL
    • FederatedCredential interface: federatedCredential must inherit property "provider" with the proper type: FAIL
    • FederatedCredential interface: federatedCredential must inherit property "protocol" with the proper type: FAIL
    • FederatedCredential interface: federatedCredential must inherit property "name" with the proper type: FAIL
    • FederatedCredential interface: federatedCredential must inherit property "iconURL" with the proper type: FAIL
    • Credential interface: federatedCredential must inherit property "id" with the proper type: FAIL
    • Credential interface: federatedCredential must inherit property "type" with the proper type: FAIL
    • Credential interface: federatedCredential must inherit property "isConditionalMediationAvailable()" with the proper type: FAIL
  • /credential-management/non-fully-active.https.html [wpt.fyi]: OK [Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt], SKIP [Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview]
    • non-fully active document behavior for CredentialsContainer: FAIL
  • /credential-management/origin-bound-opaque-origin-top-level-allow-same-origin.https.html [wpt.fyi]: OK [Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt, GitHub], SKIP [Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview] (Chrome: OK, Safari: OK)
    • get() from a top-level sandboxed page with allow-same-origin is not rejected as opaque: PRECONDITION_FAILED (Chrome: PASS, Safari: PRECONDITION_FAILED)
    • create() from a top-level sandboxed page with allow-same-origin is not rejected as opaque: PRECONDITION_FAILED (Chrome: PASS, Safari: PRECONDITION_FAILED)
    • store() from a top-level sandboxed page with allow-same-origin is not rejected as opaque: PRECONDITION_FAILED (Chrome: PASS, Safari: PRECONDITION_FAILED)
  • /credential-management/origin-bound-opaque-origin-top-level.https.html [wpt.fyi]: OK [Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt, GitHub], SKIP [Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview] (Chrome: OK, Safari: OK)
    • get() with a PasswordCredential from a top-level opaque origin rejects with SecurityError: PRECONDITION_FAILED (Chrome: FAIL, Safari: PRECONDITION_FAILED)
    • create() with a PasswordCredential from a top-level opaque origin rejects with SecurityError: PRECONDITION_FAILED (Chrome: FAIL, Safari: PRECONDITION_FAILED)
    • store() with a PasswordCredential from a top-level opaque origin rejects with SecurityError: PRECONDITION_FAILED (Chrome: FAIL, Safari: PRECONDITION_FAILED)
  • /credential-management/origin-bound-opaque-origin.https.html [wpt.fyi]: OK [Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt, GitHub], SKIP [Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview] (Chrome: OK, Safari: OK)
    • get() with a PasswordCredential from an opaque origin (sandboxed iframe) rejects with SecurityError: PRECONDITION_FAILED (Chrome: FAIL, Safari: PRECONDITION_FAILED)
    • create() with a PasswordCredential from an opaque origin (sandboxed iframe) rejects with SecurityError: PRECONDITION_FAILED (Chrome: FAIL, Safari: PRECONDITION_FAILED)
    • store() with a PasswordCredential from an opaque origin (sandboxed iframe) rejects with SecurityError: PRECONDITION_FAILED (Chrome: FAIL, Safari: PRECONDITION_FAILED)
    • get() with a PasswordCredential from an opaque origin (iframe whose document has a Content-Security-Policy: sandbox header) rejects with SecurityError: PRECONDITION_FAILED (Chrome: FAIL, Safari: PRECONDITION_FAILED)
    • create() with a PasswordCredential from an opaque origin (iframe whose document has a Content-Security-Policy: sandbox header) rejects with SecurityError: PRECONDITION_FAILED (Chrome: FAIL, Safari: PRECONDITION_FAILED)
    • store() with a PasswordCredential from an opaque origin (iframe whose document has a Content-Security-Policy: sandbox header) rejects with SecurityError: PRECONDITION_FAILED (Chrome: FAIL, Safari: PRECONDITION_FAILED)
    • get() with a PasswordCredential from a non-opaque origin (sandboxed iframe with allow-same-origin) is not rejected as opaque: PRECONDITION_FAILED (Chrome: PASS, Safari: PRECONDITION_FAILED)
    • create() with a PasswordCredential from a non-opaque origin (sandboxed iframe with allow-same-origin) is not rejected as opaque: PRECONDITION_FAILED (Chrome: PASS, Safari: PRECONDITION_FAILED)
    • store() with a PasswordCredential from a non-opaque origin (sandboxed iframe with allow-same-origin) is not rejected as opaque: PRECONDITION_FAILED (Chrome: PASS, Safari: PRECONDITION_FAILED)
  • /credential-management/require_securecontext.html [wpt.fyi]: OK [Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt], SKIP [Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview]

Tests Disabled in Gecko Infrastructure

Status: NEW → RESOLVED
Closed: 2 months ago
Resolution: --- → FIXED
Target Milestone: --- → 158 Branch
You need to log in before you can comment on or make changes to this bug.