⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 276167 in webkit


Ignore:
Timestamp:
Apr 16, 2021, 2:07:29 PM (5 years ago)
Author:
basuke.suzuki@sony.com
Message:

[PlayStation][OpenSSL] Remove warnings.
https://bugs.webkit.org/show_bug.cgi?id=224630

Reviewed by Don Olmstead.

There're two kinds of warnings in curl and openssl layer in our platform.

a) Unused param

b) 'WORDSIZE' is not defined.
warning: '
WORDSIZE' is not defined, evaluates to 0 [-Wundef]
#if WORDSIZE >= 64

No new tests because it's only for compilation issue.

  • crypto/algorithms/CryptoAlgorithmAES_GCM.cpp:

(WebCore::CryptoAlgorithmAES_GCM::encrypt):
(WebCore::CryptoAlgorithmAES_GCM::decrypt):

  • crypto/openssl/CryptoKeyECOpenSSL.cpp:

(WebCore::CryptoKeyEC::platformGeneratePair):
(WebCore::CryptoKeyEC::platformImportRaw):
(WebCore::CryptoKeyEC::platformImportJWKPublic):
(WebCore::CryptoKeyEC::platformImportJWKPrivate):
(WebCore::CryptoKeyEC::platformImportSpki):
(WebCore::CryptoKeyEC::platformImportPkcs8):

  • crypto/openssl/CryptoKeyRSAOpenSSL.cpp:

(WebCore::CryptoKeyRSA::create):
(WebCore::CryptoKeyRSA::generatePair):
(WebCore::CryptoKeyRSA::importSpki):
(WebCore::CryptoKeyRSA::importPkcs8):

