Changeset 279688 in webkit


Ignore:
Timestamp:
Jul 7, 2021 5:25:46 PM (13 months ago)
Author:
Chris Dumez
Message:

[WebCrypto] Support Elliptic Curve P-521 on Mac
https://bugs.webkit.org/show_bug.cgi?id=216755
<rdar://problem/69667220>

Reviewed by Alex Christensen.

LayoutTests/imported/w3c:

Rebaseline WPT test now that a lot more checks are passing.

  • web-platform-tests/WebCryptoAPI/derive_bits_keys/ecdh_bits.https.any-expected.txt:
  • web-platform-tests/WebCryptoAPI/derive_bits_keys/ecdh_bits.https.any.worker-expected.txt:
  • web-platform-tests/WebCryptoAPI/derive_bits_keys/ecdh_keys.https.any-expected.txt:
  • web-platform-tests/WebCryptoAPI/derive_bits_keys/ecdh_keys.https.any.worker-expected.txt:
  • web-platform-tests/WebCryptoAPI/generateKey/failures_ECDH.https.any-expected.txt:
  • web-platform-tests/WebCryptoAPI/generateKey/failures_ECDH.https.any.worker-expected.txt:
  • web-platform-tests/WebCryptoAPI/generateKey/failures_ECDSA.https.any-expected.txt:
  • web-platform-tests/WebCryptoAPI/generateKey/failures_ECDSA.https.any.worker-expected.txt:
  • web-platform-tests/WebCryptoAPI/generateKey/successes_ECDH.https.any-expected.txt:
  • web-platform-tests/WebCryptoAPI/generateKey/successes_ECDH.https.any.worker-expected.txt:
  • web-platform-tests/WebCryptoAPI/generateKey/successes_ECDSA.https.any-expected.txt:
  • web-platform-tests/WebCryptoAPI/generateKey/successes_ECDSA.https.any.worker-expected.txt:
  • web-platform-tests/WebCryptoAPI/import_export/ec_importKey.https.any-expected.txt:
  • web-platform-tests/WebCryptoAPI/import_export/ec_importKey.https.any.worker-expected.txt:
  • web-platform-tests/WebCryptoAPI/sign_verify/ecdsa.https.any-expected.txt:
  • web-platform-tests/WebCryptoAPI/sign_verify/ecdsa.https.any.worker-expected.txt:

Source/WebCore:

Add support for Elliptic Curve P-521 in WebCrypto for ECDSA and ECDH, on macOS.
Both Gecko and Blink already support this.

No new tests, rebaselined existing tests.

  • crypto/mac/CryptoAlgorithmECDHMac.cpp:

(WebCore::CryptoAlgorithmECDH::platformDeriveBits):

  • crypto/mac/CryptoAlgorithmECDSAMac.cpp:

Use std::ceil() when converting bits to bytes since 521 is not a multiple of 8.
This is as per Section 2.3.4 of http://www.secg.org/sec1-v2.pdf, which indicates
we should use ceil().

(WebCore::signECDSA):
Stop assuming the length can be encoded in a single byte as this is not true with
P-521 (values >= 128 require 2 bytes).

(WebCore::verifyECDSA):
Do not reject the promise when CCECCryptorVerifyHash() fails and instead return
false to indicate that the signature fails. This was needed to pass a few more
WPT checks. We do not do much validation on r and s before passing them to
CommonCrypto and CCECCryptorVerifyHash() may return a kCCNotVerified error when
the input signature is invalid (invalid signatures are tested by WPT tests).

(WebCore::CryptoAlgorithmECDSA::platformSign):
(WebCore::CryptoAlgorithmECDSA::platformVerify):

  • crypto/mac/CryptoKeyECMac.cpp:

(WebCore::doesUncompressedPointMatchNamedCurve):
(WebCore::doesFieldElementMatchNamedCurve):
(WebCore::getKeySizeFromNamedCurve):
(WebCore::CryptoKeyEC::platformSupportedCurve):
(WebCore::CryptoKeyEC::platformExportRaw const):
(WebCore::CryptoKeyEC::platformAddFieldElements const):
(WebCore::getOID):
(WebCore::CryptoKeyEC::platformExportSpki const):
(WebCore::CryptoKeyEC::platformImportPkcs8):
(WebCore::CryptoKeyEC::platformExportPkcs8 const):
Add support for P-521 and use std::ceil() when converting bits to bytes since
521 is not a multiple of 8.

LayoutTests:

Update / rebaseline a few tests now that we support P-521.

  • crypto/subtle/ec-generate-key-malformed-parameters-expected.txt:
  • crypto/subtle/ec-generate-key-malformed-parameters.html:
  • crypto/subtle/ecdh-derive-bits-length-limits-expected.txt:
