| Index: content/child/webcrypto/nss/hmac_nss.cc
|
| diff --git a/content/child/webcrypto/nss/hmac_nss.cc b/content/child/webcrypto/nss/hmac_nss.cc
|
| index bb146d4977708f8572ecee0207d3643629bb3749..c71f24013b6e16972f565894cc8ce7f2c0532344 100644
|
| --- a/content/child/webcrypto/nss/hmac_nss.cc
|
| +++ b/content/child/webcrypto/nss/hmac_nss.cc
|
| @@ -84,10 +84,11 @@ class HmacImplementation : public AlgorithmImplementation {
|
| Status VerifyKeyUsagesBeforeImportKey(
|
| blink::WebCryptoKeyFormat format,
|
| blink::WebCryptoKeyUsageMask usages) const override {
|
| + bool checkEmptyUsage = true;
|
| switch (format) {
|
| case blink::WebCryptoKeyFormatRaw:
|
| case blink::WebCryptoKeyFormatJwk:
|
| - return CheckKeyCreationUsages(kAllKeyUsages, usages);
|
| + return CheckKeyCreationUsages(kAllKeyUsages, usages, checkEmptyUsage);
|
| default:
|
| return Status::ErrorUnsupportedImportKeyFormat();
|
| }
|
|
|