tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

isuserverifyingplatformauthenticatoravailable.https.html (1237B)


      1 <!DOCTYPE html>
      2 <meta charset="utf-8">
      3 <title>PublicKeyCredential.isUserVerifyingPlatformAuthenticatorAvailable</title>
      4 <script src="/resources/testharness.js"></script>
      5 <script src="/resources/testharnessreport.js"></script>
      6 <script src="/resources/testdriver.js"></script>
      7 <script src="/resources/testdriver-vendor.js"></script>
      8 <script src=helpers.js></script>
      9 
     10 <body></body>
     11 <script>
     12  const TESTS = [
     13    {
     14      transport: "usb",
     15      hasUserVerification: true,
     16      expectedIsuvpaa: false,
     17      name: "No platform authenticator",
     18    },
     19    {
     20      transport: "internal",
     21      hasUserVerification: false,
     22      expectedIsuvpaa: false,
     23      name: "Non-user-verifying platform authenticator",
     24    },
     25    {
     26      transport: "internal",
     27      hasUserVerification: true,
     28      expectedIsuvpaa: true,
     29      name: "User verifying platform authenticator"
     30    },
     31  ];
     32 
     33  for (const test of TESTS) {
     34    virtualAuthenticatorPromiseTest(async _ => {
     35      assert_equals(
     36        await PublicKeyCredential.isUserVerifyingPlatformAuthenticatorAvailable(),
     37        test.expectedIsuvpaa);
     38    }, {
     39      protocol: "ctap2",
     40      transport: test.transport,
     41      hasUserVerification: test.hasUserVerification
     42    }, test.name);
     43  }
     44 </script>