Location:
trunk/Source/WebCore
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r276164 r276167  
     12021-04-16  Basuke Suzuki  <basuke.suzuki@sony.com>
     2
     3        [PlayStation][OpenSSL] Remove warnings.
     4        https://bugs.webkit.org/show_bug.cgi?id=224630
     5
     6        Reviewed by Don Olmstead.
     7
     8        There're two kinds of warnings in curl and openssl layer in our platform.
     9
     10        a) Unused param
     11
     12        b) '__WORDSIZE' is not defined.
     13        warning: '__WORDSIZE' is not defined, evaluates to 0 [-Wundef]
     14        #if __WORDSIZE >= 64
     15        ^
     16
     17        No new tests because it's only for compilation issue.
     18
     19        * crypto/algorithms/CryptoAlgorithmAES_GCM.cpp:
     20        (WebCore::CryptoAlgorithmAES_GCM::encrypt):
     21        (WebCore::CryptoAlgorithmAES_GCM::decrypt):
     22        * crypto/openssl/CryptoKeyECOpenSSL.cpp:
     23        (WebCore::CryptoKeyEC::platformGeneratePair):
     24        (WebCore::CryptoKeyEC::platformImportRaw):
     25        (WebCore::CryptoKeyEC::platformImportJWKPublic):
     26        (WebCore::CryptoKeyEC::platformImportJWKPrivate):
     27        (WebCore::CryptoKeyEC::platformImportSpki):
     28        (WebCore::CryptoKeyEC::platformImportPkcs8):
     29        * crypto/openssl/CryptoKeyRSAOpenSSL.cpp:
     30        (WebCore::CryptoKeyRSA::create):
     31        (WebCore::CryptoKeyRSA::generatePair):
     32        (WebCore::CryptoKeyRSA::importSpki):
     33        (WebCore::CryptoKeyRSA::importPkcs8):
     34
    1352021-04-16  Alex Christensen  <achristensen@webkit.org>
    236
  • trunk/Source/WebCore/crypto/algorithms/CryptoAlgorithmAES_GCM.cpp

    r238754 r276167  
    4040static const char* const ALG192 = "A192GCM";
    4141static const char* const ALG256 = "A256GCM";
    42 #if __WORDSIZE >= 64
     42#if CPU(ADDRESS64)
    4343static const uint64_t PlainTextMaxLength = 549755813632ULL; // 2^39 - 256
    4444#endif
     
    7878    auto& aesParameters = downcast<CryptoAlgorithmAesGcmParams>(parameters);
    7979
    80 #if __WORDSIZE >= 64
     80#if CPU(ADDRESS64)
    8181    if (plainText.size() > PlainTextMaxLength) {
    8282        exceptionCallback(OperationError);
     
    121121    }
    122122
    123 #if __WORDSIZE >= 64
     123#if CPU(ADDRESS64)
    124124    if (aesParameters.ivVector().size() > UINT64_MAX) {
    125125        exceptionCallback(OperationError);
  • trunk/Source/WebCore/crypto/openssl/CryptoKeyECOpenSSL.cpp

    r254958 r276167  
    4747Optional<CryptoKeyPair> CryptoKeyEC::platformGeneratePair(CryptoAlgorithmIdentifier, NamedCurve, bool extractable, CryptoKeyUsageBitmap)
    4848{
     49    UNUSED_PARAM(extractable);
    4950    notImplemented();
    5051    return { };
     
    5354RefPtr<CryptoKeyEC> CryptoKeyEC::platformImportRaw(CryptoAlgorithmIdentifier, NamedCurve, Vector<uint8_t>&& keyData, bool extractable, CryptoKeyUsageBitmap)
    5455{
     56    UNUSED_PARAM(keyData);
     57    UNUSED_PARAM(extractable);
    5558    notImplemented();
    5659    return nullptr;
     
    5962RefPtr<CryptoKeyEC> CryptoKeyEC::platformImportJWKPublic(CryptoAlgorithmIdentifier, NamedCurve, Vector<uint8_t>&& x, Vector<uint8_t>&& y, bool extractable, CryptoKeyUsageBitmap)
    6063{
     64    UNUSED_PARAM(x);
     65    UNUSED_PARAM(y);
     66    UNUSED_PARAM(extractable);
    6167    notImplemented();
    6268    return nullptr;
     
    6571RefPtr<CryptoKeyEC> CryptoKeyEC::platformImportJWKPrivate(CryptoAlgorithmIdentifier, NamedCurve, Vector<uint8_t>&& x, Vector<uint8_t>&& y, Vector<uint8_t>&& d, bool extractable, CryptoKeyUsageBitmap)
    6672{
     73    UNUSED_PARAM(x);
     74    UNUSED_PARAM(y);
     75    UNUSED_PARAM(d);
     76    UNUSED_PARAM(extractable);
    6777    notImplemented();
    6878    return nullptr;
     
    7181RefPtr<CryptoKeyEC> CryptoKeyEC::platformImportSpki(CryptoAlgorithmIdentifier, NamedCurve, Vector<uint8_t>&& keyData, bool extractable, CryptoKeyUsageBitmap)
    7282{
     83    UNUSED_PARAM(keyData);
     84    UNUSED_PARAM(extractable);
    7385    notImplemented();
    7486    return nullptr;
     
    7789RefPtr<CryptoKeyEC> CryptoKeyEC::platformImportPkcs8(CryptoAlgorithmIdentifier, NamedCurve, Vector<uint8_t>&& keyData, bool extractable, CryptoKeyUsageBitmap)
    7890{
     91    UNUSED_PARAM(keyData);
     92    UNUSED_PARAM(extractable);
    7993    notImplemented();
    8094    return nullptr;
  • trunk/Source/WebCore/crypto/openssl/CryptoKeyRSAOpenSSL.cpp

    r254958 r276167  
    3434namespace WebCore {
    3535
    36 RefPtr<CryptoKeyRSA> CryptoKeyRSA::create(CryptoAlgorithmIdentifier, CryptoAlgorithmIdentifier hash, bool hasHash, const CryptoKeyRSAComponents&, bool extractable, CryptoKeyUsageBitmap)
     36RefPtr<CryptoKeyRSA> CryptoKeyRSA::create(CryptoAlgorithmIdentifier, CryptoAlgorithmIdentifier, bool hasHash, const CryptoKeyRSAComponents&, bool extractable, CryptoKeyUsageBitmap)
    3737{
     38    UNUSED_PARAM(hasHash);
     39    UNUSED_PARAM(extractable);
    3840    notImplemented();
    3941    return nullptr;
     
    5254}
    5355
    54 void CryptoKeyRSA::generatePair(CryptoAlgorithmIdentifier, CryptoAlgorithmIdentifier hash, bool hasHash, unsigned modulusLength, const Vector<uint8_t>& publicExponent, bool extractable, CryptoKeyUsageBitmap, KeyPairCallback&&, VoidCallback&& failureCallback, ScriptExecutionContext*)
     56void CryptoKeyRSA::generatePair(CryptoAlgorithmIdentifier, CryptoAlgorithmIdentifier, bool hasHash, unsigned modulusLength, const Vector<uint8_t>& publicExponent, bool extractable, CryptoKeyUsageBitmap, KeyPairCallback&&, VoidCallback&& failureCallback, ScriptExecutionContext*)
    5557{
     58    UNUSED_PARAM(hasHash);
     59    UNUSED_PARAM(modulusLength);
     60    UNUSED_PARAM(publicExponent);
     61    UNUSED_PARAM(extractable);
     62    UNUSED_PARAM(failureCallback);
    5663    notImplemented();
    5764}
    5865
    59 RefPtr<CryptoKeyRSA> CryptoKeyRSA::importSpki(CryptoAlgorithmIdentifier, Optional<CryptoAlgorithmIdentifier> hash, Vector<uint8_t>&&, bool extractable, CryptoKeyUsageBitmap)
     66RefPtr<CryptoKeyRSA> CryptoKeyRSA::importSpki(CryptoAlgorithmIdentifier, Optional<CryptoAlgorithmIdentifier>, Vector<uint8_t>&&, bool extractable, CryptoKeyUsageBitmap)
    6067{
     68    UNUSED_PARAM(extractable);
    6169    notImplemented();
    6270    return nullptr;
    6371}
    6472
    65 RefPtr<CryptoKeyRSA> CryptoKeyRSA::importPkcs8(CryptoAlgorithmIdentifier, Optional<CryptoAlgorithmIdentifier> hash, Vector<uint8_t>&&, bool extractable, CryptoKeyUsageBitmap)
     73RefPtr<CryptoKeyRSA> CryptoKeyRSA::importPkcs8(CryptoAlgorithmIdentifier, Optional<CryptoAlgorithmIdentifier>, Vector<uint8_t>&&, bool extractable, CryptoKeyUsageBitmap)
    6674{
     75    UNUSED_PARAM(extractable);
    6776    notImplemented();
    6877    return nullptr;
Note: See TracChangeset for help on using the changeset viewer.