Location:
trunk
Files:
26 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r279684 r279688  
     12021-07-07  Chris Dumez  <cdumez@apple.com>
     2
     3        [WebCrypto] Support Elliptic Curve P-521 on Mac
     4        https://bugs.webkit.org/show_bug.cgi?id=216755
     5        <rdar://problem/69667220>
     6
     7        Reviewed by Alex Christensen.
     8
     9        Update / rebaseline a few tests now that we support P-521.
     10
     11        * crypto/subtle/ec-generate-key-malformed-parameters-expected.txt:
     12        * crypto/subtle/ec-generate-key-malformed-parameters.html:
     13        * crypto/subtle/ecdh-derive-bits-length-limits-expected.txt:
     14
    1152021-07-07  Eric Hutchison  <ehutchison@apple.com>
    216
  • trunk/LayoutTests/crypto/subtle/ec-generate-key-malformed-parameters-expected.txt

    r219663 r279688  
    2424PASS crypto.subtle.generateKey({name: "ecdsa", namedCurve: "P-256"}, extractable, ["wrapKey"]) rejected promise  with SyntaxError: A required parameter was missing or out-of-range.
    2525PASS crypto.subtle.generateKey({name: "ecdsa", namedCurve: "P-256"}, extractable, ["unwrapKey"]) rejected promise  with SyntaxError: A required parameter was missing or out-of-range.
    26 PASS crypto.subtle.generateKey({name: "ecdh", namedCurve: "P-521"}, extractable, ["deriveKey"]) rejected promise  with NotSupportedError: The algorithm is not supported.
     26PASS crypto.subtle.generateKey({name: "ecdh", namedCurve: "P-523"}, extractable, ["deriveKey"]) rejected promise  with NotSupportedError: The algorithm is not supported.
    2727PASS successfullyParsed is true
    2828
  • trunk/LayoutTests/crypto/subtle/ec-generate-key-malformed-parameters.html

    r215423 r279688  
    3737shouldReject('crypto.subtle.generateKey({name: "ecdsa", namedCurve: "P-256"}, extractable, ["unwrapKey"])');
    3838// Not supported NamedCurve
    39 shouldReject('crypto.subtle.generateKey({name: "ecdh", namedCurve: "P-521"}, extractable, ["deriveKey"])');
     39shouldReject('crypto.subtle.generateKey({name: "ecdh", namedCurve: "P-523"}, extractable, ["deriveKey"])');
    4040</script>
    4141
  • trunk/LayoutTests/crypto/subtle/ecdh-derive-bits-length-limits-expected.txt

    r221345 r279688  
    1414PASS Bit derivations for EC P-384 with minimum and maximum lengths succeeded
    1515PASS deriveBits(P384, 384 + 8) rejected promise  with OperationError: The operation failed for an operation-specific reason.
    16 Bit derivations for EC P-521 skipped, likely due to missing P-521 supprot.
     16PASS deriveBits(..., 0) successfully derived 528 bits for a P-521 curve
     17PASS deriveBits(..., 8) successfully derived 8 bits for a P-521 curve
     18PASS deriveBits(..., 528) successfully derived 528 bits for a P-521 curve
     19PASS Bit derivations for EC P-521 with minimum and maximum lengths succeeded
     20PASS deriveBits(P521, 528 + 8) rejected promise  with OperationError: The operation failed for an operation-specific reason.
    1721PASS successfullyParsed is true
    1822
  • trunk/LayoutTests/imported/w3c/ChangeLog

    r279686 r279688  
     12021-07-07  Chris Dumez  <cdumez@apple.com>
     2
     3        [WebCrypto] Support Elliptic Curve P-521 on Mac
     4        https://bugs.webkit.org/show_bug.cgi?id=216755
     5        <rdar://problem/69667220>
     6
     7        Reviewed by Alex Christensen.
     8
     9        Rebaseline WPT test now that a lot more checks are passing.
     10
     11        * web-platform-tests/WebCryptoAPI/derive_bits_keys/ecdh_bits.https.any-expected.txt:
     12        * web-platform-tests/WebCryptoAPI/derive_bits_keys/ecdh_bits.https.any.worker-expected.txt:
     13        * web-platform-tests/WebCryptoAPI/derive_bits_keys/ecdh_keys.https.any-expected.txt:
     14        * web-platform-tests/WebCryptoAPI/derive_bits_keys/ecdh_keys.https.any.worker-expected.txt:
     15        * web-platform-tests/WebCryptoAPI/generateKey/failures_ECDH.https.any-expected.txt:
     16        * web-platform-tests/WebCryptoAPI/generateKey/failures_ECDH.https.any.worker-expected.txt:
     17        * web-platform-tests/WebCryptoAPI/generateKey/failures_ECDSA.https.any-expected.txt:
     18        * web-platform-tests/WebCryptoAPI/generateKey/failures_ECDSA.https.any.worker-expected.txt:
     19        * web-platform-tests/WebCryptoAPI/generateKey/successes_ECDH.https.any-expected.txt:
     20        * web-platform-tests/WebCryptoAPI/generateKey/successes_ECDH.https.any.worker-expected.txt:
     21        * web-platform-tests/WebCryptoAPI/generateKey/successes_ECDSA.https.any-expected.txt:
     22        * web-platform-tests/WebCryptoAPI/generateKey/successes_ECDSA.https.any.worker-expected.txt:
     23        * web-platform-tests/WebCryptoAPI/import_export/ec_importKey.https.any-expected.txt:
     24        * web-platform-tests/WebCryptoAPI/import_export/ec_importKey.https.any.worker-expected.txt:
     25        * web-platform-tests/WebCryptoAPI/sign_verify/ecdsa.https.any-expected.txt:
     26        * web-platform-tests/WebCryptoAPI/sign_verify/ecdsa.https.any.worker-expected.txt:
     27
    1282021-07-07  Chris Dumez  <cdumez@apple.com>
    229
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/derive_bits_keys/ecdh_bits.https.any-expected.txt

    r263598 r279688  
    11
    2 FAIL setup - define tests promise_test: Unhandled rejection with value: object "DataError: Data provided to an operation does not meet requirements"
     2PASS setup - define tests
     3PASS P-521 good parameters
     4PASS P-521 mixed case parameters
     5PASS P-521 with null length
     6PASS P-521 short result
     7FAIL P-521 non-multiple of 8 bits assert_unreached: deriveBits failed with error OperationError: The operation failed for an operation-specific reason Reached unreachable code
     8PASS P-521 missing public curve
     9PASS P-521 public property of algorithm is not a CryptoKey
     10PASS P-521 mismatched curves
     11PASS P-521 public property of algorithm is not an ECDSA public key
     12PASS P-521 no deriveBits usage for base key
     13PASS P-521 base key is not a private key
     14PASS P-521 public property value is a private key
     15PASS P-521 public property value is a secret key
     16PASS P-521 asking for too many bits
     17PASS P-256 good parameters
     18PASS P-256 mixed case parameters
     19PASS P-256 with null length
     20PASS P-256 short result
     21FAIL P-256 non-multiple of 8 bits assert_unreached: deriveBits failed with error OperationError: The operation failed for an operation-specific reason Reached unreachable code
     22PASS P-256 missing public curve
     23PASS P-256 public property of algorithm is not a CryptoKey
     24PASS P-256 mismatched curves
     25PASS P-256 public property of algorithm is not an ECDSA public key
     26PASS P-256 no deriveBits usage for base key
     27PASS P-256 base key is not a private key
     28PASS P-256 public property value is a private key
     29PASS P-256 public property value is a secret key
     30PASS P-256 asking for too many bits
     31PASS P-384 good parameters
     32PASS P-384 mixed case parameters
     33PASS P-384 with null length
     34PASS P-384 short result
     35FAIL P-384 non-multiple of 8 bits assert_unreached: deriveBits failed with error OperationError: The operation failed for an operation-specific reason Reached unreachable code
     36PASS P-384 missing public curve
     37PASS P-384 public property of algorithm is not a CryptoKey
     38PASS P-384 mismatched curves
     39PASS P-384 public property of algorithm is not an ECDSA public key
     40PASS P-384 no deriveBits usage for base key
     41PASS P-384 base key is not a private key
     42PASS P-384 public property value is a private key
     43PASS P-384 public property value is a secret key
     44PASS P-384 asking for too many bits
    345
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/derive_bits_keys/ecdh_bits.https.any.worker-expected.txt

    r253630 r279688  
    11
    2 FAIL setup - define tests promise_test: Unhandled rejection with value: object "DataError: Data provided to an operation does not meet requirements"
     2PASS setup - define tests
     3PASS P-521 good parameters
     4PASS P-521 mixed case parameters
     5PASS P-521 with null length
     6PASS P-521 short result
     7FAIL P-521 non-multiple of 8 bits assert_unreached: deriveBits failed with error OperationError: The operation failed for an operation-specific reason Reached unreachable code
     8PASS P-521 missing public curve
     9PASS P-521 public property of algorithm is not a CryptoKey
     10PASS P-521 mismatched curves
     11PASS P-521 public property of algorithm is not an ECDSA public key
     12PASS P-521 no deriveBits usage for base key
     13PASS P-521 base key is not a private key
     14PASS P-521 public property value is a private key
     15PASS P-521 public property value is a secret key
     16PASS P-521 asking for too many bits
     17PASS P-256 good parameters
     18PASS P-256 mixed case parameters
     19PASS P-256 with null length
     20PASS P-256 short result
     21FAIL P-256 non-multiple of 8 bits assert_unreached: deriveBits failed with error OperationError: The operation failed for an operation-specific reason Reached unreachable code
     22PASS P-256 missing public curve
     23PASS P-256 public property of algorithm is not a CryptoKey
     24PASS P-256 mismatched curves
     25PASS P-256 public property of algorithm is not an ECDSA public key
     26PASS P-256 no deriveBits usage for base key
     27PASS P-256 base key is not a private key
     28PASS P-256 public property value is a private key
     29PASS P-256 public property value is a secret key
     30PASS P-256 asking for too many bits
     31PASS P-384 good parameters
     32PASS P-384 mixed case parameters
     33PASS P-384 with null length
     34PASS P-384 short result
     35FAIL P-384 non-multiple of 8 bits assert_unreached: deriveBits failed with error OperationError: The operation failed for an operation-specific reason Reached unreachable code
     36PASS P-384 missing public curve
     37PASS P-384 public property of algorithm is not a CryptoKey
     38PASS P-384 mismatched curves
     39PASS P-384 public property of algorithm is not an ECDSA public key
     40PASS P-384 no deriveBits usage for base key
     41PASS P-384 base key is not a private key
     42PASS P-384 public property value is a private key
     43PASS P-384 public property value is a secret key
     44PASS P-384 asking for too many bits
    345
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/derive_bits_keys/ecdh_keys.https.any-expected.txt

    r263598 r279688  
    11
    2 FAIL setup - define tests promise_test: Unhandled rejection with value: object "DataError: Data provided to an operation does not meet requirements"
     2PASS setup - define tests
     3PASS P-521 good parameters
     4PASS P-521 mixed case parameters
     5PASS P-521 missing public curve
     6PASS P-521 public property of algorithm is not a CryptoKey
     7PASS P-521 mismatched curves
     8PASS P-521 public property of algorithm is not an ECDSA public key
     9PASS P-521 no deriveKey usage for base key
     10PASS P-521 base key is not a private key
     11PASS P-521 public property value is a private key
     12PASS P-521 public property value is a secret key
     13PASS P-256 good parameters
     14PASS P-256 mixed case parameters
     15PASS P-256 missing public curve
     16PASS P-256 public property of algorithm is not a CryptoKey
     17PASS P-256 mismatched curves
     18PASS P-256 public property of algorithm is not an ECDSA public key
     19PASS P-256 no deriveKey usage for base key
     20PASS P-256 base key is not a private key
     21PASS P-256 public property value is a private key
     22PASS P-256 public property value is a secret key
     23PASS P-384 good parameters
     24PASS P-384 mixed case parameters
     25PASS P-384 missing public curve
     26PASS P-384 public property of algorithm is not a CryptoKey
     27PASS P-384 mismatched curves
     28PASS P-384 public property of algorithm is not an ECDSA public key
     29PASS P-384 no deriveKey usage for base key
     30PASS P-384 base key is not a private key
     31PASS P-384 public property value is a private key
     32PASS P-384 public property value is a secret key
    333
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/derive_bits_keys/ecdh_keys.https.any.worker-expected.txt

    r253630 r279688  
    11
    2 FAIL setup - define tests promise_test: Unhandled rejection with value: object "DataError: Data provided to an operation does not meet requirements"
     2PASS setup - define tests
     3PASS P-521 good parameters
     4PASS P-521 mixed case parameters
     5PASS P-521 missing public curve
     6PASS P-521 public property of algorithm is not a CryptoKey
     7PASS P-521 mismatched curves
     8PASS P-521 public property of algorithm is not an ECDSA public key
     9PASS P-521 no deriveKey usage for base key
     10PASS P-521 base key is not a private key
     11PASS P-521 public property value is a private key
     12PASS P-521 public property value is a secret key
     13PASS P-256 good parameters
     14PASS P-256 mixed case parameters
     15PASS P-256 missing public curve
     16PASS P-256 public property of algorithm is not a CryptoKey
     17PASS P-256 mismatched curves
     18PASS P-256 public property of algorithm is not an ECDSA public key
     19PASS P-256 no deriveKey usage for base key
     20PASS P-256 base key is not a private key
     21PASS P-256 public property value is a private key
     22PASS P-256 public property value is a secret key
     23PASS P-384 good parameters
     24PASS P-384 mixed case parameters
     25PASS P-384 missing public curve
     26PASS P-384 public property of algorithm is not a CryptoKey
     27PASS P-384 mismatched curves
     28PASS P-384 public property of algorithm is not an ECDSA public key
     29PASS P-384 no deriveKey usage for base key
     30PASS P-384 base key is not a private key
     31PASS P-384 public property value is a private key
     32PASS P-384 public property value is a secret key
    333
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/generateKey/failures_ECDH.https.any-expected.txt

    r267651 r279688  
    438438PASS Empty usages: generateKey({name: ECDH, namedCurve: P-384}, false, [])
    439439PASS Empty usages: generateKey({name: ECDH, namedCurve: P-384}, true, [])
    440 FAIL Empty usages: generateKey({name: ECDH, namedCurve: P-521}, false, []) assert_equals: Empty usages not supported expected "SyntaxError" but got "NotSupportedError"
    441 FAIL Empty usages: generateKey({name: ECDH, namedCurve: P-521}, true, []) assert_equals: Empty usages not supported expected "SyntaxError" but got "NotSupportedError"
     440PASS Empty usages: generateKey({name: ECDH, namedCurve: P-521}, false, [])
     441PASS Empty usages: generateKey({name: ECDH, namedCurve: P-521}, true, [])
    442442
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/generateKey/failures_ECDH.https.any.worker-expected.txt

    r267651 r279688  
    438438PASS Empty usages: generateKey({name: ECDH, namedCurve: P-384}, false, [])
    439439PASS Empty usages: generateKey({name: ECDH, namedCurve: P-384}, true, [])
    440 FAIL Empty usages: generateKey({name: ECDH, namedCurve: P-521}, false, []) assert_equals: Empty usages not supported expected "SyntaxError" but got "NotSupportedError"
    441 FAIL Empty usages: generateKey({name: ECDH, namedCurve: P-521}, true, []) assert_equals: Empty usages not supported expected "SyntaxError" but got "NotSupportedError"
     440PASS Empty usages: generateKey({name: ECDH, namedCurve: P-521}, false, [])
     441PASS Empty usages: generateKey({name: ECDH, namedCurve: P-521}, true, [])
    442442
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/generateKey/failures_ECDSA.https.any-expected.txt

    r267651 r279688  
    416416PASS Empty usages: generateKey({name: ECDSA, namedCurve: P-384}, false, [])
    417417PASS Empty usages: generateKey({name: ECDSA, namedCurve: P-384}, true, [])
    418 FAIL Empty usages: generateKey({name: ECDSA, namedCurve: P-521}, false, []) assert_equals: Empty usages not supported expected "SyntaxError" but got "NotSupportedError"
    419 FAIL Empty usages: generateKey({name: ECDSA, namedCurve: P-521}, true, []) assert_equals: Empty usages not supported expected "SyntaxError" but got "NotSupportedError"
     418PASS Empty usages: generateKey({name: ECDSA, namedCurve: P-521}, false, [])
     419PASS Empty usages: generateKey({name: ECDSA, namedCurve: P-521}, true, [])
    420420
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/generateKey/failures_ECDSA.https.any.worker-expected.txt

    r267651 r279688  
    416416PASS Empty usages: generateKey({name: ECDSA, namedCurve: P-384}, false, [])
    417417PASS Empty usages: generateKey({name: ECDSA, namedCurve: P-384}, true, [])
    418 FAIL Empty usages: generateKey({name: ECDSA, namedCurve: P-521}, false, []) assert_equals: Empty usages not supported expected "SyntaxError" but got "NotSupportedError"
    419 FAIL Empty usages: generateKey({name: ECDSA, namedCurve: P-521}, true, []) assert_equals: Empty usages not supported expected "SyntaxError" but got "NotSupportedError"
     418PASS Empty usages: generateKey({name: ECDSA, namedCurve: P-521}, false, [])
     419PASS Empty usages: generateKey({name: ECDSA, namedCurve: P-521}, true, [])
    420420
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/generateKey/successes_ECDH.https.any-expected.txt

    r267651 r279688  
    1616PASS Success: generateKey({name: ECDH, namedCurve: P-384}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    1717PASS Success: generateKey({name: ECDH, namedCurve: P-384}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    18 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    19 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    20 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    21 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    22 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    23 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    24 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    25 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
     18PASS Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveKey])
     19PASS Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveKey])
     20PASS Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveBits, deriveKey])
     21PASS Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveBits, deriveKey])
     22PASS Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveBits])
     23PASS Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveBits])
     24PASS Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
     25PASS Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    2626PASS Success: generateKey({name: ecdh, namedCurve: P-256}, false, [deriveKey])
    2727PASS Success: generateKey({name: ecdh, namedCurve: P-256}, true, [deriveKey])
     
    4040PASS Success: generateKey({name: ecdh, namedCurve: P-384}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    4141PASS Success: generateKey({name: ecdh, namedCurve: P-384}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    42 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    43 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    44 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    45 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    46 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    47 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    48 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    49 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
     42PASS Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveKey])
     43PASS Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveKey])
     44PASS Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveBits, deriveKey])
     45PASS Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveBits, deriveKey])
     46PASS Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveBits])
     47PASS Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveBits])
     48PASS Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
     49PASS Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    5050PASS Success: generateKey({name: Ecdh, namedCurve: P-256}, false, [deriveKey])
    5151PASS Success: generateKey({name: Ecdh, namedCurve: P-256}, true, [deriveKey])
     
    6464PASS Success: generateKey({name: Ecdh, namedCurve: P-384}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    6565PASS Success: generateKey({name: Ecdh, namedCurve: P-384}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    66 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    67 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    68 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    69 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    70 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    71 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    72 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    73 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
     66PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveKey])
     67PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveKey])
     68PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveBits, deriveKey])
     69PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveBits, deriveKey])
     70PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveBits])
     71PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveBits])
     72PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
     73PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    7474
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/generateKey/successes_ECDH.https.any.worker-expected.txt

    r267651 r279688  
    1616PASS Success: generateKey({name: ECDH, namedCurve: P-384}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    1717PASS Success: generateKey({name: ECDH, namedCurve: P-384}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    18 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    19 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    20 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    21 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    22 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    23 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    24 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    25 FAIL Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
     18PASS Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveKey])
     19PASS Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveKey])
     20PASS Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveBits, deriveKey])
     21PASS Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveBits, deriveKey])
     22PASS Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveBits])
     23PASS Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveBits])
     24PASS Success: generateKey({name: ECDH, namedCurve: P-521}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
     25PASS Success: generateKey({name: ECDH, namedCurve: P-521}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    2626PASS Success: generateKey({name: ecdh, namedCurve: P-256}, false, [deriveKey])
    2727PASS Success: generateKey({name: ecdh, namedCurve: P-256}, true, [deriveKey])
     
    4040PASS Success: generateKey({name: ecdh, namedCurve: P-384}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    4141PASS Success: generateKey({name: ecdh, namedCurve: P-384}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    42 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    43 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    44 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    45 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    46 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    47 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    48 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    49 FAIL Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
     42PASS Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveKey])
     43PASS Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveKey])
     44PASS Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveBits, deriveKey])
     45PASS Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveBits, deriveKey])
     46PASS Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveBits])
     47PASS Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveBits])
     48PASS Success: generateKey({name: ecdh, namedCurve: P-521}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
     49PASS Success: generateKey({name: ecdh, namedCurve: P-521}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    5050PASS Success: generateKey({name: Ecdh, namedCurve: P-256}, false, [deriveKey])
    5151PASS Success: generateKey({name: Ecdh, namedCurve: P-256}, true, [deriveKey])
     
    6464PASS Success: generateKey({name: Ecdh, namedCurve: P-384}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    6565PASS Success: generateKey({name: Ecdh, namedCurve: P-384}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    66 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    67 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    68 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    69 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    70 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    71 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    72 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    73 FAIL Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
     66PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveKey])
     67PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveKey])
     68PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveBits, deriveKey])
     69PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveBits, deriveKey])
     70PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveBits])
     71PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveBits])
     72PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, false, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
     73PASS Success: generateKey({name: Ecdh, namedCurve: P-521}, true, [deriveKey, deriveBits, deriveKey, deriveBits, deriveKey, deriveBits])
    7474
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/generateKey/successes_ECDSA.https.any-expected.txt

    r267651 r279688  
    1212PASS Success: generateKey({name: ECDSA, namedCurve: P-384}, false, [sign, verify, sign, sign, verify])
    1313PASS Success: generateKey({name: ECDSA, namedCurve: P-384}, true, [sign, verify, sign, sign, verify])
    14 FAIL Success: generateKey({name: ECDSA, namedCurve: P-521}, false, [sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    15 FAIL Success: generateKey({name: ECDSA, namedCurve: P-521}, true, [sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    16 FAIL Success: generateKey({name: ECDSA, namedCurve: P-521}, false, [verify, sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    17 FAIL Success: generateKey({name: ECDSA, namedCurve: P-521}, true, [verify, sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    18 FAIL Success: generateKey({name: ECDSA, namedCurve: P-521}, false, [sign, verify, sign, sign, verify]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    19 FAIL Success: generateKey({name: ECDSA, namedCurve: P-521}, true, [sign, verify, sign, sign, verify]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
     14PASS Success: generateKey({name: ECDSA, namedCurve: P-521}, false, [sign])
     15PASS Success: generateKey({name: ECDSA, namedCurve: P-521}, true, [sign])
     16PASS Success: generateKey({name: ECDSA, namedCurve: P-521}, false, [verify, sign])
     17PASS Success: generateKey({name: ECDSA, namedCurve: P-521}, true, [verify, sign])
     18PASS Success: generateKey({name: ECDSA, namedCurve: P-521}, false, [sign, verify, sign, sign, verify])
     19PASS Success: generateKey({name: ECDSA, namedCurve: P-521}, true, [sign, verify, sign, sign, verify])
    2020PASS Success: generateKey({name: ecdsa, namedCurve: P-256}, false, [sign])
    2121PASS Success: generateKey({name: ecdsa, namedCurve: P-256}, true, [sign])
     
    3030PASS Success: generateKey({name: ecdsa, namedCurve: P-384}, false, [sign, verify, sign, sign, verify])
    3131PASS Success: generateKey({name: ecdsa, namedCurve: P-384}, true, [sign, verify, sign, sign, verify])
    32 FAIL Success: generateKey({name: ecdsa, namedCurve: P-521}, false, [sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    33 FAIL Success: generateKey({name: ecdsa, namedCurve: P-521}, true, [sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    34 FAIL Success: generateKey({name: ecdsa, namedCurve: P-521}, false, [verify, sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    35 FAIL Success: generateKey({name: ecdsa, namedCurve: P-521}, true, [verify, sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    36 FAIL Success: generateKey({name: ecdsa, namedCurve: P-521}, false, [sign, verify, sign, sign, verify]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    37 FAIL Success: generateKey({name: ecdsa, namedCurve: P-521}, true, [sign, verify, sign, sign, verify]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
     32PASS Success: generateKey({name: ecdsa, namedCurve: P-521}, false, [sign])
     33PASS Success: generateKey({name: ecdsa, namedCurve: P-521}, true, [sign])
     34PASS Success: generateKey({name: ecdsa, namedCurve: P-521}, false, [verify, sign])
     35PASS Success: generateKey({name: ecdsa, namedCurve: P-521}, true, [verify, sign])
     36PASS Success: generateKey({name: ecdsa, namedCurve: P-521}, false, [sign, verify, sign, sign, verify])
     37PASS Success: generateKey({name: ecdsa, namedCurve: P-521}, true, [sign, verify, sign, sign, verify])
    3838PASS Success: generateKey({name: Ecdsa, namedCurve: P-256}, false, [sign])
    3939PASS Success: generateKey({name: Ecdsa, namedCurve: P-256}, true, [sign])
     
    4848PASS Success: generateKey({name: Ecdsa, namedCurve: P-384}, false, [sign, verify, sign, sign, verify])
    4949PASS Success: generateKey({name: Ecdsa, namedCurve: P-384}, true, [sign, verify, sign, sign, verify])
    50 FAIL Success: generateKey({name: Ecdsa, namedCurve: P-521}, false, [sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    51 FAIL Success: generateKey({name: Ecdsa, namedCurve: P-521}, true, [sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    52 FAIL Success: generateKey({name: Ecdsa, namedCurve: P-521}, false, [verify, sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    53 FAIL Success: generateKey({name: Ecdsa, namedCurve: P-521}, true, [verify, sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    54 FAIL Success: generateKey({name: Ecdsa, namedCurve: P-521}, false, [sign, verify, sign, sign, verify]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    55 FAIL Success: generateKey({name: Ecdsa, namedCurve: P-521}, true, [sign, verify, sign, sign, verify]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
     50PASS Success: generateKey({name: Ecdsa, namedCurve: P-521}, false, [sign])
     51PASS Success: generateKey({name: Ecdsa, namedCurve: P-521}, true, [sign])
     52PASS Success: generateKey({name: Ecdsa, namedCurve: P-521}, false, [verify, sign])
     53PASS Success: generateKey({name: Ecdsa, namedCurve: P-521}, true, [verify, sign])
     54PASS Success: generateKey({name: Ecdsa, namedCurve: P-521}, false, [sign, verify, sign, sign, verify])
     55PASS Success: generateKey({name: Ecdsa, namedCurve: P-521}, true, [sign, verify, sign, sign, verify])
    5656
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/generateKey/successes_ECDSA.https.any.worker-expected.txt

    r267651 r279688  
    1212PASS Success: generateKey({name: ECDSA, namedCurve: P-384}, false, [sign, verify, sign, sign, verify])
    1313PASS Success: generateKey({name: ECDSA, namedCurve: P-384}, true, [sign, verify, sign, sign, verify])
    14 FAIL Success: generateKey({name: ECDSA, namedCurve: P-521}, false, [sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    15 FAIL Success: generateKey({name: ECDSA, namedCurve: P-521}, true, [sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    16 FAIL Success: generateKey({name: ECDSA, namedCurve: P-521}, false, [verify, sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    17 FAIL Success: generateKey({name: ECDSA, namedCurve: P-521}, true, [verify, sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    18 FAIL Success: generateKey({name: ECDSA, namedCurve: P-521}, false, [sign, verify, sign, sign, verify]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    19 FAIL Success: generateKey({name: ECDSA, namedCurve: P-521}, true, [sign, verify, sign, sign, verify]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
     14PASS Success: generateKey({name: ECDSA, namedCurve: P-521}, false, [sign])
     15PASS Success: generateKey({name: ECDSA, namedCurve: P-521}, true, [sign])
     16PASS Success: generateKey({name: ECDSA, namedCurve: P-521}, false, [verify, sign])
     17PASS Success: generateKey({name: ECDSA, namedCurve: P-521}, true, [verify, sign])
     18PASS Success: generateKey({name: ECDSA, namedCurve: P-521}, false, [sign, verify, sign, sign, verify])
     19PASS Success: generateKey({name: ECDSA, namedCurve: P-521}, true, [sign, verify, sign, sign, verify])
    2020PASS Success: generateKey({name: ecdsa, namedCurve: P-256}, false, [sign])
    2121PASS Success: generateKey({name: ecdsa, namedCurve: P-256}, true, [sign])
     
    3030PASS Success: generateKey({name: ecdsa, namedCurve: P-384}, false, [sign, verify, sign, sign, verify])
    3131PASS Success: generateKey({name: ecdsa, namedCurve: P-384}, true, [sign, verify, sign, sign, verify])
    32 FAIL Success: generateKey({name: ecdsa, namedCurve: P-521}, false, [sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    33 FAIL Success: generateKey({name: ecdsa, namedCurve: P-521}, true, [sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    34 FAIL Success: generateKey({name: ecdsa, namedCurve: P-521}, false, [verify, sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    35 FAIL Success: generateKey({name: ecdsa, namedCurve: P-521}, true, [verify, sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    36 FAIL Success: generateKey({name: ecdsa, namedCurve: P-521}, false, [sign, verify, sign, sign, verify]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    37 FAIL Success: generateKey({name: ecdsa, namedCurve: P-521}, true, [sign, verify, sign, sign, verify]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
     32PASS Success: generateKey({name: ecdsa, namedCurve: P-521}, false, [sign])
     33PASS Success: generateKey({name: ecdsa, namedCurve: P-521}, true, [sign])
     34PASS Success: generateKey({name: ecdsa, namedCurve: P-521}, false, [verify, sign])
     35PASS Success: generateKey({name: ecdsa, namedCurve: P-521}, true, [verify, sign])
     36PASS Success: generateKey({name: ecdsa, namedCurve: P-521}, false, [sign, verify, sign, sign, verify])
     37PASS Success: generateKey({name: ecdsa, namedCurve: P-521}, true, [sign, verify, sign, sign, verify])
    3838PASS Success: generateKey({name: Ecdsa, namedCurve: P-256}, false, [sign])
    3939PASS Success: generateKey({name: Ecdsa, namedCurve: P-256}, true, [sign])
     
    4848PASS Success: generateKey({name: Ecdsa, namedCurve: P-384}, false, [sign, verify, sign, sign, verify])
    4949PASS Success: generateKey({name: Ecdsa, namedCurve: P-384}, true, [sign, verify, sign, sign, verify])
    50 FAIL Success: generateKey({name: Ecdsa, namedCurve: P-521}, false, [sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    51 FAIL Success: generateKey({name: Ecdsa, namedCurve: P-521}, true, [sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    52 FAIL Success: generateKey({name: Ecdsa, namedCurve: P-521}, false, [verify, sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    53 FAIL Success: generateKey({name: Ecdsa, namedCurve: P-521}, true, [verify, sign]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    54 FAIL Success: generateKey({name: Ecdsa, namedCurve: P-521}, false, [sign, verify, sign, sign, verify]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
    55 FAIL Success: generateKey({name: Ecdsa, namedCurve: P-521}, true, [sign, verify, sign, sign, verify]) assert_unreached: Threw an unexpected error: NotSupportedError: The algorithm is not supported Reached unreachable code
     50PASS Success: generateKey({name: Ecdsa, namedCurve: P-521}, false, [sign])
     51PASS Success: generateKey({name: Ecdsa, namedCurve: P-521}, true, [sign])
     52PASS Success: generateKey({name: Ecdsa, namedCurve: P-521}, false, [verify, sign])
     53PASS Success: generateKey({name: Ecdsa, namedCurve: P-521}, true, [verify, sign])
     54PASS Success: generateKey({name: Ecdsa, namedCurve: P-521}, false, [sign, verify, sign, sign, verify])
     55PASS Success: generateKey({name: Ecdsa, namedCurve: P-521}, true, [sign, verify, sign, sign, verify])
    5656
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/import_export/ec_importKey.https.any-expected.txt

    r279516 r279688  
    1616PASS Good parameters: P-384 bits (pkcs8, buffer(185), {name: ECDSA, namedCurve: P-384}, false, [sign])
    1717PASS Good parameters: P-384 bits (jwk, object(kty, crv, x, y, d), {name: ECDSA, namedCurve: P-384}, false, [sign])
    18 FAIL Good parameters: P-521 bits (spki, buffer(158), {name: ECDSA, namedCurve: P-521}, true, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    19 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDSA, namedCurve: P-521}, true, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    20 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDSA, namedCurve: P-521}, true, [sign]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    21 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDSA, namedCurve: P-521}, true, [sign]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    22 FAIL Good parameters: P-521 bits (spki, buffer(158), {name: ECDSA, namedCurve: P-521}, false, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    23 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDSA, namedCurve: P-521}, false, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    24 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDSA, namedCurve: P-521}, false, [sign]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    25 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDSA, namedCurve: P-521}, false, [sign]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
     18PASS Good parameters: P-521 bits (spki, buffer(158), {name: ECDSA, namedCurve: P-521}, true, [])
     19PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDSA, namedCurve: P-521}, true, [])
     20PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDSA, namedCurve: P-521}, true, [sign])
     21PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDSA, namedCurve: P-521}, true, [sign])
     22PASS Good parameters: P-521 bits (spki, buffer(158), {name: ECDSA, namedCurve: P-521}, false, [])
     23PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDSA, namedCurve: P-521}, false, [])
     24PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDSA, namedCurve: P-521}, false, [sign])
     25PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDSA, namedCurve: P-521}, false, [sign])
    2626PASS Good parameters: P-256 bits (spki, buffer(91), {name: ECDH, namedCurve: P-256}, true, [])
    2727PASS Good parameters: P-256 bits (jwk, object(kty, crv, x, y), {name: ECDH, namedCurve: P-256}, true, [])
     
    5656PASS Good parameters: P-384 bits (pkcs8, buffer(185), {name: ECDH, namedCurve: P-384}, false, [deriveBits])
    5757PASS Good parameters: P-384 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-384}, false, [deriveBits])
    58 FAIL Good parameters: P-521 bits (spki, buffer(158), {name: ECDH, namedCurve: P-521}, true, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    59 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDH, namedCurve: P-521}, true, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    60 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, true, [deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    61 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, true, [deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    62 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, true, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    63 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, true, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    64 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, true, [deriveBits]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    65 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, true, [deriveBits]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    66 FAIL Good parameters: P-521 bits (spki, buffer(158), {name: ECDH, namedCurve: P-521}, false, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    67 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDH, namedCurve: P-521}, false, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    68 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, false, [deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    69 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, false, [deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    70 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, false, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    71 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, false, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    72 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, false, [deriveBits]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    73 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, false, [deriveBits]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
     58PASS Good parameters: P-521 bits (spki, buffer(158), {name: ECDH, namedCurve: P-521}, true, [])
     59PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDH, namedCurve: P-521}, true, [])
     60PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, true, [deriveKey])
     61PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, true, [deriveKey])
     62PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, true, [deriveBits, deriveKey])
     63PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, true, [deriveBits, deriveKey])
     64PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, true, [deriveBits])
     65PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, true, [deriveBits])
     66PASS Good parameters: P-521 bits (spki, buffer(158), {name: ECDH, namedCurve: P-521}, false, [])
     67PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDH, namedCurve: P-521}, false, [])
     68PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, false, [deriveKey])
     69PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, false, [deriveKey])
     70PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, false, [deriveBits, deriveKey])
     71PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, false, [deriveBits, deriveKey])
     72PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, false, [deriveBits])
     73PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, false, [deriveBits])
    7474
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/import_export/ec_importKey.https.any.worker-expected.txt

    r279516 r279688  
    1616PASS Good parameters: P-384 bits (pkcs8, buffer(185), {name: ECDSA, namedCurve: P-384}, false, [sign])
    1717PASS Good parameters: P-384 bits (jwk, object(kty, crv, x, y, d), {name: ECDSA, namedCurve: P-384}, false, [sign])
    18 FAIL Good parameters: P-521 bits (spki, buffer(158), {name: ECDSA, namedCurve: P-521}, true, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    19 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDSA, namedCurve: P-521}, true, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    20 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDSA, namedCurve: P-521}, true, [sign]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    21 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDSA, namedCurve: P-521}, true, [sign]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    22 FAIL Good parameters: P-521 bits (spki, buffer(158), {name: ECDSA, namedCurve: P-521}, false, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    23 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDSA, namedCurve: P-521}, false, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    24 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDSA, namedCurve: P-521}, false, [sign]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    25 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDSA, namedCurve: P-521}, false, [sign]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
     18PASS Good parameters: P-521 bits (spki, buffer(158), {name: ECDSA, namedCurve: P-521}, true, [])
     19PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDSA, namedCurve: P-521}, true, [])
     20PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDSA, namedCurve: P-521}, true, [sign])
     21PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDSA, namedCurve: P-521}, true, [sign])
     22PASS Good parameters: P-521 bits (spki, buffer(158), {name: ECDSA, namedCurve: P-521}, false, [])
     23PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDSA, namedCurve: P-521}, false, [])
     24PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDSA, namedCurve: P-521}, false, [sign])
     25PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDSA, namedCurve: P-521}, false, [sign])
    2626PASS Good parameters: P-256 bits (spki, buffer(91), {name: ECDH, namedCurve: P-256}, true, [])
    2727PASS Good parameters: P-256 bits (jwk, object(kty, crv, x, y), {name: ECDH, namedCurve: P-256}, true, [])
     
    5656PASS Good parameters: P-384 bits (pkcs8, buffer(185), {name: ECDH, namedCurve: P-384}, false, [deriveBits])
    5757PASS Good parameters: P-384 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-384}, false, [deriveBits])
    58 FAIL Good parameters: P-521 bits (spki, buffer(158), {name: ECDH, namedCurve: P-521}, true, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    59 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDH, namedCurve: P-521}, true, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    60 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, true, [deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    61 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, true, [deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    62 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, true, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    63 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, true, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    64 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, true, [deriveBits]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    65 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, true, [deriveBits]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    66 FAIL Good parameters: P-521 bits (spki, buffer(158), {name: ECDH, namedCurve: P-521}, false, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    67 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDH, namedCurve: P-521}, false, []) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    68 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, false, [deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    69 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, false, [deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    70 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, false, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    71 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, false, [deriveBits, deriveKey]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    72 FAIL Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, false, [deriveBits]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
    73 FAIL Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, false, [deriveBits]) assert_unreached: Threw an unexpected error: DataError: Data provided to an operation does not meet requirements Reached unreachable code
     58PASS Good parameters: P-521 bits (spki, buffer(158), {name: ECDH, namedCurve: P-521}, true, [])
     59PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDH, namedCurve: P-521}, true, [])
     60PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, true, [deriveKey])
     61PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, true, [deriveKey])
     62PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, true, [deriveBits, deriveKey])
     63PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, true, [deriveBits, deriveKey])
     64PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, true, [deriveBits])
     65PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, true, [deriveBits])
     66PASS Good parameters: P-521 bits (spki, buffer(158), {name: ECDH, namedCurve: P-521}, false, [])
     67PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y), {name: ECDH, namedCurve: P-521}, false, [])
     68PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, false, [deriveKey])
     69PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, false, [deriveKey])
     70PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, false, [deriveBits, deriveKey])
     71PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, false, [deriveBits, deriveKey])
     72PASS Good parameters: P-521 bits (pkcs8, buffer(241), {name: ECDH, namedCurve: P-521}, false, [deriveBits])
     73PASS Good parameters: P-521 bits (jwk, object(kty, crv, x, y, d), {name: ECDH, namedCurve: P-521}, false, [deriveBits])
    7474
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/sign_verify/ecdsa.https.any-expected.txt

    r279516 r279688  
    99PASS ECDSA P-384 with SHA-384 verification
    1010PASS ECDSA P-384 with SHA-512 verification
    11 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verification assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    12 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verification assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    13 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verification assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    14 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verification assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     11PASS ECDSA P-521 with SHA-1 verification
     12PASS ECDSA P-521 with SHA-256 verification
     13PASS ECDSA P-521 with SHA-384 verification
     14PASS ECDSA P-521 with SHA-512 verification
    1515PASS ECDSA P-256 with SHA-1 verification with altered signature after call
    1616PASS ECDSA P-256 with SHA-256 verification with altered signature after call
     
    2121PASS ECDSA P-384 with SHA-384 verification with altered signature after call
    2222PASS ECDSA P-384 with SHA-512 verification with altered signature after call
    23 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verification with altered signature after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    24 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verification with altered signature after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    25 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verification with altered signature after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    26 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verification with altered signature after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     23PASS ECDSA P-521 with SHA-1 verification with altered signature after call
     24PASS ECDSA P-521 with SHA-256 verification with altered signature after call
     25PASS ECDSA P-521 with SHA-384 verification with altered signature after call
     26PASS ECDSA P-521 with SHA-512 verification with altered signature after call
    2727PASS ECDSA P-256 with SHA-1 with altered plaintext after call
    2828PASS ECDSA P-256 with SHA-256 with altered plaintext after call
     
    3333PASS ECDSA P-384 with SHA-384 with altered plaintext after call
    3434PASS ECDSA P-384 with SHA-512 with altered plaintext after call
    35 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 with altered plaintext after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    36 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 with altered plaintext after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    37 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 with altered plaintext after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    38 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 with altered plaintext after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     35PASS ECDSA P-521 with SHA-1 with altered plaintext after call
     36PASS ECDSA P-521 with SHA-256 with altered plaintext after call
     37PASS ECDSA P-521 with SHA-384 with altered plaintext after call
     38PASS ECDSA P-521 with SHA-512 with altered plaintext after call
    3939PASS ECDSA P-256 with SHA-1 using privateKey to verify
    4040PASS ECDSA P-256 with SHA-256 using privateKey to verify
     
    4545PASS ECDSA P-384 with SHA-384 using privateKey to verify
    4646PASS ECDSA P-384 with SHA-512 using privateKey to verify
    47 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 using privateKey to verify assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    48 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 using privateKey to verify assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    49 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 using privateKey to verify assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    50 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 using privateKey to verify assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     47PASS ECDSA P-521 with SHA-1 using privateKey to verify
     48PASS ECDSA P-521 with SHA-256 using privateKey to verify
     49PASS ECDSA P-521 with SHA-384 using privateKey to verify
     50PASS ECDSA P-521 with SHA-512 using privateKey to verify
    5151PASS ECDSA P-256 with SHA-1 using publicKey to sign
    5252PASS ECDSA P-256 with SHA-256 using publicKey to sign
     
    5757PASS ECDSA P-384 with SHA-384 using publicKey to sign
    5858PASS ECDSA P-384 with SHA-512 using publicKey to sign
    59 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 using publicKey to sign assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    60 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 using publicKey to sign assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    61 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 using publicKey to sign assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    62 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 using publicKey to sign assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     59PASS ECDSA P-521 with SHA-1 using publicKey to sign
     60PASS ECDSA P-521 with SHA-256 using publicKey to sign
     61PASS ECDSA P-521 with SHA-384 using publicKey to sign
     62PASS ECDSA P-521 with SHA-512 using publicKey to sign
    6363PASS ECDSA P-256 with SHA-1 no verify usage
    6464PASS ECDSA P-256 with SHA-256 no verify usage
     
    6969PASS ECDSA P-384 with SHA-384 no verify usage
    7070PASS ECDSA P-384 with SHA-512 no verify usage
    71 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 no verify usage assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    72 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 no verify usage assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    73 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 no verify usage assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    74 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 no verify usage assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     71PASS ECDSA P-521 with SHA-1 no verify usage
     72PASS ECDSA P-521 with SHA-256 no verify usage
     73PASS ECDSA P-521 with SHA-384 no verify usage
     74PASS ECDSA P-521 with SHA-512 no verify usage
    7575PASS ECDSA P-256 with SHA-1 round trip
    7676PASS ECDSA P-256 with SHA-256 round trip
     
    8181PASS ECDSA P-384 with SHA-384 round trip
    8282PASS ECDSA P-384 with SHA-512 round trip
    83 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 round trip assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    84 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 round trip assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    85 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 round trip assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    86 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 round trip assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     83PASS ECDSA P-521 with SHA-1 round trip
     84PASS ECDSA P-521 with SHA-256 round trip
     85PASS ECDSA P-521 with SHA-384 round trip
     86PASS ECDSA P-521 with SHA-512 round trip
    8787PASS ECDSA P-256 with SHA-1 signing with wrong algorithm name
    8888PASS ECDSA P-256 with SHA-256 signing with wrong algorithm name
     
    9393PASS ECDSA P-384 with SHA-384 signing with wrong algorithm name
    9494PASS ECDSA P-384 with SHA-512 signing with wrong algorithm name
     95PASS ECDSA P-521 with SHA-1 signing with wrong algorithm name
     96PASS ECDSA P-521 with SHA-256 signing with wrong algorithm name
     97PASS ECDSA P-521 with SHA-384 signing with wrong algorithm name
     98PASS ECDSA P-521 with SHA-512 signing with wrong algorithm name
    9599PASS ECDSA P-256 with SHA-1 verifying with wrong algorithm name
    96100PASS ECDSA P-256 with SHA-256 verifying with wrong algorithm name
     
    101105PASS ECDSA P-384 with SHA-384 verifying with wrong algorithm name
    102106PASS ECDSA P-384 with SHA-512 verifying with wrong algorithm name
     107PASS ECDSA P-521 with SHA-1 verifying with wrong algorithm name
     108PASS ECDSA P-521 with SHA-256 verifying with wrong algorithm name
     109PASS ECDSA P-521 with SHA-384 verifying with wrong algorithm name
     110PASS ECDSA P-521 with SHA-512 verifying with wrong algorithm name
    103111PASS ECDSA P-256 with SHA-1 verification failure due to altered signature
    104112PASS ECDSA P-256 with SHA-256 verification failure due to altered signature
     
    109117PASS ECDSA P-384 with SHA-384 verification failure due to altered signature
    110118PASS ECDSA P-384 with SHA-512 verification failure due to altered signature
    111 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verification failure due to altered signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    112 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verification failure due to altered signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    113 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verification failure due to altered signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    114 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verification failure due to altered signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     119PASS ECDSA P-521 with SHA-1 verification failure due to altered signature
     120PASS ECDSA P-521 with SHA-256 verification failure due to altered signature
     121PASS ECDSA P-521 with SHA-384 verification failure due to altered signature
     122PASS ECDSA P-521 with SHA-512 verification failure due to altered signature
    115123PASS ECDSA P-256 with SHA-1 verification failure due to wrong hash
    116124PASS ECDSA P-256 with SHA-256 verification failure due to wrong hash
     
    121129PASS ECDSA P-384 with SHA-384 verification failure due to wrong hash
    122130PASS ECDSA P-384 with SHA-512 verification failure due to wrong hash
    123 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verification failure due to wrong hash assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    124 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verification failure due to wrong hash assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    125 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verification failure due to wrong hash assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    126 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verification failure due to wrong hash assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     131PASS ECDSA P-521 with SHA-1 verification failure due to wrong hash
     132PASS ECDSA P-521 with SHA-256 verification failure due to wrong hash
     133PASS ECDSA P-521 with SHA-384 verification failure due to wrong hash
     134PASS ECDSA P-521 with SHA-512 verification failure due to wrong hash
    127135PASS ECDSA P-256 with SHA-1 verification failure due to bad hash name
    128136PASS ECDSA P-256 with SHA-256 verification failure due to bad hash name
     
    133141PASS ECDSA P-384 with SHA-384 verification failure due to bad hash name
    134142PASS ECDSA P-384 with SHA-512 verification failure due to bad hash name
    135 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verification failure due to bad hash name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    136 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verification failure due to bad hash name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    137 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verification failure due to bad hash name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    138 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verification failure due to bad hash name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     143PASS ECDSA P-521 with SHA-1 verification failure due to bad hash name
     144PASS ECDSA P-521 with SHA-256 verification failure due to bad hash name
     145PASS ECDSA P-521 with SHA-384 verification failure due to bad hash name
     146PASS ECDSA P-521 with SHA-512 verification failure due to bad hash name
    139147PASS ECDSA P-256 with SHA-1 verification failure due to shortened signature
    140148PASS ECDSA P-256 with SHA-256 verification failure due to shortened signature
     
    145153PASS ECDSA P-384 with SHA-384 verification failure due to shortened signature
    146154PASS ECDSA P-384 with SHA-512 verification failure due to shortened signature
    147 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verification failure due to shortened signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    148 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verification failure due to shortened signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    149 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verification failure due to shortened signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    150 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verification failure due to shortened signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     155PASS ECDSA P-521 with SHA-1 verification failure due to shortened signature
     156PASS ECDSA P-521 with SHA-256 verification failure due to shortened signature
     157PASS ECDSA P-521 with SHA-384 verification failure due to shortened signature
     158PASS ECDSA P-521 with SHA-512 verification failure due to shortened signature
    151159PASS ECDSA P-256 with SHA-1 verification failure due to altered plaintext
    152160PASS ECDSA P-256 with SHA-256 verification failure due to altered plaintext
     
    157165PASS ECDSA P-384 with SHA-384 verification failure due to altered plaintext
    158166PASS ECDSA P-384 with SHA-512 verification failure due to altered plaintext
    159 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verification failure due to altered plaintext assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    160 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verification failure due to altered plaintext assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    161 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verification failure due to altered plaintext assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    162 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verification failure due to altered plaintext assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    163 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 signing with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    164 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 signing with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    165 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 signing with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    166 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 signing with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    167 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verifying with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    168 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verifying with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    169 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verifying with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    170 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verifying with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     167PASS ECDSA P-521 with SHA-1 verification failure due to altered plaintext
     168PASS ECDSA P-521 with SHA-256 verification failure due to altered plaintext
     169PASS ECDSA P-521 with SHA-384 verification failure due to altered plaintext
     170PASS ECDSA P-521 with SHA-512 verification failure due to altered plaintext
    171171
  • trunk/LayoutTests/imported/w3c/web-platform-tests/WebCryptoAPI/sign_verify/ecdsa.https.any.worker-expected.txt

    r279516 r279688  
    99PASS ECDSA P-384 with SHA-384 verification
    1010PASS ECDSA P-384 with SHA-512 verification
    11 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verification assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    12 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verification assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    13 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verification assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    14 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verification assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     11PASS ECDSA P-521 with SHA-1 verification
     12PASS ECDSA P-521 with SHA-256 verification
     13PASS ECDSA P-521 with SHA-384 verification
     14PASS ECDSA P-521 with SHA-512 verification
    1515PASS ECDSA P-256 with SHA-1 verification with altered signature after call
    1616PASS ECDSA P-256 with SHA-256 verification with altered signature after call
     
    2121PASS ECDSA P-384 with SHA-384 verification with altered signature after call
    2222PASS ECDSA P-384 with SHA-512 verification with altered signature after call
    23 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verification with altered signature after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    24 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verification with altered signature after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    25 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verification with altered signature after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    26 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verification with altered signature after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     23PASS ECDSA P-521 with SHA-1 verification with altered signature after call
     24PASS ECDSA P-521 with SHA-256 verification with altered signature after call
     25PASS ECDSA P-521 with SHA-384 verification with altered signature after call
     26PASS ECDSA P-521 with SHA-512 verification with altered signature after call
    2727PASS ECDSA P-256 with SHA-1 with altered plaintext after call
    2828PASS ECDSA P-256 with SHA-256 with altered plaintext after call
     
    3333PASS ECDSA P-384 with SHA-384 with altered plaintext after call
    3434PASS ECDSA P-384 with SHA-512 with altered plaintext after call
    35 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 with altered plaintext after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    36 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 with altered plaintext after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    37 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 with altered plaintext after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    38 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 with altered plaintext after call assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     35PASS ECDSA P-521 with SHA-1 with altered plaintext after call
     36PASS ECDSA P-521 with SHA-256 with altered plaintext after call
     37PASS ECDSA P-521 with SHA-384 with altered plaintext after call
     38PASS ECDSA P-521 with SHA-512 with altered plaintext after call
    3939PASS ECDSA P-256 with SHA-1 using privateKey to verify
    4040PASS ECDSA P-256 with SHA-256 using privateKey to verify
     
    4545PASS ECDSA P-384 with SHA-384 using privateKey to verify
    4646PASS ECDSA P-384 with SHA-512 using privateKey to verify
    47 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 using privateKey to verify assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    48 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 using privateKey to verify assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    49 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 using privateKey to verify assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    50 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 using privateKey to verify assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     47PASS ECDSA P-521 with SHA-1 using privateKey to verify
     48PASS ECDSA P-521 with SHA-256 using privateKey to verify
     49PASS ECDSA P-521 with SHA-384 using privateKey to verify
     50PASS ECDSA P-521 with SHA-512 using privateKey to verify
    5151PASS ECDSA P-256 with SHA-1 using publicKey to sign
    5252PASS ECDSA P-256 with SHA-256 using publicKey to sign
     
    5757PASS ECDSA P-384 with SHA-384 using publicKey to sign
    5858PASS ECDSA P-384 with SHA-512 using publicKey to sign
    59 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 using publicKey to sign assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    60 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 using publicKey to sign assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    61 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 using publicKey to sign assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    62 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 using publicKey to sign assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     59PASS ECDSA P-521 with SHA-1 using publicKey to sign
     60PASS ECDSA P-521 with SHA-256 using publicKey to sign
     61PASS ECDSA P-521 with SHA-384 using publicKey to sign
     62PASS ECDSA P-521 with SHA-512 using publicKey to sign
    6363PASS ECDSA P-256 with SHA-1 no verify usage
    6464PASS ECDSA P-256 with SHA-256 no verify usage
     
    6969PASS ECDSA P-384 with SHA-384 no verify usage
    7070PASS ECDSA P-384 with SHA-512 no verify usage
    71 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 no verify usage assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    72 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 no verify usage assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    73 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 no verify usage assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    74 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 no verify usage assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     71PASS ECDSA P-521 with SHA-1 no verify usage
     72PASS ECDSA P-521 with SHA-256 no verify usage
     73PASS ECDSA P-521 with SHA-384 no verify usage
     74PASS ECDSA P-521 with SHA-512 no verify usage
    7575PASS ECDSA P-256 with SHA-1 round trip
    7676PASS ECDSA P-256 with SHA-256 round trip
     
    8181PASS ECDSA P-384 with SHA-384 round trip
    8282PASS ECDSA P-384 with SHA-512 round trip
    83 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 round trip assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    84 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 round trip assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    85 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 round trip assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    86 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 round trip assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     83PASS ECDSA P-521 with SHA-1 round trip
     84PASS ECDSA P-521 with SHA-256 round trip
     85PASS ECDSA P-521 with SHA-384 round trip
     86PASS ECDSA P-521 with SHA-512 round trip
    8787PASS ECDSA P-256 with SHA-1 signing with wrong algorithm name
    8888PASS ECDSA P-256 with SHA-256 signing with wrong algorithm name
     
    9393PASS ECDSA P-384 with SHA-384 signing with wrong algorithm name
    9494PASS ECDSA P-384 with SHA-512 signing with wrong algorithm name
     95PASS ECDSA P-521 with SHA-1 signing with wrong algorithm name
     96PASS ECDSA P-521 with SHA-256 signing with wrong algorithm name
     97PASS ECDSA P-521 with SHA-384 signing with wrong algorithm name
     98PASS ECDSA P-521 with SHA-512 signing with wrong algorithm name
    9599PASS ECDSA P-256 with SHA-1 verifying with wrong algorithm name
    96100PASS ECDSA P-256 with SHA-256 verifying with wrong algorithm name
     
    101105PASS ECDSA P-384 with SHA-384 verifying with wrong algorithm name
    102106PASS ECDSA P-384 with SHA-512 verifying with wrong algorithm name
     107PASS ECDSA P-521 with SHA-1 verifying with wrong algorithm name
     108PASS ECDSA P-521 with SHA-256 verifying with wrong algorithm name
     109PASS ECDSA P-521 with SHA-384 verifying with wrong algorithm name
     110PASS ECDSA P-521 with SHA-512 verifying with wrong algorithm name
    103111PASS ECDSA P-256 with SHA-1 verification failure due to altered signature
    104112PASS ECDSA P-256 with SHA-256 verification failure due to altered signature
     
    109117PASS ECDSA P-384 with SHA-384 verification failure due to altered signature
    110118PASS ECDSA P-384 with SHA-512 verification failure due to altered signature
    111 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verification failure due to altered signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    112 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verification failure due to altered signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    113 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verification failure due to altered signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    114 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verification failure due to altered signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     119PASS ECDSA P-521 with SHA-1 verification failure due to altered signature
     120PASS ECDSA P-521 with SHA-256 verification failure due to altered signature
     121PASS ECDSA P-521 with SHA-384 verification failure due to altered signature
     122PASS ECDSA P-521 with SHA-512 verification failure due to altered signature
    115123PASS ECDSA P-256 with SHA-1 verification failure due to wrong hash
    116124PASS ECDSA P-256 with SHA-256 verification failure due to wrong hash
     
    121129PASS ECDSA P-384 with SHA-384 verification failure due to wrong hash
    122130PASS ECDSA P-384 with SHA-512 verification failure due to wrong hash
    123 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verification failure due to wrong hash assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    124 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verification failure due to wrong hash assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    125 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verification failure due to wrong hash assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    126 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verification failure due to wrong hash assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     131PASS ECDSA P-521 with SHA-1 verification failure due to wrong hash
     132PASS ECDSA P-521 with SHA-256 verification failure due to wrong hash
     133PASS ECDSA P-521 with SHA-384 verification failure due to wrong hash
     134PASS ECDSA P-521 with SHA-512 verification failure due to wrong hash
    127135PASS ECDSA P-256 with SHA-1 verification failure due to bad hash name
    128136PASS ECDSA P-256 with SHA-256 verification failure due to bad hash name
     
    133141PASS ECDSA P-384 with SHA-384 verification failure due to bad hash name
    134142PASS ECDSA P-384 with SHA-512 verification failure due to bad hash name
    135 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verification failure due to bad hash name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    136 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verification failure due to bad hash name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    137 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verification failure due to bad hash name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    138 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verification failure due to bad hash name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     143PASS ECDSA P-521 with SHA-1 verification failure due to bad hash name
     144PASS ECDSA P-521 with SHA-256 verification failure due to bad hash name
     145PASS ECDSA P-521 with SHA-384 verification failure due to bad hash name
     146PASS ECDSA P-521 with SHA-512 verification failure due to bad hash name
    139147PASS ECDSA P-256 with SHA-1 verification failure due to shortened signature
    140148PASS ECDSA P-256 with SHA-256 verification failure due to shortened signature
     
    145153PASS ECDSA P-384 with SHA-384 verification failure due to shortened signature
    146154PASS ECDSA P-384 with SHA-512 verification failure due to shortened signature
    147 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verification failure due to shortened signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    148 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verification failure due to shortened signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    149 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verification failure due to shortened signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    150 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verification failure due to shortened signature assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     155PASS ECDSA P-521 with SHA-1 verification failure due to shortened signature
     156PASS ECDSA P-521 with SHA-256 verification failure due to shortened signature
     157PASS ECDSA P-521 with SHA-384 verification failure due to shortened signature
     158PASS ECDSA P-521 with SHA-512 verification failure due to shortened signature
    151159PASS ECDSA P-256 with SHA-1 verification failure due to altered plaintext
    152160PASS ECDSA P-256 with SHA-256 verification failure due to altered plaintext
     
    157165PASS ECDSA P-384 with SHA-384 verification failure due to altered plaintext
    158166PASS ECDSA P-384 with SHA-512 verification failure due to altered plaintext
    159 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verification failure due to altered plaintext assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    160 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verification failure due to altered plaintext assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    161 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verification failure due to altered plaintext assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    162 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verification failure due to altered plaintext assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    163 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 signing with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    164 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 signing with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    165 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 signing with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    166 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 signing with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    167 FAIL importVectorKeys step: ECDSA P-521 with SHA-1 verifying with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-1. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    168 FAIL importVectorKeys step: ECDSA P-521 with SHA-256 verifying with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-256. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    169 FAIL importVectorKeys step: ECDSA P-521 with SHA-384 verifying with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-384. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
    170 FAIL importVectorKeys step: ECDSA P-521 with SHA-512 verifying with wrong algorithm name assert_unreached: importVectorKeys failed for ECDSA P-521 with SHA-512. Message: ''Data provided to an operation does not meet requirements'' Reached unreachable code
     167PASS ECDSA P-521 with SHA-1 verification failure due to altered plaintext
     168PASS ECDSA P-521 with SHA-256 verification failure due to altered plaintext
     169PASS ECDSA P-521 with SHA-384 verification failure due to altered plaintext
     170PASS ECDSA P-521 with SHA-512 verification failure due to altered plaintext
    171171
  • trunk/Source/WebCore/ChangeLog

    r279686 r279688  
     12021-07-07  Chris Dumez  <cdumez@apple.com>
     2
     3        [WebCrypto] Support Elliptic Curve P-521 on Mac
     4        https://bugs.webkit.org/show_bug.cgi?id=216755
     5        <rdar://problem/69667220>
     6
     7        Reviewed by Alex Christensen.
     8
     9        Add support for Elliptic Curve P-521 in WebCrypto for ECDSA and ECDH, on macOS.
     10        Both Gecko and Blink already support this.
     11
     12        No new tests, rebaselined existing tests.
     13
     14        * crypto/mac/CryptoAlgorithmECDHMac.cpp:
     15        (WebCore::CryptoAlgorithmECDH::platformDeriveBits):
     16        * crypto/mac/CryptoAlgorithmECDSAMac.cpp:
     17        Use std::ceil() when converting bits to bytes since 521 is not a multiple of 8.
     18        This is as per Section 2.3.4 of http://www.secg.org/sec1-v2.pdf, which indicates
     19        we should use ceil().
     20
     21        (WebCore::signECDSA):
     22        Stop assuming the length can be encoded in a single byte as this is not true with
     23        P-521 (values >= 128 require 2 bytes).
     24
     25        (WebCore::verifyECDSA):
     26        Do not reject the promise when CCECCryptorVerifyHash() fails and instead return
     27        false to indicate that the signature fails. This was needed to pass a few more
     28        WPT checks. We do not do much validation on r and s before passing them to
     29        CommonCrypto and CCECCryptorVerifyHash() may return a kCCNotVerified error when
     30        the input signature is invalid (invalid signatures are tested by WPT tests).
     31
     32        (WebCore::CryptoAlgorithmECDSA::platformSign):
     33        (WebCore::CryptoAlgorithmECDSA::platformVerify):
     34        * crypto/mac/CryptoKeyECMac.cpp:
     35        (WebCore::doesUncompressedPointMatchNamedCurve):
     36        (WebCore::doesFieldElementMatchNamedCurve):
     37        (WebCore::getKeySizeFromNamedCurve):
     38        (WebCore::CryptoKeyEC::platformSupportedCurve):
     39        (WebCore::CryptoKeyEC::platformExportRaw const):
     40        (WebCore::CryptoKeyEC::platformAddFieldElements const):
     41        (WebCore::getOID):
     42        (WebCore::CryptoKeyEC::platformExportSpki const):
     43        (WebCore::CryptoKeyEC::platformImportPkcs8):
     44        (WebCore::CryptoKeyEC::platformExportPkcs8 const):
     45        Add support for P-521 and use std::ceil() when converting bits to bytes since
     46        521 is not a multiple of 8.
     47
    1482021-07-07  Chris Dumez  <cdumez@apple.com>
    249
  • trunk/Source/WebCore/crypto/keys/CryptoKeyEC.h

    r279682 r279688  
    8787
    8888    size_t keySizeInBits() const;
     89    size_t keySizeInBytes() const { return std::ceil(keySizeInBits() / 8.); }
    8990    NamedCurve namedCurve() const { return m_curve; }
    9091    String namedCurveString() const;
  • trunk/Source/WebCore/crypto/mac/CryptoAlgorithmECDHMac.cpp

    r278253 r279688  
    3737{
    3838    std::optional<Vector<uint8_t>> result = std::nullopt;
    39     Vector<uint8_t> derivedKey(baseKey.keySizeInBits() / 8); // Per https://tools.ietf.org/html/rfc6090#section-4.
     39    Vector<uint8_t> derivedKey(baseKey.keySizeInBytes()); // Per https://tools.ietf.org/html/rfc6090#section-4.
    4040    size_t size = derivedKey.size();
    4141    if (!CCECCryptorComputeSharedSecret(baseKey.platformKey(), publicKey.platformKey(), derivedKey.data(), &size))
  • trunk/Source/WebCore/crypto/mac/CryptoAlgorithmECDSAMac.cpp

    r238754 r279688  
    6565    Vector<uint8_t> newSignature;
    6666    newSignature.reserveCapacity(keyLengthInBytes * 2);
    67     size_t offset = 3; // skip tag, length, tag
     67    size_t offset = 1; // skip tag
     68    offset += bytesUsedToEncodedLength(signature[offset]); // skip length
     69    ++offset; // skip tag
    6870
    6971    // If r < keyLengthInBytes, fill the head of r with 0s.
     
    8991    } else if (signature[offset] > keyLengthInBytes) // Otherwise skip the leading 0s of s.
    9092        offset += signature[offset] - keyLengthInBytes;
    91     offset++; // skip length
     93    ++offset; // skip length
    9294    ASSERT_WITH_SECURITY_IMPLICATION(signature.size() >= offset + bytesToCopy);
    9395    newSignature.append(signature.data() + offset, bytesToCopy);
     
    149151    uint32_t valid;
    150152    CCCryptorStatus status = CCECCryptorVerifyHash(key, digestData.data(), digestData.size(), newSignature.data(), newSignature.size(), &valid);
    151     if (status)
    152         return Exception { OperationError };
     153    if (status) {
     154        WTFLogAlways("ERROR: CCECCryptorVerifyHash() returns error=%d", status);
     155        return false;
     156    }
    153157    return valid;
    154158}
     
    156160ExceptionOr<Vector<uint8_t>> CryptoAlgorithmECDSA::platformSign(const CryptoAlgorithmEcdsaParams& parameters, const CryptoKeyEC& key, const Vector<uint8_t>& data)
    157161{
    158     return signECDSA(parameters.hashIdentifier, key.platformKey(), key.keySizeInBits() / 8, data);
     162    return signECDSA(parameters.hashIdentifier, key.platformKey(), key.keySizeInBytes(), data);
    159163}
    160164
    161165ExceptionOr<bool> CryptoAlgorithmECDSA::platformVerify(const CryptoAlgorithmEcdsaParams& parameters, const CryptoKeyEC& key, const Vector<uint8_t>& signature, const Vector<uint8_t>& data)
    162166{
    163     return verifyECDSA(parameters.hashIdentifier, key.platformKey(), key.keySizeInBits() / 8, signature, data);
     167    return verifyECDSA(parameters.hashIdentifier, key.platformKey(), key.keySizeInBytes(), signature, data);
    164168}
    165169
  • trunk/Source/WebCore/crypto/mac/CryptoKeyECMac.cpp

    r278253 r279688  
    4242// OID secp384r1 1.3.132.0.34
    4343static constexpr unsigned char Secp384r1[] = {0x06, 0x05, 0x2b, 0x81, 0x04, 0x00, 0x22};
     44// OID secp521r1 1.3.132.0.35
     45static constexpr unsigned char Secp521r1[] = {0x06, 0x05, 0x2b, 0x81, 0x04, 0x00, 0x23};
     46
    4447// Version 1. Per https://tools.ietf.org/html/rfc5915#section-3
    4548static const unsigned char PrivateKeyVersion[] = {0x02, 0x01, 0x01};
     
    4750static const unsigned char TaggedType1 = 0xa1;
    4851
    49 // Per Section 2.3.4 of http://www.secg.org/sec1-v2.pdf
    50 // We only support uncompressed point format.
    51 static bool doesUncompressedPointMatchNamedCurve(CryptoKeyEC::NamedCurve curve, size_t size)
    52 {
    53     switch (curve) {
    54     case CryptoKeyEC::NamedCurve::P256:
    55         return size == 65;
    56     case CryptoKeyEC::NamedCurve::P384:
    57         return size == 97;
    58     case CryptoKeyEC::NamedCurve::P521:
    59         break;
    60     }
    61 
    62     ASSERT_NOT_REACHED();
    63     return false;
    64 }
    65 
    66 // Per Section 2.3.5 of http://www.secg.org/sec1-v2.pdf
    67 static bool doesFieldElementMatchNamedCurve(CryptoKeyEC::NamedCurve curve, size_t size)
    68 {
    69     switch (curve) {
    70     case CryptoKeyEC::NamedCurve::P256:
    71         return size == 32;
    72     case CryptoKeyEC::NamedCurve::P384:
    73         return size == 48;
    74     case CryptoKeyEC::NamedCurve::P521:
    75         break;
    76     }
    77 
    78     ASSERT_NOT_REACHED();
    79     return false;
    80 }
    81 
    82 static size_t getKeySizeFromNamedCurve(CryptoKeyEC::NamedCurve curve)
     52static constexpr size_t sizeCeil(float f)
     53{
     54    auto s = static_cast<size_t>(f);
     55    return f > s ? s + 1 : s;
     56}
     57
     58static constexpr size_t keySizeInBitsFromNamedCurve(CryptoKeyEC::NamedCurve curve)
    8359{
    8460    switch (curve) {
     
    8864        return 384;
    8965    case CryptoKeyEC::NamedCurve::P521:
    90         break;
     66        return 521;
    9167    }
    9268
     
    9571}
    9672
     73static constexpr size_t keySizeInBytesFromNamedCurve(CryptoKeyEC::NamedCurve curve)
     74{
     75    return sizeCeil(keySizeInBitsFromNamedCurve(curve) / 8.);
     76}
     77
     78// Per Section 2.3.4 of http://www.secg.org/sec1-v2.pdf
     79// We only support uncompressed point format.
     80static constexpr bool doesUncompressedPointMatchNamedCurve(CryptoKeyEC::NamedCurve curve, size_t size)
     81{
     82    return (keySizeInBytesFromNamedCurve(curve) * 2 + 1) == size;
     83}
     84
     85// Per Section 2.3.5 of http://www.secg.org/sec1-v2.pdf
     86static constexpr bool doesFieldElementMatchNamedCurve(CryptoKeyEC::NamedCurve curve, size_t size)
     87{
     88    return keySizeInBytesFromNamedCurve(curve) == size;
     89}
     90
    9791size_t CryptoKeyEC::keySizeInBits() const
    9892{
     
    10397bool CryptoKeyEC::platformSupportedCurve(NamedCurve curve)
    10498{
    105     return curve == NamedCurve::P256 || curve == NamedCurve::P384;
     99    return curve == NamedCurve::P256 || curve == NamedCurve::P384 || curve == NamedCurve::P521;
    106100}
    107101
    108102std::optional<CryptoKeyPair> CryptoKeyEC::platformGeneratePair(CryptoAlgorithmIdentifier identifier, NamedCurve curve, bool extractable, CryptoKeyUsageBitmap usages)
    109103{
    110     size_t size = getKeySizeFromNamedCurve(curve);
     104    size_t size = keySizeInBitsFromNamedCurve(curve);
    111105    CCECCryptorRef ccPublicKey = nullptr;
    112106    CCECCryptorRef ccPrivateKey = nullptr;
     
    133127Vector<uint8_t> CryptoKeyEC::platformExportRaw() const
    134128{
    135     size_t expectedSize = keySizeInBits() / 4 + 1; // Per Section 2.3.4 of http://www.secg.org/sec1-v2.pdf
     129    size_t expectedSize = 2 * keySizeInBytes() + 1; // Per Section 2.3.4 of http://www.secg.org/sec1-v2.pdf
    136130    Vector<uint8_t> result(expectedSize);
    137131    size_t size = result.size();
     
    146140        return nullptr;
    147141
    148     size_t size = getKeySizeFromNamedCurve(curve);
     142    size_t size = keySizeInBitsFromNamedCurve(curve);
    149143    CCECCryptorRef ccPublicKey = nullptr;
    150144    if (CCECCryptorCreateFromData(size, x.data(), x.size(), y.data(), y.size(), &ccPublicKey))
     
    176170bool CryptoKeyEC::platformAddFieldElements(JsonWebKey& jwk) const
    177171{
    178     size_t keySizeInBytes = keySizeInBits() / 8;
     172    size_t keySizeInBytes = this->keySizeInBytes();
    179173    size_t publicKeySize = keySizeInBytes * 2 + 1; // 04 + X + Y per Section 2.3.4 of http://www.secg.org/sec1-v2.pdf
    180174    size_t privateKeySize = keySizeInBytes * 3 + 1; // 04 + X + Y + D
     
    218212        break;
    219213    case CryptoKeyEC::NamedCurve::P521:
    220         ASSERT_NOT_REACHED();
    221         oid = nullptr;
    222         oidSize = 0;
     214        oid = Secp521r1;
     215        oidSize = sizeof(Secp521r1);
    223216        break;
    224217    }
     
    233226// secp256r1 OBJECT IDENTIFIER      ::= { iso(1) member-body(2) us(840) ansi-X9-62(10045) curves(3) prime(1) 7 }
    234227// secp384r1 OBJECT IDENTIFIER      ::= { iso(1) identified-organization(3) certicom(132) curve(0) 34 }
     228// secp521r1 OBJECT IDENTIFIER      ::= { iso(1) identified-organization(3) certicom(132) curve(0) 35 }
    235229RefPtr<CryptoKeyEC> CryptoKeyEC::platformImportSpki(CryptoAlgorithmIdentifier identifier, NamedCurve curve, Vector<uint8_t>&& keyData, bool extractable, CryptoKeyUsageBitmap usages)
    236230{
     
    273267Vector<uint8_t> CryptoKeyEC::platformExportSpki() const
    274268{
    275     size_t expectedKeySize = keySizeInBits() / 4 + 1; // Per Section 2.3.4 of http://www.secg.org/sec1-v2.pdf
     269    size_t expectedKeySize = 2 * keySizeInBytes() + 1; // Per Section 2.3.4 of http://www.secg.org/sec1-v2.pdf
    276270    Vector<uint8_t> keyBytes(expectedKeySize);
    277271    size_t keySize = keyBytes.size();
     
    285279    size_t oidSize = getOID(namedCurve(), oid);
    286280
    287     // SEQUENCE + length(1) + OID id-ecPublicKey + OID secp256r1/OID secp384r1 + BIT STRING + length(?) + InitialOctet + Key size
     281    // SEQUENCE + length(1) + OID id-ecPublicKey + OID secp256r1/OID secp384r1/OID secp521r1 + BIT STRING + length(?) + InitialOctet + Key size
    288282    size_t totalSize = sizeof(IdEcPublicKey) + oidSize + bytesNeededForEncodedLength(keySize + 1) + keySize + 4;
    289283
     
    343337    index += bytesUsedToEncodedLength(keyData[index]); // Read length
    344338
    345     if (keyData.size() < index + getKeySizeFromNamedCurve(curve) / 8)
     339    size_t privateKeySize = keySizeInBytesFromNamedCurve(curve);
     340    if (keyData.size() < index + privateKeySize)
    346341        return nullptr;
    347342    size_t privateKeyPos = index;
    348     index += getKeySizeFromNamedCurve(curve) / 8 + 1; // Read privateKey, TaggedType1
     343    index += privateKeySize + 1; // Read privateKey, TaggedType1
    349344    if (keyData.size() < index + 1)
    350345        return nullptr;
     
    358353    if (!doesUncompressedPointMatchNamedCurve(curve, keyBinary.size()))
    359354        return nullptr;
    360     keyBinary.append(keyData.data() + privateKeyPos, getKeySizeFromNamedCurve(curve) / 8);
     355    keyBinary.append(keyData.data() + privateKeyPos, privateKeySize);
    361356
    362357    CCECCryptorRef ccPrivateKey = nullptr;
     
    369364Vector<uint8_t> CryptoKeyEC::platformExportPkcs8() const
    370365{
    371     size_t keySizeInBytes = keySizeInBits() / 8;
     366    size_t keySizeInBytes = this->keySizeInBytes();
    372367    size_t expectedKeySize = keySizeInBytes * 3 + 1; // 04 + X + Y + D
    373368    Vector<uint8_t> keyBytes(expectedKeySize);
     
    390385    // SEQUENCE + length(?) + ecPrivateKeySize
    391386    size_t privateKeySize = bytesNeededForEncodedLength(ecPrivateKeySize) + ecPrivateKeySize + 1;
    392     // VERSION + SEQUENCE + length(1) + OID id-ecPublicKey + OID secp256r1/OID secp384r1 + OCTET STRING + length(?) + privateKeySize
     387    // VERSION + SEQUENCE + length(1) + OID id-ecPublicKey + OID secp256r1/OID secp384r1/OID secp521r1 + OCTET STRING + length(?) + privateKeySize
    393388    size_t totalSize = sizeof(Version) + sizeof(IdEcPublicKey) + oidSize + bytesNeededForEncodedLength(privateKeySize) + privateKeySize + 3;
    394389
Note: See TracChangeset for help on using the changeset viewer.