| Index: content/child/webcrypto/openssl/hmac_openssl.cc
|
| diff --git a/content/child/webcrypto/openssl/hmac_openssl.cc b/content/child/webcrypto/openssl/hmac_openssl.cc
|
| index 76f63c3236818e539f11baed09808b6cbd6fb484..e2754fe2d196a26852af1df03eb0a5b068af0efc 100644
|
| --- a/content/child/webcrypto/openssl/hmac_openssl.cc
|
| +++ b/content/child/webcrypto/openssl/hmac_openssl.cc
|
| @@ -91,10 +91,11 @@ class HmacImplementation : public AlgorithmImplementation {
|
| Status VerifyKeyUsagesBeforeImportKey(
|
| blink::WebCryptoKeyFormat format,
|
| blink::WebCryptoKeyUsageMask usages) const override {
|
| + bool checkEmptyUsages = true;
|
| switch (format) {
|
| case blink::WebCryptoKeyFormatRaw:
|
| case blink::WebCryptoKeyFormatJwk:
|
| - return CheckKeyCreationUsages(kAllKeyUsages, usages);
|
| + return CheckKeyCreationUsages(kAllKeyUsages, usages, checkEmptyUsages);
|
| default:
|
| return Status::ErrorUnsupportedImportKeyFormat();
|
| }
|
|
|