Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: be5cbef50e65beef09ae6956defb911329c8cb29
https://github.com/WebKit/WebKit/commit/be5cbef50e65beef09ae6956defb911329c8cb29
Author: Nitin Mahendru <[email protected]>
Date: 2024-04-23 (Tue, 23 Apr 2024)
Changed paths:
M LayoutTests/TestExpectations
M LayoutTests/crypto/subtle/hkdf-derive-bits-length-limits-expected.txt
M LayoutTests/crypto/subtle/hkdf-derive-bits-length-limits.html
M Source/WebCore/Modules/webauthn/fido/Pin.cpp
M Source/WebCore/PAL/PAL.xcodeproj/project.pbxproj
M Source/WebCore/PAL/pal/PALSwift.h
M Source/WebCore/PAL/pal/PALSwift/CryptoKitShim.swift
M Source/WebCore/PAL/pal/PALSwift/UnsafeOverlays.swift
A Source/WebCore/PAL/pal/PALSwiftUtils.h
M Source/WebCore/crypto/algorithms/CryptoAlgorithmHKDF.cpp
M Source/WebCore/crypto/algorithms/CryptoAlgorithmHKDF.h
M Source/WebCore/crypto/algorithms/CryptoAlgorithmHMAC.cpp
M Source/WebCore/crypto/algorithms/CryptoAlgorithmHMAC.h
M Source/WebCore/crypto/cocoa/CryptoAlgorithmAESGCMMac.cpp
M Source/WebCore/crypto/cocoa/CryptoAlgorithmAESKWMac.cpp
M Source/WebCore/crypto/cocoa/CryptoAlgorithmECDHMac.cpp
M Source/WebCore/crypto/cocoa/CryptoAlgorithmECDSAMac.cpp
M Source/WebCore/crypto/cocoa/CryptoAlgorithmEd25519Cocoa.cpp
M Source/WebCore/crypto/cocoa/CryptoAlgorithmHKDFMac.cpp
M Source/WebCore/crypto/cocoa/CryptoAlgorithmHMACMac.cpp
M Source/WebCore/crypto/cocoa/CryptoAlgorithmX25519Cocoa.cpp
M Source/WebCore/crypto/cocoa/CryptoKeyECMac.cpp
M Source/WebCore/crypto/gcrypt/CryptoAlgorithmHKDFGCrypt.cpp
M Source/WebCore/crypto/gcrypt/CryptoAlgorithmHMACGCrypt.cpp
M Source/WebCore/crypto/openssl/CryptoAlgorithmHKDFOpenSSL.cpp
M Source/WebCore/crypto/openssl/CryptoAlgorithmHMACOpenSSL.cpp
Log Message:
-----------
Add CryptoKit implementations for HMAC/HKDF in WebKit
rdar://126689803
https://bugs.webkit.org/show_bug.cgi?id=272879
Reviewed by Alex Christensen.
Add HMAC/HKDF implementations using CryptoKit. Still disabled by
default.
Also:
- disabled some sha224 tests. It's not part of the webcrypto standard
anymore.(since 2017)
- Renamed some Swift classes to not use acronyms.
* Source/WebCore/Modules/webauthn/fido/Pin.cpp:
(fido::pin::makePinAuth):
(fido::pin::SetPinRequest::tryCreate):
* Source/WebCore/PAL/PAL.xcodeproj/project.pbxproj:
* Source/WebCore/PAL/pal/PALSwift.h:
* Source/WebCore/PAL/pal/PALSwift/CryptoKitShim.swift:
(HMAC.sign(_:data:hashFunction:)):
(HMAC.verify(_:key:data:hashFunction:)):
(HKDF.deriveBits(_:salt:info:outputByteCount:hashFunction:)):
* Source/WebCore/PAL/pal/PALSwift/UnsafeOverlays.swift:
(CryptoKit.isValidAuthenticationCode(_:data:key:)):
(CryptoKit.deriveKey(_:salt:info:outputByteCount:)):
* Source/WebCore/PAL/pal/PALSwiftUtils.h: Copied from
Source/WebCore/PAL/pal/PALSwift.h.
(WebCore::toCKHashFunction):
(WebCore::isValidHashParameter):
* Source/WebCore/crypto/algorithms/CryptoAlgorithmHKDF.cpp:
(WebCore::CryptoAlgorithmHKDF::deriveBits):
* Source/WebCore/crypto/algorithms/CryptoAlgorithmHKDF.h:
* Source/WebCore/crypto/algorithms/CryptoAlgorithmHMAC.cpp:
(WebCore::CryptoAlgorithmHMAC::sign):
(WebCore::CryptoAlgorithmHMAC::verify):
* Source/WebCore/crypto/algorithms/CryptoAlgorithmHMAC.h:
* Source/WebCore/crypto/cocoa/CryptoAlgorithmECDSAMac.cpp:
(WebCore::toCKHashFunction): Deleted.
(WebCore::isValidHashParameter): Deleted.
* Source/WebCore/crypto/cocoa/CryptoAlgorithmHKDFMac.cpp:
(WebCore::platformDeriveBitsCC):
(WebCore::platformDeriveBitsCryptoKit):
(WebCore::CryptoAlgorithmHKDF::platformDeriveBits):
* Source/WebCore/crypto/cocoa/CryptoAlgorithmHMACMac.cpp:
(WebCore::platformSignCryptoKit):
(WebCore::platformVerifyCryptoKit):
(WebCore::platformSignCC):
(WebCore::platformVerifyCC):
(WebCore::CryptoAlgorithmHMAC::platformSign):
(WebCore::CryptoAlgorithmHMAC::platformVerify):
* Source/WebCore/crypto/gcrypt/CryptoAlgorithmHKDFGCrypt.cpp:
(WebCore::CryptoAlgorithmHKDF::platformDeriveBits):
* Source/WebCore/crypto/gcrypt/CryptoAlgorithmHMACGCrypt.cpp:
(WebCore::CryptoAlgorithmHMAC::platformSign):
(WebCore::CryptoAlgorithmHMAC::platformVerify):
* Source/WebCore/crypto/openssl/CryptoAlgorithmHKDFOpenSSL.cpp:
(WebCore::CryptoAlgorithmHKDF::platformDeriveBits):
* Source/WebCore/crypto/openssl/CryptoAlgorithmHMACOpenSSL.cpp:
(WebCore::CryptoAlgorithmHMAC::platformSign):
(WebCore::CryptoAlgorithmHMAC::platformVerify):
Canonical link: https://commits.webkit.org/277888@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes