[GCrypt] Gather SUBTLE_CRYPTO utility functions in a single header
authorzandobersek@gmail.com <zandobersek@gmail.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 3 Jun 2017 10:29:32 +0000 (10:29 +0000)
committerzandobersek@gmail.com <zandobersek@gmail.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 3 Jun 2017 10:29:32 +0000 (10:29 +0000)
commit6500fdbaa9e52945493104f6d677427b1dd79916
treea1b5a3af7ec8d1b5caf02ad3a2aa2978278ea0c3
parent9428f05dab4d2093c5c840fc5e3783aa8b8a15be
[GCrypt] Gather SUBTLE_CRYPTO utility functions in a single header
https://bugs.webkit.org/show_bug.cgi?id=172870

Reviewed by Jiewen Tan.

Gather the helper functions used across different source files
for libgcrypt-backed SUBTLE_CRYPTO implementations in a single
header file.

* crypto/gcrypt/CryptoAlgorithmECDSAGCrypt.cpp:
(WebCore::hashCryptoDigestAlgorithm): Deleted.
(WebCore::hashAlgorithmName): Deleted.
(WebCore::mpiData): Deleted.
* crypto/gcrypt/CryptoAlgorithmHKDFGCrypt.cpp:
(WebCore::gcryptDeriveBits):
(WebCore::macAlgorithmForHashFunction): Deleted.
* crypto/gcrypt/CryptoAlgorithmPBKDF2GCrypt.cpp:
(WebCore::gcryptDeriveBits):
* crypto/gcrypt/CryptoAlgorithmRSAES_PKCS1_v1_5GCrypt.cpp:
(WebCore::mpiData): Deleted.
* crypto/gcrypt/CryptoAlgorithmRSASSA_PKCS1_v1_5GCrypt.cpp:
(WebCore::hashCryptoDigestAlgorithm): Deleted.
(WebCore::hashAlgorithmName): Deleted.
(WebCore::mpiData): Deleted.
* crypto/gcrypt/CryptoAlgorithmRSA_OAEPGCrypt.cpp:
(WebCore::hashAlgorithmName): Deleted.
(WebCore::mpiData): Deleted.
* crypto/gcrypt/GCryptUtilities.h: Added.
(WebCore::hashAlgorithmName):
(WebCore::hmacAlgorithm):
(WebCore::digestAlgorithm):
(WebCore::hashCryptoDigestAlgorithm):
(WebCore::mpiData):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@217754 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/crypto/gcrypt/CryptoAlgorithmECDSAGCrypt.cpp
Source/WebCore/crypto/gcrypt/CryptoAlgorithmHKDFGCrypt.cpp
Source/WebCore/crypto/gcrypt/CryptoAlgorithmPBKDF2GCrypt.cpp
Source/WebCore/crypto/gcrypt/CryptoAlgorithmRSAES_PKCS1_v1_5GCrypt.cpp
Source/WebCore/crypto/gcrypt/CryptoAlgorithmRSASSA_PKCS1_v1_5GCrypt.cpp
Source/WebCore/crypto/gcrypt/CryptoAlgorithmRSA_OAEPGCrypt.cpp
Source/WebCore/crypto/gcrypt/GCryptUtilities.h [new file with mode: 0644]