haikuwebkit/Source/WebCore/crypto/JsonWebKey.h

64 lines
2.0 KiB
C
Raw Permalink Normal View History

Update SubtleCrypto::generateKey to match the latest spec https://bugs.webkit.org/show_bug.cgi?id=163718 <rdar://problem/28864380> Reviewed by Chris Dumez. LayoutTests/imported/w3c: * WebCryptoAPI/generateKey/test_aes-cbc-expected.txt: * WebCryptoAPI/generateKey/test_aes-cbc.html: * WebCryptoAPI/generateKey/test_aes-ctr-expected.txt: * WebCryptoAPI/generateKey/test_aes-ctr.html: * WebCryptoAPI/generateKey/test_failures-expected.txt: * WebCryptoAPI/generateKey/test_failures.html: * WebCryptoAPI/generateKey/test_failures_AES-CBC-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-CBC.html: * WebCryptoAPI/generateKey/test_failures_AES-CTR-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-CTR.html: * WebCryptoAPI/generateKey/test_failures_AES-GCM-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-GCM.html: * WebCryptoAPI/generateKey/test_failures_AES-KW-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-KW.html: * WebCryptoAPI/generateKey/test_failures_ECDH-expected.txt: * WebCryptoAPI/generateKey/test_failures_ECDH.html: * WebCryptoAPI/generateKey/test_failures_ECDSA-expected.txt: * WebCryptoAPI/generateKey/test_failures_ECDSA.html: * WebCryptoAPI/generateKey/test_failures_HMAC-expected.txt: * WebCryptoAPI/generateKey/test_failures_HMAC.html: * WebCryptoAPI/generateKey/test_failures_RSA-OAEP-expected.txt: * WebCryptoAPI/generateKey/test_failures_RSA-OAEP.html: * WebCryptoAPI/generateKey/test_failures_RSA-PSS-expected.txt: * WebCryptoAPI/generateKey/test_failures_RSA-PSS.html: * WebCryptoAPI/generateKey/test_failures_RSASSA-PKCS1-v1_5-expected.txt: * WebCryptoAPI/generateKey/test_failures_RSASSA-PKCS1-v1_5.html: * WebCryptoAPI/generateKey/test_successes-expected.txt: * WebCryptoAPI/generateKey/test_successes.html: * WebCryptoAPI/generateKey/test_successes_AES-CBC-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-CBC.html: * WebCryptoAPI/generateKey/test_successes_AES-CTR-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-CTR.html: * WebCryptoAPI/generateKey/test_successes_AES-GCM-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-GCM.html: * WebCryptoAPI/generateKey/test_successes_AES-KW-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-KW.html: * WebCryptoAPI/generateKey/test_successes_ECDH-expected.txt: * WebCryptoAPI/generateKey/test_successes_ECDH.html: * WebCryptoAPI/generateKey/test_successes_ECDSA-expected.txt: * WebCryptoAPI/generateKey/test_successes_ECDSA.html: * WebCryptoAPI/generateKey/test_successes_HMAC-expected.txt: * WebCryptoAPI/generateKey/test_successes_HMAC.html: * WebCryptoAPI/generateKey/test_successes_RSA-OAEP-expected.txt: * WebCryptoAPI/generateKey/test_successes_RSA-OAEP.html: * WebCryptoAPI/generateKey/test_successes_RSA-PSS-expected.txt: * WebCryptoAPI/generateKey/test_successes_RSA-PSS.html: * WebCryptoAPI/generateKey/test_successes_RSASSA-PKCS1-v1_5-expected.txt: * WebCryptoAPI/generateKey/test_successes_RSASSA-PKCS1-v1_5.html: * WebCryptoAPI/idlharness-expected.txt: Source/WebCore: This patch does following few things: 1. It updates the SubtleCrypto::generateKey method to match the latest spec: https://www.w3.org/TR/WebCryptoAPI/#SubtleCrypto-method-generateKey. It also refers to the latest Editor's Draft at a certain degree: https://w3c.github.io/webcrypto/Overview.html#SubtleCrypto-method-generateKey. 2. It implements generateKey operations of following algorithms: AES-CBC, AES-KW, HMAC, RSAES-PKCS1-V1_5, RSASSA-PKCS1-V1_5, and RSA-OAEP. 3. It replaces SPECIALIZE_TYPE_TRAITS_CRYPTO_ALGORITHM_PARAMETERS with SPECIALIZE_TYPE_TRAITS_CRYPTO_ALGORITHM_PARAMETERS_DEPRECATED for deprecated params. 4. It fixes https://bugs.webkit.org/show_bug.cgi?id=129750 as well. Tests: crypto/subtle/aes-cbc-generate-key-length-128.html crypto/subtle/aes-cbc-generate-key-length-192.html crypto/subtle/aes-cbc-generate-key-length-256.html crypto/subtle/aes-generate-key-malformed-parameters.html crypto/subtle/aes-kw-generate-key.html crypto/subtle/generate-key-malformed-paramters.html crypto/subtle/hmac-generate-key-customized-length.html crypto/subtle/hmac-generate-key-hash-object.html crypto/subtle/hmac-generate-key-malformed-parameters.html crypto/subtle/hmac-generate-key-sha1.html crypto/subtle/hmac-generate-key-sha224.html crypto/subtle/hmac-generate-key-sha256.html crypto/subtle/hmac-generate-key-sha384.html crypto/subtle/hmac-generate-key-sha512.html crypto/subtle/rsa-generate-key-malformed-parameters.html crypto/subtle/rsa-oaep-generate-key.html crypto/subtle/rsaes-pkcs1-v1_5-generate-key-extractable.html crypto/subtle/rsaes-pkcs1-v1_5-generate-key.html crypto/subtle/rsassa-pkcs1-v1_5-generate-key.html crypto/webkitSubtle/hmac-generate-key.html: crypto/workers/subtle/aes-generate-key.html crypto/workers/subtle/hmac-generate-key.html crypto/workers/subtle/rsa-generate-key.html * CMakeLists.txt: * DerivedSources.make: * Modules/encryptedmedia/CDMSessionClearKey.cpp: * WebCore.xcodeproj/project.pbxproj: * bindings/js/JSSubtleCryptoCustom.cpp: Added. (WebCore::toHashIdentifier): (WebCore::normalizeCryptoAlgorithmParameters): (WebCore::cryptoKeyUsagesFromJSValue): (WebCore::createAlgorithm): (WebCore::rejectWithException): (WebCore::jsSubtleCryptoFunctionGenerateKeyPromise): (WebCore::JSSubtleCrypto::generateKey): * bindings/js/JSWebKitSubtleCryptoCustom.cpp: (WebCore::JSWebKitSubtleCrypto::generateKey): * crypto/CryptoAlgorithm.cpp: (WebCore::CryptoAlgorithm::generateKey): * crypto/CryptoAlgorithm.h: * crypto/CryptoAlgorithmParameters.h: Added. (WebCore::CryptoAlgorithmParameters::CryptoAlgorithmParameters): (WebCore::CryptoAlgorithmParameters::~CryptoAlgorithmParameters): (WebCore::CryptoAlgorithmParameters::parametersClass): * crypto/CryptoAlgorithmParameters.idl: Added. * crypto/CryptoAlgorithmParametersDeprecated.h: * crypto/CryptoKey.cpp: (WebCore::CryptoKey::setUsagesBitmap): * crypto/CryptoKey.h: * crypto/CryptoKeyPair.idl: * crypto/SubtleCrypto.idl: * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: (WebCore::CryptoAlgorithmAES_CBC::generateKey): * crypto/algorithms/CryptoAlgorithmAES_CBC.h: * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: (WebCore::CryptoAlgorithmAES_KW::generateKey): * crypto/algorithms/CryptoAlgorithmAES_KW.h: * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::generateKey): * crypto/algorithms/CryptoAlgorithmHMAC.h: * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::generateKey): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::generateKey): * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: (WebCore::CryptoAlgorithmRSA_OAEP::generateKey): * crypto/algorithms/CryptoAlgorithmRSA_OAEP.h: * crypto/gnutls/CryptoKeyRSAGnuTLS.cpp: (WebCore::CryptoKeyRSA::generatePair): * crypto/keys/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::generate): * crypto/keys/CryptoKeyHMAC.cpp: (WebCore::CryptoKeyHMAC::generate): * crypto/keys/CryptoKeyRSA.h: * crypto/mac/CryptoKeyRSAMac.cpp: (WebCore::CryptoKeyRSA::generatePair): * crypto/parameters/AesKeyGenParams.idl: Added. * crypto/parameters/CryptoAlgorithmAesCbcParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmAesKeyGenParams.h: Added. * crypto/parameters/CryptoAlgorithmAesKeyGenParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmHmacKeyGenParams.h: Added. * crypto/parameters/CryptoAlgorithmHmacKeyParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmHmacParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaHashedKeyGenParams.h: Added. * crypto/parameters/CryptoAlgorithmRsaKeyGenParams.h: Added. (WebCore::CryptoAlgorithmRsaKeyGenParams::arrayToVector): * crypto/parameters/CryptoAlgorithmRsaKeyGenParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaKeyParamsWithHashDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaOaepParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaSsaParamsDeprecated.h: * crypto/parameters/HmacKeyGenParams.idl: Added. * crypto/parameters/RsaHashedKeyGenParams.idl: Added. * crypto/parameters/RsaKeyGenParams.idl: Added. LayoutTests: Besides adding tests for SubtleCrypto::generateKey related stuff and fixing HMAC. This patch also add shouldReject(_a, _rejectCallback, _resolveCallback, _message) in js-test-pre.js. * TestExpectations: * crypto/subtle/aes-cbc-generate-key-length-128-expected.txt: Added. * crypto/subtle/aes-cbc-generate-key-length-128.html: Added. * crypto/subtle/aes-cbc-generate-key-length-192-expected.txt: Added. * crypto/subtle/aes-cbc-generate-key-length-192.html: Added. * crypto/subtle/aes-cbc-generate-key-length-256-expected.txt: Added. * crypto/subtle/aes-cbc-generate-key-length-256.html: Added. * crypto/subtle/aes-generate-key-malformed-parameters-expected.txt: Added. * crypto/subtle/aes-generate-key-malformed-parameters.html: Added. * crypto/subtle/aes-kw-generate-key-expected.txt: Added. * crypto/subtle/aes-kw-generate-key.html: Added. * crypto/subtle/generate-key-malformed-paramters-expected.txt: Added. * crypto/subtle/generate-key-malformed-paramters.html: Added. * crypto/subtle/hmac-generate-key-customized-length-expected.txt: Added. * crypto/subtle/hmac-generate-key-customized-length.html: Added. * crypto/subtle/hmac-generate-key-hash-object-expected.txt: Added. * crypto/subtle/hmac-generate-key-hash-object.html: Added. * crypto/subtle/hmac-generate-key-malformed-parameters-expected.txt: Added. * crypto/subtle/hmac-generate-key-malformed-parameters.html: Added. * crypto/subtle/hmac-generate-key-sha1-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha1.html: Added. * crypto/subtle/hmac-generate-key-sha224-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha224.html: Added. * crypto/subtle/hmac-generate-key-sha256-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha256.html: Added. * crypto/subtle/hmac-generate-key-sha384-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha384.html: Added. * crypto/subtle/hmac-generate-key-sha512-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha512.html: Added. * crypto/subtle/rsa-generate-key-malformed-parameters-expected.txt: Added. * crypto/subtle/rsa-generate-key-malformed-parameters.html: Added. * crypto/subtle/rsa-oaep-generate-key-expected.txt: Added. * crypto/subtle/rsa-oaep-generate-key.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key-extractable-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key-extractable.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-generate-key-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-generate-key.html: Added. * crypto/webkitSubtle/hmac-generate-key-expected.txt: * crypto/webkitSubtle/hmac-generate-key.html: * crypto/workers/subtle/aes-generate-key-expected.txt: Added. * crypto/workers/subtle/aes-generate-key.html: Added. * crypto/workers/subtle/hmac-generate-key-expected.txt: Added. * crypto/workers/subtle/hmac-generate-key.html: Added. * crypto/workers/subtle/resources/aes-generate-key.js: Added. * crypto/workers/subtle/resources/hmac-generate-key.js: Added. * crypto/workers/subtle/resources/rsa-generate-key.js: Added. * crypto/workers/subtle/rsa-generate-key-expected.txt: Added. * crypto/workers/subtle/rsa-generate-key.html: Added. * resources/js-test-pre.js: Canonical link: https://commits.webkit.org/181666@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@207809 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-10-25 06:07:04 +00:00
/*
* Copyright (C) 2016 Apple Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
* THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
* BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
* THE POSSIBILITY OF SUCH DAMAGE.
*/
#pragma once
Update SubtleCrypto::importKey to match the latest spec https://bugs.webkit.org/show_bug.cgi?id=164446 <rdar://problem/29123621> Reviewed by Brent Fulgham. LayoutTests/imported/w3c: * WebCryptoAPI/idlharness-expected.txt: Source/WebCore: This patch does following few things: 1. It updates the SubtleCrypto::importKey method to match the latest spec: https://www.w3.org/TR/WebCryptoAPI/#SubtleCrypto-method-importKey. It also refers to the latest Editor's Draft at a certain degree: https://w3c.github.io/webcrypto/Overview.html#SubtleCrypto-method-importKey. 2. It implements importKey operations of following algorithms: AES-CBC, AES-KW, HMAC, RSAES-PKCS1-V1_5, RSASSA-PKCS1-V1_5, and RSA-OAEP. 3. It fixes some minor problems of SubtleCrypto::generateKey. 4. It addes move constructors for CryptoKeyAES, CryptoKeyHMAC, CryptoKeyRSA and CryptoKeyDataRSAComponents. 5. It renames HmacKeyGenParams to HmacKeyParams to serve the purpose of both HmacKeyGenParams and HmacImportParams which are essentially the same. 6. It enforces the key length in bits of CryptoKeyHMAC to be multiples of 8. 7. It also fixes the following bugs: https://bugs.webkit.org/show_bug.cgi?id=126033, https://bugs.webkit.org/show_bug.cgi?id=126034, https://bugs.webkit.org/show_bug.cgi?id=151308. P.S. We currently only support Raw and Jwk key format. Tests: crypto/subtle/aes-cbc-import-jwk-key-length-128.html crypto/subtle/aes-cbc-import-jwk-key-length-192.html crypto/subtle/aes-cbc-import-jwk-key-length-256.html crypto/subtle/aes-cbc-import-jwk-key-minimum.html crypto/subtle/aes-cbc-import-jwk-key-non-extractable.html crypto/subtle/aes-cbc-import-raw-key-length-128.html crypto/subtle/aes-cbc-import-raw-key-length-192.html crypto/subtle/aes-cbc-import-raw-key-length-256.html crypto/subtle/aes-import-key-malformed-parameters.html crypto/subtle/aes-kw-import-jwk-key-length-128.html crypto/subtle/aes-kw-import-jwk-key-length-192.html crypto/subtle/aes-kw-import-jwk-key-length-256.html crypto/subtle/aes-kw-import-raw-key.html crypto/subtle/generate-key-malformed-parameters.html crypto/subtle/hmac-import-jwk-key-minimum.html crypto/subtle/hmac-import-jwk-key-non-extractable.html crypto/subtle/hmac-import-jwk-key-sha1.html crypto/subtle/hmac-import-jwk-key-sha224.html crypto/subtle/hmac-import-jwk-key-sha256.html crypto/subtle/hmac-import-jwk-key-sha384.html crypto/subtle/hmac-import-jwk-key-sha512.html crypto/subtle/hmac-import-malformed-parameters.html crypto/subtle/hmac-import-raw-key-customized-length.html crypto/subtle/hmac-import-raw-key.html crypto/subtle/import-key-malformed-parameters.html crypto/subtle/rsa-import-key-malformed-parameters.html crypto/subtle/rsa-oaep-import-jwk-private-key.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha1.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha224.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha256.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha384.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha512.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-private-key.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-leading-zero.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-minimum.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-non-extractable.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-private-key.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha1.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha224.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha256.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha384.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha512.html crypto/workers/subtle/aes-import-jwk-key.html crypto/workers/subtle/aes-import-raw-key.html crypto/workers/subtle/hmac-import-jwk-key.html crypto/workers/subtle/hmac-import-raw-key.html crypto/workers/subtle/rsa-import-jwk-private-key.html crypto/workers/subtle/rsa-import-jwk-public-key.html * CMakeLists.txt: * DerivedSources.make: * PlatformEfl.cmake: * PlatformGTK.cmake: * PlatformMac.cmake: * WebCore.xcodeproj/project.pbxproj: * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::normalizeCryptoAlgorithmParameters): (WebCore::cryptoKeyUsageFromString): (WebCore::cryptoKeyUsagesFromJSValue): (WebCore::toKeyData): (WebCore::jsSubtleCryptoFunctionGenerateKeyPromise): (WebCore::jsSubtleCryptoFunctionImportKeyPromise): (WebCore::JSSubtleCrypto::importKey): * crypto/CryptoAlgorithm.cpp: (WebCore::CryptoAlgorithm::importKey): * crypto/CryptoAlgorithm.h: * crypto/CryptoAlgorithmParameters.h: * crypto/JsonWebKey.h: Added. * crypto/JsonWebKey.idl: Added. * crypto/RsaOtherPrimesInfo.h: Added. * crypto/RsaOtherPrimesInfo.idl: Added. * crypto/SubtleCrypto.h: * crypto/SubtleCrypto.idl: * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: (WebCore::CryptoAlgorithmAES_CBC::generateKey): (WebCore::CryptoAlgorithmAES_CBC::importKey): * crypto/algorithms/CryptoAlgorithmAES_CBC.h: * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: (WebCore::CryptoAlgorithmAES_KW::generateKey): (WebCore::CryptoAlgorithmAES_KW::importKey): * crypto/algorithms/CryptoAlgorithmAES_KW.h: * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::generateKey): (WebCore::CryptoAlgorithmHMAC::importKey): * crypto/algorithms/CryptoAlgorithmHMAC.h: * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: (WebCore::CryptoAlgorithmRSA_OAEP::importKey): * crypto/algorithms/CryptoAlgorithmRSA_OAEP.h: * crypto/keys/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::CryptoKeyAES): (WebCore::CryptoKeyAES::generate): (WebCore::CryptoKeyAES::importRaw): (WebCore::CryptoKeyAES::importJwk): * crypto/keys/CryptoKeyAES.h: * crypto/keys/CryptoKeyDataRSAComponents.cpp: (WebCore::CryptoKeyDataRSAComponents::CryptoKeyDataRSAComponents): * crypto/keys/CryptoKeyDataRSAComponents.h: * crypto/keys/CryptoKeyHMAC.cpp: (WebCore::CryptoKeyHMAC::CryptoKeyHMAC): (WebCore::CryptoKeyHMAC::generate): (WebCore::CryptoKeyHMAC::importRaw): (WebCore::CryptoKeyHMAC::importJwk): (WebCore::CryptoKeyHMAC::buildAlgorithm): * crypto/keys/CryptoKeyHMAC.h: * crypto/keys/CryptoKeyRSA.cpp: Added. (WebCore::CryptoKeyRSA::importJwk): * crypto/keys/CryptoKeyRSA.h: * crypto/parameters/CryptoAlgorithmHmacKeyParams.h: Renamed from Source/WebCore/crypto/parameters/CryptoAlgorithmHmacKeyGenParams.h. * crypto/parameters/CryptoAlgorithmRsaHashedImportParams.h: Added. * crypto/parameters/HmacKeyParams.idl: Renamed from Source/WebCore/crypto/parameters/HmacKeyGenParams.idl. * crypto/parameters/RsaHashedImportParams.idl: Added. LayoutTests: Besides adding test cases for SubtleCrypto::importKey. This patch also corrects a typo: generate-key-malformed-paramters*. * crypto/subtle/aes-cbc-import-jwk-key-length-128-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-128.html: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-192-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-192.html: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-256-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-256.html: Added. * crypto/subtle/aes-cbc-import-jwk-key-minimum-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-minimum.html: Added. * crypto/subtle/aes-cbc-import-jwk-key-non-extractable-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-non-extractable.html: Added. * crypto/subtle/aes-cbc-import-raw-key-length-128-expected.txt: Added. * crypto/subtle/aes-cbc-import-raw-key-length-128.html: Added. * crypto/subtle/aes-cbc-import-raw-key-length-192-expected.txt: Added. * crypto/subtle/aes-cbc-import-raw-key-length-192.html: Added. * crypto/subtle/aes-cbc-import-raw-key-length-256-expected.txt: Added. * crypto/subtle/aes-cbc-import-raw-key-length-256.html: Added. * crypto/subtle/aes-import-key-malformed-parameters-expected.txt: Added. * crypto/subtle/aes-import-key-malformed-parameters.html: Added. * crypto/subtle/aes-kw-import-jwk-key-length-128-expected.txt: Added. * crypto/subtle/aes-kw-import-jwk-key-length-128.html: Added. * crypto/subtle/aes-kw-import-jwk-key-length-192-expected.txt: Added. * crypto/subtle/aes-kw-import-jwk-key-length-192.html: Added. * crypto/subtle/aes-kw-import-jwk-key-length-256-expected.txt: Added. * crypto/subtle/aes-kw-import-jwk-key-length-256.html: Added. * crypto/subtle/aes-kw-import-raw-key-expected.txt: Added. * crypto/subtle/aes-kw-import-raw-key.html: Added. * crypto/subtle/generate-key-malformed-parameters-expected.txt: Renamed from LayoutTests/crypto/subtle/generate-key-malformed-paramters-expected.txt. * crypto/subtle/generate-key-malformed-parameters.html: Renamed from LayoutTests/crypto/subtle/generate-key-malformed-paramters.html. * crypto/subtle/hmac-generate-key-customized-length-expected.txt: * crypto/subtle/hmac-generate-key-customized-length.html: * crypto/subtle/hmac-generate-key-malformed-parameters-expected.txt: * crypto/subtle/hmac-generate-key-malformed-parameters.html: * crypto/subtle/hmac-import-raw-key-customized-length-expected.txt: * crypto/subtle/hmac-import-raw-key-customized-length.html: * crypto/subtle/hmac-import-jwk-key-minimum-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-minimum.html: Added. * crypto/subtle/hmac-import-jwk-key-non-extractable-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-non-extractable.html: Added. * crypto/subtle/hmac-import-jwk-key-sha1-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha1.html: Added. * crypto/subtle/hmac-import-jwk-key-sha224-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha224.html: Added. * crypto/subtle/hmac-import-jwk-key-sha256-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha256.html: Added. * crypto/subtle/hmac-import-jwk-key-sha384-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha384.html: Added. * crypto/subtle/hmac-import-jwk-key-sha512-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha512.html: Added. * crypto/subtle/hmac-import-malformed-parameters-expected.txt: Added. * crypto/subtle/hmac-import-malformed-parameters.html: Added. * crypto/subtle/hmac-import-raw-key-customized-length-expected.txt: Added. * crypto/subtle/hmac-import-raw-key-customized-length.html: Added. * crypto/subtle/hmac-import-raw-key-expected.txt: Added. * crypto/subtle/hmac-import-raw-key.html: Added. * crypto/subtle/import-key-malformed-parameters-expected.txt: Added. * crypto/subtle/import-key-malformed-parameters.html: Added. * crypto/subtle/rsa-import-key-malformed-parameters-expected.txt: Added. * crypto/subtle/rsa-import-key-malformed-parameters.html: Added. * crypto/subtle/rsa-oaep-import-jwk-private-key-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-private-key.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha1-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha1.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha224-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha224.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha256-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha256.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha384-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha384.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha512-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha512.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-private-key-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-private-key.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-leading-zero-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-leading-zero.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-minimum-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-minimum.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-non-extractable-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-non-extractable.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-private-key-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-private-key.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha1-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha1.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha224-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha224.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha256-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha256.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha384-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha384.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha512-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha512.html: Added. * crypto/webkitSubtle/hmac-generate-key-expected.txt: * crypto/webkitSubtle/hmac-generate-key.html: * crypto/webkitSubtle/hmac-import-jwk-expected.txt: * crypto/webkitSubtle/hmac-import-jwk.html: * crypto/webkitSubtle/hmac-postMessage-expected.txt: * crypto/webkitSubtle/hmac-postMessage.html: * crypto/webkitSubtle/hmac-sign-verify-expected.txt: * crypto/webkitSubtle/hmac-sign-verify.html: * crypto/workers/subtle/aes-import-jwk-key-expected.txt: Added. * crypto/workers/subtle/aes-import-jwk-key.html: Added. * crypto/workers/subtle/aes-import-raw-key-expected.txt: Added. * crypto/workers/subtle/aes-import-raw-key.html: Added. * crypto/workers/subtle/hmac-import-jwk-key-expected.txt: Added. * crypto/workers/subtle/hmac-import-jwk-key.html: Added. * crypto/workers/subtle/hmac-import-raw-key-expected.txt: Added. * crypto/workers/subtle/hmac-import-raw-key.html: Added. * crypto/workers/subtle/hmac-postMessage-worker-expected.txt: * crypto/workers/subtle/hmac-postMessage-worker.html: * crypto/workers/subtle/resources/aes-import-jwk-key.js: Added. * crypto/workers/subtle/resources/aes-import-raw-key.js: Added. * crypto/workers/subtle/resources/hmac-import-jwk-key.js: Added. * crypto/workers/subtle/resources/hmac-import-raw-key.js: Added. * crypto/workers/subtle/resources/hmac-postMessage-worker.js: * crypto/workers/subtle/resources/rsa-import-jwk-private-key.js: Added. * crypto/workers/subtle/resources/rsa-import-jwk-public-key.js: Added. * crypto/workers/subtle/rsa-import-jwk-private-key-expected.txt: Added. * crypto/workers/subtle/rsa-import-jwk-private-key.html: Added. * crypto/workers/subtle/rsa-import-jwk-public-key-expected.txt: Added. * crypto/workers/subtle/rsa-import-jwk-public-key.html: Added. Canonical link: https://commits.webkit.org/182271@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@208548 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-11-10 18:36:44 +00:00
#include "CryptoKeyUsage.h"
#include "RsaOtherPrimesInfo.h"
#include <wtf/Vector.h>
Update SubtleCrypto::generateKey to match the latest spec https://bugs.webkit.org/show_bug.cgi?id=163718 <rdar://problem/28864380> Reviewed by Chris Dumez. LayoutTests/imported/w3c: * WebCryptoAPI/generateKey/test_aes-cbc-expected.txt: * WebCryptoAPI/generateKey/test_aes-cbc.html: * WebCryptoAPI/generateKey/test_aes-ctr-expected.txt: * WebCryptoAPI/generateKey/test_aes-ctr.html: * WebCryptoAPI/generateKey/test_failures-expected.txt: * WebCryptoAPI/generateKey/test_failures.html: * WebCryptoAPI/generateKey/test_failures_AES-CBC-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-CBC.html: * WebCryptoAPI/generateKey/test_failures_AES-CTR-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-CTR.html: * WebCryptoAPI/generateKey/test_failures_AES-GCM-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-GCM.html: * WebCryptoAPI/generateKey/test_failures_AES-KW-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-KW.html: * WebCryptoAPI/generateKey/test_failures_ECDH-expected.txt: * WebCryptoAPI/generateKey/test_failures_ECDH.html: * WebCryptoAPI/generateKey/test_failures_ECDSA-expected.txt: * WebCryptoAPI/generateKey/test_failures_ECDSA.html: * WebCryptoAPI/generateKey/test_failures_HMAC-expected.txt: * WebCryptoAPI/generateKey/test_failures_HMAC.html: * WebCryptoAPI/generateKey/test_failures_RSA-OAEP-expected.txt: * WebCryptoAPI/generateKey/test_failures_RSA-OAEP.html: * WebCryptoAPI/generateKey/test_failures_RSA-PSS-expected.txt: * WebCryptoAPI/generateKey/test_failures_RSA-PSS.html: * WebCryptoAPI/generateKey/test_failures_RSASSA-PKCS1-v1_5-expected.txt: * WebCryptoAPI/generateKey/test_failures_RSASSA-PKCS1-v1_5.html: * WebCryptoAPI/generateKey/test_successes-expected.txt: * WebCryptoAPI/generateKey/test_successes.html: * WebCryptoAPI/generateKey/test_successes_AES-CBC-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-CBC.html: * WebCryptoAPI/generateKey/test_successes_AES-CTR-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-CTR.html: * WebCryptoAPI/generateKey/test_successes_AES-GCM-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-GCM.html: * WebCryptoAPI/generateKey/test_successes_AES-KW-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-KW.html: * WebCryptoAPI/generateKey/test_successes_ECDH-expected.txt: * WebCryptoAPI/generateKey/test_successes_ECDH.html: * WebCryptoAPI/generateKey/test_successes_ECDSA-expected.txt: * WebCryptoAPI/generateKey/test_successes_ECDSA.html: * WebCryptoAPI/generateKey/test_successes_HMAC-expected.txt: * WebCryptoAPI/generateKey/test_successes_HMAC.html: * WebCryptoAPI/generateKey/test_successes_RSA-OAEP-expected.txt: * WebCryptoAPI/generateKey/test_successes_RSA-OAEP.html: * WebCryptoAPI/generateKey/test_successes_RSA-PSS-expected.txt: * WebCryptoAPI/generateKey/test_successes_RSA-PSS.html: * WebCryptoAPI/generateKey/test_successes_RSASSA-PKCS1-v1_5-expected.txt: * WebCryptoAPI/generateKey/test_successes_RSASSA-PKCS1-v1_5.html: * WebCryptoAPI/idlharness-expected.txt: Source/WebCore: This patch does following few things: 1. It updates the SubtleCrypto::generateKey method to match the latest spec: https://www.w3.org/TR/WebCryptoAPI/#SubtleCrypto-method-generateKey. It also refers to the latest Editor's Draft at a certain degree: https://w3c.github.io/webcrypto/Overview.html#SubtleCrypto-method-generateKey. 2. It implements generateKey operations of following algorithms: AES-CBC, AES-KW, HMAC, RSAES-PKCS1-V1_5, RSASSA-PKCS1-V1_5, and RSA-OAEP. 3. It replaces SPECIALIZE_TYPE_TRAITS_CRYPTO_ALGORITHM_PARAMETERS with SPECIALIZE_TYPE_TRAITS_CRYPTO_ALGORITHM_PARAMETERS_DEPRECATED for deprecated params. 4. It fixes https://bugs.webkit.org/show_bug.cgi?id=129750 as well. Tests: crypto/subtle/aes-cbc-generate-key-length-128.html crypto/subtle/aes-cbc-generate-key-length-192.html crypto/subtle/aes-cbc-generate-key-length-256.html crypto/subtle/aes-generate-key-malformed-parameters.html crypto/subtle/aes-kw-generate-key.html crypto/subtle/generate-key-malformed-paramters.html crypto/subtle/hmac-generate-key-customized-length.html crypto/subtle/hmac-generate-key-hash-object.html crypto/subtle/hmac-generate-key-malformed-parameters.html crypto/subtle/hmac-generate-key-sha1.html crypto/subtle/hmac-generate-key-sha224.html crypto/subtle/hmac-generate-key-sha256.html crypto/subtle/hmac-generate-key-sha384.html crypto/subtle/hmac-generate-key-sha512.html crypto/subtle/rsa-generate-key-malformed-parameters.html crypto/subtle/rsa-oaep-generate-key.html crypto/subtle/rsaes-pkcs1-v1_5-generate-key-extractable.html crypto/subtle/rsaes-pkcs1-v1_5-generate-key.html crypto/subtle/rsassa-pkcs1-v1_5-generate-key.html crypto/webkitSubtle/hmac-generate-key.html: crypto/workers/subtle/aes-generate-key.html crypto/workers/subtle/hmac-generate-key.html crypto/workers/subtle/rsa-generate-key.html * CMakeLists.txt: * DerivedSources.make: * Modules/encryptedmedia/CDMSessionClearKey.cpp: * WebCore.xcodeproj/project.pbxproj: * bindings/js/JSSubtleCryptoCustom.cpp: Added. (WebCore::toHashIdentifier): (WebCore::normalizeCryptoAlgorithmParameters): (WebCore::cryptoKeyUsagesFromJSValue): (WebCore::createAlgorithm): (WebCore::rejectWithException): (WebCore::jsSubtleCryptoFunctionGenerateKeyPromise): (WebCore::JSSubtleCrypto::generateKey): * bindings/js/JSWebKitSubtleCryptoCustom.cpp: (WebCore::JSWebKitSubtleCrypto::generateKey): * crypto/CryptoAlgorithm.cpp: (WebCore::CryptoAlgorithm::generateKey): * crypto/CryptoAlgorithm.h: * crypto/CryptoAlgorithmParameters.h: Added. (WebCore::CryptoAlgorithmParameters::CryptoAlgorithmParameters): (WebCore::CryptoAlgorithmParameters::~CryptoAlgorithmParameters): (WebCore::CryptoAlgorithmParameters::parametersClass): * crypto/CryptoAlgorithmParameters.idl: Added. * crypto/CryptoAlgorithmParametersDeprecated.h: * crypto/CryptoKey.cpp: (WebCore::CryptoKey::setUsagesBitmap): * crypto/CryptoKey.h: * crypto/CryptoKeyPair.idl: * crypto/SubtleCrypto.idl: * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: (WebCore::CryptoAlgorithmAES_CBC::generateKey): * crypto/algorithms/CryptoAlgorithmAES_CBC.h: * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: (WebCore::CryptoAlgorithmAES_KW::generateKey): * crypto/algorithms/CryptoAlgorithmAES_KW.h: * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::generateKey): * crypto/algorithms/CryptoAlgorithmHMAC.h: * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::generateKey): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::generateKey): * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: (WebCore::CryptoAlgorithmRSA_OAEP::generateKey): * crypto/algorithms/CryptoAlgorithmRSA_OAEP.h: * crypto/gnutls/CryptoKeyRSAGnuTLS.cpp: (WebCore::CryptoKeyRSA::generatePair): * crypto/keys/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::generate): * crypto/keys/CryptoKeyHMAC.cpp: (WebCore::CryptoKeyHMAC::generate): * crypto/keys/CryptoKeyRSA.h: * crypto/mac/CryptoKeyRSAMac.cpp: (WebCore::CryptoKeyRSA::generatePair): * crypto/parameters/AesKeyGenParams.idl: Added. * crypto/parameters/CryptoAlgorithmAesCbcParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmAesKeyGenParams.h: Added. * crypto/parameters/CryptoAlgorithmAesKeyGenParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmHmacKeyGenParams.h: Added. * crypto/parameters/CryptoAlgorithmHmacKeyParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmHmacParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaHashedKeyGenParams.h: Added. * crypto/parameters/CryptoAlgorithmRsaKeyGenParams.h: Added. (WebCore::CryptoAlgorithmRsaKeyGenParams::arrayToVector): * crypto/parameters/CryptoAlgorithmRsaKeyGenParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaKeyParamsWithHashDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaOaepParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaSsaParamsDeprecated.h: * crypto/parameters/HmacKeyGenParams.idl: Added. * crypto/parameters/RsaHashedKeyGenParams.idl: Added. * crypto/parameters/RsaKeyGenParams.idl: Added. LayoutTests: Besides adding tests for SubtleCrypto::generateKey related stuff and fixing HMAC. This patch also add shouldReject(_a, _rejectCallback, _resolveCallback, _message) in js-test-pre.js. * TestExpectations: * crypto/subtle/aes-cbc-generate-key-length-128-expected.txt: Added. * crypto/subtle/aes-cbc-generate-key-length-128.html: Added. * crypto/subtle/aes-cbc-generate-key-length-192-expected.txt: Added. * crypto/subtle/aes-cbc-generate-key-length-192.html: Added. * crypto/subtle/aes-cbc-generate-key-length-256-expected.txt: Added. * crypto/subtle/aes-cbc-generate-key-length-256.html: Added. * crypto/subtle/aes-generate-key-malformed-parameters-expected.txt: Added. * crypto/subtle/aes-generate-key-malformed-parameters.html: Added. * crypto/subtle/aes-kw-generate-key-expected.txt: Added. * crypto/subtle/aes-kw-generate-key.html: Added. * crypto/subtle/generate-key-malformed-paramters-expected.txt: Added. * crypto/subtle/generate-key-malformed-paramters.html: Added. * crypto/subtle/hmac-generate-key-customized-length-expected.txt: Added. * crypto/subtle/hmac-generate-key-customized-length.html: Added. * crypto/subtle/hmac-generate-key-hash-object-expected.txt: Added. * crypto/subtle/hmac-generate-key-hash-object.html: Added. * crypto/subtle/hmac-generate-key-malformed-parameters-expected.txt: Added. * crypto/subtle/hmac-generate-key-malformed-parameters.html: Added. * crypto/subtle/hmac-generate-key-sha1-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha1.html: Added. * crypto/subtle/hmac-generate-key-sha224-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha224.html: Added. * crypto/subtle/hmac-generate-key-sha256-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha256.html: Added. * crypto/subtle/hmac-generate-key-sha384-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha384.html: Added. * crypto/subtle/hmac-generate-key-sha512-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha512.html: Added. * crypto/subtle/rsa-generate-key-malformed-parameters-expected.txt: Added. * crypto/subtle/rsa-generate-key-malformed-parameters.html: Added. * crypto/subtle/rsa-oaep-generate-key-expected.txt: Added. * crypto/subtle/rsa-oaep-generate-key.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key-extractable-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key-extractable.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-generate-key-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-generate-key.html: Added. * crypto/webkitSubtle/hmac-generate-key-expected.txt: * crypto/webkitSubtle/hmac-generate-key.html: * crypto/workers/subtle/aes-generate-key-expected.txt: Added. * crypto/workers/subtle/aes-generate-key.html: Added. * crypto/workers/subtle/hmac-generate-key-expected.txt: Added. * crypto/workers/subtle/hmac-generate-key.html: Added. * crypto/workers/subtle/resources/aes-generate-key.js: Added. * crypto/workers/subtle/resources/hmac-generate-key.js: Added. * crypto/workers/subtle/resources/rsa-generate-key.js: Added. * crypto/workers/subtle/rsa-generate-key-expected.txt: Added. * crypto/workers/subtle/rsa-generate-key.html: Added. * resources/js-test-pre.js: Canonical link: https://commits.webkit.org/181666@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@207809 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-10-25 06:07:04 +00:00
Rename ENABLE_SUBTLE_CRYPTO to ENABLE_WEB_CRYPTO https://bugs.webkit.org/show_bug.cgi?id=192197 Reviewed by Jiewen Tan. .: * Source/cmake/OptionsGTK.cmake: * Source/cmake/OptionsWPE.cmake: * Source/cmake/OptionsWin.cmake: * Source/cmake/WebKitFeatures.cmake: Source/JavaScriptCore: * Configurations/FeatureDefines.xcconfig: Source/WebCore: No new tests. No change in behavior. * Configurations/FeatureDefines.xcconfig: * bindings/js/SerializedScriptValue.cpp: (WebCore::CloneSerializer::dumpIfTerminal): (WebCore::CloneDeserializer::readTerminal): * crypto/CommonCryptoUtilities.cpp: * crypto/CommonCryptoUtilities.h: * crypto/CryptoAlgorithm.cpp: * crypto/CryptoAlgorithm.h: * crypto/CryptoAlgorithmIdentifier.h: * crypto/CryptoAlgorithmParameters.h: * crypto/CryptoAlgorithmParameters.idl: * crypto/CryptoAlgorithmRegistry.cpp: * crypto/CryptoAlgorithmRegistry.h: * crypto/CryptoKey.cpp: * crypto/CryptoKey.h: * crypto/CryptoKey.idl: * crypto/CryptoKeyFormat.h: * crypto/CryptoKeyPair.h: * crypto/CryptoKeyPair.idl: * crypto/CryptoKeyType.h: * crypto/CryptoKeyUsage.h: * crypto/CryptoKeyUsage.idl: * crypto/JsonWebKey.h: * crypto/JsonWebKey.idl: * crypto/RsaOtherPrimesInfo.h: * crypto/RsaOtherPrimesInfo.idl: * crypto/SerializedCryptoKeyWrap.h: * crypto/SubtleCrypto.cpp: * crypto/SubtleCrypto.h: * crypto/SubtleCrypto.idl: * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: * crypto/algorithms/CryptoAlgorithmAES_CBC.h: * crypto/algorithms/CryptoAlgorithmAES_CFB.cpp: * crypto/algorithms/CryptoAlgorithmAES_CFB.h: * crypto/algorithms/CryptoAlgorithmAES_CTR.cpp: * crypto/algorithms/CryptoAlgorithmAES_CTR.h: * crypto/algorithms/CryptoAlgorithmAES_GCM.cpp: * crypto/algorithms/CryptoAlgorithmAES_GCM.h: * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: * crypto/algorithms/CryptoAlgorithmAES_KW.h: * crypto/algorithms/CryptoAlgorithmECDH.cpp: * crypto/algorithms/CryptoAlgorithmECDH.h: * crypto/algorithms/CryptoAlgorithmECDSA.cpp: * crypto/algorithms/CryptoAlgorithmECDSA.h: * crypto/algorithms/CryptoAlgorithmHKDF.cpp: * crypto/algorithms/CryptoAlgorithmHKDF.h: * crypto/algorithms/CryptoAlgorithmHMAC.cpp: * crypto/algorithms/CryptoAlgorithmHMAC.h: * crypto/algorithms/CryptoAlgorithmPBKDF2.cpp: * crypto/algorithms/CryptoAlgorithmPBKDF2.h: * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: * crypto/algorithms/CryptoAlgorithmRSA_OAEP.h: * crypto/algorithms/CryptoAlgorithmRSA_PSS.cpp: * crypto/algorithms/CryptoAlgorithmRSA_PSS.h: * crypto/algorithms/CryptoAlgorithmSHA1.cpp: * crypto/algorithms/CryptoAlgorithmSHA1.h: * crypto/algorithms/CryptoAlgorithmSHA224.cpp: * crypto/algorithms/CryptoAlgorithmSHA224.h: * crypto/algorithms/CryptoAlgorithmSHA256.cpp: * crypto/algorithms/CryptoAlgorithmSHA256.h: * crypto/algorithms/CryptoAlgorithmSHA384.cpp: * crypto/algorithms/CryptoAlgorithmSHA384.h: * crypto/algorithms/CryptoAlgorithmSHA512.cpp: * crypto/algorithms/CryptoAlgorithmSHA512.h: * crypto/gcrypt/CryptoAlgorithmAES_CBCGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmAES_CFBGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmAES_CTRGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmAES_GCMGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmAES_KWGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmECDHGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmECDSAGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmHKDFGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmHMACGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmPBKDF2GCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmRSAES_PKCS1_v1_5GCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmRSASSA_PKCS1_v1_5GCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmRSA_OAEPGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmRSA_PSSGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmRegistryGCrypt.cpp: * crypto/gcrypt/CryptoKeyECGCrypt.cpp: * crypto/gcrypt/CryptoKeyRSAGCrypt.cpp: * crypto/gcrypt/SerializedCryptoKeyWrapGCrypt.cpp: * crypto/keys/CryptoAesKeyAlgorithm.idl: * crypto/keys/CryptoEcKeyAlgorithm.idl: * crypto/keys/CryptoHmacKeyAlgorithm.idl: * crypto/keys/CryptoKeyAES.cpp: * crypto/keys/CryptoKeyAES.h: * crypto/keys/CryptoKeyAlgorithm.idl: * crypto/keys/CryptoKeyEC.cpp: * crypto/keys/CryptoKeyEC.h: * crypto/keys/CryptoKeyHMAC.cpp: * crypto/keys/CryptoKeyHMAC.h: * crypto/keys/CryptoKeyRSA.cpp: * crypto/keys/CryptoKeyRSA.h: * crypto/keys/CryptoKeyRSAComponents.cpp: * crypto/keys/CryptoKeyRSAComponents.h: * crypto/keys/CryptoKeyRaw.cpp: * crypto/keys/CryptoKeyRaw.h: * crypto/keys/CryptoRsaHashedKeyAlgorithm.idl: * crypto/keys/CryptoRsaKeyAlgorithm.idl: * crypto/mac/CommonCryptoDERUtilities.cpp: * crypto/mac/CommonCryptoDERUtilities.h: * crypto/mac/CryptoAlgorithmAES_CBCMac.cpp: * crypto/mac/CryptoAlgorithmAES_CFBMac.cpp: * crypto/mac/CryptoAlgorithmAES_CTRMac.cpp: * crypto/mac/CryptoAlgorithmAES_GCMMac.cpp: * crypto/mac/CryptoAlgorithmAES_KWMac.cpp: * crypto/mac/CryptoAlgorithmECDHMac.cpp: * crypto/mac/CryptoAlgorithmECDSAMac.cpp: * crypto/mac/CryptoAlgorithmHKDFMac.cpp: * crypto/mac/CryptoAlgorithmHMACMac.cpp: * crypto/mac/CryptoAlgorithmPBKDF2Mac.cpp: * crypto/mac/CryptoAlgorithmRSAES_PKCS1_v1_5Mac.cpp: * crypto/mac/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp: * crypto/mac/CryptoAlgorithmRSA_OAEPMac.cpp: * crypto/mac/CryptoAlgorithmRSA_PSSMac.cpp: * crypto/mac/CryptoAlgorithmRegistryMac.cpp: * crypto/mac/CryptoDigestAlgorithm.h: * crypto/mac/CryptoKeyECMac.cpp: * crypto/mac/CryptoKeyMac.cpp: * crypto/mac/CryptoKeyRSAMac.cpp: * crypto/mac/SerializedCryptoKeyWrapMac.mm: * crypto/parameters/AesCbcCfbParams.idl: * crypto/parameters/AesCtrParams.idl: * crypto/parameters/AesGcmParams.idl: * crypto/parameters/AesKeyParams.idl: * crypto/parameters/CryptoAlgorithmAesCbcCfbParams.h: * crypto/parameters/CryptoAlgorithmAesCtrParams.h: * crypto/parameters/CryptoAlgorithmAesGcmParams.h: * crypto/parameters/CryptoAlgorithmAesKeyParams.h: * crypto/parameters/CryptoAlgorithmEcKeyParams.h: * crypto/parameters/CryptoAlgorithmEcdhKeyDeriveParams.h: * crypto/parameters/CryptoAlgorithmEcdsaParams.h: * crypto/parameters/CryptoAlgorithmHkdfParams.h: * crypto/parameters/CryptoAlgorithmHmacKeyParams.h: * crypto/parameters/CryptoAlgorithmPbkdf2Params.h: * crypto/parameters/CryptoAlgorithmRsaHashedImportParams.h: * crypto/parameters/CryptoAlgorithmRsaHashedKeyGenParams.h: * crypto/parameters/CryptoAlgorithmRsaKeyGenParams.h: * crypto/parameters/CryptoAlgorithmRsaOaepParams.h: * crypto/parameters/CryptoAlgorithmRsaPssParams.h: * crypto/parameters/EcKeyParams.idl: * crypto/parameters/EcdhKeyDeriveParams.idl: * crypto/parameters/EcdsaParams.idl: * crypto/parameters/HkdfParams.idl: * crypto/parameters/HmacKeyParams.idl: * crypto/parameters/Pbkdf2Params.idl: * crypto/parameters/RsaHashedImportParams.idl: * crypto/parameters/RsaHashedKeyGenParams.idl: * crypto/parameters/RsaKeyGenParams.idl: * crypto/parameters/RsaOaepParams.idl: * crypto/parameters/RsaPssParams.idl: * dom/Document.cpp: * dom/Document.h: * dom/ScriptExecutionContext.h: * page/ChromeClient.h: * page/Crypto.cpp: (WebCore::Crypto::Crypto): * page/Crypto.h: * page/Crypto.idl: * platform/GCrypt.cmake: * platform/LocalizedStrings.cpp: * platform/LocalizedStrings.h: * workers/WorkerGlobalScope.cpp: * workers/WorkerGlobalScope.h: * worklets/WorkletGlobalScope.h: Source/WebCore/PAL: * Configurations/FeatureDefines.xcconfig: * pal/PlatformGTK.cmake: * pal/PlatformWPE.cmake: Source/WebKit: * Configurations/FeatureDefines.xcconfig: * UIProcess/API/C/WKPage.cpp: (WKPageSetPageNavigationClient): * UIProcess/WebPageProxy.cpp: * UIProcess/WebPageProxy.h: * UIProcess/WebPageProxy.messages.in: * WebProcess/WebCoreSupport/WebChromeClient.cpp: * WebProcess/WebCoreSupport/WebChromeClient.h: Source/WebKitLegacy/mac: * Configurations/FeatureDefines.xcconfig: * WebCoreSupport/WebChromeClient.h: * WebCoreSupport/WebChromeClient.mm: Tools: * Scripts/webkitperl/FeatureList.pm: * TestWebKitAPI/Configurations/FeatureDefines.xcconfig: Canonical link: https://commits.webkit.org/206898@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@238754 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2018-11-30 22:23:17 +00:00
#if ENABLE(WEB_CRYPTO)
Update SubtleCrypto::generateKey to match the latest spec https://bugs.webkit.org/show_bug.cgi?id=163718 <rdar://problem/28864380> Reviewed by Chris Dumez. LayoutTests/imported/w3c: * WebCryptoAPI/generateKey/test_aes-cbc-expected.txt: * WebCryptoAPI/generateKey/test_aes-cbc.html: * WebCryptoAPI/generateKey/test_aes-ctr-expected.txt: * WebCryptoAPI/generateKey/test_aes-ctr.html: * WebCryptoAPI/generateKey/test_failures-expected.txt: * WebCryptoAPI/generateKey/test_failures.html: * WebCryptoAPI/generateKey/test_failures_AES-CBC-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-CBC.html: * WebCryptoAPI/generateKey/test_failures_AES-CTR-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-CTR.html: * WebCryptoAPI/generateKey/test_failures_AES-GCM-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-GCM.html: * WebCryptoAPI/generateKey/test_failures_AES-KW-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-KW.html: * WebCryptoAPI/generateKey/test_failures_ECDH-expected.txt: * WebCryptoAPI/generateKey/test_failures_ECDH.html: * WebCryptoAPI/generateKey/test_failures_ECDSA-expected.txt: * WebCryptoAPI/generateKey/test_failures_ECDSA.html: * WebCryptoAPI/generateKey/test_failures_HMAC-expected.txt: * WebCryptoAPI/generateKey/test_failures_HMAC.html: * WebCryptoAPI/generateKey/test_failures_RSA-OAEP-expected.txt: * WebCryptoAPI/generateKey/test_failures_RSA-OAEP.html: * WebCryptoAPI/generateKey/test_failures_RSA-PSS-expected.txt: * WebCryptoAPI/generateKey/test_failures_RSA-PSS.html: * WebCryptoAPI/generateKey/test_failures_RSASSA-PKCS1-v1_5-expected.txt: * WebCryptoAPI/generateKey/test_failures_RSASSA-PKCS1-v1_5.html: * WebCryptoAPI/generateKey/test_successes-expected.txt: * WebCryptoAPI/generateKey/test_successes.html: * WebCryptoAPI/generateKey/test_successes_AES-CBC-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-CBC.html: * WebCryptoAPI/generateKey/test_successes_AES-CTR-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-CTR.html: * WebCryptoAPI/generateKey/test_successes_AES-GCM-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-GCM.html: * WebCryptoAPI/generateKey/test_successes_AES-KW-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-KW.html: * WebCryptoAPI/generateKey/test_successes_ECDH-expected.txt: * WebCryptoAPI/generateKey/test_successes_ECDH.html: * WebCryptoAPI/generateKey/test_successes_ECDSA-expected.txt: * WebCryptoAPI/generateKey/test_successes_ECDSA.html: * WebCryptoAPI/generateKey/test_successes_HMAC-expected.txt: * WebCryptoAPI/generateKey/test_successes_HMAC.html: * WebCryptoAPI/generateKey/test_successes_RSA-OAEP-expected.txt: * WebCryptoAPI/generateKey/test_successes_RSA-OAEP.html: * WebCryptoAPI/generateKey/test_successes_RSA-PSS-expected.txt: * WebCryptoAPI/generateKey/test_successes_RSA-PSS.html: * WebCryptoAPI/generateKey/test_successes_RSASSA-PKCS1-v1_5-expected.txt: * WebCryptoAPI/generateKey/test_successes_RSASSA-PKCS1-v1_5.html: * WebCryptoAPI/idlharness-expected.txt: Source/WebCore: This patch does following few things: 1. It updates the SubtleCrypto::generateKey method to match the latest spec: https://www.w3.org/TR/WebCryptoAPI/#SubtleCrypto-method-generateKey. It also refers to the latest Editor's Draft at a certain degree: https://w3c.github.io/webcrypto/Overview.html#SubtleCrypto-method-generateKey. 2. It implements generateKey operations of following algorithms: AES-CBC, AES-KW, HMAC, RSAES-PKCS1-V1_5, RSASSA-PKCS1-V1_5, and RSA-OAEP. 3. It replaces SPECIALIZE_TYPE_TRAITS_CRYPTO_ALGORITHM_PARAMETERS with SPECIALIZE_TYPE_TRAITS_CRYPTO_ALGORITHM_PARAMETERS_DEPRECATED for deprecated params. 4. It fixes https://bugs.webkit.org/show_bug.cgi?id=129750 as well. Tests: crypto/subtle/aes-cbc-generate-key-length-128.html crypto/subtle/aes-cbc-generate-key-length-192.html crypto/subtle/aes-cbc-generate-key-length-256.html crypto/subtle/aes-generate-key-malformed-parameters.html crypto/subtle/aes-kw-generate-key.html crypto/subtle/generate-key-malformed-paramters.html crypto/subtle/hmac-generate-key-customized-length.html crypto/subtle/hmac-generate-key-hash-object.html crypto/subtle/hmac-generate-key-malformed-parameters.html crypto/subtle/hmac-generate-key-sha1.html crypto/subtle/hmac-generate-key-sha224.html crypto/subtle/hmac-generate-key-sha256.html crypto/subtle/hmac-generate-key-sha384.html crypto/subtle/hmac-generate-key-sha512.html crypto/subtle/rsa-generate-key-malformed-parameters.html crypto/subtle/rsa-oaep-generate-key.html crypto/subtle/rsaes-pkcs1-v1_5-generate-key-extractable.html crypto/subtle/rsaes-pkcs1-v1_5-generate-key.html crypto/subtle/rsassa-pkcs1-v1_5-generate-key.html crypto/webkitSubtle/hmac-generate-key.html: crypto/workers/subtle/aes-generate-key.html crypto/workers/subtle/hmac-generate-key.html crypto/workers/subtle/rsa-generate-key.html * CMakeLists.txt: * DerivedSources.make: * Modules/encryptedmedia/CDMSessionClearKey.cpp: * WebCore.xcodeproj/project.pbxproj: * bindings/js/JSSubtleCryptoCustom.cpp: Added. (WebCore::toHashIdentifier): (WebCore::normalizeCryptoAlgorithmParameters): (WebCore::cryptoKeyUsagesFromJSValue): (WebCore::createAlgorithm): (WebCore::rejectWithException): (WebCore::jsSubtleCryptoFunctionGenerateKeyPromise): (WebCore::JSSubtleCrypto::generateKey): * bindings/js/JSWebKitSubtleCryptoCustom.cpp: (WebCore::JSWebKitSubtleCrypto::generateKey): * crypto/CryptoAlgorithm.cpp: (WebCore::CryptoAlgorithm::generateKey): * crypto/CryptoAlgorithm.h: * crypto/CryptoAlgorithmParameters.h: Added. (WebCore::CryptoAlgorithmParameters::CryptoAlgorithmParameters): (WebCore::CryptoAlgorithmParameters::~CryptoAlgorithmParameters): (WebCore::CryptoAlgorithmParameters::parametersClass): * crypto/CryptoAlgorithmParameters.idl: Added. * crypto/CryptoAlgorithmParametersDeprecated.h: * crypto/CryptoKey.cpp: (WebCore::CryptoKey::setUsagesBitmap): * crypto/CryptoKey.h: * crypto/CryptoKeyPair.idl: * crypto/SubtleCrypto.idl: * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: (WebCore::CryptoAlgorithmAES_CBC::generateKey): * crypto/algorithms/CryptoAlgorithmAES_CBC.h: * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: (WebCore::CryptoAlgorithmAES_KW::generateKey): * crypto/algorithms/CryptoAlgorithmAES_KW.h: * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::generateKey): * crypto/algorithms/CryptoAlgorithmHMAC.h: * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::generateKey): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::generateKey): * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: (WebCore::CryptoAlgorithmRSA_OAEP::generateKey): * crypto/algorithms/CryptoAlgorithmRSA_OAEP.h: * crypto/gnutls/CryptoKeyRSAGnuTLS.cpp: (WebCore::CryptoKeyRSA::generatePair): * crypto/keys/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::generate): * crypto/keys/CryptoKeyHMAC.cpp: (WebCore::CryptoKeyHMAC::generate): * crypto/keys/CryptoKeyRSA.h: * crypto/mac/CryptoKeyRSAMac.cpp: (WebCore::CryptoKeyRSA::generatePair): * crypto/parameters/AesKeyGenParams.idl: Added. * crypto/parameters/CryptoAlgorithmAesCbcParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmAesKeyGenParams.h: Added. * crypto/parameters/CryptoAlgorithmAesKeyGenParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmHmacKeyGenParams.h: Added. * crypto/parameters/CryptoAlgorithmHmacKeyParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmHmacParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaHashedKeyGenParams.h: Added. * crypto/parameters/CryptoAlgorithmRsaKeyGenParams.h: Added. (WebCore::CryptoAlgorithmRsaKeyGenParams::arrayToVector): * crypto/parameters/CryptoAlgorithmRsaKeyGenParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaKeyParamsWithHashDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaOaepParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaSsaParamsDeprecated.h: * crypto/parameters/HmacKeyGenParams.idl: Added. * crypto/parameters/RsaHashedKeyGenParams.idl: Added. * crypto/parameters/RsaKeyGenParams.idl: Added. LayoutTests: Besides adding tests for SubtleCrypto::generateKey related stuff and fixing HMAC. This patch also add shouldReject(_a, _rejectCallback, _resolveCallback, _message) in js-test-pre.js. * TestExpectations: * crypto/subtle/aes-cbc-generate-key-length-128-expected.txt: Added. * crypto/subtle/aes-cbc-generate-key-length-128.html: Added. * crypto/subtle/aes-cbc-generate-key-length-192-expected.txt: Added. * crypto/subtle/aes-cbc-generate-key-length-192.html: Added. * crypto/subtle/aes-cbc-generate-key-length-256-expected.txt: Added. * crypto/subtle/aes-cbc-generate-key-length-256.html: Added. * crypto/subtle/aes-generate-key-malformed-parameters-expected.txt: Added. * crypto/subtle/aes-generate-key-malformed-parameters.html: Added. * crypto/subtle/aes-kw-generate-key-expected.txt: Added. * crypto/subtle/aes-kw-generate-key.html: Added. * crypto/subtle/generate-key-malformed-paramters-expected.txt: Added. * crypto/subtle/generate-key-malformed-paramters.html: Added. * crypto/subtle/hmac-generate-key-customized-length-expected.txt: Added. * crypto/subtle/hmac-generate-key-customized-length.html: Added. * crypto/subtle/hmac-generate-key-hash-object-expected.txt: Added. * crypto/subtle/hmac-generate-key-hash-object.html: Added. * crypto/subtle/hmac-generate-key-malformed-parameters-expected.txt: Added. * crypto/subtle/hmac-generate-key-malformed-parameters.html: Added. * crypto/subtle/hmac-generate-key-sha1-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha1.html: Added. * crypto/subtle/hmac-generate-key-sha224-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha224.html: Added. * crypto/subtle/hmac-generate-key-sha256-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha256.html: Added. * crypto/subtle/hmac-generate-key-sha384-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha384.html: Added. * crypto/subtle/hmac-generate-key-sha512-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha512.html: Added. * crypto/subtle/rsa-generate-key-malformed-parameters-expected.txt: Added. * crypto/subtle/rsa-generate-key-malformed-parameters.html: Added. * crypto/subtle/rsa-oaep-generate-key-expected.txt: Added. * crypto/subtle/rsa-oaep-generate-key.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key-extractable-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key-extractable.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-generate-key-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-generate-key.html: Added. * crypto/webkitSubtle/hmac-generate-key-expected.txt: * crypto/webkitSubtle/hmac-generate-key.html: * crypto/workers/subtle/aes-generate-key-expected.txt: Added. * crypto/workers/subtle/aes-generate-key.html: Added. * crypto/workers/subtle/hmac-generate-key-expected.txt: Added. * crypto/workers/subtle/hmac-generate-key.html: Added. * crypto/workers/subtle/resources/aes-generate-key.js: Added. * crypto/workers/subtle/resources/hmac-generate-key.js: Added. * crypto/workers/subtle/resources/rsa-generate-key.js: Added. * crypto/workers/subtle/rsa-generate-key-expected.txt: Added. * crypto/workers/subtle/rsa-generate-key.html: Added. * resources/js-test-pre.js: Canonical link: https://commits.webkit.org/181666@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@207809 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-10-25 06:07:04 +00:00
namespace WebCore {
Update SubtleCrypto::importKey to match the latest spec https://bugs.webkit.org/show_bug.cgi?id=164446 <rdar://problem/29123621> Reviewed by Brent Fulgham. LayoutTests/imported/w3c: * WebCryptoAPI/idlharness-expected.txt: Source/WebCore: This patch does following few things: 1. It updates the SubtleCrypto::importKey method to match the latest spec: https://www.w3.org/TR/WebCryptoAPI/#SubtleCrypto-method-importKey. It also refers to the latest Editor's Draft at a certain degree: https://w3c.github.io/webcrypto/Overview.html#SubtleCrypto-method-importKey. 2. It implements importKey operations of following algorithms: AES-CBC, AES-KW, HMAC, RSAES-PKCS1-V1_5, RSASSA-PKCS1-V1_5, and RSA-OAEP. 3. It fixes some minor problems of SubtleCrypto::generateKey. 4. It addes move constructors for CryptoKeyAES, CryptoKeyHMAC, CryptoKeyRSA and CryptoKeyDataRSAComponents. 5. It renames HmacKeyGenParams to HmacKeyParams to serve the purpose of both HmacKeyGenParams and HmacImportParams which are essentially the same. 6. It enforces the key length in bits of CryptoKeyHMAC to be multiples of 8. 7. It also fixes the following bugs: https://bugs.webkit.org/show_bug.cgi?id=126033, https://bugs.webkit.org/show_bug.cgi?id=126034, https://bugs.webkit.org/show_bug.cgi?id=151308. P.S. We currently only support Raw and Jwk key format. Tests: crypto/subtle/aes-cbc-import-jwk-key-length-128.html crypto/subtle/aes-cbc-import-jwk-key-length-192.html crypto/subtle/aes-cbc-import-jwk-key-length-256.html crypto/subtle/aes-cbc-import-jwk-key-minimum.html crypto/subtle/aes-cbc-import-jwk-key-non-extractable.html crypto/subtle/aes-cbc-import-raw-key-length-128.html crypto/subtle/aes-cbc-import-raw-key-length-192.html crypto/subtle/aes-cbc-import-raw-key-length-256.html crypto/subtle/aes-import-key-malformed-parameters.html crypto/subtle/aes-kw-import-jwk-key-length-128.html crypto/subtle/aes-kw-import-jwk-key-length-192.html crypto/subtle/aes-kw-import-jwk-key-length-256.html crypto/subtle/aes-kw-import-raw-key.html crypto/subtle/generate-key-malformed-parameters.html crypto/subtle/hmac-import-jwk-key-minimum.html crypto/subtle/hmac-import-jwk-key-non-extractable.html crypto/subtle/hmac-import-jwk-key-sha1.html crypto/subtle/hmac-import-jwk-key-sha224.html crypto/subtle/hmac-import-jwk-key-sha256.html crypto/subtle/hmac-import-jwk-key-sha384.html crypto/subtle/hmac-import-jwk-key-sha512.html crypto/subtle/hmac-import-malformed-parameters.html crypto/subtle/hmac-import-raw-key-customized-length.html crypto/subtle/hmac-import-raw-key.html crypto/subtle/import-key-malformed-parameters.html crypto/subtle/rsa-import-key-malformed-parameters.html crypto/subtle/rsa-oaep-import-jwk-private-key.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha1.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha224.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha256.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha384.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha512.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-private-key.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-leading-zero.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-minimum.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-non-extractable.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-private-key.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha1.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha224.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha256.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha384.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha512.html crypto/workers/subtle/aes-import-jwk-key.html crypto/workers/subtle/aes-import-raw-key.html crypto/workers/subtle/hmac-import-jwk-key.html crypto/workers/subtle/hmac-import-raw-key.html crypto/workers/subtle/rsa-import-jwk-private-key.html crypto/workers/subtle/rsa-import-jwk-public-key.html * CMakeLists.txt: * DerivedSources.make: * PlatformEfl.cmake: * PlatformGTK.cmake: * PlatformMac.cmake: * WebCore.xcodeproj/project.pbxproj: * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::normalizeCryptoAlgorithmParameters): (WebCore::cryptoKeyUsageFromString): (WebCore::cryptoKeyUsagesFromJSValue): (WebCore::toKeyData): (WebCore::jsSubtleCryptoFunctionGenerateKeyPromise): (WebCore::jsSubtleCryptoFunctionImportKeyPromise): (WebCore::JSSubtleCrypto::importKey): * crypto/CryptoAlgorithm.cpp: (WebCore::CryptoAlgorithm::importKey): * crypto/CryptoAlgorithm.h: * crypto/CryptoAlgorithmParameters.h: * crypto/JsonWebKey.h: Added. * crypto/JsonWebKey.idl: Added. * crypto/RsaOtherPrimesInfo.h: Added. * crypto/RsaOtherPrimesInfo.idl: Added. * crypto/SubtleCrypto.h: * crypto/SubtleCrypto.idl: * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: (WebCore::CryptoAlgorithmAES_CBC::generateKey): (WebCore::CryptoAlgorithmAES_CBC::importKey): * crypto/algorithms/CryptoAlgorithmAES_CBC.h: * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: (WebCore::CryptoAlgorithmAES_KW::generateKey): (WebCore::CryptoAlgorithmAES_KW::importKey): * crypto/algorithms/CryptoAlgorithmAES_KW.h: * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::generateKey): (WebCore::CryptoAlgorithmHMAC::importKey): * crypto/algorithms/CryptoAlgorithmHMAC.h: * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: (WebCore::CryptoAlgorithmRSA_OAEP::importKey): * crypto/algorithms/CryptoAlgorithmRSA_OAEP.h: * crypto/keys/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::CryptoKeyAES): (WebCore::CryptoKeyAES::generate): (WebCore::CryptoKeyAES::importRaw): (WebCore::CryptoKeyAES::importJwk): * crypto/keys/CryptoKeyAES.h: * crypto/keys/CryptoKeyDataRSAComponents.cpp: (WebCore::CryptoKeyDataRSAComponents::CryptoKeyDataRSAComponents): * crypto/keys/CryptoKeyDataRSAComponents.h: * crypto/keys/CryptoKeyHMAC.cpp: (WebCore::CryptoKeyHMAC::CryptoKeyHMAC): (WebCore::CryptoKeyHMAC::generate): (WebCore::CryptoKeyHMAC::importRaw): (WebCore::CryptoKeyHMAC::importJwk): (WebCore::CryptoKeyHMAC::buildAlgorithm): * crypto/keys/CryptoKeyHMAC.h: * crypto/keys/CryptoKeyRSA.cpp: Added. (WebCore::CryptoKeyRSA::importJwk): * crypto/keys/CryptoKeyRSA.h: * crypto/parameters/CryptoAlgorithmHmacKeyParams.h: Renamed from Source/WebCore/crypto/parameters/CryptoAlgorithmHmacKeyGenParams.h. * crypto/parameters/CryptoAlgorithmRsaHashedImportParams.h: Added. * crypto/parameters/HmacKeyParams.idl: Renamed from Source/WebCore/crypto/parameters/HmacKeyGenParams.idl. * crypto/parameters/RsaHashedImportParams.idl: Added. LayoutTests: Besides adding test cases for SubtleCrypto::importKey. This patch also corrects a typo: generate-key-malformed-paramters*. * crypto/subtle/aes-cbc-import-jwk-key-length-128-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-128.html: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-192-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-192.html: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-256-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-256.html: Added. * crypto/subtle/aes-cbc-import-jwk-key-minimum-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-minimum.html: Added. * crypto/subtle/aes-cbc-import-jwk-key-non-extractable-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-non-extractable.html: Added. * crypto/subtle/aes-cbc-import-raw-key-length-128-expected.txt: Added. * crypto/subtle/aes-cbc-import-raw-key-length-128.html: Added. * crypto/subtle/aes-cbc-import-raw-key-length-192-expected.txt: Added. * crypto/subtle/aes-cbc-import-raw-key-length-192.html: Added. * crypto/subtle/aes-cbc-import-raw-key-length-256-expected.txt: Added. * crypto/subtle/aes-cbc-import-raw-key-length-256.html: Added. * crypto/subtle/aes-import-key-malformed-parameters-expected.txt: Added. * crypto/subtle/aes-import-key-malformed-parameters.html: Added. * crypto/subtle/aes-kw-import-jwk-key-length-128-expected.txt: Added. * crypto/subtle/aes-kw-import-jwk-key-length-128.html: Added. * crypto/subtle/aes-kw-import-jwk-key-length-192-expected.txt: Added. * crypto/subtle/aes-kw-import-jwk-key-length-192.html: Added. * crypto/subtle/aes-kw-import-jwk-key-length-256-expected.txt: Added. * crypto/subtle/aes-kw-import-jwk-key-length-256.html: Added. * crypto/subtle/aes-kw-import-raw-key-expected.txt: Added. * crypto/subtle/aes-kw-import-raw-key.html: Added. * crypto/subtle/generate-key-malformed-parameters-expected.txt: Renamed from LayoutTests/crypto/subtle/generate-key-malformed-paramters-expected.txt. * crypto/subtle/generate-key-malformed-parameters.html: Renamed from LayoutTests/crypto/subtle/generate-key-malformed-paramters.html. * crypto/subtle/hmac-generate-key-customized-length-expected.txt: * crypto/subtle/hmac-generate-key-customized-length.html: * crypto/subtle/hmac-generate-key-malformed-parameters-expected.txt: * crypto/subtle/hmac-generate-key-malformed-parameters.html: * crypto/subtle/hmac-import-raw-key-customized-length-expected.txt: * crypto/subtle/hmac-import-raw-key-customized-length.html: * crypto/subtle/hmac-import-jwk-key-minimum-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-minimum.html: Added. * crypto/subtle/hmac-import-jwk-key-non-extractable-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-non-extractable.html: Added. * crypto/subtle/hmac-import-jwk-key-sha1-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha1.html: Added. * crypto/subtle/hmac-import-jwk-key-sha224-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha224.html: Added. * crypto/subtle/hmac-import-jwk-key-sha256-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha256.html: Added. * crypto/subtle/hmac-import-jwk-key-sha384-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha384.html: Added. * crypto/subtle/hmac-import-jwk-key-sha512-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha512.html: Added. * crypto/subtle/hmac-import-malformed-parameters-expected.txt: Added. * crypto/subtle/hmac-import-malformed-parameters.html: Added. * crypto/subtle/hmac-import-raw-key-customized-length-expected.txt: Added. * crypto/subtle/hmac-import-raw-key-customized-length.html: Added. * crypto/subtle/hmac-import-raw-key-expected.txt: Added. * crypto/subtle/hmac-import-raw-key.html: Added. * crypto/subtle/import-key-malformed-parameters-expected.txt: Added. * crypto/subtle/import-key-malformed-parameters.html: Added. * crypto/subtle/rsa-import-key-malformed-parameters-expected.txt: Added. * crypto/subtle/rsa-import-key-malformed-parameters.html: Added. * crypto/subtle/rsa-oaep-import-jwk-private-key-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-private-key.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha1-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha1.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha224-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha224.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha256-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha256.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha384-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha384.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha512-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha512.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-private-key-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-private-key.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-leading-zero-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-leading-zero.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-minimum-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-minimum.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-non-extractable-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-non-extractable.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-private-key-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-private-key.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha1-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha1.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha224-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha224.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha256-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha256.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha384-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha384.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha512-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha512.html: Added. * crypto/webkitSubtle/hmac-generate-key-expected.txt: * crypto/webkitSubtle/hmac-generate-key.html: * crypto/webkitSubtle/hmac-import-jwk-expected.txt: * crypto/webkitSubtle/hmac-import-jwk.html: * crypto/webkitSubtle/hmac-postMessage-expected.txt: * crypto/webkitSubtle/hmac-postMessage.html: * crypto/webkitSubtle/hmac-sign-verify-expected.txt: * crypto/webkitSubtle/hmac-sign-verify.html: * crypto/workers/subtle/aes-import-jwk-key-expected.txt: Added. * crypto/workers/subtle/aes-import-jwk-key.html: Added. * crypto/workers/subtle/aes-import-raw-key-expected.txt: Added. * crypto/workers/subtle/aes-import-raw-key.html: Added. * crypto/workers/subtle/hmac-import-jwk-key-expected.txt: Added. * crypto/workers/subtle/hmac-import-jwk-key.html: Added. * crypto/workers/subtle/hmac-import-raw-key-expected.txt: Added. * crypto/workers/subtle/hmac-import-raw-key.html: Added. * crypto/workers/subtle/hmac-postMessage-worker-expected.txt: * crypto/workers/subtle/hmac-postMessage-worker.html: * crypto/workers/subtle/resources/aes-import-jwk-key.js: Added. * crypto/workers/subtle/resources/aes-import-raw-key.js: Added. * crypto/workers/subtle/resources/hmac-import-jwk-key.js: Added. * crypto/workers/subtle/resources/hmac-import-raw-key.js: Added. * crypto/workers/subtle/resources/hmac-postMessage-worker.js: * crypto/workers/subtle/resources/rsa-import-jwk-private-key.js: Added. * crypto/workers/subtle/resources/rsa-import-jwk-public-key.js: Added. * crypto/workers/subtle/rsa-import-jwk-private-key-expected.txt: Added. * crypto/workers/subtle/rsa-import-jwk-private-key.html: Added. * crypto/workers/subtle/rsa-import-jwk-public-key-expected.txt: Added. * crypto/workers/subtle/rsa-import-jwk-public-key.html: Added. Canonical link: https://commits.webkit.org/182271@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@208548 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-11-10 18:36:44 +00:00
struct JsonWebKey {
String kty;
[WebCrypto] remove toJSValueFromJsonWebKey from custom SubtleCrypto binding codes https://bugs.webkit.org/show_bug.cgi?id=167026 Reviewed by Chris Dumez. Source/WebCore: Covered by existing tests. * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::jsSubtleCryptoFunctionExportKeyPromise): (WebCore::jsSubtleCryptoFunctionWrapKeyPromise): (WebCore::toJSValueFromJsonWebKey): Deleted. * crypto/JsonWebKey.h: * crypto/JsonWebKey.idl: * crypto/RsaOtherPrimesInfo.idl: Change std::optional<String> to String in order to use toJS<IDLDictionary<JsonWebKey>>. * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: (WebCore::CryptoAlgorithmAES_CBC::importKey): * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: (WebCore::CryptoAlgorithmAES_KW::importKey): * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::importKey): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: (WebCore::CryptoAlgorithmRSA_OAEP::importKey): * crypto/keys/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::importJwk): Only check if key_ops contains all of the specified usages when key_ops field of jwk is present, as per the specification: https://www.w3.org/TR/WebCryptoAPI/#aes-cbc-operations * crypto/keys/CryptoKeyAES.h: * crypto/keys/CryptoKeyHMAC.cpp: (WebCore::CryptoKeyHMAC::importJwk): * crypto/keys/CryptoKeyHMAC.h: * crypto/keys/CryptoKeyRSA.cpp: (WebCore::CryptoKeyRSA::importJwk): Accommodate the change from std::optional<String> to String. * crypto/mac/CryptoKeyRSAMac.cpp: (WebCore::CryptoKeyRSA::create): Add a null check for p. LayoutTests: * crypto/subtle/aes-cbc-import-key-wrap-jwk-rsa-key-private.html: * crypto/subtle/aes-cbc-import-key-wrap-jwk-rsa-key-public.html: Order of attributes inside JWK is different after this patch. * crypto/subtle/aes-import-key-malformed-parameters-expected.txt: * crypto/subtle/aes-import-key-malformed-parameters.html: * crypto/subtle/hmac-import-key-malformed-parameters-expected.txt: * crypto/subtle/hmac-import-key-malformed-parameters.html: * crypto/subtle/rsa-import-key-malformed-parameters-expected.txt: * crypto/subtle/rsa-import-key-malformed-parameters.html: * crypto/workers/subtle/resources/aes-cbc-import-key-wrap-key.js: Canonical link: https://commits.webkit.org/185480@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@212465 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2017-02-16 22:31:14 +00:00
String use;
Update SubtleCrypto::importKey to match the latest spec https://bugs.webkit.org/show_bug.cgi?id=164446 <rdar://problem/29123621> Reviewed by Brent Fulgham. LayoutTests/imported/w3c: * WebCryptoAPI/idlharness-expected.txt: Source/WebCore: This patch does following few things: 1. It updates the SubtleCrypto::importKey method to match the latest spec: https://www.w3.org/TR/WebCryptoAPI/#SubtleCrypto-method-importKey. It also refers to the latest Editor's Draft at a certain degree: https://w3c.github.io/webcrypto/Overview.html#SubtleCrypto-method-importKey. 2. It implements importKey operations of following algorithms: AES-CBC, AES-KW, HMAC, RSAES-PKCS1-V1_5, RSASSA-PKCS1-V1_5, and RSA-OAEP. 3. It fixes some minor problems of SubtleCrypto::generateKey. 4. It addes move constructors for CryptoKeyAES, CryptoKeyHMAC, CryptoKeyRSA and CryptoKeyDataRSAComponents. 5. It renames HmacKeyGenParams to HmacKeyParams to serve the purpose of both HmacKeyGenParams and HmacImportParams which are essentially the same. 6. It enforces the key length in bits of CryptoKeyHMAC to be multiples of 8. 7. It also fixes the following bugs: https://bugs.webkit.org/show_bug.cgi?id=126033, https://bugs.webkit.org/show_bug.cgi?id=126034, https://bugs.webkit.org/show_bug.cgi?id=151308. P.S. We currently only support Raw and Jwk key format. Tests: crypto/subtle/aes-cbc-import-jwk-key-length-128.html crypto/subtle/aes-cbc-import-jwk-key-length-192.html crypto/subtle/aes-cbc-import-jwk-key-length-256.html crypto/subtle/aes-cbc-import-jwk-key-minimum.html crypto/subtle/aes-cbc-import-jwk-key-non-extractable.html crypto/subtle/aes-cbc-import-raw-key-length-128.html crypto/subtle/aes-cbc-import-raw-key-length-192.html crypto/subtle/aes-cbc-import-raw-key-length-256.html crypto/subtle/aes-import-key-malformed-parameters.html crypto/subtle/aes-kw-import-jwk-key-length-128.html crypto/subtle/aes-kw-import-jwk-key-length-192.html crypto/subtle/aes-kw-import-jwk-key-length-256.html crypto/subtle/aes-kw-import-raw-key.html crypto/subtle/generate-key-malformed-parameters.html crypto/subtle/hmac-import-jwk-key-minimum.html crypto/subtle/hmac-import-jwk-key-non-extractable.html crypto/subtle/hmac-import-jwk-key-sha1.html crypto/subtle/hmac-import-jwk-key-sha224.html crypto/subtle/hmac-import-jwk-key-sha256.html crypto/subtle/hmac-import-jwk-key-sha384.html crypto/subtle/hmac-import-jwk-key-sha512.html crypto/subtle/hmac-import-malformed-parameters.html crypto/subtle/hmac-import-raw-key-customized-length.html crypto/subtle/hmac-import-raw-key.html crypto/subtle/import-key-malformed-parameters.html crypto/subtle/rsa-import-key-malformed-parameters.html crypto/subtle/rsa-oaep-import-jwk-private-key.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha1.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha224.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha256.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha384.html crypto/subtle/rsa-oaep-import-jwk-public-key-sha512.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-private-key.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-leading-zero.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-minimum.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-non-extractable.html crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-private-key.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha1.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha224.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha256.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha384.html crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha512.html crypto/workers/subtle/aes-import-jwk-key.html crypto/workers/subtle/aes-import-raw-key.html crypto/workers/subtle/hmac-import-jwk-key.html crypto/workers/subtle/hmac-import-raw-key.html crypto/workers/subtle/rsa-import-jwk-private-key.html crypto/workers/subtle/rsa-import-jwk-public-key.html * CMakeLists.txt: * DerivedSources.make: * PlatformEfl.cmake: * PlatformGTK.cmake: * PlatformMac.cmake: * WebCore.xcodeproj/project.pbxproj: * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::normalizeCryptoAlgorithmParameters): (WebCore::cryptoKeyUsageFromString): (WebCore::cryptoKeyUsagesFromJSValue): (WebCore::toKeyData): (WebCore::jsSubtleCryptoFunctionGenerateKeyPromise): (WebCore::jsSubtleCryptoFunctionImportKeyPromise): (WebCore::JSSubtleCrypto::importKey): * crypto/CryptoAlgorithm.cpp: (WebCore::CryptoAlgorithm::importKey): * crypto/CryptoAlgorithm.h: * crypto/CryptoAlgorithmParameters.h: * crypto/JsonWebKey.h: Added. * crypto/JsonWebKey.idl: Added. * crypto/RsaOtherPrimesInfo.h: Added. * crypto/RsaOtherPrimesInfo.idl: Added. * crypto/SubtleCrypto.h: * crypto/SubtleCrypto.idl: * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: (WebCore::CryptoAlgorithmAES_CBC::generateKey): (WebCore::CryptoAlgorithmAES_CBC::importKey): * crypto/algorithms/CryptoAlgorithmAES_CBC.h: * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: (WebCore::CryptoAlgorithmAES_KW::generateKey): (WebCore::CryptoAlgorithmAES_KW::importKey): * crypto/algorithms/CryptoAlgorithmAES_KW.h: * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::generateKey): (WebCore::CryptoAlgorithmHMAC::importKey): * crypto/algorithms/CryptoAlgorithmHMAC.h: * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: (WebCore::CryptoAlgorithmRSA_OAEP::importKey): * crypto/algorithms/CryptoAlgorithmRSA_OAEP.h: * crypto/keys/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::CryptoKeyAES): (WebCore::CryptoKeyAES::generate): (WebCore::CryptoKeyAES::importRaw): (WebCore::CryptoKeyAES::importJwk): * crypto/keys/CryptoKeyAES.h: * crypto/keys/CryptoKeyDataRSAComponents.cpp: (WebCore::CryptoKeyDataRSAComponents::CryptoKeyDataRSAComponents): * crypto/keys/CryptoKeyDataRSAComponents.h: * crypto/keys/CryptoKeyHMAC.cpp: (WebCore::CryptoKeyHMAC::CryptoKeyHMAC): (WebCore::CryptoKeyHMAC::generate): (WebCore::CryptoKeyHMAC::importRaw): (WebCore::CryptoKeyHMAC::importJwk): (WebCore::CryptoKeyHMAC::buildAlgorithm): * crypto/keys/CryptoKeyHMAC.h: * crypto/keys/CryptoKeyRSA.cpp: Added. (WebCore::CryptoKeyRSA::importJwk): * crypto/keys/CryptoKeyRSA.h: * crypto/parameters/CryptoAlgorithmHmacKeyParams.h: Renamed from Source/WebCore/crypto/parameters/CryptoAlgorithmHmacKeyGenParams.h. * crypto/parameters/CryptoAlgorithmRsaHashedImportParams.h: Added. * crypto/parameters/HmacKeyParams.idl: Renamed from Source/WebCore/crypto/parameters/HmacKeyGenParams.idl. * crypto/parameters/RsaHashedImportParams.idl: Added. LayoutTests: Besides adding test cases for SubtleCrypto::importKey. This patch also corrects a typo: generate-key-malformed-paramters*. * crypto/subtle/aes-cbc-import-jwk-key-length-128-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-128.html: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-192-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-192.html: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-256-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-length-256.html: Added. * crypto/subtle/aes-cbc-import-jwk-key-minimum-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-minimum.html: Added. * crypto/subtle/aes-cbc-import-jwk-key-non-extractable-expected.txt: Added. * crypto/subtle/aes-cbc-import-jwk-key-non-extractable.html: Added. * crypto/subtle/aes-cbc-import-raw-key-length-128-expected.txt: Added. * crypto/subtle/aes-cbc-import-raw-key-length-128.html: Added. * crypto/subtle/aes-cbc-import-raw-key-length-192-expected.txt: Added. * crypto/subtle/aes-cbc-import-raw-key-length-192.html: Added. * crypto/subtle/aes-cbc-import-raw-key-length-256-expected.txt: Added. * crypto/subtle/aes-cbc-import-raw-key-length-256.html: Added. * crypto/subtle/aes-import-key-malformed-parameters-expected.txt: Added. * crypto/subtle/aes-import-key-malformed-parameters.html: Added. * crypto/subtle/aes-kw-import-jwk-key-length-128-expected.txt: Added. * crypto/subtle/aes-kw-import-jwk-key-length-128.html: Added. * crypto/subtle/aes-kw-import-jwk-key-length-192-expected.txt: Added. * crypto/subtle/aes-kw-import-jwk-key-length-192.html: Added. * crypto/subtle/aes-kw-import-jwk-key-length-256-expected.txt: Added. * crypto/subtle/aes-kw-import-jwk-key-length-256.html: Added. * crypto/subtle/aes-kw-import-raw-key-expected.txt: Added. * crypto/subtle/aes-kw-import-raw-key.html: Added. * crypto/subtle/generate-key-malformed-parameters-expected.txt: Renamed from LayoutTests/crypto/subtle/generate-key-malformed-paramters-expected.txt. * crypto/subtle/generate-key-malformed-parameters.html: Renamed from LayoutTests/crypto/subtle/generate-key-malformed-paramters.html. * crypto/subtle/hmac-generate-key-customized-length-expected.txt: * crypto/subtle/hmac-generate-key-customized-length.html: * crypto/subtle/hmac-generate-key-malformed-parameters-expected.txt: * crypto/subtle/hmac-generate-key-malformed-parameters.html: * crypto/subtle/hmac-import-raw-key-customized-length-expected.txt: * crypto/subtle/hmac-import-raw-key-customized-length.html: * crypto/subtle/hmac-import-jwk-key-minimum-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-minimum.html: Added. * crypto/subtle/hmac-import-jwk-key-non-extractable-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-non-extractable.html: Added. * crypto/subtle/hmac-import-jwk-key-sha1-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha1.html: Added. * crypto/subtle/hmac-import-jwk-key-sha224-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha224.html: Added. * crypto/subtle/hmac-import-jwk-key-sha256-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha256.html: Added. * crypto/subtle/hmac-import-jwk-key-sha384-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha384.html: Added. * crypto/subtle/hmac-import-jwk-key-sha512-expected.txt: Added. * crypto/subtle/hmac-import-jwk-key-sha512.html: Added. * crypto/subtle/hmac-import-malformed-parameters-expected.txt: Added. * crypto/subtle/hmac-import-malformed-parameters.html: Added. * crypto/subtle/hmac-import-raw-key-customized-length-expected.txt: Added. * crypto/subtle/hmac-import-raw-key-customized-length.html: Added. * crypto/subtle/hmac-import-raw-key-expected.txt: Added. * crypto/subtle/hmac-import-raw-key.html: Added. * crypto/subtle/import-key-malformed-parameters-expected.txt: Added. * crypto/subtle/import-key-malformed-parameters.html: Added. * crypto/subtle/rsa-import-key-malformed-parameters-expected.txt: Added. * crypto/subtle/rsa-import-key-malformed-parameters.html: Added. * crypto/subtle/rsa-oaep-import-jwk-private-key-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-private-key.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha1-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha1.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha224-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha224.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha256-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha256.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha384-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha384.html: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha512-expected.txt: Added. * crypto/subtle/rsa-oaep-import-jwk-public-key-sha512.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-private-key-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-private-key.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-leading-zero-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-leading-zero.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-minimum-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-minimum.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-non-extractable-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key-non-extractable.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-import-jwk-public-key.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-private-key-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-private-key.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha1-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha1.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha224-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha224.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha256-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha256.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha384-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha384.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha512-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-import-jwk-public-key-sha512.html: Added. * crypto/webkitSubtle/hmac-generate-key-expected.txt: * crypto/webkitSubtle/hmac-generate-key.html: * crypto/webkitSubtle/hmac-import-jwk-expected.txt: * crypto/webkitSubtle/hmac-import-jwk.html: * crypto/webkitSubtle/hmac-postMessage-expected.txt: * crypto/webkitSubtle/hmac-postMessage.html: * crypto/webkitSubtle/hmac-sign-verify-expected.txt: * crypto/webkitSubtle/hmac-sign-verify.html: * crypto/workers/subtle/aes-import-jwk-key-expected.txt: Added. * crypto/workers/subtle/aes-import-jwk-key.html: Added. * crypto/workers/subtle/aes-import-raw-key-expected.txt: Added. * crypto/workers/subtle/aes-import-raw-key.html: Added. * crypto/workers/subtle/hmac-import-jwk-key-expected.txt: Added. * crypto/workers/subtle/hmac-import-jwk-key.html: Added. * crypto/workers/subtle/hmac-import-raw-key-expected.txt: Added. * crypto/workers/subtle/hmac-import-raw-key.html: Added. * crypto/workers/subtle/hmac-postMessage-worker-expected.txt: * crypto/workers/subtle/hmac-postMessage-worker.html: * crypto/workers/subtle/resources/aes-import-jwk-key.js: Added. * crypto/workers/subtle/resources/aes-import-raw-key.js: Added. * crypto/workers/subtle/resources/hmac-import-jwk-key.js: Added. * crypto/workers/subtle/resources/hmac-import-raw-key.js: Added. * crypto/workers/subtle/resources/hmac-postMessage-worker.js: * crypto/workers/subtle/resources/rsa-import-jwk-private-key.js: Added. * crypto/workers/subtle/resources/rsa-import-jwk-public-key.js: Added. * crypto/workers/subtle/rsa-import-jwk-private-key-expected.txt: Added. * crypto/workers/subtle/rsa-import-jwk-private-key.html: Added. * crypto/workers/subtle/rsa-import-jwk-public-key-expected.txt: Added. * crypto/workers/subtle/rsa-import-jwk-public-key.html: Added. Canonical link: https://commits.webkit.org/182271@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@208548 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-11-10 18:36:44 +00:00
// FIXME: Consider merging key_ops and usages.
Remove WTF::Optional synonym for std::optional, using that class template directly instead https://bugs.webkit.org/show_bug.cgi?id=226433 Reviewed by Chris Dumez. Source/JavaScriptCore: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. * inspector/scripts/codegen/generate_objc_protocol_types_implementation.py: (ObjCProtocolTypesImplementationGenerator._generate_init_method_for_payload): Use auto instead of Optional<>. Also use * instead of value() and nest the definition of the local inside an if statement in the case where it's an optional. * inspector/scripts/tests/expected/*: Regenerated these results. Source/WebCore: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebCore/PAL: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebDriver: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebKit: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. * Scripts/webkit/tests: Regenerated expected results, by running the command "python Scripts/webkit/messages_unittest.py -r". (How am I supposed to know to do that?) Source/WebKitLegacy/ios: * WebCoreSupport/WebChromeClientIOS.h: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebKitLegacy/mac: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebKitLegacy/win: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WTF: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. * wtf/Optional.h: Remove WTF::Optional. Tools: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Canonical link: https://commits.webkit.org/238290@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@278253 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2021-05-30 16:11:40 +00:00
std::optional<Vector<CryptoKeyUsage>> key_ops;
Rename CryptoKeyUsage to CryptoKeyUsageBitmap and CryptoKey::Usage to CryptoKeyUsage https://bugs.webkit.org/show_bug.cgi?id=164624 <rdar://problem/29210140> Reviewed by Brent Fulgham. Source/WebCore: This patch allows IDLType CryptoKeyUsage to be shared among different IDLs, i.e. CryptoKey.idl, SubtleCrypto.idl and JsonWebKey.idl such that it can simplify the customized binding codes. Covered by existing tests. * CMakeLists.txt: * DerivedSources.make: * WebCore.xcodeproj/project.pbxproj: * bindings/js/JSCryptoKeySerializationJWK.cpp: * bindings/js/JSCryptoKeySerializationJWK.h: * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::toCryptoKeyUsageBitmap): (WebCore::cryptoKeyUsageBitmapFromJSValue): (WebCore::toKeyData): (WebCore::jsSubtleCryptoFunctionGenerateKeyPromise): (WebCore::jsSubtleCryptoFunctionImportKeyPromise): (WebCore::cryptoKeyUsageFromString): Deleted. (WebCore::cryptoKeyUsagesFromJSValue): Deleted. * bindings/js/JSWebKitSubtleCryptoCustom.cpp: * bindings/js/SerializedScriptValue.cpp: * crypto/CryptoAlgorithm.cpp: * crypto/CryptoAlgorithm.h: * crypto/CryptoKey.cpp: * crypto/CryptoKey.h: * crypto/CryptoKey.idl: * crypto/CryptoKeySerialization.h: * crypto/CryptoKeyUsage.h: * crypto/CryptoKeyUsage.idl: Added. * crypto/gnutls/CryptoKeyRSAGnuTLS.cpp: * crypto/JsonWebKey.h: * crypto/JsonWebKey.idl: * crypto/SubtleCrypto.idl: * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: * crypto/algorithms/CryptoAlgorithmAES_CBC.h: * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: * crypto/algorithms/CryptoAlgorithmAES_KW.h: * crypto/algorithms/CryptoAlgorithmHMAC.cpp: * crypto/algorithms/CryptoAlgorithmHMAC.h: * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: * crypto/algorithms/CryptoAlgorithmRSA_OAEP.h: * crypto/keys/CryptoKeyAES.cpp: * crypto/keys/CryptoKeyAES.h: * crypto/keys/CryptoKeyHMAC.cpp: * crypto/keys/CryptoKeyHMAC.h: * crypto/keys/CryptoKeyRSA.cpp: * crypto/keys/CryptoKeyRSA.h: * crypto/keys/CryptoKeySerializationRaw.cpp: * crypto/keys/CryptoKeySerializationRaw.h: * crypto/mac/CryptoKeyRSAMac.cpp: LayoutTests: * crypto/subtle/generate-key-malformed-parameters-expected.txt: * crypto/subtle/import-key-malformed-parameters-expected.txt: Canonical link: https://commits.webkit.org/182325@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@208602 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-11-11 20:12:00 +00:00
CryptoKeyUsageBitmap usages;
[WebCrypto] remove toJSValueFromJsonWebKey from custom SubtleCrypto binding codes https://bugs.webkit.org/show_bug.cgi?id=167026 Reviewed by Chris Dumez. Source/WebCore: Covered by existing tests. * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::jsSubtleCryptoFunctionExportKeyPromise): (WebCore::jsSubtleCryptoFunctionWrapKeyPromise): (WebCore::toJSValueFromJsonWebKey): Deleted. * crypto/JsonWebKey.h: * crypto/JsonWebKey.idl: * crypto/RsaOtherPrimesInfo.idl: Change std::optional<String> to String in order to use toJS<IDLDictionary<JsonWebKey>>. * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: (WebCore::CryptoAlgorithmAES_CBC::importKey): * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: (WebCore::CryptoAlgorithmAES_KW::importKey): * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::importKey): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: (WebCore::CryptoAlgorithmRSA_OAEP::importKey): * crypto/keys/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::importJwk): Only check if key_ops contains all of the specified usages when key_ops field of jwk is present, as per the specification: https://www.w3.org/TR/WebCryptoAPI/#aes-cbc-operations * crypto/keys/CryptoKeyAES.h: * crypto/keys/CryptoKeyHMAC.cpp: (WebCore::CryptoKeyHMAC::importJwk): * crypto/keys/CryptoKeyHMAC.h: * crypto/keys/CryptoKeyRSA.cpp: (WebCore::CryptoKeyRSA::importJwk): Accommodate the change from std::optional<String> to String. * crypto/mac/CryptoKeyRSAMac.cpp: (WebCore::CryptoKeyRSA::create): Add a null check for p. LayoutTests: * crypto/subtle/aes-cbc-import-key-wrap-jwk-rsa-key-private.html: * crypto/subtle/aes-cbc-import-key-wrap-jwk-rsa-key-public.html: Order of attributes inside JWK is different after this patch. * crypto/subtle/aes-import-key-malformed-parameters-expected.txt: * crypto/subtle/aes-import-key-malformed-parameters.html: * crypto/subtle/hmac-import-key-malformed-parameters-expected.txt: * crypto/subtle/hmac-import-key-malformed-parameters.html: * crypto/subtle/rsa-import-key-malformed-parameters-expected.txt: * crypto/subtle/rsa-import-key-malformed-parameters.html: * crypto/workers/subtle/resources/aes-cbc-import-key-wrap-key.js: Canonical link: https://commits.webkit.org/185480@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@212465 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2017-02-16 22:31:14 +00:00
String alg;
[WTF] Import std::optional reference implementation as WTF::Optional https://bugs.webkit.org/show_bug.cgi?id=164199 Reviewed by Saam Barati and Sam Weinig. Source/JavaScriptCore: Previous WTF::Optional::operator= is not compatible to std::optional::operator=. std::optional::emplace has the same semantics to the previous one. So we change the code to use it. * Scripts/builtins/builtins_templates.py: * Scripts/tests/builtins/expected/JavaScriptCore-Builtin.Promise-Combined.js-result: * Scripts/tests/builtins/expected/JavaScriptCore-Builtin.Promise-Separate.js-result: * Scripts/tests/builtins/expected/JavaScriptCore-Builtin.prototype-Combined.js-result: * Scripts/tests/builtins/expected/JavaScriptCore-Builtin.prototype-Separate.js-result: * Scripts/tests/builtins/expected/JavaScriptCore-BuiltinConstructor-Combined.js-result: * Scripts/tests/builtins/expected/JavaScriptCore-BuiltinConstructor-Separate.js-result: * Scripts/tests/builtins/expected/JavaScriptCore-InternalClashingNames-Combined.js-result: * Scripts/tests/builtins/expected/WebCore-AnotherGuardedInternalBuiltin-Separate.js-result: * Scripts/tests/builtins/expected/WebCore-ArbitraryConditionalGuard-Separate.js-result: * Scripts/tests/builtins/expected/WebCore-GuardedBuiltin-Separate.js-result: * Scripts/tests/builtins/expected/WebCore-GuardedInternalBuiltin-Separate.js-result: * Scripts/tests/builtins/expected/WebCore-UnguardedBuiltin-Separate.js-result: * Scripts/tests/builtins/expected/WebCore-xmlCasingTest-Separate.js-result: * assembler/MacroAssemblerARM64.h: (JSC::MacroAssemblerARM64::commuteCompareToZeroIntoTest): * assembler/MacroAssemblerX86Common.h: (JSC::MacroAssemblerX86Common::commuteCompareToZeroIntoTest): * b3/B3CheckSpecial.cpp: (JSC::B3::CheckSpecial::forEachArg): (JSC::B3::CheckSpecial::shouldTryAliasingDef): * b3/B3CheckSpecial.h: * b3/B3LowerToAir.cpp: (JSC::B3::Air::LowerToAir::scaleForShl): (JSC::B3::Air::LowerToAir::effectiveAddr): (JSC::B3::Air::LowerToAir::tryAppendLea): * b3/B3Opcode.cpp: (JSC::B3::invertedCompare): * b3/B3Opcode.h: * b3/B3PatchpointSpecial.cpp: (JSC::B3::PatchpointSpecial::forEachArg): * b3/B3StackmapSpecial.cpp: (JSC::B3::StackmapSpecial::forEachArgImpl): * b3/B3StackmapSpecial.h: * b3/B3Value.cpp: (JSC::B3::Value::invertedCompare): * b3/air/AirArg.h: (JSC::B3::Air::Arg::isValidScale): (JSC::B3::Air::Arg::isValidAddrForm): (JSC::B3::Air::Arg::isValidIndexForm): (JSC::B3::Air::Arg::isValidForm): * b3/air/AirCustom.h: (JSC::B3::Air::PatchCustom::shouldTryAliasingDef): * b3/air/AirFixObviousSpills.cpp: * b3/air/AirInst.h: * b3/air/AirInstInlines.h: (JSC::B3::Air::Inst::shouldTryAliasingDef): * b3/air/AirIteratedRegisterCoalescing.cpp: * b3/air/AirSpecial.cpp: (JSC::B3::Air::Special::shouldTryAliasingDef): * b3/air/AirSpecial.h: * bytecode/BytecodeGeneratorification.cpp: (JSC::BytecodeGeneratorification::storageForGeneratorLocal): * bytecode/CodeBlock.cpp: (JSC::CodeBlock::findPC): (JSC::CodeBlock::bytecodeOffsetFromCallSiteIndex): * bytecode/CodeBlock.h: * bytecode/UnlinkedFunctionExecutable.cpp: (JSC::UnlinkedFunctionExecutable::link): * bytecode/UnlinkedFunctionExecutable.h: * bytecompiler/BytecodeGenerator.h: * bytecompiler/NodesCodegen.cpp: (JSC::PropertyListNode::emitPutConstantProperty): (JSC::ObjectPatternNode::bindValue): * debugger/Debugger.cpp: (JSC::Debugger::resolveBreakpoint): * debugger/DebuggerCallFrame.cpp: (JSC::DebuggerCallFrame::currentPosition): * debugger/DebuggerParseData.cpp: (JSC::DebuggerPausePositions::breakpointLocationForLineColumn): * debugger/DebuggerParseData.h: * debugger/ScriptProfilingScope.h: * dfg/DFGAbstractInterpreterInlines.h: (JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects): (JSC::DFG::AbstractInterpreter<AbstractStateType>::executeDoubleUnaryOpEffects): * dfg/DFGJITCode.cpp: (JSC::DFG::JITCode::findPC): * dfg/DFGJITCode.h: * dfg/DFGOperations.cpp: (JSC::DFG::operationPutByValInternal): * dfg/DFGSlowPathGenerator.h: (JSC::DFG::SlowPathGenerator::generate): * dfg/DFGSpeculativeJIT.cpp: (JSC::DFG::SpeculativeJIT::runSlowPathGenerators): (JSC::DFG::SpeculativeJIT::emitUntypedBitOp): (JSC::DFG::SpeculativeJIT::emitUntypedRightShiftBitOp): (JSC::DFG::SpeculativeJIT::compileMathIC): (JSC::DFG::SpeculativeJIT::compileArithDiv): (JSC::DFG::SpeculativeJIT::compileCallDOMGetter): * dfg/DFGSpeculativeJIT.h: * dfg/DFGSpeculativeJIT32_64.cpp: (JSC::DFG::SpeculativeJIT::compile): * dfg/DFGSpeculativeJIT64.cpp: (JSC::DFG::SpeculativeJIT::compileLogicalNot): (JSC::DFG::SpeculativeJIT::emitBranch): (JSC::DFG::SpeculativeJIT::compile): * dfg/DFGStrengthReductionPhase.cpp: (JSC::DFG::StrengthReductionPhase::handleNode): * ftl/FTLJITCode.cpp: (JSC::FTL::JITCode::findPC): * ftl/FTLJITCode.h: * heap/Heap.cpp: (JSC::Heap::collectAsync): (JSC::Heap::collectSync): (JSC::Heap::collectInThread): (JSC::Heap::requestCollection): (JSC::Heap::willStartCollection): (JSC::Heap::didFinishCollection): (JSC::Heap::shouldDoFullCollection): * heap/Heap.h: (JSC::Heap::collectionScope): * heap/HeapSnapshot.cpp: (JSC::HeapSnapshot::nodeForCell): (JSC::HeapSnapshot::nodeForObjectIdentifier): * heap/HeapSnapshot.h: * inspector/InspectorBackendDispatcher.cpp: (Inspector::BackendDispatcher::dispatch): (Inspector::BackendDispatcher::sendPendingErrors): (Inspector::BackendDispatcher::reportProtocolError): * inspector/InspectorBackendDispatcher.h: * inspector/agents/InspectorHeapAgent.cpp: (Inspector::InspectorHeapAgent::nodeForHeapObjectIdentifier): (Inspector::InspectorHeapAgent::getPreview): (Inspector::InspectorHeapAgent::getRemoteObject): * inspector/agents/InspectorHeapAgent.h: * inspector/remote/RemoteConnectionToTarget.h: * inspector/remote/RemoteConnectionToTarget.mm: (Inspector::RemoteConnectionToTarget::targetIdentifier): (Inspector::RemoteConnectionToTarget::setup): * inspector/remote/RemoteInspector.h: * inspector/remote/RemoteInspector.mm: (Inspector::RemoteInspector::updateClientCapabilities): * inspector/scripts/codegen/generate_cpp_protocol_types_header.py: (_generate_declarations_for_enum_conversion_methods): (_generate_declarations_for_enum_conversion_methods.return_type_with_export_macro): * inspector/scripts/codegen/generate_cpp_protocol_types_implementation.py: (CppProtocolTypesImplementationGenerator._generate_enum_conversion_methods_for_domain.generate_conversion_method_body): * inspector/scripts/tests/expected/commands-with-async-attribute.json-result: * inspector/scripts/tests/expected/commands-with-optional-call-return-parameters.json-result: * inspector/scripts/tests/expected/enum-values.json-result: * inspector/scripts/tests/expected/shadowed-optional-type-setters.json-result: * inspector/scripts/tests/expected/type-declaration-array-type.json-result: * inspector/scripts/tests/expected/type-declaration-enum-type.json-result: * inspector/scripts/tests/expected/type-requiring-runtime-casts.json-result: * jit/JITCode.h: (JSC::JITCode::findPC): * jit/JITDivGenerator.cpp: (JSC::JITDivGenerator::generateFastPath): * jit/JITOperations.cpp: * jit/PCToCodeOriginMap.cpp: (JSC::PCToCodeOriginMap::findPC): * jit/PCToCodeOriginMap.h: * jsc.cpp: (WTF::RuntimeArray::getOwnPropertySlot): * llint/LLIntSlowPaths.cpp: (JSC::LLInt::LLINT_SLOW_PATH_DECL): * parser/ModuleAnalyzer.cpp: (JSC::ModuleAnalyzer::exportVariable): * runtime/ConcurrentJSLock.h: (JSC::ConcurrentJSLocker::ConcurrentJSLocker): * runtime/DefinePropertyAttributes.h: (JSC::DefinePropertyAttributes::writable): (JSC::DefinePropertyAttributes::configurable): (JSC::DefinePropertyAttributes::enumerable): * runtime/GenericArgumentsInlines.h: (JSC::GenericArguments<Type>::getOwnPropertySlot): (JSC::GenericArguments<Type>::put): (JSC::GenericArguments<Type>::deleteProperty): (JSC::GenericArguments<Type>::defineOwnProperty): * runtime/HasOwnPropertyCache.h: (JSC::HasOwnPropertyCache::get): * runtime/HashMapImpl.h: (JSC::concurrentJSMapHash): * runtime/Identifier.h: (JSC::parseIndex): * runtime/JSArray.cpp: (JSC::JSArray::defineOwnProperty): * runtime/JSCJSValue.cpp: (JSC::JSValue::toNumberFromPrimitive): (JSC::JSValue::putToPrimitive): * runtime/JSCJSValue.h: * runtime/JSGenericTypedArrayView.h: (JSC::JSGenericTypedArrayView::toAdaptorNativeFromValueWithoutCoercion): * runtime/JSGenericTypedArrayViewConstructorInlines.h: (JSC::constructGenericTypedArrayViewWithArguments): (JSC::constructGenericTypedArrayView): * runtime/JSGenericTypedArrayViewInlines.h: (JSC::JSGenericTypedArrayView<Adaptor>::getOwnPropertySlot): (JSC::JSGenericTypedArrayView<Adaptor>::put): * runtime/JSModuleRecord.cpp: * runtime/JSModuleRecord.h: * runtime/JSObject.cpp: (JSC::JSObject::putDirectAccessor): (JSC::JSObject::deleteProperty): (JSC::JSObject::putDirectMayBeIndex): (JSC::JSObject::defineOwnProperty): * runtime/JSObject.h: (JSC::JSObject::getOwnPropertySlot): (JSC::JSObject::getPropertySlot): (JSC::JSObject::putOwnDataPropertyMayBeIndex): * runtime/JSObjectInlines.h: (JSC::JSObject::putInline): * runtime/JSString.cpp: (JSC::JSString::getStringPropertyDescriptor): * runtime/JSString.h: (JSC::JSString::getStringPropertySlot): * runtime/LiteralParser.cpp: (JSC::LiteralParser<CharType>::parse): * runtime/MathCommon.h: (JSC::safeReciprocalForDivByConst): * runtime/ObjectPrototype.cpp: (JSC::objectProtoFuncHasOwnProperty): * runtime/PropertyDescriptor.h: (JSC::toPropertyDescriptor): * runtime/PropertyName.h: (JSC::parseIndex): * runtime/SamplingProfiler.cpp: (JSC::SamplingProfiler::processUnverifiedStackTraces): * runtime/StringObject.cpp: (JSC::StringObject::put): (JSC::isStringOwnProperty): (JSC::StringObject::deleteProperty): * runtime/ToNativeFromValue.h: (JSC::toNativeFromValueWithoutCoercion): * runtime/TypedArrayAdaptors.h: (JSC::IntegralTypedArrayAdaptor::toNativeFromInt32WithoutCoercion): (JSC::IntegralTypedArrayAdaptor::toNativeFromUint32WithoutCoercion): (JSC::IntegralTypedArrayAdaptor::toNativeFromDoubleWithoutCoercion): (JSC::FloatTypedArrayAdaptor::toNativeFromInt32WithoutCoercion): (JSC::FloatTypedArrayAdaptor::toNativeFromDoubleWithoutCoercion): (JSC::Uint8ClampedAdaptor::toNativeFromInt32WithoutCoercion): (JSC::Uint8ClampedAdaptor::toNativeFromDoubleWithoutCoercion): Source/WebCore: Rename valueOr to value_or. This is specified in C++17 proposal. Use Optional::emplace. C++17 Optional::operator=(Optional&&) requires either copy assignment operator or move assignment operator. But DFG::JSValueOperand etc. only defines move constructors and drop implicit copy assignment operators. It was OK in the previous WTF::Optional since it always uses move constructors. But it is not valid in C++17 Optional. We use Optional::emplace instead. This function has the same semantics to the previous WTF::Optional's operator=. No behavior change. * Modules/applepay/ApplePaySession.cpp: (WebCore::parseAmount): (WebCore::createContactFields): (WebCore::toLineItemType): (WebCore::createLineItem): (WebCore::createLineItems): (WebCore::createMerchantCapabilities): (WebCore::createSupportedNetworks): (WebCore::toShippingType): (WebCore::createShippingMethod): (WebCore::createShippingMethods): (WebCore::createPaymentRequest): (WebCore::toPaymentAuthorizationStatus): * Modules/applepay/PaymentContact.h: * Modules/applepay/PaymentCoordinator.cpp: (WebCore::PaymentCoordinator::completeShippingMethodSelection): (WebCore::PaymentCoordinator::completeShippingContactSelection): (WebCore::PaymentCoordinator::completePaymentMethodSelection): * Modules/applepay/PaymentCoordinator.h: * Modules/applepay/PaymentCoordinatorClient.h: * Modules/applepay/PaymentMerchantSession.h: * Modules/applepay/PaymentRequest.h: * Modules/applepay/cocoa/PaymentContactCocoa.mm: (WebCore::PaymentContact::fromJS): * Modules/applepay/cocoa/PaymentMerchantSessionCocoa.mm: (WebCore::PaymentMerchantSession::fromJS): * Modules/encryptedmedia/MediaKeyStatusMap.cpp: (WebCore::MediaKeyStatusMap::Iterator::next): * Modules/encryptedmedia/MediaKeyStatusMap.h: * Modules/fetch/FetchBody.cpp: (WebCore::FetchBody::extract): * Modules/fetch/FetchBody.h: * Modules/fetch/FetchBodyOwner.cpp: (WebCore::FetchBodyOwner::FetchBodyOwner): (WebCore::FetchBodyOwner::loadBlob): (WebCore::FetchBodyOwner::finishBlobLoading): * Modules/fetch/FetchBodyOwner.h: * Modules/fetch/FetchHeaders.cpp: (WebCore::FetchHeaders::Iterator::next): * Modules/fetch/FetchHeaders.h: * Modules/fetch/FetchRequest.cpp: (WebCore::setReferrerPolicy): (WebCore::setMode): (WebCore::setCredentials): (WebCore::setCache): (WebCore::setRedirect): (WebCore::setMethod): (WebCore::setReferrer): (WebCore::buildOptions): (WebCore::FetchRequest::clone): * Modules/fetch/FetchRequest.h: (WebCore::FetchRequest::FetchRequest): * Modules/fetch/FetchResponse.cpp: (WebCore::FetchResponse::FetchResponse): (WebCore::FetchResponse::cloneForJS): (WebCore::FetchResponse::fetch): (WebCore::FetchResponse::BodyLoader::didSucceed): (WebCore::FetchResponse::BodyLoader::didFail): (WebCore::FetchResponse::BodyLoader::didReceiveResponse): (WebCore::FetchResponse::BodyLoader::stop): * Modules/fetch/FetchResponse.h: * Modules/geolocation/Coordinates.cpp: (WebCore::Coordinates::altitude): (WebCore::Coordinates::altitudeAccuracy): (WebCore::Coordinates::heading): (WebCore::Coordinates::speed): * Modules/geolocation/Coordinates.h: * Modules/indexeddb/IDBCursor.cpp: (WebCore::IDBCursor::stringToDirection): * Modules/indexeddb/IDBCursor.h: * Modules/indexeddb/IDBDatabase.h: * Modules/indexeddb/IDBDatabaseIdentifier.h: (WebCore::IDBDatabaseIdentifier::hash): * Modules/indexeddb/IDBFactory.cpp: (WebCore::IDBFactory::open): * Modules/indexeddb/IDBFactory.h: * Modules/indexeddb/IDBIndex.cpp: (WebCore::IDBIndex::getAll): (WebCore::IDBIndex::getAllKeys): * Modules/indexeddb/IDBIndex.h: * Modules/indexeddb/IDBKeyPath.h: (WebCore::isolatedCopy): * Modules/indexeddb/IDBObjectStore.cpp: (WebCore::IDBObjectStore::keyPath): (WebCore::IDBObjectStore::getAll): (WebCore::IDBObjectStore::getAllKeys): * Modules/indexeddb/IDBObjectStore.h: * Modules/indexeddb/IDBTransaction.cpp: (WebCore::IDBTransaction::requestGetAllObjectStoreRecords): (WebCore::IDBTransaction::requestGetAllIndexRecords): * Modules/indexeddb/IDBTransaction.h: * Modules/indexeddb/IDBVersionChangeEvent.cpp: (WebCore::IDBVersionChangeEvent::IDBVersionChangeEvent): * Modules/indexeddb/IDBVersionChangeEvent.h: * Modules/indexeddb/server/IDBSerialization.cpp: (WebCore::serializeIDBKeyPath): (WebCore::deserializeIDBKeyPath): * Modules/indexeddb/server/IDBSerialization.h: * Modules/indexeddb/server/MemoryIndex.cpp: (WebCore::IDBServer::MemoryIndex::getAllRecords): * Modules/indexeddb/server/MemoryIndex.h: * Modules/indexeddb/server/MemoryObjectStore.cpp: (WebCore::IDBServer::MemoryObjectStore::getAllRecords): * Modules/indexeddb/server/MemoryObjectStore.h: * Modules/indexeddb/server/MemoryObjectStoreCursor.cpp: (WebCore::IDBServer::MemoryObjectStoreCursor::objectStoreCleared): (WebCore::IDBServer::MemoryObjectStoreCursor::keyDeleted): (WebCore::IDBServer::MemoryObjectStoreCursor::setFirstInRemainingRange): (WebCore::IDBServer::MemoryObjectStoreCursor::setForwardIteratorFromRemainingRange): (WebCore::IDBServer::MemoryObjectStoreCursor::setReverseIteratorFromRemainingRange): (WebCore::IDBServer::MemoryObjectStoreCursor::incrementForwardIterator): (WebCore::IDBServer::MemoryObjectStoreCursor::incrementReverseIterator): * Modules/indexeddb/server/MemoryObjectStoreCursor.h: * Modules/indexeddb/server/SQLiteIDBBackingStore.cpp: (WebCore::IDBServer::SQLiteIDBBackingStore::extractExistingDatabaseInfo): * Modules/indexeddb/shared/IDBDatabaseInfo.cpp: (WebCore::IDBDatabaseInfo::createNewObjectStore): * Modules/indexeddb/shared/IDBDatabaseInfo.h: * Modules/indexeddb/shared/IDBGetAllRecordsData.h: * Modules/indexeddb/shared/IDBObjectStoreInfo.cpp: (WebCore::IDBObjectStoreInfo::IDBObjectStoreInfo): * Modules/indexeddb/shared/IDBObjectStoreInfo.h: (WebCore::IDBObjectStoreInfo::keyPath): * Modules/mediacontrols/MediaControlsHost.cpp: (WebCore::MediaControlsHost::displayNameForTrack): * Modules/mediacontrols/MediaControlsHost.h: * Modules/mediasource/MediaSource.cpp: (WebCore::MediaSource::endOfStream): (WebCore::MediaSource::streamEndedWithError): * Modules/mediasource/MediaSource.h: * Modules/mediastream/MediaStreamTrack.h: * Modules/mediastream/PeerConnectionBackend.cpp: (WebCore::PeerConnectionBackend::createOfferSucceeded): (WebCore::PeerConnectionBackend::createOfferFailed): (WebCore::PeerConnectionBackend::createAnswerSucceeded): (WebCore::PeerConnectionBackend::createAnswerFailed): (WebCore::PeerConnectionBackend::setLocalDescriptionSucceeded): (WebCore::PeerConnectionBackend::setLocalDescriptionFailed): (WebCore::PeerConnectionBackend::setRemoteDescriptionSucceeded): (WebCore::PeerConnectionBackend::setRemoteDescriptionFailed): (WebCore::PeerConnectionBackend::addIceCandidateSucceeded): (WebCore::PeerConnectionBackend::addIceCandidateFailed): (WebCore::PeerConnectionBackend::stop): * Modules/mediastream/PeerConnectionBackend.h: * Modules/mediastream/RTCDTMFSender.cpp: (WebCore::RTCDTMFSender::insertDTMF): * Modules/mediastream/RTCDTMFSender.h: * Modules/mediastream/RTCIceCandidate.cpp: (WebCore::RTCIceCandidate::create): (WebCore::RTCIceCandidate::RTCIceCandidate): * Modules/mediastream/RTCIceCandidate.h: (WebCore::RTCIceCandidate::sdpMLineIndex): * Modules/mediastream/SDPProcessor.cpp: (WebCore::iceCandidateFromJSON): * Modules/proximity/DeviceProximityEvent.h: * Modules/streams/ReadableStreamSource.h: (WebCore::ReadableStreamSource::startFinished): (WebCore::ReadableStreamSource::pullFinished): (WebCore::ReadableStreamSource::clean): * Modules/webaudio/AudioBufferSourceNode.cpp: (WebCore::AudioBufferSourceNode::start): * Modules/webaudio/AudioBufferSourceNode.h: * Modules/webdatabase/SQLResultSet.h: * Modules/websockets/WebSocket.cpp: (WebCore::WebSocket::close): * Modules/websockets/WebSocket.h: * Modules/websockets/WebSocketChannel.cpp: (WebCore::WebSocketChannel::didReceiveSocketStreamData): * Modules/websockets/WebSocketChannel.h: * bindings/generic/IDLTypes.h: (WebCore::IDLType::nullValue): * bindings/js/CachedModuleScript.h: (WebCore::CachedModuleScript::error): * bindings/js/Dictionary.h: (WebCore::Dictionary::get): * bindings/js/IDBBindingUtilities.cpp: (WebCore::toJS): * bindings/js/IDBBindingUtilities.h: * bindings/js/JSCryptoKeySerializationJWK.cpp: (WebCore::JSCryptoKeySerializationJWK::reconcileAlgorithm): * bindings/js/JSCryptoKeySerializationJWK.h: * bindings/js/JSDOMConvert.h: (WebCore::Detail::VariadicConverterBase::convert): (WebCore::Detail::VariadicConverterBase<IDLInterface<T>>::convert): (WebCore::convertVariadicArguments): * bindings/js/JSDOMIterator.h: (WebCore::IteratorTraits>::next): * bindings/js/JSDOMPromise.h: (WebCore::DOMPromise::DOMPromise): (WebCore::DOMPromise::operator=): * bindings/js/JSDOMWindowCustom.cpp: (WebCore::JSDOMWindow::getOwnPropertySlot): * bindings/js/JSDictionary.h: (WebCore::JSDictionary::convertValue): * bindings/js/JSFileCustom.cpp: (WebCore::constructJSFile): * bindings/js/JSHTMLAllCollectionCustom.cpp: (WebCore::callHTMLAllCollection): (WebCore::JSHTMLAllCollection::item): * bindings/js/JSHTMLCanvasElementCustom.cpp: (WebCore::JSHTMLCanvasElement::toDataURL): * bindings/js/JSImageConstructor.cpp: (WebCore::JSImageConstructor::construct): * bindings/js/JSMediaDevicesCustom.cpp: (WebCore::createStringConstraint): (WebCore::createBooleanConstraint): (WebCore::createDoubleConstraint): (WebCore::createIntConstraint): * bindings/js/JSWebKitSubtleCryptoCustom.cpp: (WebCore::importKey): * bindings/js/ScriptController.cpp: (WebCore::ScriptController::setupModuleScriptHandlers): (WebCore::ScriptController::executeScriptInWorld): (WebCore::ScriptController::executeScript): * bindings/scripts/CodeGeneratorJS.pm: (GenerateGetOwnPropertySlotBody): (GenerateEnumerationImplementationContent): (GenerateEnumerationHeaderContent): (GenerateDefaultValue): (GenerateImplementation): (GenerateParametersCheck): * bindings/scripts/test/JS/JSFloat64Array.cpp: (WebCore::JSFloat64Array::getOwnPropertySlot): (WebCore::JSFloat64Array::getOwnPropertyDescriptor): (WebCore::JSFloat64Array::put): * bindings/scripts/test/JS/JSTestEventTarget.cpp: (WebCore::JSTestEventTarget::getOwnPropertySlot): * bindings/scripts/test/JS/JSTestObj.cpp: (WebCore::parseEnumeration<TestObj::EnumType>): (WebCore::parseEnumeration<TestObj::Optional>): (WebCore::parseEnumeration<AlternateEnumName>): (WebCore::parseEnumeration<TestObj::EnumA>): (WebCore::parseEnumeration<TestObj::EnumB>): (WebCore::parseEnumeration<TestObj::EnumC>): (WebCore::parseEnumeration<TestObj::Kind>): (WebCore::parseEnumeration<TestObj::Size>): (WebCore::parseEnumeration<TestObj::Confidence>): (WebCore::convertDictionary<TestObj::Dictionary>): (WebCore::JSTestObj::getOwnPropertySlot): (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalEnumArgCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArgCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndOptionalArgCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndTwoOptionalArgsCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalLongLongCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalUnsignedLongLongCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalSequenceCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalBooleanCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalRecordCaller): (WebCore::jsTestObjPrototypeFunctionOverloadedMethod2Caller): (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithOptionalParameter2Caller): (WebCore::jsTestObjConstructorFunctionClassMethodWithOptional): (WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithOptionalIntArgumentCaller): * bindings/scripts/test/JS/JSTestObj.h: * bindings/scripts/test/JS/JSTestStandaloneDictionary.cpp: (WebCore::parseEnumeration<TestStandaloneDictionary::EnumInStandaloneDictionaryFile>): * bindings/scripts/test/JS/JSTestStandaloneDictionary.h: * bindings/scripts/test/JS/JSTestStandaloneEnumeration.cpp: (WebCore::parseEnumeration<TestStandaloneEnumeration>): * bindings/scripts/test/JS/JSTestStandaloneEnumeration.h: * bindings/scripts/test/JS/JSTestTypedefs.cpp: (WebCore::jsTestTypedefsPrototypeFunctionSetShadowCaller): (WebCore::jsTestTypedefsPrototypeFunctionFuncWithClampCaller): * bridge/runtime_array.cpp: (JSC::RuntimeArray::getOwnPropertySlot): (JSC::RuntimeArray::put): * crypto/CryptoAlgorithmRegistry.cpp: (WebCore::CryptoAlgorithmRegistry::identifier): * crypto/CryptoAlgorithmRegistry.h: * crypto/CryptoKeySerialization.h: * crypto/JsonWebKey.h: * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: (WebCore::CryptoAlgorithmAES_CBC::importKey): * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: (WebCore::CryptoAlgorithmAES_KW::importKey): * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::generateKey): (WebCore::CryptoAlgorithmHMAC::importKey): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::importKey): * crypto/gcrypt/CryptoAlgorithmHMACGCrypt.cpp: (WebCore::calculateSignature): * crypto/keys/CryptoKeyAES.h: * crypto/keys/CryptoKeyHMAC.h: * crypto/keys/CryptoKeyRSA.cpp: (WebCore::CryptoKeyRSA::importJwk): * crypto/keys/CryptoKeyRSA.h: * crypto/keys/CryptoKeySerializationRaw.cpp: (WebCore::CryptoKeySerializationRaw::reconcileAlgorithm): * crypto/keys/CryptoKeySerializationRaw.h: * crypto/mac/CryptoAlgorithmHMACMac.cpp: (WebCore::commonCryptoHMACAlgorithm): * crypto/mac/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp: (WebCore::cryptoDigestAlgorithm): * crypto/parameters/CryptoAlgorithmHmacKeyParams.h: * crypto/parameters/CryptoAlgorithmRsaOaepParams.h: * css/CSSFontFace.cpp: (WebCore::CSSFontFace::calculateStyleMask): (WebCore::CSSFontFace::calculateWeightMask): * css/CSSFontFace.h: * css/CSSFontFaceSet.cpp: (WebCore::computeFontTraitsMask): * css/CSSPrimitiveValue.cpp: (WebCore::CSSPrimitiveValue::doubleValue): (WebCore::CSSPrimitiveValue::doubleValueInternal): * css/CSSPrimitiveValue.h: * css/CSSPropertyNames.in: * css/CSSSegmentedFontFace.cpp: * css/CSSStyleSheet.cpp: (WebCore::CSSStyleSheet::create): (WebCore::CSSStyleSheet::CSSStyleSheet): (WebCore::CSSStyleSheet::addRule): * css/CSSStyleSheet.h: * css/FontFace.cpp: (WebCore::FontFace::fontStateChanged): * css/FontFace.h: * css/FontFaceSet.cpp: (WebCore::FontFaceSet::completedLoading): * css/FontFaceSet.h: * css/MediaQueryEvaluator.cpp: (WebCore::doubleValue): * css/StyleBuilderConverter.h: (WebCore::StyleBuilderConverter::convertGridPosition): (WebCore::StyleBuilderConverter::convertWordSpacing): (WebCore::StyleBuilderConverter::convertPerspective): (WebCore::StyleBuilderConverter::convertMarqueeIncrement): (WebCore::StyleBuilderConverter::convertFilterOperations): (WebCore::StyleBuilderConverter::convertLineHeight): * css/StyleBuilderCustom.h: (WebCore::StyleBuilderCustom::applyValueLineHeight): * css/StyleRuleImport.cpp: (WebCore::StyleRuleImport::requestStyleSheet): * css/parser/CSSParser.cpp: (WebCore::CSSParser::parseCubicBezierTimingFunctionValue): (WebCore::CSSParser::parseSpringTimingFunctionValue): (WebCore::CSSParser::parseColorFunctionParameters): (WebCore::CSSParser::parseColorFromValue): * css/parser/CSSParser.h: * cssjit/SelectorCompiler.cpp: (WebCore::SelectorCompiler::SelectorCodeGenerator::generateAddStyleRelationIfResolvingStyle): (WebCore::SelectorCompiler::SelectorCodeGenerator::generateAddStyleRelation): * dom/CustomElementReactionQueue.cpp: * dom/Document.cpp: (WebCore::Document::lastModified): * dom/Element.cpp: (WebCore::Element::scrollBy): (WebCore::Element::getIntegralAttribute): (WebCore::Element::getUnsignedIntegralAttribute): (WebCore::Element::resolveCustomStyle): * dom/Element.h: * dom/ElementIteratorAssertions.h: (WebCore::ElementIteratorAssertions::dropEventDispatchAssertion): (WebCore::ElementIteratorAssertions::clear): * dom/ExceptionOr.h: * dom/InlineStyleSheetOwner.cpp: (WebCore::makeInlineStyleSheetCacheKey): * dom/KeyboardEvent.h: * dom/LoadableClassicScript.cpp: (WebCore::LoadableClassicScript::error): * dom/LoadableClassicScript.h: * dom/LoadableModuleScript.cpp: (WebCore::LoadableModuleScript::error): * dom/LoadableModuleScript.h: * dom/LoadableScript.h: * dom/MessageEvent.cpp: (WebCore::MessageEvent::MessageEvent): (WebCore::MessageEvent::create): (WebCore::MessageEvent::initMessageEvent): * dom/MessageEvent.h: * dom/MutationObserver.cpp: (WebCore::MutationObserver::observe): * dom/MutationObserver.h: * dom/ProcessingInstruction.cpp: (WebCore::ProcessingInstruction::checkStyleSheet): * dom/PseudoElement.cpp: (WebCore::PseudoElement::resolveCustomStyle): * dom/PseudoElement.h: * dom/RangeBoundaryPoint.h: (WebCore::RangeBoundaryPoint::setToBeforeChild): (WebCore::RangeBoundaryPoint::setToAfterChild): (WebCore::RangeBoundaryPoint::setToEndOfNode): (WebCore::RangeBoundaryPoint::invalidateOffset): * dom/ScriptElement.cpp: (WebCore::ScriptElement::determineScriptType): (WebCore::ScriptElement::prepareScript): (WebCore::ScriptElement::executeScriptAndDispatchEvent): * dom/ScriptElement.h: * dom/TextDecoder.cpp: (WebCore::TextDecoder::decode): * dom/TextDecoder.h: * dom/UserGestureIndicator.cpp: (WebCore::UserGestureIndicator::UserGestureIndicator): * dom/UserGestureIndicator.h: * editing/CompositeEditCommand.cpp: (WebCore::CompositeEditCommand::moveParagraphs): * editing/CompositeEditCommand.h: * fileapi/File.h: * history/CachedFrame.h: (WebCore::CachedFrame::hasInsecureContent): * html/DOMTokenList.cpp: (WebCore::DOMTokenList::toggle): * html/DOMTokenList.h: * html/HTMLAnchorElement.cpp: (WebCore::HTMLAnchorElement::handleClick): * html/HTMLCanvasElement.cpp: (WebCore::HTMLCanvasElement::toDataURL): * html/HTMLCanvasElement.h: * html/HTMLElement.cpp: (WebCore::HTMLElement::parseBorderWidthAttribute): (WebCore::HTMLElement::parseAttribute): * html/HTMLImageElement.cpp: (WebCore::HTMLImageElement::createForJSConstructor): (WebCore::HTMLImageElement::width): (WebCore::HTMLImageElement::height): * html/HTMLImageElement.h: * html/HTMLInputElement.cpp: (WebCore::HTMLInputElement::findClosestTickMarkValue): (WebCore::HTMLInputElement::maxLengthAttributeChanged): (WebCore::HTMLInputElement::minLengthAttributeChanged): * html/HTMLInputElement.h: * html/HTMLLinkElement.cpp: (WebCore::HTMLLinkElement::process): (WebCore::HTMLLinkElement::initializeStyleSheet): (WebCore::HTMLLinkElement::iconType): * html/HTMLLinkElement.h: * html/HTMLOListElement.h: * html/HTMLOptionsCollection.cpp: (WebCore::HTMLOptionsCollection::add): * html/HTMLOptionsCollection.h: * html/HTMLSelectElement.cpp: (WebCore::HTMLSelectElement::add): (WebCore::HTMLSelectElement::setLength): * html/HTMLSelectElement.h: * html/HTMLTextAreaElement.cpp: (WebCore::HTMLTextAreaElement::maxLengthAttributeChanged): (WebCore::HTMLTextAreaElement::minLengthAttributeChanged): * html/ImageInputType.cpp: (WebCore::ImageInputType::height): (WebCore::ImageInputType::width): * html/InputType.cpp: (WebCore::InputType::findClosestTickMarkValue): * html/InputType.h: * html/LinkIconCollector.cpp: * html/LinkRelAttribute.h: * html/RangeInputType.cpp: (WebCore::RangeInputType::findClosestTickMarkValue): * html/RangeInputType.h: * html/canvas/CanvasRenderingContext2D.cpp: (WebCore::CanvasRenderingContext2D::restore): (WebCore::CanvasRenderingContext2D::setStrokeColor): (WebCore::CanvasRenderingContext2D::setFillColor): (WebCore::CanvasRenderingContext2D::isPointInPathInternal): (WebCore::CanvasRenderingContext2D::isPointInStrokeInternal): (WebCore::CanvasRenderingContext2D::setShadow): (WebCore::CanvasRenderingContext2D::fillText): (WebCore::CanvasRenderingContext2D::strokeText): (WebCore::CanvasRenderingContext2D::drawTextInternal): * html/canvas/CanvasRenderingContext2D.h: * html/canvas/WebGL2RenderingContext.cpp: (WebCore::arrayBufferViewElementSize): * html/canvas/WebGLRenderingContextBase.cpp: (WebCore::WebGLRenderingContextBase::bufferData): (WebCore::WebGLRenderingContextBase::bufferSubData): (WebCore::WebGLRenderingContextBase::texSubImage2D): (WebCore::WebGLRenderingContextBase::validateArrayBufferType): (WebCore::WebGLRenderingContextBase::validateTexFuncData): (WebCore::WebGLRenderingContextBase::texImage2D): * html/canvas/WebGLRenderingContextBase.h: * html/parser/HTMLConstructionSite.cpp: (WebCore::HTMLConstructionSite::indexOfFirstUnopenFormattingElement): (WebCore::HTMLConstructionSite::reconstructTheActiveFormattingElements): * html/parser/HTMLConstructionSite.h: * html/parser/HTMLParserIdioms.cpp: (WebCore::parseHTMLIntegerInternal): (WebCore::parseHTMLInteger): (WebCore::parseHTMLNonNegativeInteger): (WebCore::parseValidHTMLNonNegativeIntegerInternal): (WebCore::parseValidHTMLNonNegativeInteger): (WebCore::parseValidHTMLFloatingPointNumberInternal): (WebCore::parseValidHTMLFloatingPointNumber): (WebCore::parseHTTPRefreshInternal): * html/parser/HTMLParserIdioms.h: (WebCore::limitToOnlyHTMLNonNegative): * html/parser/HTMLSrcsetParser.cpp: (WebCore::parseDescriptors): * html/shadow/SliderThumbElement.cpp: (WebCore::SliderThumbElement::setPositionFromPoint): (WebCore::SliderThumbElement::resolveCustomStyle): (WebCore::SliderContainerElement::resolveCustomStyle): * html/shadow/SliderThumbElement.h: * html/shadow/TextControlInnerElements.cpp: (WebCore::TextControlInnerElement::resolveCustomStyle): (WebCore::TextControlInnerTextElement::resolveCustomStyle): (WebCore::TextControlPlaceholderElement::resolveCustomStyle): * html/shadow/TextControlInnerElements.h: * html/track/TrackEvent.h: * inspector/InspectorIndexedDBAgent.cpp: * inspector/InspectorInstrumentation.cpp: (WebCore::InspectorInstrumentation::didFinishXHRLoadingImpl): * inspector/InspectorInstrumentation.h: (WebCore::InspectorInstrumentation::didFinishXHRLoading): * inspector/InspectorStyleSheet.cpp: (WebCore::InspectorStyleSheet::addRule): * inspector/InspectorTimelineAgent.cpp: (WebCore::InspectorTimelineAgent::setInstruments): * loader/DocumentLoader.cpp: (WebCore::DocumentLoader::startIconLoading): * loader/DocumentThreadableLoader.cpp: (WebCore::DocumentThreadableLoader::makeCrossOriginAccessRequestWithPreflight): (WebCore::DocumentThreadableLoader::clearResource): (WebCore::DocumentThreadableLoader::preflightSuccess): (WebCore::DocumentThreadableLoader::preflightFailure): * loader/DocumentThreadableLoader.h: * loader/EmptyClients.cpp: * loader/EmptyClients.h: * loader/FrameLoader.cpp: (WebCore::FrameLoader::urlSelected): (WebCore::FrameLoader::receivedFirstData): (WebCore::FrameLoader::commitProvisionalLoad): (WebCore::FrameLoader::open): (WebCore::FrameLoader::dispatchDidCommitLoad): (WebCore::FrameLoader::clearTestingOverrides): * loader/FrameLoader.h: * loader/FrameLoaderClient.h: * loader/LinkLoader.cpp: (WebCore::LinkLoader::resourceTypeFromAsAttribute): (WebCore::LinkLoader::loadLink): * loader/LinkLoader.h: * loader/SubresourceLoader.cpp: (WebCore::SubresourceLoader::SubresourceLoader): (WebCore::SubresourceLoader::didReceiveResponse): (WebCore::SubresourceLoader::notifyDone): * loader/SubresourceLoader.h: * loader/cache/CachedResource.cpp: (WebCore::CachedResource::setLoadPriority): * loader/cache/CachedResource.h: * loader/cache/CachedResourceRequest.cpp: (WebCore::CachedResourceRequest::CachedResourceRequest): * loader/cache/CachedResourceRequest.h: (WebCore::CachedResourceRequest::priority): * mathml/MathMLElement.h: (WebCore::MathMLElement::specifiedDisplayStyle): (WebCore::MathMLElement::specifiedMathVariant): * mathml/MathMLFractionElement.cpp: (WebCore::MathMLFractionElement::cachedFractionAlignment): (WebCore::MathMLFractionElement::parseAttribute): * mathml/MathMLFractionElement.h: * mathml/MathMLMathElement.cpp: (WebCore::MathMLMathElement::specifiedDisplayStyle): (WebCore::MathMLMathElement::parseAttribute): * mathml/MathMLMathElement.h: * mathml/MathMLMencloseElement.cpp: (WebCore::MathMLMencloseElement::parseAttribute): * mathml/MathMLMencloseElement.h: * mathml/MathMLOperatorDictionary.cpp: (WebCore::MathMLOperatorDictionary::search): * mathml/MathMLOperatorDictionary.h: * mathml/MathMLOperatorElement.cpp: (WebCore::MathMLOperatorElement::computeOperatorFlag): (WebCore::MathMLOperatorElement::childrenChanged): (WebCore::attributeNameToPropertyFlag): (WebCore::MathMLOperatorElement::parseAttribute): * mathml/MathMLOperatorElement.h: * mathml/MathMLPaddedElement.cpp: (WebCore::MathMLPaddedElement::parseAttribute): * mathml/MathMLPaddedElement.h: * mathml/MathMLPresentationElement.cpp: (WebCore::MathMLPresentationElement::cachedBooleanAttribute): (WebCore::MathMLPresentationElement::cachedMathMLLength): (WebCore::MathMLPresentationElement::specifiedDisplayStyle): (WebCore::MathMLPresentationElement::specifiedMathVariant): (WebCore::MathMLPresentationElement::parseAttribute): * mathml/MathMLPresentationElement.h: (WebCore::MathMLPresentationElement::toOptionalBool): * mathml/MathMLScriptsElement.cpp: (WebCore::MathMLScriptsElement::parseAttribute): * mathml/MathMLScriptsElement.h: * mathml/MathMLSpaceElement.cpp: (WebCore::MathMLSpaceElement::parseAttribute): * mathml/MathMLSpaceElement.h: * mathml/MathMLTokenElement.cpp: (WebCore::MathMLTokenElement::convertToSingleCodePoint): * mathml/MathMLTokenElement.h: * mathml/MathMLUnderOverElement.cpp: (WebCore::MathMLUnderOverElement::parseAttribute): * mathml/MathMLUnderOverElement.h: * page/ChromeClient.h: * page/DOMTimer.cpp: (WebCore::DOMTimer::alignedFireTime): * page/DOMTimer.h: * page/DOMWindow.cpp: (WebCore::DOMWindow::scrollBy): * page/DOMWindow.h: * page/EventSource.cpp: (WebCore::EventSource::parseEventStream): (WebCore::EventSource::parseEventStreamLine): * page/EventSource.h: * page/FrameView.cpp: (WebCore::FrameView::recalculateScrollbarOverlayStyle): (WebCore::FrameView::setLayoutViewportOverrideRect): (WebCore::FrameView::setViewExposedRect): * page/FrameView.h: * page/Page.cpp: (WebCore::Page::takeAnyMediaCanStartListener): * page/Page.h: (WebCore::Page::eventThrottlingBehaviorOverride): (WebCore::Page::setEventThrottlingBehaviorOverride): * page/ScrollToOptions.h: * page/SecurityOrigin.cpp: (WebCore::SecurityOrigin::SecurityOrigin): (WebCore::SecurityOrigin::create): * page/SecurityOrigin.h: (WebCore::SecurityOrigin::port): * page/SecurityOriginData.cpp: (WebCore::SecurityOriginData::debugString): (WebCore::SecurityOriginData::databaseIdentifier): (WebCore::SecurityOriginData::fromDatabaseIdentifier): * page/SecurityOriginData.h: (WebCore::SecurityOriginData::SecurityOriginData): (WebCore::SecurityOriginData::isEmpty): (WebCore::SecurityOriginDataHash::hash): * page/SecurityOriginHash.h: (WebCore::SecurityOriginHash::hash): * page/WindowFeatures.cpp: (WebCore::parseDialogFeatures): (WebCore::boolFeature): (WebCore::floatFeature): * page/WindowFeatures.h: * page/csp/ContentSecurityPolicySource.cpp: (WebCore::ContentSecurityPolicySource::ContentSecurityPolicySource): (WebCore::ContentSecurityPolicySource::portMatches): * page/csp/ContentSecurityPolicySource.h: * page/csp/ContentSecurityPolicySourceList.cpp: (WebCore::ContentSecurityPolicySourceList::parse): (WebCore::ContentSecurityPolicySourceList::parseSource): (WebCore::ContentSecurityPolicySourceList::parsePort): * page/csp/ContentSecurityPolicySourceList.h: * page/scrolling/AsyncScrollingCoordinator.cpp: (WebCore::AsyncScrollingCoordinator::requestScrollPositionUpdate): (WebCore::AsyncScrollingCoordinator::scheduleUpdateScrollPositionAfterAsyncScroll): (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll): (WebCore::AsyncScrollingCoordinator::reconcileScrollingState): * page/scrolling/AsyncScrollingCoordinator.h: (WebCore::AsyncScrollingCoordinator::ScheduledScrollUpdate::ScheduledScrollUpdate): * page/scrolling/ScrollingCoordinator.h: * page/scrolling/ScrollingTree.cpp: (WebCore::ScrollingTree::scrollPositionChangedViaDelegatedScrolling): * page/scrolling/ScrollingTree.h: * page/scrolling/ScrollingTreeScrollingNode.cpp: (WebCore::ScrollingTreeScrollingNode::setScrollPositionWithoutContentEdgeConstraints): * page/scrolling/ThreadedScrollingTree.cpp: (WebCore::ThreadedScrollingTree::scrollingTreeNodeDidScroll): * page/scrolling/ThreadedScrollingTree.h: * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.mm: (WebCore::ScrollingTreeFrameScrollingNodeIOS::setScrollPositionWithoutContentEdgeConstraints): * page/scrolling/ios/ScrollingTreeIOS.cpp: (WebCore::ScrollingTreeIOS::scrollingTreeNodeDidScroll): * page/scrolling/ios/ScrollingTreeIOS.h: * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm: (WebCore::ScrollingTreeFrameScrollingNodeMac::setScrollPositionWithoutContentEdgeConstraints): * platform/DragImage.cpp: * platform/LinkIcon.h: * platform/MemoryPressureHandler.h: * platform/ScrollView.cpp: (WebCore::ScrollView::handleDeferredScrollUpdateAfterContentSizeChange): * platform/ScrollView.h: * platform/Theme.h: (WebCore::Theme::controlFont): * platform/Timer.h: (WebCore::TimerBase::alignedFireTime): * platform/URL.cpp: (WebCore::URL::port): (WebCore::defaultPortForProtocol): (WebCore::portAllowed): * platform/URL.h: * platform/URLParser.cpp: (WebCore::URLParser::defaultPortForProtocol): (WebCore::findLongestZeroSequence): (WebCore::URLParser::parseIPv4Piece): (WebCore::URLParser::parseIPv4Host): (WebCore::URLParser::parseIPv4PieceInsideIPv6): (WebCore::URLParser::parseIPv4AddressInsideIPv6): (WebCore::URLParser::parseIPv6Host): (WebCore::URLParser::domainToASCII): (WebCore::URLParser::formURLDecode): * platform/URLParser.h: * platform/graphics/BitmapImage.h: * platform/graphics/Color.h: (WebCore::colorWithOverrideAlpha): * platform/graphics/DisplayRefreshMonitorClient.h: * platform/graphics/Font.h: * platform/graphics/FontCascade.cpp: (WebCore::FontCascade::drawText): (WebCore::FontCascade::drawEmphasisMarks): (WebCore::FontCascade::adjustSelectionRectForText): (WebCore::FontCascade::getEmphasisMarkGlyphData): (WebCore::FontCascade::emphasisMarkAscent): (WebCore::FontCascade::emphasisMarkDescent): (WebCore::FontCascade::emphasisMarkHeight): * platform/graphics/FontCascade.h: * platform/graphics/GraphicsContext.cpp: (WebCore::GraphicsContext::drawText): (WebCore::GraphicsContext::drawEmphasisMarks): (WebCore::GraphicsContext::drawBidiText): * platform/graphics/GraphicsContext.h: (WebCore::InterpolationQualityMaintainer::InterpolationQualityMaintainer): * platform/graphics/GraphicsLayer.h: (WebCore::GraphicsLayer::setPosition): (WebCore::GraphicsLayer::setApproximatePosition): * platform/graphics/Image.h: (WebCore::Image::hotSpot): * platform/graphics/ImageBuffer.h: * platform/graphics/ImageFrameCache.cpp: (WebCore::ImageFrameCache::clearMetadata): (WebCore::ImageFrameCache::metadata): (WebCore::ImageFrameCache::frameMetadataAtIndex): (WebCore::ImageFrameCache::hotSpot): * platform/graphics/ImageFrameCache.h: * platform/graphics/ImageSource.h: (WebCore::ImageSource::hotSpot): * platform/graphics/PathUtilities.cpp: (WebCore::rectFromPolygon): (WebCore::PathUtilities::pathWithShrinkWrappedRectsForOutline): * platform/graphics/ShadowBlur.cpp: (WebCore::ShadowBlur::calculateLayerBoundingRect): * platform/graphics/TiledBacking.h: * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm: (WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithVideoOutput): * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h: * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm: (WebCore::SourceBufferPrivateAVFObjC::flush): (WebCore::SourceBufferPrivateAVFObjC::naturalSize): * platform/graphics/ca/GraphicsLayerCA.cpp: (WebCore::GraphicsLayerCA::computeVisibleAndCoverageRect): * platform/graphics/ca/TileController.cpp: (WebCore::TileController::setLayoutViewportRect): * platform/graphics/ca/TileController.h: * platform/graphics/cairo/ImageBufferCairo.cpp: (WebCore::ImageBuffer::toDataURL): * platform/graphics/cg/ImageBufferCG.cpp: (WebCore::encodeImage): (WebCore::dataURL): (WebCore::ImageBuffer::toDataURL): * platform/graphics/cg/ImageDecoderCG.cpp: (WebCore::ImageDecoder::hotSpot): * platform/graphics/cg/ImageDecoderCG.h: * platform/graphics/cocoa/FontCocoa.mm: (WebCore::openTypeFeature): (WebCore::advanceForColorBitmapFont): * platform/graphics/displaylists/DisplayListItems.cpp: (WebCore::DisplayList::DrawGlyphs::localBounds): (WebCore::DisplayList::DrawLine::localBounds): (WebCore::DisplayList::DrawLinesForText::localBounds): (WebCore::DisplayList::DrawLineForDocumentMarker::localBounds): (WebCore::DisplayList::DrawFocusRingPath::localBounds): (WebCore::DisplayList::DrawFocusRingRects::localBounds): (WebCore::DisplayList::StrokeRect::localBounds): (WebCore::DisplayList::StrokePath::localBounds): (WebCore::DisplayList::StrokeEllipse::localBounds): * platform/graphics/displaylists/DisplayListItems.h: (WebCore::DisplayList::DrawingItem::localBounds): * platform/graphics/displaylists/DisplayListRecorder.cpp: (WebCore::DisplayList::Recorder::updateItemExtent): (WebCore::DisplayList::Recorder::ContextState::rotate): (WebCore::DisplayList::Recorder::ContextState::concatCTM): * platform/graphics/efl/ImageBufferEfl.cpp: (WebCore::encodeImageJPEG): (WebCore::ImageBuffer::toDataURL): * platform/graphics/filters/Filter.h: (WebCore::Filter::mapAbsolutePointToLocalPoint): * platform/graphics/gtk/ImageBufferGtk.cpp: (WebCore::encodeImage): (WebCore::ImageBuffer::toDataURL): * platform/graphics/harfbuzz/HarfBuzzShaper.cpp: (WebCore::HarfBuzzShaper::selectionRect): * platform/graphics/mac/ComplexTextController.cpp: (WebCore::capitalized): (WebCore::shouldSynthesize): * platform/graphics/texmap/TextureMapperLayer.cpp: (WebCore::TextureMapperLayer::paintSelfAndChildrenWithReplica): (WebCore::TextureMapperLayer::replicaTransform): (WebCore::TextureMapperLayer::mapScrollOffset): * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp: (WebCore::CoordinatedGraphicsLayer::transformedVisibleRect): (WebCore::CoordinatedGraphicsLayer::computeTransformedVisibleRect): * platform/graphics/transforms/AffineTransform.cpp: (WebCore::AffineTransform::inverse): * platform/graphics/transforms/AffineTransform.h: * platform/graphics/transforms/TransformState.cpp: (WebCore::TransformState::mappedPoint): (WebCore::TransformState::mappedSecondaryQuad): (WebCore::TransformState::mapQuad): (WebCore::TransformState::flattenWithTransform): * platform/graphics/transforms/TransformState.h: * platform/graphics/transforms/TransformationMatrix.cpp: (WebCore::TransformationMatrix::inverse): * platform/graphics/transforms/TransformationMatrix.h: * platform/graphics/win/ImageBufferDirect2D.cpp: (WebCore::ImageBuffer::toDataURL): * platform/graphics/win/ImageDecoderDirect2D.cpp: (WebCore::ImageDecoder::hotSpot): * platform/graphics/win/ImageDecoderDirect2D.h: * platform/graphics/x11/PlatformDisplayX11.cpp: (WebCore::PlatformDisplayX11::supportsXDamage): * platform/graphics/x11/PlatformDisplayX11.h: * platform/image-decoders/ImageDecoder.h: (WebCore::ImageDecoder::hotSpot): * platform/image-decoders/ico/ICOImageDecoder.cpp: (WebCore::ICOImageDecoder::hotSpot): (WebCore::ICOImageDecoder::hotSpotAtIndex): * platform/image-decoders/ico/ICOImageDecoder.h: * platform/image-encoders/JPEGImageEncoder.cpp: (WebCore::compressRGBABigEndianToJPEG): * platform/image-encoders/JPEGImageEncoder.h: * platform/ios/LegacyTileCache.h: * platform/ios/LegacyTileCache.mm: (WebCore::LegacyTileCache::setOverrideVisibleRect): * platform/ios/LegacyTileLayer.mm: (-[LegacyTileHostLayer renderInContext:]): * platform/linux/MemoryPressureHandlerLinux.cpp: * platform/mac/ThemeMac.h: * platform/mac/ThemeMac.mm: (WebCore::ThemeMac::controlFont): * platform/mediastream/MediaConstraints.cpp: (WebCore::MediaTrackConstraintSetMap::set): * platform/mediastream/MediaConstraints.h: (WebCore::MediaTrackConstraintSetMap::width): (WebCore::MediaTrackConstraintSetMap::height): (WebCore::MediaTrackConstraintSetMap::sampleRate): (WebCore::MediaTrackConstraintSetMap::sampleSize): (WebCore::MediaTrackConstraintSetMap::aspectRatio): (WebCore::MediaTrackConstraintSetMap::frameRate): (WebCore::MediaTrackConstraintSetMap::volume): (WebCore::MediaTrackConstraintSetMap::echoCancellation): (WebCore::MediaTrackConstraintSetMap::facingMode): (WebCore::MediaTrackConstraintSetMap::deviceId): (WebCore::MediaTrackConstraintSetMap::groupId): * platform/mediastream/RealtimeMediaSource.cpp: (WebCore::RealtimeMediaSource::supportsSizeAndFrameRate): (WebCore::RealtimeMediaSource::applySizeAndFrameRate): (WebCore::RealtimeMediaSource::applyConstraints): * platform/mediastream/RealtimeMediaSource.h: * platform/mediastream/mac/AVVideoCaptureSource.h: * platform/mediastream/mac/AVVideoCaptureSource.mm: (WebCore::AVVideoCaptureSource::applySizeAndFrameRate): (WebCore::AVVideoCaptureSource::bestSessionPresetForVideoDimensions): (WebCore::AVVideoCaptureSource::supportsSizeAndFrameRate): * platform/mediastream/openwebrtc/MediaEndpointOwr.h: * platform/network/CacheValidation.cpp: (WebCore::computeCurrentAge): (WebCore::computeFreshnessLifetimeForHTTPFamily): * platform/network/CacheValidation.h: * platform/network/DataURLDecoder.h: * platform/network/HTTPHeaderMap.h: (WebCore::HTTPHeaderMap::HTTPHeaderMapConstIterator::updateKeyValue): * platform/network/HTTPParsers.cpp: (WebCore::parseHTTPDate): * platform/network/HTTPParsers.h: * platform/network/ResourceHandle.cpp: (WebCore::ResourceHandle::didReceiveResponse): * platform/network/ResourceResponseBase.cpp: (WebCore::ResourceResponseBase::cacheControlMaxAge): (WebCore::parseDateValueInHeader): (WebCore::ResourceResponseBase::date): (WebCore::ResourceResponseBase::age): (WebCore::ResourceResponseBase::expires): (WebCore::ResourceResponseBase::lastModified): * platform/network/ResourceResponseBase.h: (WebCore::ResourceResponseBase::certificateInfo): * platform/network/SocketStreamHandle.h: * platform/network/SocketStreamHandleClient.h: * platform/network/cf/SocketStreamHandleImpl.h: * platform/network/cf/SocketStreamHandleImplCFNet.cpp: (WebCore::SocketStreamHandleImpl::readStreamCallback): (WebCore::SocketStreamHandleImpl::platformSend): * platform/network/curl/SocketStreamHandleImpl.h: * platform/network/curl/SocketStreamHandleImplCurl.cpp: (WebCore::SocketStreamHandleImpl::platformSend): * platform/network/mac/CookieJarMac.mm: (WebCore::cookiesInPartitionForURL): * platform/network/soup/SocketStreamHandleImpl.h: * platform/network/soup/SocketStreamHandleImplSoup.cpp: (WebCore::SocketStreamHandleImpl::readBytes): (WebCore::SocketStreamHandleImpl::platformSend): * rendering/BreakLines.h: (WebCore::nextBreakablePositionNonLoosely): (WebCore::nextBreakablePositionLoosely): (WebCore::isBreakable): * rendering/HitTestingTransformState.cpp: (WebCore::HitTestingTransformState::flattenWithTransform): * rendering/ImageQualityController.cpp: (WebCore::ImageQualityController::interpolationQualityFromStyle): (WebCore::ImageQualityController::chooseInterpolationQuality): * rendering/ImageQualityController.h: * rendering/InlineIterator.h: (WebCore::InlineIterator::moveTo): (WebCore::InlineIterator::nextBreakablePosition): (WebCore::InlineIterator::setNextBreakablePosition): * rendering/InlineTextBox.cpp: (WebCore::InlineTextBox::paintSelection): (WebCore::InlineTextBox::substringToRender): (WebCore::InlineTextBox::hyphenatedStringForTextRun): (WebCore::InlineTextBox::constructTextRun): * rendering/InlineTextBox.h: (WebCore::InlineTextBox::substringToRender): (WebCore::InlineTextBox::hyphenatedStringForTextRun): (WebCore::InlineTextBox::constructTextRun): * rendering/OrderIterator.cpp: (WebCore::OrderIterator::reset): * rendering/OrderIterator.h: * rendering/PaintInfo.h: (WebCore::PaintInfo::applyTransform): * rendering/RenderBlock.cpp: (WebCore::RenderBlockRareData::RenderBlockRareData): (WebCore::RenderBlock::baselinePosition): (WebCore::RenderBlock::firstLineBaseline): (WebCore::RenderBlock::inlineBlockBaseline): (WebCore::RenderBlock::setCachedFlowThreadContainingBlockNeedsUpdate): * rendering/RenderBlock.h: * rendering/RenderBlockFlow.cpp: (WebCore::RenderBlockFlow::firstLineBaseline): (WebCore::RenderBlockFlow::inlineBlockBaseline): * rendering/RenderBlockFlow.h: * rendering/RenderBox.cpp: (WebCore::RenderBox::constrainLogicalHeightByMinMax): (WebCore::RenderBox::constrainContentBoxLogicalHeightByMinMax): (WebCore::RenderBox::overrideContainingBlockContentLogicalWidth): (WebCore::RenderBox::overrideContainingBlockContentLogicalHeight): (WebCore::RenderBox::setOverrideContainingBlockContentLogicalWidth): (WebCore::RenderBox::setOverrideContainingBlockContentLogicalHeight): (WebCore::RenderBox::adjustContentBoxLogicalHeightForBoxSizing): (WebCore::RenderBox::computeLogicalHeight): (WebCore::RenderBox::computeLogicalHeightUsing): (WebCore::RenderBox::computeContentLogicalHeight): (WebCore::RenderBox::computeIntrinsicLogicalContentHeightUsing): (WebCore::RenderBox::computeContentAndScrollbarLogicalHeightUsing): (WebCore::RenderBox::computePercentageLogicalHeight): (WebCore::RenderBox::computeReplacedLogicalHeightUsing): (WebCore::RenderBox::availableLogicalHeight): (WebCore::RenderBox::availableLogicalHeightUsing): * rendering/RenderBox.h: (WebCore::RenderBox::firstLineBaseline): (WebCore::RenderBox::inlineBlockBaseline): * rendering/RenderCombineText.cpp: (WebCore::RenderCombineText::computeTextOrigin): * rendering/RenderCombineText.h: * rendering/RenderDeprecatedFlexibleBox.cpp: (WebCore::RenderDeprecatedFlexibleBox::layoutHorizontalBox): * rendering/RenderFlexibleBox.cpp: (WebCore::RenderFlexibleBox::baselinePosition): (WebCore::RenderFlexibleBox::firstLineBaseline): (WebCore::RenderFlexibleBox::inlineBlockBaseline): (WebCore::RenderFlexibleBox::computeMainAxisExtentForChild): (WebCore::RenderFlexibleBox::preferredMainAxisContentExtentForChild): (WebCore::RenderFlexibleBox::marginBoxAscentForChild): (WebCore::RenderFlexibleBox::computeMainSizeFromAspectRatioUsing): (WebCore::RenderFlexibleBox::adjustChildSizeForAspectRatioCrossAxisMinAndMax): (WebCore::RenderFlexibleBox::adjustChildSizeForMinAndMax): * rendering/RenderFlexibleBox.h: * rendering/RenderFlowThread.cpp: (WebCore::RenderFlowThread::addForcedRegionBreak): * rendering/RenderGrid.cpp: (WebCore::GridTrack::setGrowthLimit): (WebCore::GridTrack::setGrowthLimitCap): (WebCore::GridTrack::growthLimitCap): (WebCore::RenderGrid::GridSizingData::freeSpace): (WebCore::RenderGrid::GridSizingData::availableSpace): (WebCore::RenderGrid::GridSizingData::setAvailableSpace): (WebCore::RenderGrid::GridSizingData::setFreeSpace): (WebCore::RenderGrid::layoutBlock): (WebCore::RenderGrid::computeIntrinsicLogicalWidths): (WebCore::RenderGrid::computeIntrinsicLogicalHeight): (WebCore::RenderGrid::computeIntrinsicLogicalContentHeightUsing): (WebCore::RenderGrid::computeUsedBreadthOfGridTracks): (WebCore::overrideContainingBlockContentSizeForChild): (WebCore::setOverrideContainingBlockContentSizeForChild): (WebCore::RenderGrid::logicalHeightForChild): (WebCore::RenderGrid::minSizeForChild): (WebCore::RenderGrid::minContentForChild): (WebCore::RenderGrid::maxContentForChild): (WebCore::RenderGrid::resolveContentBasedTrackSizingFunctionsForNonSpanningItems): (WebCore::sortByGridTrackGrowthPotential): (WebCore::RenderGrid::tracksAreWiderThanMinTrackBreadth): (WebCore::RenderGrid::computeAutoRepeatTracksCount): (WebCore::RenderGrid::applyStretchAlignmentToTracksIfNeeded): (WebCore::RenderGrid::layoutGridItems): * rendering/RenderGrid.h: * rendering/RenderLayer.cpp: (WebCore::RenderLayer::paintLayerByApplyingTransform): (WebCore::RenderLayer::hitTestLayer): * rendering/RenderLayerBacking.cpp: * rendering/RenderListBox.cpp: (WebCore::RenderListBox::paintItem): (WebCore::RenderListBox::listIndexIsVisible): (WebCore::RenderListBox::computeFirstIndexesVisibleInPaddingTopBottomAreas): * rendering/RenderListBox.h: * rendering/RenderMenuList.h: * rendering/RenderMultiColumnSet.cpp: (WebCore::RenderMultiColumnSet::calculateMaxColumnHeight): * rendering/RenderTable.cpp: (WebCore::RenderTable::convertStyleLogicalHeightToComputedHeight): (WebCore::RenderTable::baselinePosition): (WebCore::RenderTable::inlineBlockBaseline): (WebCore::RenderTable::firstLineBaseline): * rendering/RenderTable.h: * rendering/RenderTableCell.cpp: (WebCore::RenderTableCell::cellBaselinePosition): * rendering/RenderTableSection.cpp: (WebCore::RenderTableSection::firstLineBaseline): * rendering/RenderTableSection.h: * rendering/RenderText.cpp: (WebCore::RenderText::computePreferredLogicalWidths): (WebCore::RenderText::stringView): * rendering/RenderText.h: * rendering/RenderTextControl.h: * rendering/RenderView.cpp: (WebCore::RenderView::setSelection): (WebCore::RenderView::splitSelectionBetweenSubtrees): (WebCore::RenderView::getSelection): (WebCore::RenderView::clearSelection): * rendering/RenderView.h: * rendering/SelectionSubtreeRoot.h: (WebCore::SelectionSubtreeRoot::SelectionSubtreeData::SelectionSubtreeData): (WebCore::SelectionSubtreeRoot::SelectionSubtreeData::selectionStartPos): (WebCore::SelectionSubtreeRoot::SelectionSubtreeData::selectionEndPos): (WebCore::SelectionSubtreeRoot::SelectionSubtreeData::setSelectionStartPos): (WebCore::SelectionSubtreeRoot::SelectionSubtreeData::setSelectionEndPos): (WebCore::SelectionSubtreeRoot::SelectionSubtreeData::clearSelection): * rendering/SimpleLineLayout.cpp: (WebCore::SimpleLineLayout::LineState::lastFragment): (WebCore::SimpleLineLayout::closeLineEndingAndAdjustRuns): (WebCore::SimpleLineLayout::createTextRuns): * rendering/SimpleLineLayoutFunctions.cpp: (WebCore::SimpleLineLayout::paintFlow): * rendering/line/BreakingContext.h: (WebCore::WordTrailingSpace::width): (WebCore::BreakingContext::commitLineBreakAtCurrentWidth): (WebCore::BreakingContext::InlineIteratorHistory::nextBreakablePosition): (WebCore::BreakingContext::InlineIteratorHistory::moveTo): (WebCore::tryHyphenating): (WebCore::BreakingContext::computeAdditionalBetweenWordsWidth): (WebCore::BreakingContext::handleText): (WebCore::BreakingContext::optimalLineBreakLocationForTrailingWord): * rendering/mathml/MathMLStyle.cpp: (WebCore::MathMLStyle::resolveMathMLStyle): * rendering/mathml/RenderMathMLBlock.cpp: (WebCore::RenderMathMLBlock::baselinePosition): (WebCore::RenderMathMLTable::firstLineBaseline): * rendering/mathml/RenderMathMLBlock.h: (WebCore::RenderMathMLBlock::ascentForChild): * rendering/mathml/RenderMathMLFraction.cpp: (WebCore::RenderMathMLFraction::firstLineBaseline): * rendering/mathml/RenderMathMLFraction.h: * rendering/mathml/RenderMathMLOperator.cpp: (WebCore::RenderMathMLOperator::firstLineBaseline): * rendering/mathml/RenderMathMLOperator.h: * rendering/mathml/RenderMathMLPadded.cpp: (WebCore::RenderMathMLPadded::firstLineBaseline): * rendering/mathml/RenderMathMLPadded.h: * rendering/mathml/RenderMathMLRow.cpp: (WebCore::RenderMathMLRow::firstLineBaseline): * rendering/mathml/RenderMathMLRow.h: * rendering/mathml/RenderMathMLScripts.cpp: (WebCore::RenderMathMLScripts::validateAndGetReferenceChildren): (WebCore::RenderMathMLScripts::firstLineBaseline): * rendering/mathml/RenderMathMLScripts.h: * rendering/mathml/RenderMathMLSpace.cpp: (WebCore::RenderMathMLSpace::firstLineBaseline): * rendering/mathml/RenderMathMLSpace.h: * rendering/mathml/RenderMathMLToken.cpp: (WebCore::RenderMathMLToken::updateMathVariantGlyph): (WebCore::RenderMathMLToken::firstLineBaseline): * rendering/mathml/RenderMathMLToken.h: * rendering/svg/RenderSVGContainer.cpp: (WebCore::RenderSVGContainer::nodeAtFloatPoint): * rendering/svg/RenderSVGForeignObject.cpp: (WebCore::RenderSVGForeignObject::nodeAtFloatPoint): * rendering/svg/RenderSVGImage.cpp: (WebCore::RenderSVGImage::nodeAtFloatPoint): * rendering/svg/RenderSVGResourceClipper.cpp: (WebCore::RenderSVGResourceClipper::hitTestClipContent): * rendering/svg/RenderSVGResourceFilter.cpp: (WebCore::RenderSVGResourceFilter::postApplyResource): * rendering/svg/RenderSVGRoot.cpp: (WebCore::RenderSVGRoot::nodeAtPoint): * rendering/svg/RenderSVGShape.cpp: (WebCore::RenderSVGShape::setupNonScalingStrokeContext): (WebCore::RenderSVGShape::nodeAtFloatPoint): (WebCore::RenderSVGShape::calculateStrokeBoundingBox): * rendering/svg/RenderSVGText.cpp: (WebCore::RenderSVGText::nodeAtFloatPoint): * rendering/svg/SVGRenderSupport.cpp: (WebCore::SVGRenderSupport::intersectRepaintRectWithShadows): * rendering/svg/SVGRenderingContext.cpp: (WebCore::SVGRenderingContext::clipToImageBuffer): * rendering/svg/SVGTextQuery.cpp: (WebCore::SVGTextQuery::modifyStartEndPositionsRespectingLigatures): * style/RenderTreeUpdater.cpp: (WebCore::RenderTreeUpdater::Parent::Parent): * style/RenderTreeUpdater.h: * style/StyleScope.h: * svg/SVGElement.cpp: (WebCore::SVGElement::parseAttribute): (WebCore::SVGElement::resolveCustomStyle): * svg/SVGElement.h: * svg/SVGToOTFFontConversion.cpp: (WebCore::SVGToOTFFontConverter::transcodeGlyphPaths): (WebCore::SVGToOTFFontConverter::processGlyphElement): (WebCore::SVGToOTFFontConverter::SVGToOTFFontConverter): (WebCore::convertSVGToOTFFont): * svg/SVGToOTFFontConversion.h: * testing/Internals.cpp: (WebCore::Internals::setEventThrottlingBehaviorOverride): (WebCore::Internals::eventThrottlingBehaviorOverride): * testing/Internals.h: * workers/Worker.h: * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::prepareToSend): (WebCore::XMLHttpRequest::didFinishLoading): * xml/XMLHttpRequest.h: Source/WebKit/mac: Use WTF::Optional::value_or. * DOM/DOMHTMLOptionsCollection.mm: (-[DOMHTMLOptionsCollection add:index:]): * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::evaluate): * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView sendEvent:isDrawRect:]): * WebCoreSupport/WebFrameLoaderClient.h: * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::dispatchDidCommitLoad): * WebCoreSupport/WebPaymentCoordinatorClient.h: * WebCoreSupport/WebPaymentCoordinatorClient.mm: (WebPaymentCoordinatorClient::completeShippingMethodSelection): (WebPaymentCoordinatorClient::completeShippingContactSelection): (WebPaymentCoordinatorClient::completePaymentMethodSelection): * WebCoreSupport/WebSecurityOrigin.mm: (-[WebSecurityOrigin port]): * WebView/WebHTMLView.mm: (toAction): (toTag): Source/WebKit/win: Use WTF::Optional::value_or. * Plugins/PluginView.cpp: (WebCore::PluginView::performRequest): * WebCoreSupport/WebFrameLoaderClient.cpp: (WebFrameLoaderClient::dispatchDidCommitLoad): * WebCoreSupport/WebFrameLoaderClient.h: * WebSecurityOrigin.cpp: (WebSecurityOrigin::port): Source/WebKit2: * NetworkProcess/NetworkDataTask.cpp: (WebKit::NetworkDataTask::didReceiveResponse): * NetworkProcess/NetworkLoad.h: * NetworkProcess/cache/NetworkCache.cpp: (WebKit::NetworkCache::responseHasExpired): * NetworkProcess/cache/NetworkCacheCoders.h: (WebKit::NetworkCache::Coder<std::optional<T>>::encode): (WebKit::NetworkCache::Coder<std::optional<T>>::decode): (WebKit::NetworkCache::Coder<Optional<T>>::encode): Deleted. (WebKit::NetworkCache::Coder<Optional<T>>::decode): Deleted. * NetworkProcess/cache/NetworkCacheData.cpp: (WebKit::NetworkCache::readOrMakeSalt): * NetworkProcess/cache/NetworkCacheData.h: * NetworkProcess/cache/NetworkCacheSpeculativeLoadManager.cpp: (WebKit::NetworkCache::SpeculativeLoadManager::PreloadedEntry::PreloadedEntry): (WebKit::NetworkCache::SpeculativeLoadManager::PreloadedEntry::revalidationRequest): (WebKit::NetworkCache::SpeculativeLoadManager::addPreloadedEntry): * NetworkProcess/cache/NetworkCacheSpeculativeLoadManager.h: * NetworkProcess/cache/NetworkCacheStatistics.cpp: (WebKit::NetworkCache::Statistics::recordNotUsingCacheForRequest): (WebKit::NetworkCache::Statistics::recordRetrievalFailure): (WebKit::NetworkCache::Statistics::queryWasEverRequested): * NetworkProcess/cache/NetworkCacheStatistics.h: * NetworkProcess/cache/NetworkCacheStorage.cpp: (WebKit::NetworkCache::Storage::storeBodyAsBlob): (WebKit::NetworkCache::Storage::encodeRecord): (WebKit::NetworkCache::Storage::dispatchWriteOperation): * NetworkProcess/cache/NetworkCacheStorage.h: * Platform/IPC/ArgumentCoders.h: (IPC::ArgumentCoder<std::optional<T>>::encode): (IPC::ArgumentCoder<std::optional<T>>::decode): (IPC::ArgumentCoder<WTF::Optional<T>>::encode): Deleted. (IPC::ArgumentCoder<WTF::Optional<T>>::decode): Deleted. * Platform/IPC/Connection.h: (IPC::Connection::sendWithReply): * Platform/SharedMemory.h: * Platform/unix/SharedMemoryUnix.cpp: (WebKit::SharedMemory::map): * Scripts/webkit/messages.py: (class_template_headers): * Shared/API/APISecurityOrigin.h: (API::SecurityOrigin::create): * Shared/API/Cocoa/_WKRemoteObjectInterface.mm: * Shared/API/c/WKSecurityOriginRef.cpp: (WKSecurityOriginGetPort): * Shared/SessionState.h: * Shared/WebPageCreationParameters.h: * Shared/mac/ObjCObjectGraph.mm: (WebKit::typeFromObject): * Shared/mac/SecItemShim.cpp: (WebKit::sendSecItemRequest): * UIProcess/API/C/WKKeyValueStorageManager.cpp: (WKKeyValueStorageManagerGetStorageDetailsByOrigin): * UIProcess/API/Cocoa/WKSecurityOrigin.mm: (-[WKSecurityOrigin port]): * UIProcess/API/Cocoa/WKWebView.mm: (-[WKWebView _didCommitLayerTree:]): (-[WKWebView _navigationGestureDidEnd]): * UIProcess/API/Cocoa/WKWebsiteDataRecordInternal.h: (WebKit::toWebsiteDataType): * UIProcess/API/efl/EwkView.cpp: (EwkView::setCursor): * UIProcess/API/mac/WKView.mm: (toCoreScrollbarStyle): (toAPIScrollbarStyle): * UIProcess/ApplePay/WebPaymentCoordinatorProxy.cpp: (WebKit::WebPaymentCoordinatorProxy::completeShippingMethodSelection): (WebKit::WebPaymentCoordinatorProxy::completeShippingContactSelection): (WebKit::WebPaymentCoordinatorProxy::completePaymentMethodSelection): * UIProcess/ApplePay/WebPaymentCoordinatorProxy.h: * UIProcess/ApplePay/WebPaymentCoordinatorProxy.messages.in: * UIProcess/ApplePay/cocoa/WebPaymentCoordinatorProxyCocoa.mm: (WebKit::toPKPaymentSummaryItem): (WebKit::WebPaymentCoordinatorProxy::platformCompleteShippingMethodSelection): (WebKit::WebPaymentCoordinatorProxy::platformCompleteShippingContactSelection): (WebKit::WebPaymentCoordinatorProxy::platformCompletePaymentMethodSelection): * UIProcess/Automation/WebAutomationSession.cpp: (WebKit::WebAutomationSession::webFrameIDForHandle): (WebKit::WebAutomationSession::switchToBrowsingContext): (WebKit::WebAutomationSession::evaluateJavaScriptFunction): (WebKit::WebAutomationSession::resolveChildFrameHandle): (WebKit::WebAutomationSession::resolveParentFrameHandle): (WebKit::WebAutomationSession::computeElementLayout): * UIProcess/Automation/WebAutomationSession.h: * UIProcess/Cocoa/WebViewImpl.h: * UIProcess/Cocoa/WebViewImpl.mm: (WebKit::WebViewImpl::updateViewExposedRect): (WebKit::WebViewImpl::setOverlayScrollbarStyle): (WebKit::WebViewImpl::overlayScrollbarStyle): * UIProcess/DrawingAreaProxy.cpp: (WebKit::DrawingAreaProxy::setViewExposedRect): * UIProcess/DrawingAreaProxy.h: (WebKit::DrawingAreaProxy::viewExposedRect): * UIProcess/InspectorServer/WebSocketServerConnection.cpp: (WebKit::WebSocketServerConnection::didReceiveSocketStreamData): * UIProcess/InspectorServer/WebSocketServerConnection.h: * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.cpp: (WebKit::RemoteScrollingCoordinatorProxy::scrollingTreeNodeDidScroll): * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.h: * UIProcess/Scrolling/RemoteScrollingTree.cpp: (WebKit::RemoteScrollingTree::scrollingTreeNodeDidScroll): * UIProcess/Scrolling/RemoteScrollingTree.h: * UIProcess/Storage/LocalStorageDatabaseTracker.cpp: (WebKit::fileCreationTime): (WebKit::fileModificationTime): * UIProcess/Storage/LocalStorageDatabaseTracker.h: * UIProcess/UserMediaPermissionRequestManagerProxy.cpp: (WebKit::UserMediaPermissionRequestManagerProxy::enumerateMediaDevicesForFrame): * UIProcess/WebBackForwardList.cpp: (WebKit::WebBackForwardList::backForwardListState): (WebKit::WebBackForwardList::restoreFromState): * UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::didCommitLoadForFrame): (WebKit::WebPageProxy::creationParameters): (WebKit::WebPageProxy::setOverlayScrollbarStyle): * UIProcess/WebPageProxy.h: (WebKit::WebPageProxy::overlayScrollbarStyle): * UIProcess/WebPageProxy.messages.in: * UIProcess/WebsiteData/WebsiteDataRecord.h: * UIProcess/efl/WebView.cpp: (WebKit::WebView::transformFromScene): * UIProcess/gtk/AcceleratedBackingStoreX11.cpp: * UIProcess/gtk/WebPreferencesGtk.cpp: (WebKit::WebPreferences::platformInitializeStore): * UIProcess/ios/WKContentViewInteraction.mm: (-[WKContentView _scrollOffsetForEvent:]): (-[WKContentView _interpretKeyEvent:isCharEvent:]): * UIProcess/mac/LegacySessionStateCoding.cpp: (WebKit::encodeFormDataElement): (WebKit::decodeFormDataElement): (WebKit::decodeV1SessionHistory): * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.h: * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm: (WebKit::RemoteLayerTreeDrawingAreaProxy::setViewExposedRect): * WebProcess/ApplePay/WebPaymentCoordinator.cpp: (WebKit::WebPaymentCoordinator::completeShippingMethodSelection): (WebKit::WebPaymentCoordinator::completeShippingContactSelection): (WebKit::WebPaymentCoordinator::completePaymentMethodSelection): * WebProcess/ApplePay/WebPaymentCoordinator.h: * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp: (WKBundlePageSetEventThrottlingBehaviorOverride): * WebProcess/Plugins/PDF/DeprecatedPDFPlugin.mm: (WebKit::PDFPlugin::convertFromPDFViewToRootView): (WebKit::PDFPlugin::convertFromPDFViewToScreen): (WebKit::PDFPlugin::boundsOnScreen): (WebKit::PDFPlugin::geometryDidChange): * WebProcess/Plugins/PDF/PDFPlugin.mm: (WebKit::PDFPlugin::geometryDidChange): * WebProcess/Plugins/PluginView.cpp: (WebKit::PluginView::performFrameLoadURLRequest): (WebKit::PluginView::evaluate): * WebProcess/Plugins/WebPluginInfoProvider.cpp: (WebKit::WebPluginInfoProvider::pluginLoadClientPolicyForHost): * WebProcess/Plugins/WebPluginInfoProvider.h: * WebProcess/Scrolling/RemoteScrollingCoordinator.mm: (WebKit::RemoteScrollingCoordinator::scrollPositionChangedForNode): * WebProcess/WebCoreSupport/SessionStateConversion.cpp: (WebKit::toFormData): * WebProcess/WebCoreSupport/WebChromeClient.cpp: (WebKit::WebChromeClient::preferredScrollbarOverlayStyle): * WebProcess/WebCoreSupport/WebChromeClient.h: * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp: (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad): * WebProcess/WebCoreSupport/WebFrameLoaderClient.h: * WebProcess/WebPage/DrawingArea.h: * WebProcess/WebPage/DrawingArea.messages.in: * WebProcess/WebPage/WebFrame.cpp: (WebKit::WebFrame::certificateInfo): * WebProcess/WebPage/WebPage.cpp: (WebKit::m_userInterfaceLayoutDirection): (WebKit::WebPage::setScrollbarOverlayStyle): * WebProcess/WebPage/WebPage.h: (WebKit::WebPage::scrollbarOverlayStyle): * WebProcess/WebPage/WebPage.messages.in: * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h: * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm: (WebKit::RemoteLayerTreeDrawingArea::setViewExposedRect): * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h: * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm: (WebKit::TiledCoreAnimationDrawingArea::setViewExposedRect): Source/WTF: Import std::optional reference implementation offered by the C++17 original proposal paper. It has the same interface and functionality to the C++17's one. Previous WTF::Optional lacks several functionalities. The largest one is the correct constexpr constructors. This fact prevents us from using Optional<literal type> in constexpr context in WebKit. In WebKit, we do not allow global constructors. So only the constexpr constructor is the way to use WTF::Optional in the static const global variables. WTF::Optional is used in DOMJIT::Effect and we would like to emit static const global variables that includes this DOMJIT::Effect. That is the main motivation of this work. This functionality allows the IDL code generator to emit DOMJIT signatures as static const global variables. We import the reference implementation one instead of LLVM libc++'s one. This is because LLVM libc++'s one depends on many macro and type_traits offered by libc++ implementation. And adopting it to WebKit requires large modification compared to this reference implementation one. Furthermore, it is difficult to compile libc++'s optional in old GCC and VC++. It also requires some more modifications. To keep the thing simple, we import the reference implementation one now. Once C++17 is released and we update the compiler baseline, we can smoothly switch to the standard library's std::optional. We also add support for the environment that does not use exceptions to this reference implementation. And we also add valueOrCompute helper function. That keeps the extended functionality that previous WTF::Optional has. * wtf/CrossThreadQueue.h: (WTF::CrossThreadQueue<DataType>::tryGetMessage): * wtf/Expected.h: (WTF::makeExpected): * wtf/Forward.h: * wtf/HashTraits.h: (WTF::HashTraits<Ref<P>>::take): * wtf/MainThread.cpp: (WTF::initializeGCThreads): (WTF::mayBeGCThread): * wtf/MainThread.h: * wtf/Optional.h: (std::detail_::is_assignable::has_assign): (std::detail_::has_overloaded_addressof::has_overload): (std::detail_::static_addressof): (std::detail_::convert): (std::nullopt_t::nullopt_t): (std::bad_optional_access::bad_optional_access): (std::optional_base::optional_base): (std::optional_base::~optional_base): (std::constexpr_optional_base::constexpr_optional_base): (std::optional::dataptr): (std::optional::contained_val): (std::optional::__NOEXCEPT_): (std::optional::optional): (std::optional::operator=): (std::optional::emplace): (std::optional::operator ->): (std::optional::operator *): (std::optional::value): (std::optional::value_or): (std::operator==): (std::operator!=): (std::operator<): (std::operator>): (std::operator<=): (std::operator>=): (std::__NOEXCEPT_): (std::make_optional): (std::hash<std::optional<T>>::operator()): (WTF::NulloptTag::NulloptTag): Deleted. (WTF::Optional::Optional): Deleted. (WTF::Optional::~Optional): Deleted. (WTF::Optional::operator=): Deleted. (WTF::Optional::operator bool): Deleted. (WTF::Optional::operator->): Deleted. (WTF::Optional::operator*): Deleted. (WTF::Optional::value): Deleted. (WTF::Optional::valueOr): Deleted. (WTF::Optional::valueOrCompute): Deleted. (WTF::Optional::asPtr): Deleted. (WTF::Optional::destroy): Deleted. (WTF::operator==): Deleted. (WTF::operator!=): Deleted. (WTF::makeOptional): Deleted. (WTF::printInternal): Deleted. * wtf/text/StringView.cpp: (WTF::StringView::GraphemeClusters::Iterator::Impl::Impl): (WTF::StringView::GraphemeClusters::Iterator::Iterator): * wtf/text/StringView.h: Tools: Use WTF::Optional::value_or. * DumpRenderTree/ios/UIScriptControllerIOS.mm: (WTR::UIScriptController::stableStateOverride): (WTR::UIScriptController::setStableStateOverride): * TestRunnerShared/Bindings/JSWrappable.h: (WTR::JSValueMakeBooleanOrNull): (WTR::JSValueToNullableBoolean): * TestRunnerShared/UIScriptContext/UIScriptController.cpp: (WTR::UIScriptController::stableStateOverride): (WTR::UIScriptController::setStableStateOverride): * TestRunnerShared/UIScriptContext/UIScriptController.h: * TestWebKitAPI/Tests/WTF/Optional.cpp: (TestWebKitAPI::TEST): * TestWebKitAPI/Tests/WebCore/HTMLParserIdioms.cpp: (TestWebKitAPI::testParseHTMLInteger): (TestWebKitAPI::testParseHTMLNonNegativeInteger): * TestWebKitAPI/Tests/WebCore/URLParser.cpp: (TestWebKitAPI::checkURL): (TestWebKitAPI::checkRelativeURL): (TestWebKitAPI::checkURLDifferences): (TestWebKitAPI::checkRelativeURLDifferences): * WebKitTestRunner/ios/UIScriptControllerIOS.mm: (WTR::UIScriptController::stableStateOverride): (WTR::UIScriptController::setStableStateOverride): Canonical link: https://commits.webkit.org/182693@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@208985 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-11-27 06:08:16 +00:00
Remove WTF::Optional synonym for std::optional, using that class template directly instead https://bugs.webkit.org/show_bug.cgi?id=226433 Reviewed by Chris Dumez. Source/JavaScriptCore: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. * inspector/scripts/codegen/generate_objc_protocol_types_implementation.py: (ObjCProtocolTypesImplementationGenerator._generate_init_method_for_payload): Use auto instead of Optional<>. Also use * instead of value() and nest the definition of the local inside an if statement in the case where it's an optional. * inspector/scripts/tests/expected/*: Regenerated these results. Source/WebCore: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebCore/PAL: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebDriver: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebKit: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. * Scripts/webkit/tests: Regenerated expected results, by running the command "python Scripts/webkit/messages_unittest.py -r". (How am I supposed to know to do that?) Source/WebKitLegacy/ios: * WebCoreSupport/WebChromeClientIOS.h: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebKitLegacy/mac: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebKitLegacy/win: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WTF: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. * wtf/Optional.h: Remove WTF::Optional. Tools: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Canonical link: https://commits.webkit.org/238290@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@278253 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2021-05-30 16:11:40 +00:00
std::optional<bool> ext;
[WTF] Import std::optional reference implementation as WTF::Optional https://bugs.webkit.org/show_bug.cgi?id=164199 Reviewed by Saam Barati and Sam Weinig. Source/JavaScriptCore: Previous WTF::Optional::operator= is not compatible to std::optional::operator=. std::optional::emplace has the same semantics to the previous one. So we change the code to use it. * Scripts/builtins/builtins_templates.py: * Scripts/tests/builtins/expected/JavaScriptCore-Builtin.Promise-Combined.js-result: * Scripts/tests/builtins/expected/JavaScriptCore-Builtin.Promise-Separate.js-result: * Scripts/tests/builtins/expected/JavaScriptCore-Builtin.prototype-Combined.js-result: * Scripts/tests/builtins/expected/JavaScriptCore-Builtin.prototype-Separate.js-result: * Scripts/tests/builtins/expected/JavaScriptCore-BuiltinConstructor-Combined.js-result: * Scripts/tests/builtins/expected/JavaScriptCore-BuiltinConstructor-Separate.js-result: * Scripts/tests/builtins/expected/JavaScriptCore-InternalClashingNames-Combined.js-result: * Scripts/tests/builtins/expected/WebCore-AnotherGuardedInternalBuiltin-Separate.js-result: * Scripts/tests/builtins/expected/WebCore-ArbitraryConditionalGuard-Separate.js-result: * Scripts/tests/builtins/expected/WebCore-GuardedBuiltin-Separate.js-result: * Scripts/tests/builtins/expected/WebCore-GuardedInternalBuiltin-Separate.js-result: * Scripts/tests/builtins/expected/WebCore-UnguardedBuiltin-Separate.js-result: * Scripts/tests/builtins/expected/WebCore-xmlCasingTest-Separate.js-result: * assembler/MacroAssemblerARM64.h: (JSC::MacroAssemblerARM64::commuteCompareToZeroIntoTest): * assembler/MacroAssemblerX86Common.h: (JSC::MacroAssemblerX86Common::commuteCompareToZeroIntoTest): * b3/B3CheckSpecial.cpp: (JSC::B3::CheckSpecial::forEachArg): (JSC::B3::CheckSpecial::shouldTryAliasingDef): * b3/B3CheckSpecial.h: * b3/B3LowerToAir.cpp: (JSC::B3::Air::LowerToAir::scaleForShl): (JSC::B3::Air::LowerToAir::effectiveAddr): (JSC::B3::Air::LowerToAir::tryAppendLea): * b3/B3Opcode.cpp: (JSC::B3::invertedCompare): * b3/B3Opcode.h: * b3/B3PatchpointSpecial.cpp: (JSC::B3::PatchpointSpecial::forEachArg): * b3/B3StackmapSpecial.cpp: (JSC::B3::StackmapSpecial::forEachArgImpl): * b3/B3StackmapSpecial.h: * b3/B3Value.cpp: (JSC::B3::Value::invertedCompare): * b3/air/AirArg.h: (JSC::B3::Air::Arg::isValidScale): (JSC::B3::Air::Arg::isValidAddrForm): (JSC::B3::Air::Arg::isValidIndexForm): (JSC::B3::Air::Arg::isValidForm): * b3/air/AirCustom.h: (JSC::B3::Air::PatchCustom::shouldTryAliasingDef): * b3/air/AirFixObviousSpills.cpp: * b3/air/AirInst.h: * b3/air/AirInstInlines.h: (JSC::B3::Air::Inst::shouldTryAliasingDef): * b3/air/AirIteratedRegisterCoalescing.cpp: * b3/air/AirSpecial.cpp: (JSC::B3::Air::Special::shouldTryAliasingDef): * b3/air/AirSpecial.h: * bytecode/BytecodeGeneratorification.cpp: (JSC::BytecodeGeneratorification::storageForGeneratorLocal): * bytecode/CodeBlock.cpp: (JSC::CodeBlock::findPC): (JSC::CodeBlock::bytecodeOffsetFromCallSiteIndex): * bytecode/CodeBlock.h: * bytecode/UnlinkedFunctionExecutable.cpp: (JSC::UnlinkedFunctionExecutable::link): * bytecode/UnlinkedFunctionExecutable.h: * bytecompiler/BytecodeGenerator.h: * bytecompiler/NodesCodegen.cpp: (JSC::PropertyListNode::emitPutConstantProperty): (JSC::ObjectPatternNode::bindValue): * debugger/Debugger.cpp: (JSC::Debugger::resolveBreakpoint): * debugger/DebuggerCallFrame.cpp: (JSC::DebuggerCallFrame::currentPosition): * debugger/DebuggerParseData.cpp: (JSC::DebuggerPausePositions::breakpointLocationForLineColumn): * debugger/DebuggerParseData.h: * debugger/ScriptProfilingScope.h: * dfg/DFGAbstractInterpreterInlines.h: (JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects): (JSC::DFG::AbstractInterpreter<AbstractStateType>::executeDoubleUnaryOpEffects): * dfg/DFGJITCode.cpp: (JSC::DFG::JITCode::findPC): * dfg/DFGJITCode.h: * dfg/DFGOperations.cpp: (JSC::DFG::operationPutByValInternal): * dfg/DFGSlowPathGenerator.h: (JSC::DFG::SlowPathGenerator::generate): * dfg/DFGSpeculativeJIT.cpp: (JSC::DFG::SpeculativeJIT::runSlowPathGenerators): (JSC::DFG::SpeculativeJIT::emitUntypedBitOp): (JSC::DFG::SpeculativeJIT::emitUntypedRightShiftBitOp): (JSC::DFG::SpeculativeJIT::compileMathIC): (JSC::DFG::SpeculativeJIT::compileArithDiv): (JSC::DFG::SpeculativeJIT::compileCallDOMGetter): * dfg/DFGSpeculativeJIT.h: * dfg/DFGSpeculativeJIT32_64.cpp: (JSC::DFG::SpeculativeJIT::compile): * dfg/DFGSpeculativeJIT64.cpp: (JSC::DFG::SpeculativeJIT::compileLogicalNot): (JSC::DFG::SpeculativeJIT::emitBranch): (JSC::DFG::SpeculativeJIT::compile): * dfg/DFGStrengthReductionPhase.cpp: (JSC::DFG::StrengthReductionPhase::handleNode): * ftl/FTLJITCode.cpp: (JSC::FTL::JITCode::findPC): * ftl/FTLJITCode.h: * heap/Heap.cpp: (JSC::Heap::collectAsync): (JSC::Heap::collectSync): (JSC::Heap::collectInThread): (JSC::Heap::requestCollection): (JSC::Heap::willStartCollection): (JSC::Heap::didFinishCollection): (JSC::Heap::shouldDoFullCollection): * heap/Heap.h: (JSC::Heap::collectionScope): * heap/HeapSnapshot.cpp: (JSC::HeapSnapshot::nodeForCell): (JSC::HeapSnapshot::nodeForObjectIdentifier): * heap/HeapSnapshot.h: * inspector/InspectorBackendDispatcher.cpp: (Inspector::BackendDispatcher::dispatch): (Inspector::BackendDispatcher::sendPendingErrors): (Inspector::BackendDispatcher::reportProtocolError): * inspector/InspectorBackendDispatcher.h: * inspector/agents/InspectorHeapAgent.cpp: (Inspector::InspectorHeapAgent::nodeForHeapObjectIdentifier): (Inspector::InspectorHeapAgent::getPreview): (Inspector::InspectorHeapAgent::getRemoteObject): * inspector/agents/InspectorHeapAgent.h: * inspector/remote/RemoteConnectionToTarget.h: * inspector/remote/RemoteConnectionToTarget.mm: (Inspector::RemoteConnectionToTarget::targetIdentifier): (Inspector::RemoteConnectionToTarget::setup): * inspector/remote/RemoteInspector.h: * inspector/remote/RemoteInspector.mm: (Inspector::RemoteInspector::updateClientCapabilities): * inspector/scripts/codegen/generate_cpp_protocol_types_header.py: (_generate_declarations_for_enum_conversion_methods): (_generate_declarations_for_enum_conversion_methods.return_type_with_export_macro): * inspector/scripts/codegen/generate_cpp_protocol_types_implementation.py: (CppProtocolTypesImplementationGenerator._generate_enum_conversion_methods_for_domain.generate_conversion_method_body): * inspector/scripts/tests/expected/commands-with-async-attribute.json-result: * inspector/scripts/tests/expected/commands-with-optional-call-return-parameters.json-result: * inspector/scripts/tests/expected/enum-values.json-result: * inspector/scripts/tests/expected/shadowed-optional-type-setters.json-result: * inspector/scripts/tests/expected/type-declaration-array-type.json-result: * inspector/scripts/tests/expected/type-declaration-enum-type.json-result: * inspector/scripts/tests/expected/type-requiring-runtime-casts.json-result: * jit/JITCode.h: (JSC::JITCode::findPC): * jit/JITDivGenerator.cpp: (JSC::JITDivGenerator::generateFastPath): * jit/JITOperations.cpp: * jit/PCToCodeOriginMap.cpp: (JSC::PCToCodeOriginMap::findPC): * jit/PCToCodeOriginMap.h: * jsc.cpp: (WTF::RuntimeArray::getOwnPropertySlot): * llint/LLIntSlowPaths.cpp: (JSC::LLInt::LLINT_SLOW_PATH_DECL): * parser/ModuleAnalyzer.cpp: (JSC::ModuleAnalyzer::exportVariable): * runtime/ConcurrentJSLock.h: (JSC::ConcurrentJSLocker::ConcurrentJSLocker): * runtime/DefinePropertyAttributes.h: (JSC::DefinePropertyAttributes::writable): (JSC::DefinePropertyAttributes::configurable): (JSC::DefinePropertyAttributes::enumerable): * runtime/GenericArgumentsInlines.h: (JSC::GenericArguments<Type>::getOwnPropertySlot): (JSC::GenericArguments<Type>::put): (JSC::GenericArguments<Type>::deleteProperty): (JSC::GenericArguments<Type>::defineOwnProperty): * runtime/HasOwnPropertyCache.h: (JSC::HasOwnPropertyCache::get): * runtime/HashMapImpl.h: (JSC::concurrentJSMapHash): * runtime/Identifier.h: (JSC::parseIndex): * runtime/JSArray.cpp: (JSC::JSArray::defineOwnProperty): * runtime/JSCJSValue.cpp: (JSC::JSValue::toNumberFromPrimitive): (JSC::JSValue::putToPrimitive): * runtime/JSCJSValue.h: * runtime/JSGenericTypedArrayView.h: (JSC::JSGenericTypedArrayView::toAdaptorNativeFromValueWithoutCoercion): * runtime/JSGenericTypedArrayViewConstructorInlines.h: (JSC::constructGenericTypedArrayViewWithArguments): (JSC::constructGenericTypedArrayView): * runtime/JSGenericTypedArrayViewInlines.h: (JSC::JSGenericTypedArrayView<Adaptor>::getOwnPropertySlot): (JSC::JSGenericTypedArrayView<Adaptor>::put): * runtime/JSModuleRecord.cpp: * runtime/JSModuleRecord.h: * runtime/JSObject.cpp: (JSC::JSObject::putDirectAccessor): (JSC::JSObject::deleteProperty): (JSC::JSObject::putDirectMayBeIndex): (JSC::JSObject::defineOwnProperty): * runtime/JSObject.h: (JSC::JSObject::getOwnPropertySlot): (JSC::JSObject::getPropertySlot): (JSC::JSObject::putOwnDataPropertyMayBeIndex): * runtime/JSObjectInlines.h: (JSC::JSObject::putInline): * runtime/JSString.cpp: (JSC::JSString::getStringPropertyDescriptor): * runtime/JSString.h: (JSC::JSString::getStringPropertySlot): * runtime/LiteralParser.cpp: (JSC::LiteralParser<CharType>::parse): * runtime/MathCommon.h: (JSC::safeReciprocalForDivByConst): * runtime/ObjectPrototype.cpp: (JSC::objectProtoFuncHasOwnProperty): * runtime/PropertyDescriptor.h: (JSC::toPropertyDescriptor): * runtime/PropertyName.h: (JSC::parseIndex): * runtime/SamplingProfiler.cpp: (JSC::SamplingProfiler::processUnverifiedStackTraces): * runtime/StringObject.cpp: (JSC::StringObject::put): (JSC::isStringOwnProperty): (JSC::StringObject::deleteProperty): * runtime/ToNativeFromValue.h: (JSC::toNativeFromValueWithoutCoercion): * runtime/TypedArrayAdaptors.h: (JSC::IntegralTypedArrayAdaptor::toNativeFromInt32WithoutCoercion): (JSC::IntegralTypedArrayAdaptor::toNativeFromUint32WithoutCoercion): (JSC::IntegralTypedArrayAdaptor::toNativeFromDoubleWithoutCoercion): (JSC::FloatTypedArrayAdaptor::toNativeFromInt32WithoutCoercion): (JSC::FloatTypedArrayAdaptor::toNativeFromDoubleWithoutCoercion): (JSC::Uint8ClampedAdaptor::toNativeFromInt32WithoutCoercion): (JSC::Uint8ClampedAdaptor::toNativeFromDoubleWithoutCoercion): Source/WebCore: Rename valueOr to value_or. This is specified in C++17 proposal. Use Optional::emplace. C++17 Optional::operator=(Optional&&) requires either copy assignment operator or move assignment operator. But DFG::JSValueOperand etc. only defines move constructors and drop implicit copy assignment operators. It was OK in the previous WTF::Optional since it always uses move constructors. But it is not valid in C++17 Optional. We use Optional::emplace instead. This function has the same semantics to the previous WTF::Optional's operator=. No behavior change. * Modules/applepay/ApplePaySession.cpp: (WebCore::parseAmount): (WebCore::createContactFields): (WebCore::toLineItemType): (WebCore::createLineItem): (WebCore::createLineItems): (WebCore::createMerchantCapabilities): (WebCore::createSupportedNetworks): (WebCore::toShippingType): (WebCore::createShippingMethod): (WebCore::createShippingMethods): (WebCore::createPaymentRequest): (WebCore::toPaymentAuthorizationStatus): * Modules/applepay/PaymentContact.h: * Modules/applepay/PaymentCoordinator.cpp: (WebCore::PaymentCoordinator::completeShippingMethodSelection): (WebCore::PaymentCoordinator::completeShippingContactSelection): (WebCore::PaymentCoordinator::completePaymentMethodSelection): * Modules/applepay/PaymentCoordinator.h: * Modules/applepay/PaymentCoordinatorClient.h: * Modules/applepay/PaymentMerchantSession.h: * Modules/applepay/PaymentRequest.h: * Modules/applepay/cocoa/PaymentContactCocoa.mm: (WebCore::PaymentContact::fromJS): * Modules/applepay/cocoa/PaymentMerchantSessionCocoa.mm: (WebCore::PaymentMerchantSession::fromJS): * Modules/encryptedmedia/MediaKeyStatusMap.cpp: (WebCore::MediaKeyStatusMap::Iterator::next): * Modules/encryptedmedia/MediaKeyStatusMap.h: * Modules/fetch/FetchBody.cpp: (WebCore::FetchBody::extract): * Modules/fetch/FetchBody.h: * Modules/fetch/FetchBodyOwner.cpp: (WebCore::FetchBodyOwner::FetchBodyOwner): (WebCore::FetchBodyOwner::loadBlob): (WebCore::FetchBodyOwner::finishBlobLoading): * Modules/fetch/FetchBodyOwner.h: * Modules/fetch/FetchHeaders.cpp: (WebCore::FetchHeaders::Iterator::next): * Modules/fetch/FetchHeaders.h: * Modules/fetch/FetchRequest.cpp: (WebCore::setReferrerPolicy): (WebCore::setMode): (WebCore::setCredentials): (WebCore::setCache): (WebCore::setRedirect): (WebCore::setMethod): (WebCore::setReferrer): (WebCore::buildOptions): (WebCore::FetchRequest::clone): * Modules/fetch/FetchRequest.h: (WebCore::FetchRequest::FetchRequest): * Modules/fetch/FetchResponse.cpp: (WebCore::FetchResponse::FetchResponse): (WebCore::FetchResponse::cloneForJS): (WebCore::FetchResponse::fetch): (WebCore::FetchResponse::BodyLoader::didSucceed): (WebCore::FetchResponse::BodyLoader::didFail): (WebCore::FetchResponse::BodyLoader::didReceiveResponse): (WebCore::FetchResponse::BodyLoader::stop): * Modules/fetch/FetchResponse.h: * Modules/geolocation/Coordinates.cpp: (WebCore::Coordinates::altitude): (WebCore::Coordinates::altitudeAccuracy): (WebCore::Coordinates::heading): (WebCore::Coordinates::speed): * Modules/geolocation/Coordinates.h: * Modules/indexeddb/IDBCursor.cpp: (WebCore::IDBCursor::stringToDirection): * Modules/indexeddb/IDBCursor.h: * Modules/indexeddb/IDBDatabase.h: * Modules/indexeddb/IDBDatabaseIdentifier.h: (WebCore::IDBDatabaseIdentifier::hash): * Modules/indexeddb/IDBFactory.cpp: (WebCore::IDBFactory::open): * Modules/indexeddb/IDBFactory.h: * Modules/indexeddb/IDBIndex.cpp: (WebCore::IDBIndex::getAll): (WebCore::IDBIndex::getAllKeys): * Modules/indexeddb/IDBIndex.h: * Modules/indexeddb/IDBKeyPath.h: (WebCore::isolatedCopy): * Modules/indexeddb/IDBObjectStore.cpp: (WebCore::IDBObjectStore::keyPath): (WebCore::IDBObjectStore::getAll): (WebCore::IDBObjectStore::getAllKeys): * Modules/indexeddb/IDBObjectStore.h: * Modules/indexeddb/IDBTransaction.cpp: (WebCore::IDBTransaction::requestGetAllObjectStoreRecords): (WebCore::IDBTransaction::requestGetAllIndexRecords): * Modules/indexeddb/IDBTransaction.h: * Modules/indexeddb/IDBVersionChangeEvent.cpp: (WebCore::IDBVersionChangeEvent::IDBVersionChangeEvent): * Modules/indexeddb/IDBVersionChangeEvent.h: * Modules/indexeddb/server/IDBSerialization.cpp: (WebCore::serializeIDBKeyPath): (WebCore::deserializeIDBKeyPath): * Modules/indexeddb/server/IDBSerialization.h: * Modules/indexeddb/server/MemoryIndex.cpp: (WebCore::IDBServer::MemoryIndex::getAllRecords): * Modules/indexeddb/server/MemoryIndex.h: * Modules/indexeddb/server/MemoryObjectStore.cpp: (WebCore::IDBServer::MemoryObjectStore::getAllRecords): * Modules/indexeddb/server/MemoryObjectStore.h: * Modules/indexeddb/server/MemoryObjectStoreCursor.cpp: (WebCore::IDBServer::MemoryObjectStoreCursor::objectStoreCleared): (WebCore::IDBServer::MemoryObjectStoreCursor::keyDeleted): (WebCore::IDBServer::MemoryObjectStoreCursor::setFirstInRemainingRange): (WebCore::IDBServer::MemoryObjectStoreCursor::setForwardIteratorFromRemainingRange): (WebCore::IDBServer::MemoryObjectStoreCursor::setReverseIteratorFromRemainingRange): (WebCore::IDBServer::MemoryObjectStoreCursor::incrementForwardIterator): (WebCore::IDBServer::MemoryObjectStoreCursor::incrementReverseIterator): * Modules/indexeddb/server/MemoryObjectStoreCursor.h: * Modules/indexeddb/server/SQLiteIDBBackingStore.cpp: (WebCore::IDBServer::SQLiteIDBBackingStore::extractExistingDatabaseInfo): * Modules/indexeddb/shared/IDBDatabaseInfo.cpp: (WebCore::IDBDatabaseInfo::createNewObjectStore): * Modules/indexeddb/shared/IDBDatabaseInfo.h: * Modules/indexeddb/shared/IDBGetAllRecordsData.h: * Modules/indexeddb/shared/IDBObjectStoreInfo.cpp: (WebCore::IDBObjectStoreInfo::IDBObjectStoreInfo): * Modules/indexeddb/shared/IDBObjectStoreInfo.h: (WebCore::IDBObjectStoreInfo::keyPath): * Modules/mediacontrols/MediaControlsHost.cpp: (WebCore::MediaControlsHost::displayNameForTrack): * Modules/mediacontrols/MediaControlsHost.h: * Modules/mediasource/MediaSource.cpp: (WebCore::MediaSource::endOfStream): (WebCore::MediaSource::streamEndedWithError): * Modules/mediasource/MediaSource.h: * Modules/mediastream/MediaStreamTrack.h: * Modules/mediastream/PeerConnectionBackend.cpp: (WebCore::PeerConnectionBackend::createOfferSucceeded): (WebCore::PeerConnectionBackend::createOfferFailed): (WebCore::PeerConnectionBackend::createAnswerSucceeded): (WebCore::PeerConnectionBackend::createAnswerFailed): (WebCore::PeerConnectionBackend::setLocalDescriptionSucceeded): (WebCore::PeerConnectionBackend::setLocalDescriptionFailed): (WebCore::PeerConnectionBackend::setRemoteDescriptionSucceeded): (WebCore::PeerConnectionBackend::setRemoteDescriptionFailed): (WebCore::PeerConnectionBackend::addIceCandidateSucceeded): (WebCore::PeerConnectionBackend::addIceCandidateFailed): (WebCore::PeerConnectionBackend::stop): * Modules/mediastream/PeerConnectionBackend.h: * Modules/mediastream/RTCDTMFSender.cpp: (WebCore::RTCDTMFSender::insertDTMF): * Modules/mediastream/RTCDTMFSender.h: * Modules/mediastream/RTCIceCandidate.cpp: (WebCore::RTCIceCandidate::create): (WebCore::RTCIceCandidate::RTCIceCandidate): * Modules/mediastream/RTCIceCandidate.h: (WebCore::RTCIceCandidate::sdpMLineIndex): * Modules/mediastream/SDPProcessor.cpp: (WebCore::iceCandidateFromJSON): * Modules/proximity/DeviceProximityEvent.h: * Modules/streams/ReadableStreamSource.h: (WebCore::ReadableStreamSource::startFinished): (WebCore::ReadableStreamSource::pullFinished): (WebCore::ReadableStreamSource::clean): * Modules/webaudio/AudioBufferSourceNode.cpp: (WebCore::AudioBufferSourceNode::start): * Modules/webaudio/AudioBufferSourceNode.h: * Modules/webdatabase/SQLResultSet.h: * Modules/websockets/WebSocket.cpp: (WebCore::WebSocket::close): * Modules/websockets/WebSocket.h: * Modules/websockets/WebSocketChannel.cpp: (WebCore::WebSocketChannel::didReceiveSocketStreamData): * Modules/websockets/WebSocketChannel.h: * bindings/generic/IDLTypes.h: (WebCore::IDLType::nullValue): * bindings/js/CachedModuleScript.h: (WebCore::CachedModuleScript::error): * bindings/js/Dictionary.h: (WebCore::Dictionary::get): * bindings/js/IDBBindingUtilities.cpp: (WebCore::toJS): * bindings/js/IDBBindingUtilities.h: * bindings/js/JSCryptoKeySerializationJWK.cpp: (WebCore::JSCryptoKeySerializationJWK::reconcileAlgorithm): * bindings/js/JSCryptoKeySerializationJWK.h: * bindings/js/JSDOMConvert.h: (WebCore::Detail::VariadicConverterBase::convert): (WebCore::Detail::VariadicConverterBase<IDLInterface<T>>::convert): (WebCore::convertVariadicArguments): * bindings/js/JSDOMIterator.h: (WebCore::IteratorTraits>::next): * bindings/js/JSDOMPromise.h: (WebCore::DOMPromise::DOMPromise): (WebCore::DOMPromise::operator=): * bindings/js/JSDOMWindowCustom.cpp: (WebCore::JSDOMWindow::getOwnPropertySlot): * bindings/js/JSDictionary.h: (WebCore::JSDictionary::convertValue): * bindings/js/JSFileCustom.cpp: (WebCore::constructJSFile): * bindings/js/JSHTMLAllCollectionCustom.cpp: (WebCore::callHTMLAllCollection): (WebCore::JSHTMLAllCollection::item): * bindings/js/JSHTMLCanvasElementCustom.cpp: (WebCore::JSHTMLCanvasElement::toDataURL): * bindings/js/JSImageConstructor.cpp: (WebCore::JSImageConstructor::construct): * bindings/js/JSMediaDevicesCustom.cpp: (WebCore::createStringConstraint): (WebCore::createBooleanConstraint): (WebCore::createDoubleConstraint): (WebCore::createIntConstraint): * bindings/js/JSWebKitSubtleCryptoCustom.cpp: (WebCore::importKey): * bindings/js/ScriptController.cpp: (WebCore::ScriptController::setupModuleScriptHandlers): (WebCore::ScriptController::executeScriptInWorld): (WebCore::ScriptController::executeScript): * bindings/scripts/CodeGeneratorJS.pm: (GenerateGetOwnPropertySlotBody): (GenerateEnumerationImplementationContent): (GenerateEnumerationHeaderContent): (GenerateDefaultValue): (GenerateImplementation): (GenerateParametersCheck): * bindings/scripts/test/JS/JSFloat64Array.cpp: (WebCore::JSFloat64Array::getOwnPropertySlot): (WebCore::JSFloat64Array::getOwnPropertyDescriptor): (WebCore::JSFloat64Array::put): * bindings/scripts/test/JS/JSTestEventTarget.cpp: (WebCore::JSTestEventTarget::getOwnPropertySlot): * bindings/scripts/test/JS/JSTestObj.cpp: (WebCore::parseEnumeration<TestObj::EnumType>): (WebCore::parseEnumeration<TestObj::Optional>): (WebCore::parseEnumeration<AlternateEnumName>): (WebCore::parseEnumeration<TestObj::EnumA>): (WebCore::parseEnumeration<TestObj::EnumB>): (WebCore::parseEnumeration<TestObj::EnumC>): (WebCore::parseEnumeration<TestObj::Kind>): (WebCore::parseEnumeration<TestObj::Size>): (WebCore::parseEnumeration<TestObj::Confidence>): (WebCore::convertDictionary<TestObj::Dictionary>): (WebCore::JSTestObj::getOwnPropertySlot): (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalEnumArgCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArgCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndOptionalArgCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndTwoOptionalArgsCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalLongLongCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalUnsignedLongLongCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalSequenceCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalBooleanCaller): (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalRecordCaller): (WebCore::jsTestObjPrototypeFunctionOverloadedMethod2Caller): (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithOptionalParameter2Caller): (WebCore::jsTestObjConstructorFunctionClassMethodWithOptional): (WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithOptionalIntArgumentCaller): * bindings/scripts/test/JS/JSTestObj.h: * bindings/scripts/test/JS/JSTestStandaloneDictionary.cpp: (WebCore::parseEnumeration<TestStandaloneDictionary::EnumInStandaloneDictionaryFile>): * bindings/scripts/test/JS/JSTestStandaloneDictionary.h: * bindings/scripts/test/JS/JSTestStandaloneEnumeration.cpp: (WebCore::parseEnumeration<TestStandaloneEnumeration>): * bindings/scripts/test/JS/JSTestStandaloneEnumeration.h: * bindings/scripts/test/JS/JSTestTypedefs.cpp: (WebCore::jsTestTypedefsPrototypeFunctionSetShadowCaller): (WebCore::jsTestTypedefsPrototypeFunctionFuncWithClampCaller): * bridge/runtime_array.cpp: (JSC::RuntimeArray::getOwnPropertySlot): (JSC::RuntimeArray::put): * crypto/CryptoAlgorithmRegistry.cpp: (WebCore::CryptoAlgorithmRegistry::identifier): * crypto/CryptoAlgorithmRegistry.h: * crypto/CryptoKeySerialization.h: * crypto/JsonWebKey.h: * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: (WebCore::CryptoAlgorithmAES_CBC::importKey): * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: (WebCore::CryptoAlgorithmAES_KW::importKey): * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::generateKey): (WebCore::CryptoAlgorithmHMAC::importKey): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::importKey): * crypto/gcrypt/CryptoAlgorithmHMACGCrypt.cpp: (WebCore::calculateSignature): * crypto/keys/CryptoKeyAES.h: * crypto/keys/CryptoKeyHMAC.h: * crypto/keys/CryptoKeyRSA.cpp: (WebCore::CryptoKeyRSA::importJwk): * crypto/keys/CryptoKeyRSA.h: * crypto/keys/CryptoKeySerializationRaw.cpp: (WebCore::CryptoKeySerializationRaw::reconcileAlgorithm): * crypto/keys/CryptoKeySerializationRaw.h: * crypto/mac/CryptoAlgorithmHMACMac.cpp: (WebCore::commonCryptoHMACAlgorithm): * crypto/mac/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp: (WebCore::cryptoDigestAlgorithm): * crypto/parameters/CryptoAlgorithmHmacKeyParams.h: * crypto/parameters/CryptoAlgorithmRsaOaepParams.h: * css/CSSFontFace.cpp: (WebCore::CSSFontFace::calculateStyleMask): (WebCore::CSSFontFace::calculateWeightMask): * css/CSSFontFace.h: * css/CSSFontFaceSet.cpp: (WebCore::computeFontTraitsMask): * css/CSSPrimitiveValue.cpp: (WebCore::CSSPrimitiveValue::doubleValue): (WebCore::CSSPrimitiveValue::doubleValueInternal): * css/CSSPrimitiveValue.h: * css/CSSPropertyNames.in: * css/CSSSegmentedFontFace.cpp: * css/CSSStyleSheet.cpp: (WebCore::CSSStyleSheet::create): (WebCore::CSSStyleSheet::CSSStyleSheet): (WebCore::CSSStyleSheet::addRule): * css/CSSStyleSheet.h: * css/FontFace.cpp: (WebCore::FontFace::fontStateChanged): * css/FontFace.h: * css/FontFaceSet.cpp: (WebCore::FontFaceSet::completedLoading): * css/FontFaceSet.h: * css/MediaQueryEvaluator.cpp: (WebCore::doubleValue): * css/StyleBuilderConverter.h: (WebCore::StyleBuilderConverter::convertGridPosition): (WebCore::StyleBuilderConverter::convertWordSpacing): (WebCore::StyleBuilderConverter::convertPerspective): (WebCore::StyleBuilderConverter::convertMarqueeIncrement): (WebCore::StyleBuilderConverter::convertFilterOperations): (WebCore::StyleBuilderConverter::convertLineHeight): * css/StyleBuilderCustom.h: (WebCore::StyleBuilderCustom::applyValueLineHeight): * css/StyleRuleImport.cpp: (WebCore::StyleRuleImport::requestStyleSheet): * css/parser/CSSParser.cpp: (WebCore::CSSParser::parseCubicBezierTimingFunctionValue): (WebCore::CSSParser::parseSpringTimingFunctionValue): (WebCore::CSSParser::parseColorFunctionParameters): (WebCore::CSSParser::parseColorFromValue): * css/parser/CSSParser.h: * cssjit/SelectorCompiler.cpp: (WebCore::SelectorCompiler::SelectorCodeGenerator::generateAddStyleRelationIfResolvingStyle): (WebCore::SelectorCompiler::SelectorCodeGenerator::generateAddStyleRelation): * dom/CustomElementReactionQueue.cpp: * dom/Document.cpp: (WebCore::Document::lastModified): * dom/Element.cpp: (WebCore::Element::scrollBy): (WebCore::Element::getIntegralAttribute): (WebCore::Element::getUnsignedIntegralAttribute): (WebCore::Element::resolveCustomStyle): * dom/Element.h: * dom/ElementIteratorAssertions.h: (WebCore::ElementIteratorAssertions::dropEventDispatchAssertion): (WebCore::ElementIteratorAssertions::clear): * dom/ExceptionOr.h: * dom/InlineStyleSheetOwner.cpp: (WebCore::makeInlineStyleSheetCacheKey): * dom/KeyboardEvent.h: * dom/LoadableClassicScript.cpp: (WebCore::LoadableClassicScript::error): * dom/LoadableClassicScript.h: * dom/LoadableModuleScript.cpp: (WebCore::LoadableModuleScript::error): * dom/LoadableModuleScript.h: * dom/LoadableScript.h: * dom/MessageEvent.cpp: (WebCore::MessageEvent::MessageEvent): (WebCore::MessageEvent::create): (WebCore::MessageEvent::initMessageEvent): * dom/MessageEvent.h: * dom/MutationObserver.cpp: (WebCore::MutationObserver::observe): * dom/MutationObserver.h: * dom/ProcessingInstruction.cpp: (WebCore::ProcessingInstruction::checkStyleSheet): * dom/PseudoElement.cpp: (WebCore::PseudoElement::resolveCustomStyle): * dom/PseudoElement.h: * dom/RangeBoundaryPoint.h: (WebCore::RangeBoundaryPoint::setToBeforeChild): (WebCore::RangeBoundaryPoint::setToAfterChild): (WebCore::RangeBoundaryPoint::setToEndOfNode): (WebCore::RangeBoundaryPoint::invalidateOffset): * dom/ScriptElement.cpp: (WebCore::ScriptElement::determineScriptType): (WebCore::ScriptElement::prepareScript): (WebCore::ScriptElement::executeScriptAndDispatchEvent): * dom/ScriptElement.h: * dom/TextDecoder.cpp: (WebCore::TextDecoder::decode): * dom/TextDecoder.h: * dom/UserGestureIndicator.cpp: (WebCore::UserGestureIndicator::UserGestureIndicator): * dom/UserGestureIndicator.h: * editing/CompositeEditCommand.cpp: (WebCore::CompositeEditCommand::moveParagraphs): * editing/CompositeEditCommand.h: * fileapi/File.h: * history/CachedFrame.h: (WebCore::CachedFrame::hasInsecureContent): * html/DOMTokenList.cpp: (WebCore::DOMTokenList::toggle): * html/DOMTokenList.h: * html/HTMLAnchorElement.cpp: (WebCore::HTMLAnchorElement::handleClick): * html/HTMLCanvasElement.cpp: (WebCore::HTMLCanvasElement::toDataURL): * html/HTMLCanvasElement.h: * html/HTMLElement.cpp: (WebCore::HTMLElement::parseBorderWidthAttribute): (WebCore::HTMLElement::parseAttribute): * html/HTMLImageElement.cpp: (WebCore::HTMLImageElement::createForJSConstructor): (WebCore::HTMLImageElement::width): (WebCore::HTMLImageElement::height): * html/HTMLImageElement.h: * html/HTMLInputElement.cpp: (WebCore::HTMLInputElement::findClosestTickMarkValue): (WebCore::HTMLInputElement::maxLengthAttributeChanged): (WebCore::HTMLInputElement::minLengthAttributeChanged): * html/HTMLInputElement.h: * html/HTMLLinkElement.cpp: (WebCore::HTMLLinkElement::process): (WebCore::HTMLLinkElement::initializeStyleSheet): (WebCore::HTMLLinkElement::iconType): * html/HTMLLinkElement.h: * html/HTMLOListElement.h: * html/HTMLOptionsCollection.cpp: (WebCore::HTMLOptionsCollection::add): * html/HTMLOptionsCollection.h: * html/HTMLSelectElement.cpp: (WebCore::HTMLSelectElement::add): (WebCore::HTMLSelectElement::setLength): * html/HTMLSelectElement.h: * html/HTMLTextAreaElement.cpp: (WebCore::HTMLTextAreaElement::maxLengthAttributeChanged): (WebCore::HTMLTextAreaElement::minLengthAttributeChanged): * html/ImageInputType.cpp: (WebCore::ImageInputType::height): (WebCore::ImageInputType::width): * html/InputType.cpp: (WebCore::InputType::findClosestTickMarkValue): * html/InputType.h: * html/LinkIconCollector.cpp: * html/LinkRelAttribute.h: * html/RangeInputType.cpp: (WebCore::RangeInputType::findClosestTickMarkValue): * html/RangeInputType.h: * html/canvas/CanvasRenderingContext2D.cpp: (WebCore::CanvasRenderingContext2D::restore): (WebCore::CanvasRenderingContext2D::setStrokeColor): (WebCore::CanvasRenderingContext2D::setFillColor): (WebCore::CanvasRenderingContext2D::isPointInPathInternal): (WebCore::CanvasRenderingContext2D::isPointInStrokeInternal): (WebCore::CanvasRenderingContext2D::setShadow): (WebCore::CanvasRenderingContext2D::fillText): (WebCore::CanvasRenderingContext2D::strokeText): (WebCore::CanvasRenderingContext2D::drawTextInternal): * html/canvas/CanvasRenderingContext2D.h: * html/canvas/WebGL2RenderingContext.cpp: (WebCore::arrayBufferViewElementSize): * html/canvas/WebGLRenderingContextBase.cpp: (WebCore::WebGLRenderingContextBase::bufferData): (WebCore::WebGLRenderingContextBase::bufferSubData): (WebCore::WebGLRenderingContextBase::texSubImage2D): (WebCore::WebGLRenderingContextBase::validateArrayBufferType): (WebCore::WebGLRenderingContextBase::validateTexFuncData): (WebCore::WebGLRenderingContextBase::texImage2D): * html/canvas/WebGLRenderingContextBase.h: * html/parser/HTMLConstructionSite.cpp: (WebCore::HTMLConstructionSite::indexOfFirstUnopenFormattingElement): (WebCore::HTMLConstructionSite::reconstructTheActiveFormattingElements): * html/parser/HTMLConstructionSite.h: * html/parser/HTMLParserIdioms.cpp: (WebCore::parseHTMLIntegerInternal): (WebCore::parseHTMLInteger): (WebCore::parseHTMLNonNegativeInteger): (WebCore::parseValidHTMLNonNegativeIntegerInternal): (WebCore::parseValidHTMLNonNegativeInteger): (WebCore::parseValidHTMLFloatingPointNumberInternal): (WebCore::parseValidHTMLFloatingPointNumber): (WebCore::parseHTTPRefreshInternal): * html/parser/HTMLParserIdioms.h: (WebCore::limitToOnlyHTMLNonNegative): * html/parser/HTMLSrcsetParser.cpp: (WebCore::parseDescriptors): * html/shadow/SliderThumbElement.cpp: (WebCore::SliderThumbElement::setPositionFromPoint): (WebCore::SliderThumbElement::resolveCustomStyle): (WebCore::SliderContainerElement::resolveCustomStyle): * html/shadow/SliderThumbElement.h: * html/shadow/TextControlInnerElements.cpp: (WebCore::TextControlInnerElement::resolveCustomStyle): (WebCore::TextControlInnerTextElement::resolveCustomStyle): (WebCore::TextControlPlaceholderElement::resolveCustomStyle): * html/shadow/TextControlInnerElements.h: * html/track/TrackEvent.h: * inspector/InspectorIndexedDBAgent.cpp: * inspector/InspectorInstrumentation.cpp: (WebCore::InspectorInstrumentation::didFinishXHRLoadingImpl): * inspector/InspectorInstrumentation.h: (WebCore::InspectorInstrumentation::didFinishXHRLoading): * inspector/InspectorStyleSheet.cpp: (WebCore::InspectorStyleSheet::addRule): * inspector/InspectorTimelineAgent.cpp: (WebCore::InspectorTimelineAgent::setInstruments): * loader/DocumentLoader.cpp: (WebCore::DocumentLoader::startIconLoading): * loader/DocumentThreadableLoader.cpp: (WebCore::DocumentThreadableLoader::makeCrossOriginAccessRequestWithPreflight): (WebCore::DocumentThreadableLoader::clearResource): (WebCore::DocumentThreadableLoader::preflightSuccess): (WebCore::DocumentThreadableLoader::preflightFailure): * loader/DocumentThreadableLoader.h: * loader/EmptyClients.cpp: * loader/EmptyClients.h: * loader/FrameLoader.cpp: (WebCore::FrameLoader::urlSelected): (WebCore::FrameLoader::receivedFirstData): (WebCore::FrameLoader::commitProvisionalLoad): (WebCore::FrameLoader::open): (WebCore::FrameLoader::dispatchDidCommitLoad): (WebCore::FrameLoader::clearTestingOverrides): * loader/FrameLoader.h: * loader/FrameLoaderClient.h: * loader/LinkLoader.cpp: (WebCore::LinkLoader::resourceTypeFromAsAttribute): (WebCore::LinkLoader::loadLink): * loader/LinkLoader.h: * loader/SubresourceLoader.cpp: (WebCore::SubresourceLoader::SubresourceLoader): (WebCore::SubresourceLoader::didReceiveResponse): (WebCore::SubresourceLoader::notifyDone): * loader/SubresourceLoader.h: * loader/cache/CachedResource.cpp: (WebCore::CachedResource::setLoadPriority): * loader/cache/CachedResource.h: * loader/cache/CachedResourceRequest.cpp: (WebCore::CachedResourceRequest::CachedResourceRequest): * loader/cache/CachedResourceRequest.h: (WebCore::CachedResourceRequest::priority): * mathml/MathMLElement.h: (WebCore::MathMLElement::specifiedDisplayStyle): (WebCore::MathMLElement::specifiedMathVariant): * mathml/MathMLFractionElement.cpp: (WebCore::MathMLFractionElement::cachedFractionAlignment): (WebCore::MathMLFractionElement::parseAttribute): * mathml/MathMLFractionElement.h: * mathml/MathMLMathElement.cpp: (WebCore::MathMLMathElement::specifiedDisplayStyle): (WebCore::MathMLMathElement::parseAttribute): * mathml/MathMLMathElement.h: * mathml/MathMLMencloseElement.cpp: (WebCore::MathMLMencloseElement::parseAttribute): * mathml/MathMLMencloseElement.h: * mathml/MathMLOperatorDictionary.cpp: (WebCore::MathMLOperatorDictionary::search): * mathml/MathMLOperatorDictionary.h: * mathml/MathMLOperatorElement.cpp: (WebCore::MathMLOperatorElement::computeOperatorFlag): (WebCore::MathMLOperatorElement::childrenChanged): (WebCore::attributeNameToPropertyFlag): (WebCore::MathMLOperatorElement::parseAttribute): * mathml/MathMLOperatorElement.h: * mathml/MathMLPaddedElement.cpp: (WebCore::MathMLPaddedElement::parseAttribute): * mathml/MathMLPaddedElement.h: * mathml/MathMLPresentationElement.cpp: (WebCore::MathMLPresentationElement::cachedBooleanAttribute): (WebCore::MathMLPresentationElement::cachedMathMLLength): (WebCore::MathMLPresentationElement::specifiedDisplayStyle): (WebCore::MathMLPresentationElement::specifiedMathVariant): (WebCore::MathMLPresentationElement::parseAttribute): * mathml/MathMLPresentationElement.h: (WebCore::MathMLPresentationElement::toOptionalBool): * mathml/MathMLScriptsElement.cpp: (WebCore::MathMLScriptsElement::parseAttribute): * mathml/MathMLScriptsElement.h: * mathml/MathMLSpaceElement.cpp: (WebCore::MathMLSpaceElement::parseAttribute): * mathml/MathMLSpaceElement.h: * mathml/MathMLTokenElement.cpp: (WebCore::MathMLTokenElement::convertToSingleCodePoint): * mathml/MathMLTokenElement.h: * mathml/MathMLUnderOverElement.cpp: (WebCore::MathMLUnderOverElement::parseAttribute): * mathml/MathMLUnderOverElement.h: * page/ChromeClient.h: * page/DOMTimer.cpp: (WebCore::DOMTimer::alignedFireTime): * page/DOMTimer.h: * page/DOMWindow.cpp: (WebCore::DOMWindow::scrollBy): * page/DOMWindow.h: * page/EventSource.cpp: (WebCore::EventSource::parseEventStream): (WebCore::EventSource::parseEventStreamLine): * page/EventSource.h: * page/FrameView.cpp: (WebCore::FrameView::recalculateScrollbarOverlayStyle): (WebCore::FrameView::setLayoutViewportOverrideRect): (WebCore::FrameView::setViewExposedRect): * page/FrameView.h: * page/Page.cpp: (WebCore::Page::takeAnyMediaCanStartListener): * page/Page.h: (WebCore::Page::eventThrottlingBehaviorOverride): (WebCore::Page::setEventThrottlingBehaviorOverride): * page/ScrollToOptions.h: * page/SecurityOrigin.cpp: (WebCore::SecurityOrigin::SecurityOrigin): (WebCore::SecurityOrigin::create): * page/SecurityOrigin.h: (WebCore::SecurityOrigin::port): * page/SecurityOriginData.cpp: (WebCore::SecurityOriginData::debugString): (WebCore::SecurityOriginData::databaseIdentifier): (WebCore::SecurityOriginData::fromDatabaseIdentifier): * page/SecurityOriginData.h: (WebCore::SecurityOriginData::SecurityOriginData): (WebCore::SecurityOriginData::isEmpty): (WebCore::SecurityOriginDataHash::hash): * page/SecurityOriginHash.h: (WebCore::SecurityOriginHash::hash): * page/WindowFeatures.cpp: (WebCore::parseDialogFeatures): (WebCore::boolFeature): (WebCore::floatFeature): * page/WindowFeatures.h: * page/csp/ContentSecurityPolicySource.cpp: (WebCore::ContentSecurityPolicySource::ContentSecurityPolicySource): (WebCore::ContentSecurityPolicySource::portMatches): * page/csp/ContentSecurityPolicySource.h: * page/csp/ContentSecurityPolicySourceList.cpp: (WebCore::ContentSecurityPolicySourceList::parse): (WebCore::ContentSecurityPolicySourceList::parseSource): (WebCore::ContentSecurityPolicySourceList::parsePort): * page/csp/ContentSecurityPolicySourceList.h: * page/scrolling/AsyncScrollingCoordinator.cpp: (WebCore::AsyncScrollingCoordinator::requestScrollPositionUpdate): (WebCore::AsyncScrollingCoordinator::scheduleUpdateScrollPositionAfterAsyncScroll): (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll): (WebCore::AsyncScrollingCoordinator::reconcileScrollingState): * page/scrolling/AsyncScrollingCoordinator.h: (WebCore::AsyncScrollingCoordinator::ScheduledScrollUpdate::ScheduledScrollUpdate): * page/scrolling/ScrollingCoordinator.h: * page/scrolling/ScrollingTree.cpp: (WebCore::ScrollingTree::scrollPositionChangedViaDelegatedScrolling): * page/scrolling/ScrollingTree.h: * page/scrolling/ScrollingTreeScrollingNode.cpp: (WebCore::ScrollingTreeScrollingNode::setScrollPositionWithoutContentEdgeConstraints): * page/scrolling/ThreadedScrollingTree.cpp: (WebCore::ThreadedScrollingTree::scrollingTreeNodeDidScroll): * page/scrolling/ThreadedScrollingTree.h: * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.mm: (WebCore::ScrollingTreeFrameScrollingNodeIOS::setScrollPositionWithoutContentEdgeConstraints): * page/scrolling/ios/ScrollingTreeIOS.cpp: (WebCore::ScrollingTreeIOS::scrollingTreeNodeDidScroll): * page/scrolling/ios/ScrollingTreeIOS.h: * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm: (WebCore::ScrollingTreeFrameScrollingNodeMac::setScrollPositionWithoutContentEdgeConstraints): * platform/DragImage.cpp: * platform/LinkIcon.h: * platform/MemoryPressureHandler.h: * platform/ScrollView.cpp: (WebCore::ScrollView::handleDeferredScrollUpdateAfterContentSizeChange): * platform/ScrollView.h: * platform/Theme.h: (WebCore::Theme::controlFont): * platform/Timer.h: (WebCore::TimerBase::alignedFireTime): * platform/URL.cpp: (WebCore::URL::port): (WebCore::defaultPortForProtocol): (WebCore::portAllowed): * platform/URL.h: * platform/URLParser.cpp: (WebCore::URLParser::defaultPortForProtocol): (WebCore::findLongestZeroSequence): (WebCore::URLParser::parseIPv4Piece): (WebCore::URLParser::parseIPv4Host): (WebCore::URLParser::parseIPv4PieceInsideIPv6): (WebCore::URLParser::parseIPv4AddressInsideIPv6): (WebCore::URLParser::parseIPv6Host): (WebCore::URLParser::domainToASCII): (WebCore::URLParser::formURLDecode): * platform/URLParser.h: * platform/graphics/BitmapImage.h: * platform/graphics/Color.h: (WebCore::colorWithOverrideAlpha): * platform/graphics/DisplayRefreshMonitorClient.h: * platform/graphics/Font.h: * platform/graphics/FontCascade.cpp: (WebCore::FontCascade::drawText): (WebCore::FontCascade::drawEmphasisMarks): (WebCore::FontCascade::adjustSelectionRectForText): (WebCore::FontCascade::getEmphasisMarkGlyphData): (WebCore::FontCascade::emphasisMarkAscent): (WebCore::FontCascade::emphasisMarkDescent): (WebCore::FontCascade::emphasisMarkHeight): * platform/graphics/FontCascade.h: * platform/graphics/GraphicsContext.cpp: (WebCore::GraphicsContext::drawText): (WebCore::GraphicsContext::drawEmphasisMarks): (WebCore::GraphicsContext::drawBidiText): * platform/graphics/GraphicsContext.h: (WebCore::InterpolationQualityMaintainer::InterpolationQualityMaintainer): * platform/graphics/GraphicsLayer.h: (WebCore::GraphicsLayer::setPosition): (WebCore::GraphicsLayer::setApproximatePosition): * platform/graphics/Image.h: (WebCore::Image::hotSpot): * platform/graphics/ImageBuffer.h: * platform/graphics/ImageFrameCache.cpp: (WebCore::ImageFrameCache::clearMetadata): (WebCore::ImageFrameCache::metadata): (WebCore::ImageFrameCache::frameMetadataAtIndex): (WebCore::ImageFrameCache::hotSpot): * platform/graphics/ImageFrameCache.h: * platform/graphics/ImageSource.h: (WebCore::ImageSource::hotSpot): * platform/graphics/PathUtilities.cpp: (WebCore::rectFromPolygon): (WebCore::PathUtilities::pathWithShrinkWrappedRectsForOutline): * platform/graphics/ShadowBlur.cpp: (WebCore::ShadowBlur::calculateLayerBoundingRect): * platform/graphics/TiledBacking.h: * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm: (WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithVideoOutput): * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h: * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm: (WebCore::SourceBufferPrivateAVFObjC::flush): (WebCore::SourceBufferPrivateAVFObjC::naturalSize): * platform/graphics/ca/GraphicsLayerCA.cpp: (WebCore::GraphicsLayerCA::computeVisibleAndCoverageRect): * platform/graphics/ca/TileController.cpp: (WebCore::TileController::setLayoutViewportRect): * platform/graphics/ca/TileController.h: * platform/graphics/cairo/ImageBufferCairo.cpp: (WebCore::ImageBuffer::toDataURL): * platform/graphics/cg/ImageBufferCG.cpp: (WebCore::encodeImage): (WebCore::dataURL): (WebCore::ImageBuffer::toDataURL): * platform/graphics/cg/ImageDecoderCG.cpp: (WebCore::ImageDecoder::hotSpot): * platform/graphics/cg/ImageDecoderCG.h: * platform/graphics/cocoa/FontCocoa.mm: (WebCore::openTypeFeature): (WebCore::advanceForColorBitmapFont): * platform/graphics/displaylists/DisplayListItems.cpp: (WebCore::DisplayList::DrawGlyphs::localBounds): (WebCore::DisplayList::DrawLine::localBounds): (WebCore::DisplayList::DrawLinesForText::localBounds): (WebCore::DisplayList::DrawLineForDocumentMarker::localBounds): (WebCore::DisplayList::DrawFocusRingPath::localBounds): (WebCore::DisplayList::DrawFocusRingRects::localBounds): (WebCore::DisplayList::StrokeRect::localBounds): (WebCore::DisplayList::StrokePath::localBounds): (WebCore::DisplayList::StrokeEllipse::localBounds): * platform/graphics/displaylists/DisplayListItems.h: (WebCore::DisplayList::DrawingItem::localBounds): * platform/graphics/displaylists/DisplayListRecorder.cpp: (WebCore::DisplayList::Recorder::updateItemExtent): (WebCore::DisplayList::Recorder::ContextState::rotate): (WebCore::DisplayList::Recorder::ContextState::concatCTM): * platform/graphics/efl/ImageBufferEfl.cpp: (WebCore::encodeImageJPEG): (WebCore::ImageBuffer::toDataURL): * platform/graphics/filters/Filter.h: (WebCore::Filter::mapAbsolutePointToLocalPoint): * platform/graphics/gtk/ImageBufferGtk.cpp: (WebCore::encodeImage): (WebCore::ImageBuffer::toDataURL): * platform/graphics/harfbuzz/HarfBuzzShaper.cpp: (WebCore::HarfBuzzShaper::selectionRect): * platform/graphics/mac/ComplexTextController.cpp: (WebCore::capitalized): (WebCore::shouldSynthesize): * platform/graphics/texmap/TextureMapperLayer.cpp: (WebCore::TextureMapperLayer::paintSelfAndChildrenWithReplica): (WebCore::TextureMapperLayer::replicaTransform): (WebCore::TextureMapperLayer::mapScrollOffset): * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp: (WebCore::CoordinatedGraphicsLayer::transformedVisibleRect): (WebCore::CoordinatedGraphicsLayer::computeTransformedVisibleRect): * platform/graphics/transforms/AffineTransform.cpp: (WebCore::AffineTransform::inverse): * platform/graphics/transforms/AffineTransform.h: * platform/graphics/transforms/TransformState.cpp: (WebCore::TransformState::mappedPoint): (WebCore::TransformState::mappedSecondaryQuad): (WebCore::TransformState::mapQuad): (WebCore::TransformState::flattenWithTransform): * platform/graphics/transforms/TransformState.h: * platform/graphics/transforms/TransformationMatrix.cpp: (WebCore::TransformationMatrix::inverse): * platform/graphics/transforms/TransformationMatrix.h: * platform/graphics/win/ImageBufferDirect2D.cpp: (WebCore::ImageBuffer::toDataURL): * platform/graphics/win/ImageDecoderDirect2D.cpp: (WebCore::ImageDecoder::hotSpot): * platform/graphics/win/ImageDecoderDirect2D.h: * platform/graphics/x11/PlatformDisplayX11.cpp: (WebCore::PlatformDisplayX11::supportsXDamage): * platform/graphics/x11/PlatformDisplayX11.h: * platform/image-decoders/ImageDecoder.h: (WebCore::ImageDecoder::hotSpot): * platform/image-decoders/ico/ICOImageDecoder.cpp: (WebCore::ICOImageDecoder::hotSpot): (WebCore::ICOImageDecoder::hotSpotAtIndex): * platform/image-decoders/ico/ICOImageDecoder.h: * platform/image-encoders/JPEGImageEncoder.cpp: (WebCore::compressRGBABigEndianToJPEG): * platform/image-encoders/JPEGImageEncoder.h: * platform/ios/LegacyTileCache.h: * platform/ios/LegacyTileCache.mm: (WebCore::LegacyTileCache::setOverrideVisibleRect): * platform/ios/LegacyTileLayer.mm: (-[LegacyTileHostLayer renderInContext:]): * platform/linux/MemoryPressureHandlerLinux.cpp: * platform/mac/ThemeMac.h: * platform/mac/ThemeMac.mm: (WebCore::ThemeMac::controlFont): * platform/mediastream/MediaConstraints.cpp: (WebCore::MediaTrackConstraintSetMap::set): * platform/mediastream/MediaConstraints.h: (WebCore::MediaTrackConstraintSetMap::width): (WebCore::MediaTrackConstraintSetMap::height): (WebCore::MediaTrackConstraintSetMap::sampleRate): (WebCore::MediaTrackConstraintSetMap::sampleSize): (WebCore::MediaTrackConstraintSetMap::aspectRatio): (WebCore::MediaTrackConstraintSetMap::frameRate): (WebCore::MediaTrackConstraintSetMap::volume): (WebCore::MediaTrackConstraintSetMap::echoCancellation): (WebCore::MediaTrackConstraintSetMap::facingMode): (WebCore::MediaTrackConstraintSetMap::deviceId): (WebCore::MediaTrackConstraintSetMap::groupId): * platform/mediastream/RealtimeMediaSource.cpp: (WebCore::RealtimeMediaSource::supportsSizeAndFrameRate): (WebCore::RealtimeMediaSource::applySizeAndFrameRate): (WebCore::RealtimeMediaSource::applyConstraints): * platform/mediastream/RealtimeMediaSource.h: * platform/mediastream/mac/AVVideoCaptureSource.h: * platform/mediastream/mac/AVVideoCaptureSource.mm: (WebCore::AVVideoCaptureSource::applySizeAndFrameRate): (WebCore::AVVideoCaptureSource::bestSessionPresetForVideoDimensions): (WebCore::AVVideoCaptureSource::supportsSizeAndFrameRate): * platform/mediastream/openwebrtc/MediaEndpointOwr.h: * platform/network/CacheValidation.cpp: (WebCore::computeCurrentAge): (WebCore::computeFreshnessLifetimeForHTTPFamily): * platform/network/CacheValidation.h: * platform/network/DataURLDecoder.h: * platform/network/HTTPHeaderMap.h: (WebCore::HTTPHeaderMap::HTTPHeaderMapConstIterator::updateKeyValue): * platform/network/HTTPParsers.cpp: (WebCore::parseHTTPDate): * platform/network/HTTPParsers.h: * platform/network/ResourceHandle.cpp: (WebCore::ResourceHandle::didReceiveResponse): * platform/network/ResourceResponseBase.cpp: (WebCore::ResourceResponseBase::cacheControlMaxAge): (WebCore::parseDateValueInHeader): (WebCore::ResourceResponseBase::date): (WebCore::ResourceResponseBase::age): (WebCore::ResourceResponseBase::expires): (WebCore::ResourceResponseBase::lastModified): * platform/network/ResourceResponseBase.h: (WebCore::ResourceResponseBase::certificateInfo): * platform/network/SocketStreamHandle.h: * platform/network/SocketStreamHandleClient.h: * platform/network/cf/SocketStreamHandleImpl.h: * platform/network/cf/SocketStreamHandleImplCFNet.cpp: (WebCore::SocketStreamHandleImpl::readStreamCallback): (WebCore::SocketStreamHandleImpl::platformSend): * platform/network/curl/SocketStreamHandleImpl.h: * platform/network/curl/SocketStreamHandleImplCurl.cpp: (WebCore::SocketStreamHandleImpl::platformSend): * platform/network/mac/CookieJarMac.mm: (WebCore::cookiesInPartitionForURL): * platform/network/soup/SocketStreamHandleImpl.h: * platform/network/soup/SocketStreamHandleImplSoup.cpp: (WebCore::SocketStreamHandleImpl::readBytes): (WebCore::SocketStreamHandleImpl::platformSend): * rendering/BreakLines.h: (WebCore::nextBreakablePositionNonLoosely): (WebCore::nextBreakablePositionLoosely): (WebCore::isBreakable): * rendering/HitTestingTransformState.cpp: (WebCore::HitTestingTransformState::flattenWithTransform): * rendering/ImageQualityController.cpp: (WebCore::ImageQualityController::interpolationQualityFromStyle): (WebCore::ImageQualityController::chooseInterpolationQuality): * rendering/ImageQualityController.h: * rendering/InlineIterator.h: (WebCore::InlineIterator::moveTo): (WebCore::InlineIterator::nextBreakablePosition): (WebCore::InlineIterator::setNextBreakablePosition): * rendering/InlineTextBox.cpp: (WebCore::InlineTextBox::paintSelection): (WebCore::InlineTextBox::substringToRender): (WebCore::InlineTextBox::hyphenatedStringForTextRun): (WebCore::InlineTextBox::constructTextRun): * rendering/InlineTextBox.h: (WebCore::InlineTextBox::substringToRender): (WebCore::InlineTextBox::hyphenatedStringForTextRun): (WebCore::InlineTextBox::constructTextRun): * rendering/OrderIterator.cpp: (WebCore::OrderIterator::reset): * rendering/OrderIterator.h: * rendering/PaintInfo.h: (WebCore::PaintInfo::applyTransform): * rendering/RenderBlock.cpp: (WebCore::RenderBlockRareData::RenderBlockRareData): (WebCore::RenderBlock::baselinePosition): (WebCore::RenderBlock::firstLineBaseline): (WebCore::RenderBlock::inlineBlockBaseline): (WebCore::RenderBlock::setCachedFlowThreadContainingBlockNeedsUpdate): * rendering/RenderBlock.h: * rendering/RenderBlockFlow.cpp: (WebCore::RenderBlockFlow::firstLineBaseline): (WebCore::RenderBlockFlow::inlineBlockBaseline): * rendering/RenderBlockFlow.h: * rendering/RenderBox.cpp: (WebCore::RenderBox::constrainLogicalHeightByMinMax): (WebCore::RenderBox::constrainContentBoxLogicalHeightByMinMax): (WebCore::RenderBox::overrideContainingBlockContentLogicalWidth): (WebCore::RenderBox::overrideContainingBlockContentLogicalHeight): (WebCore::RenderBox::setOverrideContainingBlockContentLogicalWidth): (WebCore::RenderBox::setOverrideContainingBlockContentLogicalHeight): (WebCore::RenderBox::adjustContentBoxLogicalHeightForBoxSizing): (WebCore::RenderBox::computeLogicalHeight): (WebCore::RenderBox::computeLogicalHeightUsing): (WebCore::RenderBox::computeContentLogicalHeight): (WebCore::RenderBox::computeIntrinsicLogicalContentHeightUsing): (WebCore::RenderBox::computeContentAndScrollbarLogicalHeightUsing): (WebCore::RenderBox::computePercentageLogicalHeight): (WebCore::RenderBox::computeReplacedLogicalHeightUsing): (WebCore::RenderBox::availableLogicalHeight): (WebCore::RenderBox::availableLogicalHeightUsing): * rendering/RenderBox.h: (WebCore::RenderBox::firstLineBaseline): (WebCore::RenderBox::inlineBlockBaseline): * rendering/RenderCombineText.cpp: (WebCore::RenderCombineText::computeTextOrigin): * rendering/RenderCombineText.h: * rendering/RenderDeprecatedFlexibleBox.cpp: (WebCore::RenderDeprecatedFlexibleBox::layoutHorizontalBox): * rendering/RenderFlexibleBox.cpp: (WebCore::RenderFlexibleBox::baselinePosition): (WebCore::RenderFlexibleBox::firstLineBaseline): (WebCore::RenderFlexibleBox::inlineBlockBaseline): (WebCore::RenderFlexibleBox::computeMainAxisExtentForChild): (WebCore::RenderFlexibleBox::preferredMainAxisContentExtentForChild): (WebCore::RenderFlexibleBox::marginBoxAscentForChild): (WebCore::RenderFlexibleBox::computeMainSizeFromAspectRatioUsing): (WebCore::RenderFlexibleBox::adjustChildSizeForAspectRatioCrossAxisMinAndMax): (WebCore::RenderFlexibleBox::adjustChildSizeForMinAndMax): * rendering/RenderFlexibleBox.h: * rendering/RenderFlowThread.cpp: (WebCore::RenderFlowThread::addForcedRegionBreak): * rendering/RenderGrid.cpp: (WebCore::GridTrack::setGrowthLimit): (WebCore::GridTrack::setGrowthLimitCap): (WebCore::GridTrack::growthLimitCap): (WebCore::RenderGrid::GridSizingData::freeSpace): (WebCore::RenderGrid::GridSizingData::availableSpace): (WebCore::RenderGrid::GridSizingData::setAvailableSpace): (WebCore::RenderGrid::GridSizingData::setFreeSpace): (WebCore::RenderGrid::layoutBlock): (WebCore::RenderGrid::computeIntrinsicLogicalWidths): (WebCore::RenderGrid::computeIntrinsicLogicalHeight): (WebCore::RenderGrid::computeIntrinsicLogicalContentHeightUsing): (WebCore::RenderGrid::computeUsedBreadthOfGridTracks): (WebCore::overrideContainingBlockContentSizeForChild): (WebCore::setOverrideContainingBlockContentSizeForChild): (WebCore::RenderGrid::logicalHeightForChild): (WebCore::RenderGrid::minSizeForChild): (WebCore::RenderGrid::minContentForChild): (WebCore::RenderGrid::maxContentForChild): (WebCore::RenderGrid::resolveContentBasedTrackSizingFunctionsForNonSpanningItems): (WebCore::sortByGridTrackGrowthPotential): (WebCore::RenderGrid::tracksAreWiderThanMinTrackBreadth): (WebCore::RenderGrid::computeAutoRepeatTracksCount): (WebCore::RenderGrid::applyStretchAlignmentToTracksIfNeeded): (WebCore::RenderGrid::layoutGridItems): * rendering/RenderGrid.h: * rendering/RenderLayer.cpp: (WebCore::RenderLayer::paintLayerByApplyingTransform): (WebCore::RenderLayer::hitTestLayer): * rendering/RenderLayerBacking.cpp: * rendering/RenderListBox.cpp: (WebCore::RenderListBox::paintItem): (WebCore::RenderListBox::listIndexIsVisible): (WebCore::RenderListBox::computeFirstIndexesVisibleInPaddingTopBottomAreas): * rendering/RenderListBox.h: * rendering/RenderMenuList.h: * rendering/RenderMultiColumnSet.cpp: (WebCore::RenderMultiColumnSet::calculateMaxColumnHeight): * rendering/RenderTable.cpp: (WebCore::RenderTable::convertStyleLogicalHeightToComputedHeight): (WebCore::RenderTable::baselinePosition): (WebCore::RenderTable::inlineBlockBaseline): (WebCore::RenderTable::firstLineBaseline): * rendering/RenderTable.h: * rendering/RenderTableCell.cpp: (WebCore::RenderTableCell::cellBaselinePosition): * rendering/RenderTableSection.cpp: (WebCore::RenderTableSection::firstLineBaseline): * rendering/RenderTableSection.h: * rendering/RenderText.cpp: (WebCore::RenderText::computePreferredLogicalWidths): (WebCore::RenderText::stringView): * rendering/RenderText.h: * rendering/RenderTextControl.h: * rendering/RenderView.cpp: (WebCore::RenderView::setSelection): (WebCore::RenderView::splitSelectionBetweenSubtrees): (WebCore::RenderView::getSelection): (WebCore::RenderView::clearSelection): * rendering/RenderView.h: * rendering/SelectionSubtreeRoot.h: (WebCore::SelectionSubtreeRoot::SelectionSubtreeData::SelectionSubtreeData): (WebCore::SelectionSubtreeRoot::SelectionSubtreeData::selectionStartPos): (WebCore::SelectionSubtreeRoot::SelectionSubtreeData::selectionEndPos): (WebCore::SelectionSubtreeRoot::SelectionSubtreeData::setSelectionStartPos): (WebCore::SelectionSubtreeRoot::SelectionSubtreeData::setSelectionEndPos): (WebCore::SelectionSubtreeRoot::SelectionSubtreeData::clearSelection): * rendering/SimpleLineLayout.cpp: (WebCore::SimpleLineLayout::LineState::lastFragment): (WebCore::SimpleLineLayout::closeLineEndingAndAdjustRuns): (WebCore::SimpleLineLayout::createTextRuns): * rendering/SimpleLineLayoutFunctions.cpp: (WebCore::SimpleLineLayout::paintFlow): * rendering/line/BreakingContext.h: (WebCore::WordTrailingSpace::width): (WebCore::BreakingContext::commitLineBreakAtCurrentWidth): (WebCore::BreakingContext::InlineIteratorHistory::nextBreakablePosition): (WebCore::BreakingContext::InlineIteratorHistory::moveTo): (WebCore::tryHyphenating): (WebCore::BreakingContext::computeAdditionalBetweenWordsWidth): (WebCore::BreakingContext::handleText): (WebCore::BreakingContext::optimalLineBreakLocationForTrailingWord): * rendering/mathml/MathMLStyle.cpp: (WebCore::MathMLStyle::resolveMathMLStyle): * rendering/mathml/RenderMathMLBlock.cpp: (WebCore::RenderMathMLBlock::baselinePosition): (WebCore::RenderMathMLTable::firstLineBaseline): * rendering/mathml/RenderMathMLBlock.h: (WebCore::RenderMathMLBlock::ascentForChild): * rendering/mathml/RenderMathMLFraction.cpp: (WebCore::RenderMathMLFraction::firstLineBaseline): * rendering/mathml/RenderMathMLFraction.h: * rendering/mathml/RenderMathMLOperator.cpp: (WebCore::RenderMathMLOperator::firstLineBaseline): * rendering/mathml/RenderMathMLOperator.h: * rendering/mathml/RenderMathMLPadded.cpp: (WebCore::RenderMathMLPadded::firstLineBaseline): * rendering/mathml/RenderMathMLPadded.h: * rendering/mathml/RenderMathMLRow.cpp: (WebCore::RenderMathMLRow::firstLineBaseline): * rendering/mathml/RenderMathMLRow.h: * rendering/mathml/RenderMathMLScripts.cpp: (WebCore::RenderMathMLScripts::validateAndGetReferenceChildren): (WebCore::RenderMathMLScripts::firstLineBaseline): * rendering/mathml/RenderMathMLScripts.h: * rendering/mathml/RenderMathMLSpace.cpp: (WebCore::RenderMathMLSpace::firstLineBaseline): * rendering/mathml/RenderMathMLSpace.h: * rendering/mathml/RenderMathMLToken.cpp: (WebCore::RenderMathMLToken::updateMathVariantGlyph): (WebCore::RenderMathMLToken::firstLineBaseline): * rendering/mathml/RenderMathMLToken.h: * rendering/svg/RenderSVGContainer.cpp: (WebCore::RenderSVGContainer::nodeAtFloatPoint): * rendering/svg/RenderSVGForeignObject.cpp: (WebCore::RenderSVGForeignObject::nodeAtFloatPoint): * rendering/svg/RenderSVGImage.cpp: (WebCore::RenderSVGImage::nodeAtFloatPoint): * rendering/svg/RenderSVGResourceClipper.cpp: (WebCore::RenderSVGResourceClipper::hitTestClipContent): * rendering/svg/RenderSVGResourceFilter.cpp: (WebCore::RenderSVGResourceFilter::postApplyResource): * rendering/svg/RenderSVGRoot.cpp: (WebCore::RenderSVGRoot::nodeAtPoint): * rendering/svg/RenderSVGShape.cpp: (WebCore::RenderSVGShape::setupNonScalingStrokeContext): (WebCore::RenderSVGShape::nodeAtFloatPoint): (WebCore::RenderSVGShape::calculateStrokeBoundingBox): * rendering/svg/RenderSVGText.cpp: (WebCore::RenderSVGText::nodeAtFloatPoint): * rendering/svg/SVGRenderSupport.cpp: (WebCore::SVGRenderSupport::intersectRepaintRectWithShadows): * rendering/svg/SVGRenderingContext.cpp: (WebCore::SVGRenderingContext::clipToImageBuffer): * rendering/svg/SVGTextQuery.cpp: (WebCore::SVGTextQuery::modifyStartEndPositionsRespectingLigatures): * style/RenderTreeUpdater.cpp: (WebCore::RenderTreeUpdater::Parent::Parent): * style/RenderTreeUpdater.h: * style/StyleScope.h: * svg/SVGElement.cpp: (WebCore::SVGElement::parseAttribute): (WebCore::SVGElement::resolveCustomStyle): * svg/SVGElement.h: * svg/SVGToOTFFontConversion.cpp: (WebCore::SVGToOTFFontConverter::transcodeGlyphPaths): (WebCore::SVGToOTFFontConverter::processGlyphElement): (WebCore::SVGToOTFFontConverter::SVGToOTFFontConverter): (WebCore::convertSVGToOTFFont): * svg/SVGToOTFFontConversion.h: * testing/Internals.cpp: (WebCore::Internals::setEventThrottlingBehaviorOverride): (WebCore::Internals::eventThrottlingBehaviorOverride): * testing/Internals.h: * workers/Worker.h: * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::prepareToSend): (WebCore::XMLHttpRequest::didFinishLoading): * xml/XMLHttpRequest.h: Source/WebKit/mac: Use WTF::Optional::value_or. * DOM/DOMHTMLOptionsCollection.mm: (-[DOMHTMLOptionsCollection add:index:]): * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::evaluate): * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView sendEvent:isDrawRect:]): * WebCoreSupport/WebFrameLoaderClient.h: * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::dispatchDidCommitLoad): * WebCoreSupport/WebPaymentCoordinatorClient.h: * WebCoreSupport/WebPaymentCoordinatorClient.mm: (WebPaymentCoordinatorClient::completeShippingMethodSelection): (WebPaymentCoordinatorClient::completeShippingContactSelection): (WebPaymentCoordinatorClient::completePaymentMethodSelection): * WebCoreSupport/WebSecurityOrigin.mm: (-[WebSecurityOrigin port]): * WebView/WebHTMLView.mm: (toAction): (toTag): Source/WebKit/win: Use WTF::Optional::value_or. * Plugins/PluginView.cpp: (WebCore::PluginView::performRequest): * WebCoreSupport/WebFrameLoaderClient.cpp: (WebFrameLoaderClient::dispatchDidCommitLoad): * WebCoreSupport/WebFrameLoaderClient.h: * WebSecurityOrigin.cpp: (WebSecurityOrigin::port): Source/WebKit2: * NetworkProcess/NetworkDataTask.cpp: (WebKit::NetworkDataTask::didReceiveResponse): * NetworkProcess/NetworkLoad.h: * NetworkProcess/cache/NetworkCache.cpp: (WebKit::NetworkCache::responseHasExpired): * NetworkProcess/cache/NetworkCacheCoders.h: (WebKit::NetworkCache::Coder<std::optional<T>>::encode): (WebKit::NetworkCache::Coder<std::optional<T>>::decode): (WebKit::NetworkCache::Coder<Optional<T>>::encode): Deleted. (WebKit::NetworkCache::Coder<Optional<T>>::decode): Deleted. * NetworkProcess/cache/NetworkCacheData.cpp: (WebKit::NetworkCache::readOrMakeSalt): * NetworkProcess/cache/NetworkCacheData.h: * NetworkProcess/cache/NetworkCacheSpeculativeLoadManager.cpp: (WebKit::NetworkCache::SpeculativeLoadManager::PreloadedEntry::PreloadedEntry): (WebKit::NetworkCache::SpeculativeLoadManager::PreloadedEntry::revalidationRequest): (WebKit::NetworkCache::SpeculativeLoadManager::addPreloadedEntry): * NetworkProcess/cache/NetworkCacheSpeculativeLoadManager.h: * NetworkProcess/cache/NetworkCacheStatistics.cpp: (WebKit::NetworkCache::Statistics::recordNotUsingCacheForRequest): (WebKit::NetworkCache::Statistics::recordRetrievalFailure): (WebKit::NetworkCache::Statistics::queryWasEverRequested): * NetworkProcess/cache/NetworkCacheStatistics.h: * NetworkProcess/cache/NetworkCacheStorage.cpp: (WebKit::NetworkCache::Storage::storeBodyAsBlob): (WebKit::NetworkCache::Storage::encodeRecord): (WebKit::NetworkCache::Storage::dispatchWriteOperation): * NetworkProcess/cache/NetworkCacheStorage.h: * Platform/IPC/ArgumentCoders.h: (IPC::ArgumentCoder<std::optional<T>>::encode): (IPC::ArgumentCoder<std::optional<T>>::decode): (IPC::ArgumentCoder<WTF::Optional<T>>::encode): Deleted. (IPC::ArgumentCoder<WTF::Optional<T>>::decode): Deleted. * Platform/IPC/Connection.h: (IPC::Connection::sendWithReply): * Platform/SharedMemory.h: * Platform/unix/SharedMemoryUnix.cpp: (WebKit::SharedMemory::map): * Scripts/webkit/messages.py: (class_template_headers): * Shared/API/APISecurityOrigin.h: (API::SecurityOrigin::create): * Shared/API/Cocoa/_WKRemoteObjectInterface.mm: * Shared/API/c/WKSecurityOriginRef.cpp: (WKSecurityOriginGetPort): * Shared/SessionState.h: * Shared/WebPageCreationParameters.h: * Shared/mac/ObjCObjectGraph.mm: (WebKit::typeFromObject): * Shared/mac/SecItemShim.cpp: (WebKit::sendSecItemRequest): * UIProcess/API/C/WKKeyValueStorageManager.cpp: (WKKeyValueStorageManagerGetStorageDetailsByOrigin): * UIProcess/API/Cocoa/WKSecurityOrigin.mm: (-[WKSecurityOrigin port]): * UIProcess/API/Cocoa/WKWebView.mm: (-[WKWebView _didCommitLayerTree:]): (-[WKWebView _navigationGestureDidEnd]): * UIProcess/API/Cocoa/WKWebsiteDataRecordInternal.h: (WebKit::toWebsiteDataType): * UIProcess/API/efl/EwkView.cpp: (EwkView::setCursor): * UIProcess/API/mac/WKView.mm: (toCoreScrollbarStyle): (toAPIScrollbarStyle): * UIProcess/ApplePay/WebPaymentCoordinatorProxy.cpp: (WebKit::WebPaymentCoordinatorProxy::completeShippingMethodSelection): (WebKit::WebPaymentCoordinatorProxy::completeShippingContactSelection): (WebKit::WebPaymentCoordinatorProxy::completePaymentMethodSelection): * UIProcess/ApplePay/WebPaymentCoordinatorProxy.h: * UIProcess/ApplePay/WebPaymentCoordinatorProxy.messages.in: * UIProcess/ApplePay/cocoa/WebPaymentCoordinatorProxyCocoa.mm: (WebKit::toPKPaymentSummaryItem): (WebKit::WebPaymentCoordinatorProxy::platformCompleteShippingMethodSelection): (WebKit::WebPaymentCoordinatorProxy::platformCompleteShippingContactSelection): (WebKit::WebPaymentCoordinatorProxy::platformCompletePaymentMethodSelection): * UIProcess/Automation/WebAutomationSession.cpp: (WebKit::WebAutomationSession::webFrameIDForHandle): (WebKit::WebAutomationSession::switchToBrowsingContext): (WebKit::WebAutomationSession::evaluateJavaScriptFunction): (WebKit::WebAutomationSession::resolveChildFrameHandle): (WebKit::WebAutomationSession::resolveParentFrameHandle): (WebKit::WebAutomationSession::computeElementLayout): * UIProcess/Automation/WebAutomationSession.h: * UIProcess/Cocoa/WebViewImpl.h: * UIProcess/Cocoa/WebViewImpl.mm: (WebKit::WebViewImpl::updateViewExposedRect): (WebKit::WebViewImpl::setOverlayScrollbarStyle): (WebKit::WebViewImpl::overlayScrollbarStyle): * UIProcess/DrawingAreaProxy.cpp: (WebKit::DrawingAreaProxy::setViewExposedRect): * UIProcess/DrawingAreaProxy.h: (WebKit::DrawingAreaProxy::viewExposedRect): * UIProcess/InspectorServer/WebSocketServerConnection.cpp: (WebKit::WebSocketServerConnection::didReceiveSocketStreamData): * UIProcess/InspectorServer/WebSocketServerConnection.h: * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.cpp: (WebKit::RemoteScrollingCoordinatorProxy::scrollingTreeNodeDidScroll): * UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.h: * UIProcess/Scrolling/RemoteScrollingTree.cpp: (WebKit::RemoteScrollingTree::scrollingTreeNodeDidScroll): * UIProcess/Scrolling/RemoteScrollingTree.h: * UIProcess/Storage/LocalStorageDatabaseTracker.cpp: (WebKit::fileCreationTime): (WebKit::fileModificationTime): * UIProcess/Storage/LocalStorageDatabaseTracker.h: * UIProcess/UserMediaPermissionRequestManagerProxy.cpp: (WebKit::UserMediaPermissionRequestManagerProxy::enumerateMediaDevicesForFrame): * UIProcess/WebBackForwardList.cpp: (WebKit::WebBackForwardList::backForwardListState): (WebKit::WebBackForwardList::restoreFromState): * UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::didCommitLoadForFrame): (WebKit::WebPageProxy::creationParameters): (WebKit::WebPageProxy::setOverlayScrollbarStyle): * UIProcess/WebPageProxy.h: (WebKit::WebPageProxy::overlayScrollbarStyle): * UIProcess/WebPageProxy.messages.in: * UIProcess/WebsiteData/WebsiteDataRecord.h: * UIProcess/efl/WebView.cpp: (WebKit::WebView::transformFromScene): * UIProcess/gtk/AcceleratedBackingStoreX11.cpp: * UIProcess/gtk/WebPreferencesGtk.cpp: (WebKit::WebPreferences::platformInitializeStore): * UIProcess/ios/WKContentViewInteraction.mm: (-[WKContentView _scrollOffsetForEvent:]): (-[WKContentView _interpretKeyEvent:isCharEvent:]): * UIProcess/mac/LegacySessionStateCoding.cpp: (WebKit::encodeFormDataElement): (WebKit::decodeFormDataElement): (WebKit::decodeV1SessionHistory): * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.h: * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm: (WebKit::RemoteLayerTreeDrawingAreaProxy::setViewExposedRect): * WebProcess/ApplePay/WebPaymentCoordinator.cpp: (WebKit::WebPaymentCoordinator::completeShippingMethodSelection): (WebKit::WebPaymentCoordinator::completeShippingContactSelection): (WebKit::WebPaymentCoordinator::completePaymentMethodSelection): * WebProcess/ApplePay/WebPaymentCoordinator.h: * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp: (WKBundlePageSetEventThrottlingBehaviorOverride): * WebProcess/Plugins/PDF/DeprecatedPDFPlugin.mm: (WebKit::PDFPlugin::convertFromPDFViewToRootView): (WebKit::PDFPlugin::convertFromPDFViewToScreen): (WebKit::PDFPlugin::boundsOnScreen): (WebKit::PDFPlugin::geometryDidChange): * WebProcess/Plugins/PDF/PDFPlugin.mm: (WebKit::PDFPlugin::geometryDidChange): * WebProcess/Plugins/PluginView.cpp: (WebKit::PluginView::performFrameLoadURLRequest): (WebKit::PluginView::evaluate): * WebProcess/Plugins/WebPluginInfoProvider.cpp: (WebKit::WebPluginInfoProvider::pluginLoadClientPolicyForHost): * WebProcess/Plugins/WebPluginInfoProvider.h: * WebProcess/Scrolling/RemoteScrollingCoordinator.mm: (WebKit::RemoteScrollingCoordinator::scrollPositionChangedForNode): * WebProcess/WebCoreSupport/SessionStateConversion.cpp: (WebKit::toFormData): * WebProcess/WebCoreSupport/WebChromeClient.cpp: (WebKit::WebChromeClient::preferredScrollbarOverlayStyle): * WebProcess/WebCoreSupport/WebChromeClient.h: * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp: (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad): * WebProcess/WebCoreSupport/WebFrameLoaderClient.h: * WebProcess/WebPage/DrawingArea.h: * WebProcess/WebPage/DrawingArea.messages.in: * WebProcess/WebPage/WebFrame.cpp: (WebKit::WebFrame::certificateInfo): * WebProcess/WebPage/WebPage.cpp: (WebKit::m_userInterfaceLayoutDirection): (WebKit::WebPage::setScrollbarOverlayStyle): * WebProcess/WebPage/WebPage.h: (WebKit::WebPage::scrollbarOverlayStyle): * WebProcess/WebPage/WebPage.messages.in: * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h: * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm: (WebKit::RemoteLayerTreeDrawingArea::setViewExposedRect): * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h: * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm: (WebKit::TiledCoreAnimationDrawingArea::setViewExposedRect): Source/WTF: Import std::optional reference implementation offered by the C++17 original proposal paper. It has the same interface and functionality to the C++17's one. Previous WTF::Optional lacks several functionalities. The largest one is the correct constexpr constructors. This fact prevents us from using Optional<literal type> in constexpr context in WebKit. In WebKit, we do not allow global constructors. So only the constexpr constructor is the way to use WTF::Optional in the static const global variables. WTF::Optional is used in DOMJIT::Effect and we would like to emit static const global variables that includes this DOMJIT::Effect. That is the main motivation of this work. This functionality allows the IDL code generator to emit DOMJIT signatures as static const global variables. We import the reference implementation one instead of LLVM libc++'s one. This is because LLVM libc++'s one depends on many macro and type_traits offered by libc++ implementation. And adopting it to WebKit requires large modification compared to this reference implementation one. Furthermore, it is difficult to compile libc++'s optional in old GCC and VC++. It also requires some more modifications. To keep the thing simple, we import the reference implementation one now. Once C++17 is released and we update the compiler baseline, we can smoothly switch to the standard library's std::optional. We also add support for the environment that does not use exceptions to this reference implementation. And we also add valueOrCompute helper function. That keeps the extended functionality that previous WTF::Optional has. * wtf/CrossThreadQueue.h: (WTF::CrossThreadQueue<DataType>::tryGetMessage): * wtf/Expected.h: (WTF::makeExpected): * wtf/Forward.h: * wtf/HashTraits.h: (WTF::HashTraits<Ref<P>>::take): * wtf/MainThread.cpp: (WTF::initializeGCThreads): (WTF::mayBeGCThread): * wtf/MainThread.h: * wtf/Optional.h: (std::detail_::is_assignable::has_assign): (std::detail_::has_overloaded_addressof::has_overload): (std::detail_::static_addressof): (std::detail_::convert): (std::nullopt_t::nullopt_t): (std::bad_optional_access::bad_optional_access): (std::optional_base::optional_base): (std::optional_base::~optional_base): (std::constexpr_optional_base::constexpr_optional_base): (std::optional::dataptr): (std::optional::contained_val): (std::optional::__NOEXCEPT_): (std::optional::optional): (std::optional::operator=): (std::optional::emplace): (std::optional::operator ->): (std::optional::operator *): (std::optional::value): (std::optional::value_or): (std::operator==): (std::operator!=): (std::operator<): (std::operator>): (std::operator<=): (std::operator>=): (std::__NOEXCEPT_): (std::make_optional): (std::hash<std::optional<T>>::operator()): (WTF::NulloptTag::NulloptTag): Deleted. (WTF::Optional::Optional): Deleted. (WTF::Optional::~Optional): Deleted. (WTF::Optional::operator=): Deleted. (WTF::Optional::operator bool): Deleted. (WTF::Optional::operator->): Deleted. (WTF::Optional::operator*): Deleted. (WTF::Optional::value): Deleted. (WTF::Optional::valueOr): Deleted. (WTF::Optional::valueOrCompute): Deleted. (WTF::Optional::asPtr): Deleted. (WTF::Optional::destroy): Deleted. (WTF::operator==): Deleted. (WTF::operator!=): Deleted. (WTF::makeOptional): Deleted. (WTF::printInternal): Deleted. * wtf/text/StringView.cpp: (WTF::StringView::GraphemeClusters::Iterator::Impl::Impl): (WTF::StringView::GraphemeClusters::Iterator::Iterator): * wtf/text/StringView.h: Tools: Use WTF::Optional::value_or. * DumpRenderTree/ios/UIScriptControllerIOS.mm: (WTR::UIScriptController::stableStateOverride): (WTR::UIScriptController::setStableStateOverride): * TestRunnerShared/Bindings/JSWrappable.h: (WTR::JSValueMakeBooleanOrNull): (WTR::JSValueToNullableBoolean): * TestRunnerShared/UIScriptContext/UIScriptController.cpp: (WTR::UIScriptController::stableStateOverride): (WTR::UIScriptController::setStableStateOverride): * TestRunnerShared/UIScriptContext/UIScriptController.h: * TestWebKitAPI/Tests/WTF/Optional.cpp: (TestWebKitAPI::TEST): * TestWebKitAPI/Tests/WebCore/HTMLParserIdioms.cpp: (TestWebKitAPI::testParseHTMLInteger): (TestWebKitAPI::testParseHTMLNonNegativeInteger): * TestWebKitAPI/Tests/WebCore/URLParser.cpp: (TestWebKitAPI::checkURL): (TestWebKitAPI::checkRelativeURL): (TestWebKitAPI::checkURLDifferences): (TestWebKitAPI::checkRelativeURLDifferences): * WebKitTestRunner/ios/UIScriptControllerIOS.mm: (WTR::UIScriptController::stableStateOverride): (WTR::UIScriptController::setStableStateOverride): Canonical link: https://commits.webkit.org/182693@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@208985 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-11-27 06:08:16 +00:00
[WebCrypto] remove toJSValueFromJsonWebKey from custom SubtleCrypto binding codes https://bugs.webkit.org/show_bug.cgi?id=167026 Reviewed by Chris Dumez. Source/WebCore: Covered by existing tests. * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::jsSubtleCryptoFunctionExportKeyPromise): (WebCore::jsSubtleCryptoFunctionWrapKeyPromise): (WebCore::toJSValueFromJsonWebKey): Deleted. * crypto/JsonWebKey.h: * crypto/JsonWebKey.idl: * crypto/RsaOtherPrimesInfo.idl: Change std::optional<String> to String in order to use toJS<IDLDictionary<JsonWebKey>>. * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: (WebCore::CryptoAlgorithmAES_CBC::importKey): * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: (WebCore::CryptoAlgorithmAES_KW::importKey): * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::importKey): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: (WebCore::CryptoAlgorithmRSA_OAEP::importKey): * crypto/keys/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::importJwk): Only check if key_ops contains all of the specified usages when key_ops field of jwk is present, as per the specification: https://www.w3.org/TR/WebCryptoAPI/#aes-cbc-operations * crypto/keys/CryptoKeyAES.h: * crypto/keys/CryptoKeyHMAC.cpp: (WebCore::CryptoKeyHMAC::importJwk): * crypto/keys/CryptoKeyHMAC.h: * crypto/keys/CryptoKeyRSA.cpp: (WebCore::CryptoKeyRSA::importJwk): Accommodate the change from std::optional<String> to String. * crypto/mac/CryptoKeyRSAMac.cpp: (WebCore::CryptoKeyRSA::create): Add a null check for p. LayoutTests: * crypto/subtle/aes-cbc-import-key-wrap-jwk-rsa-key-private.html: * crypto/subtle/aes-cbc-import-key-wrap-jwk-rsa-key-public.html: Order of attributes inside JWK is different after this patch. * crypto/subtle/aes-import-key-malformed-parameters-expected.txt: * crypto/subtle/aes-import-key-malformed-parameters.html: * crypto/subtle/hmac-import-key-malformed-parameters-expected.txt: * crypto/subtle/hmac-import-key-malformed-parameters.html: * crypto/subtle/rsa-import-key-malformed-parameters-expected.txt: * crypto/subtle/rsa-import-key-malformed-parameters.html: * crypto/workers/subtle/resources/aes-cbc-import-key-wrap-key.js: Canonical link: https://commits.webkit.org/185480@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@212465 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2017-02-16 22:31:14 +00:00
String crv;
String x;
String y;
String d;
String n;
String e;
String p;
String q;
String dp;
String dq;
String qi;
Remove WTF::Optional synonym for std::optional, using that class template directly instead https://bugs.webkit.org/show_bug.cgi?id=226433 Reviewed by Chris Dumez. Source/JavaScriptCore: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. * inspector/scripts/codegen/generate_objc_protocol_types_implementation.py: (ObjCProtocolTypesImplementationGenerator._generate_init_method_for_payload): Use auto instead of Optional<>. Also use * instead of value() and nest the definition of the local inside an if statement in the case where it's an optional. * inspector/scripts/tests/expected/*: Regenerated these results. Source/WebCore: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebCore/PAL: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebDriver: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebKit: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. * Scripts/webkit/tests: Regenerated expected results, by running the command "python Scripts/webkit/messages_unittest.py -r". (How am I supposed to know to do that?) Source/WebKitLegacy/ios: * WebCoreSupport/WebChromeClientIOS.h: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebKitLegacy/mac: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WebKitLegacy/win: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Source/WTF: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. * wtf/Optional.h: Remove WTF::Optional. Tools: * <many files>: Let the do-webcore-rename script rename Optional<> to std::optional<>. Canonical link: https://commits.webkit.org/238290@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@278253 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2021-05-30 16:11:40 +00:00
std::optional<Vector<RsaOtherPrimesInfo>> oth;
[WebCrypto] remove toJSValueFromJsonWebKey from custom SubtleCrypto binding codes https://bugs.webkit.org/show_bug.cgi?id=167026 Reviewed by Chris Dumez. Source/WebCore: Covered by existing tests. * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::jsSubtleCryptoFunctionExportKeyPromise): (WebCore::jsSubtleCryptoFunctionWrapKeyPromise): (WebCore::toJSValueFromJsonWebKey): Deleted. * crypto/JsonWebKey.h: * crypto/JsonWebKey.idl: * crypto/RsaOtherPrimesInfo.idl: Change std::optional<String> to String in order to use toJS<IDLDictionary<JsonWebKey>>. * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: (WebCore::CryptoAlgorithmAES_CBC::importKey): * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: (WebCore::CryptoAlgorithmAES_KW::importKey): * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::importKey): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: (WebCore::CryptoAlgorithmRSA_OAEP::importKey): * crypto/keys/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::importJwk): Only check if key_ops contains all of the specified usages when key_ops field of jwk is present, as per the specification: https://www.w3.org/TR/WebCryptoAPI/#aes-cbc-operations * crypto/keys/CryptoKeyAES.h: * crypto/keys/CryptoKeyHMAC.cpp: (WebCore::CryptoKeyHMAC::importJwk): * crypto/keys/CryptoKeyHMAC.h: * crypto/keys/CryptoKeyRSA.cpp: (WebCore::CryptoKeyRSA::importJwk): Accommodate the change from std::optional<String> to String. * crypto/mac/CryptoKeyRSAMac.cpp: (WebCore::CryptoKeyRSA::create): Add a null check for p. LayoutTests: * crypto/subtle/aes-cbc-import-key-wrap-jwk-rsa-key-private.html: * crypto/subtle/aes-cbc-import-key-wrap-jwk-rsa-key-public.html: Order of attributes inside JWK is different after this patch. * crypto/subtle/aes-import-key-malformed-parameters-expected.txt: * crypto/subtle/aes-import-key-malformed-parameters.html: * crypto/subtle/hmac-import-key-malformed-parameters-expected.txt: * crypto/subtle/hmac-import-key-malformed-parameters.html: * crypto/subtle/rsa-import-key-malformed-parameters-expected.txt: * crypto/subtle/rsa-import-key-malformed-parameters.html: * crypto/workers/subtle/resources/aes-cbc-import-key-wrap-key.js: Canonical link: https://commits.webkit.org/185480@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@212465 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2017-02-16 22:31:14 +00:00
String k;
Update SubtleCrypto::generateKey to match the latest spec https://bugs.webkit.org/show_bug.cgi?id=163718 <rdar://problem/28864380> Reviewed by Chris Dumez. LayoutTests/imported/w3c: * WebCryptoAPI/generateKey/test_aes-cbc-expected.txt: * WebCryptoAPI/generateKey/test_aes-cbc.html: * WebCryptoAPI/generateKey/test_aes-ctr-expected.txt: * WebCryptoAPI/generateKey/test_aes-ctr.html: * WebCryptoAPI/generateKey/test_failures-expected.txt: * WebCryptoAPI/generateKey/test_failures.html: * WebCryptoAPI/generateKey/test_failures_AES-CBC-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-CBC.html: * WebCryptoAPI/generateKey/test_failures_AES-CTR-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-CTR.html: * WebCryptoAPI/generateKey/test_failures_AES-GCM-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-GCM.html: * WebCryptoAPI/generateKey/test_failures_AES-KW-expected.txt: * WebCryptoAPI/generateKey/test_failures_AES-KW.html: * WebCryptoAPI/generateKey/test_failures_ECDH-expected.txt: * WebCryptoAPI/generateKey/test_failures_ECDH.html: * WebCryptoAPI/generateKey/test_failures_ECDSA-expected.txt: * WebCryptoAPI/generateKey/test_failures_ECDSA.html: * WebCryptoAPI/generateKey/test_failures_HMAC-expected.txt: * WebCryptoAPI/generateKey/test_failures_HMAC.html: * WebCryptoAPI/generateKey/test_failures_RSA-OAEP-expected.txt: * WebCryptoAPI/generateKey/test_failures_RSA-OAEP.html: * WebCryptoAPI/generateKey/test_failures_RSA-PSS-expected.txt: * WebCryptoAPI/generateKey/test_failures_RSA-PSS.html: * WebCryptoAPI/generateKey/test_failures_RSASSA-PKCS1-v1_5-expected.txt: * WebCryptoAPI/generateKey/test_failures_RSASSA-PKCS1-v1_5.html: * WebCryptoAPI/generateKey/test_successes-expected.txt: * WebCryptoAPI/generateKey/test_successes.html: * WebCryptoAPI/generateKey/test_successes_AES-CBC-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-CBC.html: * WebCryptoAPI/generateKey/test_successes_AES-CTR-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-CTR.html: * WebCryptoAPI/generateKey/test_successes_AES-GCM-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-GCM.html: * WebCryptoAPI/generateKey/test_successes_AES-KW-expected.txt: * WebCryptoAPI/generateKey/test_successes_AES-KW.html: * WebCryptoAPI/generateKey/test_successes_ECDH-expected.txt: * WebCryptoAPI/generateKey/test_successes_ECDH.html: * WebCryptoAPI/generateKey/test_successes_ECDSA-expected.txt: * WebCryptoAPI/generateKey/test_successes_ECDSA.html: * WebCryptoAPI/generateKey/test_successes_HMAC-expected.txt: * WebCryptoAPI/generateKey/test_successes_HMAC.html: * WebCryptoAPI/generateKey/test_successes_RSA-OAEP-expected.txt: * WebCryptoAPI/generateKey/test_successes_RSA-OAEP.html: * WebCryptoAPI/generateKey/test_successes_RSA-PSS-expected.txt: * WebCryptoAPI/generateKey/test_successes_RSA-PSS.html: * WebCryptoAPI/generateKey/test_successes_RSASSA-PKCS1-v1_5-expected.txt: * WebCryptoAPI/generateKey/test_successes_RSASSA-PKCS1-v1_5.html: * WebCryptoAPI/idlharness-expected.txt: Source/WebCore: This patch does following few things: 1. It updates the SubtleCrypto::generateKey method to match the latest spec: https://www.w3.org/TR/WebCryptoAPI/#SubtleCrypto-method-generateKey. It also refers to the latest Editor's Draft at a certain degree: https://w3c.github.io/webcrypto/Overview.html#SubtleCrypto-method-generateKey. 2. It implements generateKey operations of following algorithms: AES-CBC, AES-KW, HMAC, RSAES-PKCS1-V1_5, RSASSA-PKCS1-V1_5, and RSA-OAEP. 3. It replaces SPECIALIZE_TYPE_TRAITS_CRYPTO_ALGORITHM_PARAMETERS with SPECIALIZE_TYPE_TRAITS_CRYPTO_ALGORITHM_PARAMETERS_DEPRECATED for deprecated params. 4. It fixes https://bugs.webkit.org/show_bug.cgi?id=129750 as well. Tests: crypto/subtle/aes-cbc-generate-key-length-128.html crypto/subtle/aes-cbc-generate-key-length-192.html crypto/subtle/aes-cbc-generate-key-length-256.html crypto/subtle/aes-generate-key-malformed-parameters.html crypto/subtle/aes-kw-generate-key.html crypto/subtle/generate-key-malformed-paramters.html crypto/subtle/hmac-generate-key-customized-length.html crypto/subtle/hmac-generate-key-hash-object.html crypto/subtle/hmac-generate-key-malformed-parameters.html crypto/subtle/hmac-generate-key-sha1.html crypto/subtle/hmac-generate-key-sha224.html crypto/subtle/hmac-generate-key-sha256.html crypto/subtle/hmac-generate-key-sha384.html crypto/subtle/hmac-generate-key-sha512.html crypto/subtle/rsa-generate-key-malformed-parameters.html crypto/subtle/rsa-oaep-generate-key.html crypto/subtle/rsaes-pkcs1-v1_5-generate-key-extractable.html crypto/subtle/rsaes-pkcs1-v1_5-generate-key.html crypto/subtle/rsassa-pkcs1-v1_5-generate-key.html crypto/webkitSubtle/hmac-generate-key.html: crypto/workers/subtle/aes-generate-key.html crypto/workers/subtle/hmac-generate-key.html crypto/workers/subtle/rsa-generate-key.html * CMakeLists.txt: * DerivedSources.make: * Modules/encryptedmedia/CDMSessionClearKey.cpp: * WebCore.xcodeproj/project.pbxproj: * bindings/js/JSSubtleCryptoCustom.cpp: Added. (WebCore::toHashIdentifier): (WebCore::normalizeCryptoAlgorithmParameters): (WebCore::cryptoKeyUsagesFromJSValue): (WebCore::createAlgorithm): (WebCore::rejectWithException): (WebCore::jsSubtleCryptoFunctionGenerateKeyPromise): (WebCore::JSSubtleCrypto::generateKey): * bindings/js/JSWebKitSubtleCryptoCustom.cpp: (WebCore::JSWebKitSubtleCrypto::generateKey): * crypto/CryptoAlgorithm.cpp: (WebCore::CryptoAlgorithm::generateKey): * crypto/CryptoAlgorithm.h: * crypto/CryptoAlgorithmParameters.h: Added. (WebCore::CryptoAlgorithmParameters::CryptoAlgorithmParameters): (WebCore::CryptoAlgorithmParameters::~CryptoAlgorithmParameters): (WebCore::CryptoAlgorithmParameters::parametersClass): * crypto/CryptoAlgorithmParameters.idl: Added. * crypto/CryptoAlgorithmParametersDeprecated.h: * crypto/CryptoKey.cpp: (WebCore::CryptoKey::setUsagesBitmap): * crypto/CryptoKey.h: * crypto/CryptoKeyPair.idl: * crypto/SubtleCrypto.idl: * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: (WebCore::CryptoAlgorithmAES_CBC::generateKey): * crypto/algorithms/CryptoAlgorithmAES_CBC.h: * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: (WebCore::CryptoAlgorithmAES_KW::generateKey): * crypto/algorithms/CryptoAlgorithmAES_KW.h: * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::generateKey): * crypto/algorithms/CryptoAlgorithmHMAC.h: * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::generateKey): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::generateKey): * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: (WebCore::CryptoAlgorithmRSA_OAEP::generateKey): * crypto/algorithms/CryptoAlgorithmRSA_OAEP.h: * crypto/gnutls/CryptoKeyRSAGnuTLS.cpp: (WebCore::CryptoKeyRSA::generatePair): * crypto/keys/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::generate): * crypto/keys/CryptoKeyHMAC.cpp: (WebCore::CryptoKeyHMAC::generate): * crypto/keys/CryptoKeyRSA.h: * crypto/mac/CryptoKeyRSAMac.cpp: (WebCore::CryptoKeyRSA::generatePair): * crypto/parameters/AesKeyGenParams.idl: Added. * crypto/parameters/CryptoAlgorithmAesCbcParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmAesKeyGenParams.h: Added. * crypto/parameters/CryptoAlgorithmAesKeyGenParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmHmacKeyGenParams.h: Added. * crypto/parameters/CryptoAlgorithmHmacKeyParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmHmacParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaHashedKeyGenParams.h: Added. * crypto/parameters/CryptoAlgorithmRsaKeyGenParams.h: Added. (WebCore::CryptoAlgorithmRsaKeyGenParams::arrayToVector): * crypto/parameters/CryptoAlgorithmRsaKeyGenParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaKeyParamsWithHashDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaOaepParamsDeprecated.h: * crypto/parameters/CryptoAlgorithmRsaSsaParamsDeprecated.h: * crypto/parameters/HmacKeyGenParams.idl: Added. * crypto/parameters/RsaHashedKeyGenParams.idl: Added. * crypto/parameters/RsaKeyGenParams.idl: Added. LayoutTests: Besides adding tests for SubtleCrypto::generateKey related stuff and fixing HMAC. This patch also add shouldReject(_a, _rejectCallback, _resolveCallback, _message) in js-test-pre.js. * TestExpectations: * crypto/subtle/aes-cbc-generate-key-length-128-expected.txt: Added. * crypto/subtle/aes-cbc-generate-key-length-128.html: Added. * crypto/subtle/aes-cbc-generate-key-length-192-expected.txt: Added. * crypto/subtle/aes-cbc-generate-key-length-192.html: Added. * crypto/subtle/aes-cbc-generate-key-length-256-expected.txt: Added. * crypto/subtle/aes-cbc-generate-key-length-256.html: Added. * crypto/subtle/aes-generate-key-malformed-parameters-expected.txt: Added. * crypto/subtle/aes-generate-key-malformed-parameters.html: Added. * crypto/subtle/aes-kw-generate-key-expected.txt: Added. * crypto/subtle/aes-kw-generate-key.html: Added. * crypto/subtle/generate-key-malformed-paramters-expected.txt: Added. * crypto/subtle/generate-key-malformed-paramters.html: Added. * crypto/subtle/hmac-generate-key-customized-length-expected.txt: Added. * crypto/subtle/hmac-generate-key-customized-length.html: Added. * crypto/subtle/hmac-generate-key-hash-object-expected.txt: Added. * crypto/subtle/hmac-generate-key-hash-object.html: Added. * crypto/subtle/hmac-generate-key-malformed-parameters-expected.txt: Added. * crypto/subtle/hmac-generate-key-malformed-parameters.html: Added. * crypto/subtle/hmac-generate-key-sha1-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha1.html: Added. * crypto/subtle/hmac-generate-key-sha224-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha224.html: Added. * crypto/subtle/hmac-generate-key-sha256-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha256.html: Added. * crypto/subtle/hmac-generate-key-sha384-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha384.html: Added. * crypto/subtle/hmac-generate-key-sha512-expected.txt: Added. * crypto/subtle/hmac-generate-key-sha512.html: Added. * crypto/subtle/rsa-generate-key-malformed-parameters-expected.txt: Added. * crypto/subtle/rsa-generate-key-malformed-parameters.html: Added. * crypto/subtle/rsa-oaep-generate-key-expected.txt: Added. * crypto/subtle/rsa-oaep-generate-key.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key-extractable-expected.txt: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key-extractable.html: Added. * crypto/subtle/rsaes-pkcs1-v1_5-generate-key.html: Added. * crypto/subtle/rsassa-pkcs1-v1_5-generate-key-expected.txt: Added. * crypto/subtle/rsassa-pkcs1-v1_5-generate-key.html: Added. * crypto/webkitSubtle/hmac-generate-key-expected.txt: * crypto/webkitSubtle/hmac-generate-key.html: * crypto/workers/subtle/aes-generate-key-expected.txt: Added. * crypto/workers/subtle/aes-generate-key.html: Added. * crypto/workers/subtle/hmac-generate-key-expected.txt: Added. * crypto/workers/subtle/hmac-generate-key.html: Added. * crypto/workers/subtle/resources/aes-generate-key.js: Added. * crypto/workers/subtle/resources/hmac-generate-key.js: Added. * crypto/workers/subtle/resources/rsa-generate-key.js: Added. * crypto/workers/subtle/rsa-generate-key-expected.txt: Added. * crypto/workers/subtle/rsa-generate-key.html: Added. * resources/js-test-pre.js: Canonical link: https://commits.webkit.org/181666@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@207809 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-10-25 06:07:04 +00:00
};
} // namespace WebCore
Rename ENABLE_SUBTLE_CRYPTO to ENABLE_WEB_CRYPTO https://bugs.webkit.org/show_bug.cgi?id=192197 Reviewed by Jiewen Tan. .: * Source/cmake/OptionsGTK.cmake: * Source/cmake/OptionsWPE.cmake: * Source/cmake/OptionsWin.cmake: * Source/cmake/WebKitFeatures.cmake: Source/JavaScriptCore: * Configurations/FeatureDefines.xcconfig: Source/WebCore: No new tests. No change in behavior. * Configurations/FeatureDefines.xcconfig: * bindings/js/SerializedScriptValue.cpp: (WebCore::CloneSerializer::dumpIfTerminal): (WebCore::CloneDeserializer::readTerminal): * crypto/CommonCryptoUtilities.cpp: * crypto/CommonCryptoUtilities.h: * crypto/CryptoAlgorithm.cpp: * crypto/CryptoAlgorithm.h: * crypto/CryptoAlgorithmIdentifier.h: * crypto/CryptoAlgorithmParameters.h: * crypto/CryptoAlgorithmParameters.idl: * crypto/CryptoAlgorithmRegistry.cpp: * crypto/CryptoAlgorithmRegistry.h: * crypto/CryptoKey.cpp: * crypto/CryptoKey.h: * crypto/CryptoKey.idl: * crypto/CryptoKeyFormat.h: * crypto/CryptoKeyPair.h: * crypto/CryptoKeyPair.idl: * crypto/CryptoKeyType.h: * crypto/CryptoKeyUsage.h: * crypto/CryptoKeyUsage.idl: * crypto/JsonWebKey.h: * crypto/JsonWebKey.idl: * crypto/RsaOtherPrimesInfo.h: * crypto/RsaOtherPrimesInfo.idl: * crypto/SerializedCryptoKeyWrap.h: * crypto/SubtleCrypto.cpp: * crypto/SubtleCrypto.h: * crypto/SubtleCrypto.idl: * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: * crypto/algorithms/CryptoAlgorithmAES_CBC.h: * crypto/algorithms/CryptoAlgorithmAES_CFB.cpp: * crypto/algorithms/CryptoAlgorithmAES_CFB.h: * crypto/algorithms/CryptoAlgorithmAES_CTR.cpp: * crypto/algorithms/CryptoAlgorithmAES_CTR.h: * crypto/algorithms/CryptoAlgorithmAES_GCM.cpp: * crypto/algorithms/CryptoAlgorithmAES_GCM.h: * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: * crypto/algorithms/CryptoAlgorithmAES_KW.h: * crypto/algorithms/CryptoAlgorithmECDH.cpp: * crypto/algorithms/CryptoAlgorithmECDH.h: * crypto/algorithms/CryptoAlgorithmECDSA.cpp: * crypto/algorithms/CryptoAlgorithmECDSA.h: * crypto/algorithms/CryptoAlgorithmHKDF.cpp: * crypto/algorithms/CryptoAlgorithmHKDF.h: * crypto/algorithms/CryptoAlgorithmHMAC.cpp: * crypto/algorithms/CryptoAlgorithmHMAC.h: * crypto/algorithms/CryptoAlgorithmPBKDF2.cpp: * crypto/algorithms/CryptoAlgorithmPBKDF2.h: * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.h: * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: * crypto/algorithms/CryptoAlgorithmRSA_OAEP.h: * crypto/algorithms/CryptoAlgorithmRSA_PSS.cpp: * crypto/algorithms/CryptoAlgorithmRSA_PSS.h: * crypto/algorithms/CryptoAlgorithmSHA1.cpp: * crypto/algorithms/CryptoAlgorithmSHA1.h: * crypto/algorithms/CryptoAlgorithmSHA224.cpp: * crypto/algorithms/CryptoAlgorithmSHA224.h: * crypto/algorithms/CryptoAlgorithmSHA256.cpp: * crypto/algorithms/CryptoAlgorithmSHA256.h: * crypto/algorithms/CryptoAlgorithmSHA384.cpp: * crypto/algorithms/CryptoAlgorithmSHA384.h: * crypto/algorithms/CryptoAlgorithmSHA512.cpp: * crypto/algorithms/CryptoAlgorithmSHA512.h: * crypto/gcrypt/CryptoAlgorithmAES_CBCGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmAES_CFBGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmAES_CTRGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmAES_GCMGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmAES_KWGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmECDHGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmECDSAGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmHKDFGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmHMACGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmPBKDF2GCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmRSAES_PKCS1_v1_5GCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmRSASSA_PKCS1_v1_5GCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmRSA_OAEPGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmRSA_PSSGCrypt.cpp: * crypto/gcrypt/CryptoAlgorithmRegistryGCrypt.cpp: * crypto/gcrypt/CryptoKeyECGCrypt.cpp: * crypto/gcrypt/CryptoKeyRSAGCrypt.cpp: * crypto/gcrypt/SerializedCryptoKeyWrapGCrypt.cpp: * crypto/keys/CryptoAesKeyAlgorithm.idl: * crypto/keys/CryptoEcKeyAlgorithm.idl: * crypto/keys/CryptoHmacKeyAlgorithm.idl: * crypto/keys/CryptoKeyAES.cpp: * crypto/keys/CryptoKeyAES.h: * crypto/keys/CryptoKeyAlgorithm.idl: * crypto/keys/CryptoKeyEC.cpp: * crypto/keys/CryptoKeyEC.h: * crypto/keys/CryptoKeyHMAC.cpp: * crypto/keys/CryptoKeyHMAC.h: * crypto/keys/CryptoKeyRSA.cpp: * crypto/keys/CryptoKeyRSA.h: * crypto/keys/CryptoKeyRSAComponents.cpp: * crypto/keys/CryptoKeyRSAComponents.h: * crypto/keys/CryptoKeyRaw.cpp: * crypto/keys/CryptoKeyRaw.h: * crypto/keys/CryptoRsaHashedKeyAlgorithm.idl: * crypto/keys/CryptoRsaKeyAlgorithm.idl: * crypto/mac/CommonCryptoDERUtilities.cpp: * crypto/mac/CommonCryptoDERUtilities.h: * crypto/mac/CryptoAlgorithmAES_CBCMac.cpp: * crypto/mac/CryptoAlgorithmAES_CFBMac.cpp: * crypto/mac/CryptoAlgorithmAES_CTRMac.cpp: * crypto/mac/CryptoAlgorithmAES_GCMMac.cpp: * crypto/mac/CryptoAlgorithmAES_KWMac.cpp: * crypto/mac/CryptoAlgorithmECDHMac.cpp: * crypto/mac/CryptoAlgorithmECDSAMac.cpp: * crypto/mac/CryptoAlgorithmHKDFMac.cpp: * crypto/mac/CryptoAlgorithmHMACMac.cpp: * crypto/mac/CryptoAlgorithmPBKDF2Mac.cpp: * crypto/mac/CryptoAlgorithmRSAES_PKCS1_v1_5Mac.cpp: * crypto/mac/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp: * crypto/mac/CryptoAlgorithmRSA_OAEPMac.cpp: * crypto/mac/CryptoAlgorithmRSA_PSSMac.cpp: * crypto/mac/CryptoAlgorithmRegistryMac.cpp: * crypto/mac/CryptoDigestAlgorithm.h: * crypto/mac/CryptoKeyECMac.cpp: * crypto/mac/CryptoKeyMac.cpp: * crypto/mac/CryptoKeyRSAMac.cpp: * crypto/mac/SerializedCryptoKeyWrapMac.mm: * crypto/parameters/AesCbcCfbParams.idl: * crypto/parameters/AesCtrParams.idl: * crypto/parameters/AesGcmParams.idl: * crypto/parameters/AesKeyParams.idl: * crypto/parameters/CryptoAlgorithmAesCbcCfbParams.h: * crypto/parameters/CryptoAlgorithmAesCtrParams.h: * crypto/parameters/CryptoAlgorithmAesGcmParams.h: * crypto/parameters/CryptoAlgorithmAesKeyParams.h: * crypto/parameters/CryptoAlgorithmEcKeyParams.h: * crypto/parameters/CryptoAlgorithmEcdhKeyDeriveParams.h: * crypto/parameters/CryptoAlgorithmEcdsaParams.h: * crypto/parameters/CryptoAlgorithmHkdfParams.h: * crypto/parameters/CryptoAlgorithmHmacKeyParams.h: * crypto/parameters/CryptoAlgorithmPbkdf2Params.h: * crypto/parameters/CryptoAlgorithmRsaHashedImportParams.h: * crypto/parameters/CryptoAlgorithmRsaHashedKeyGenParams.h: * crypto/parameters/CryptoAlgorithmRsaKeyGenParams.h: * crypto/parameters/CryptoAlgorithmRsaOaepParams.h: * crypto/parameters/CryptoAlgorithmRsaPssParams.h: * crypto/parameters/EcKeyParams.idl: * crypto/parameters/EcdhKeyDeriveParams.idl: * crypto/parameters/EcdsaParams.idl: * crypto/parameters/HkdfParams.idl: * crypto/parameters/HmacKeyParams.idl: * crypto/parameters/Pbkdf2Params.idl: * crypto/parameters/RsaHashedImportParams.idl: * crypto/parameters/RsaHashedKeyGenParams.idl: * crypto/parameters/RsaKeyGenParams.idl: * crypto/parameters/RsaOaepParams.idl: * crypto/parameters/RsaPssParams.idl: * dom/Document.cpp: * dom/Document.h: * dom/ScriptExecutionContext.h: * page/ChromeClient.h: * page/Crypto.cpp: (WebCore::Crypto::Crypto): * page/Crypto.h: * page/Crypto.idl: * platform/GCrypt.cmake: * platform/LocalizedStrings.cpp: * platform/LocalizedStrings.h: * workers/WorkerGlobalScope.cpp: * workers/WorkerGlobalScope.h: * worklets/WorkletGlobalScope.h: Source/WebCore/PAL: * Configurations/FeatureDefines.xcconfig: * pal/PlatformGTK.cmake: * pal/PlatformWPE.cmake: Source/WebKit: * Configurations/FeatureDefines.xcconfig: * UIProcess/API/C/WKPage.cpp: (WKPageSetPageNavigationClient): * UIProcess/WebPageProxy.cpp: * UIProcess/WebPageProxy.h: * UIProcess/WebPageProxy.messages.in: * WebProcess/WebCoreSupport/WebChromeClient.cpp: * WebProcess/WebCoreSupport/WebChromeClient.h: Source/WebKitLegacy/mac: * Configurations/FeatureDefines.xcconfig: * WebCoreSupport/WebChromeClient.h: * WebCoreSupport/WebChromeClient.mm: Tools: * Scripts/webkitperl/FeatureList.pm: * TestWebKitAPI/Configurations/FeatureDefines.xcconfig: Canonical link: https://commits.webkit.org/206898@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@238754 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2018-11-30 22:23:17 +00:00
#endif // ENABLE(WEB_CRYPTO)