| Index: content/child/webcrypto/webcrypto_util.cc
|
| diff --git a/content/child/webcrypto/webcrypto_util.cc b/content/child/webcrypto/webcrypto_util.cc
|
| index e3433fdfc1da0cc95dcad94d365e904ea3f2194a..a46961c4e9699ebe6618f5c3ba7413d482f7253f 100644
|
| --- a/content/child/webcrypto/webcrypto_util.cc
|
| +++ b/content/child/webcrypto/webcrypto_util.cc
|
| @@ -63,15 +63,22 @@ struct JwkToWebCryptoUsage {
|
| const blink::WebCryptoKeyUsage webcrypto_usage;
|
| };
|
|
|
| +// Keep this ordered according to the definition
|
| +// order of WebCrypto's "recognized key usage
|
| +// values".
|
| +//
|
| +// This is not required for spec compliance,
|
| +// however it makes the ordering of key_ops match
|
| +// that of WebCrypto's Key.usages.
|
| const JwkToWebCryptoUsage kJwkWebCryptoUsageMap[] = {
|
| {"encrypt", blink::WebCryptoKeyUsageEncrypt},
|
| {"decrypt", blink::WebCryptoKeyUsageDecrypt},
|
| - {"deriveKey", blink::WebCryptoKeyUsageDeriveKey},
|
| - {"deriveBits", blink::WebCryptoKeyUsageDeriveBits},
|
| {"sign", blink::WebCryptoKeyUsageSign},
|
| - {"unwrapKey", blink::WebCryptoKeyUsageUnwrapKey},
|
| {"verify", blink::WebCryptoKeyUsageVerify},
|
| - {"wrapKey", blink::WebCryptoKeyUsageWrapKey}};
|
| + {"deriveKey", blink::WebCryptoKeyUsageDeriveKey},
|
| + {"deriveBits", blink::WebCryptoKeyUsageDeriveBits},
|
| + {"wrapKey", blink::WebCryptoKeyUsageWrapKey},
|
| + {"unwrapKey", blink::WebCryptoKeyUsageUnwrapKey}};
|
|
|
| // Modifies the input usage_mask by according to the key_op value.
|
| bool JwkKeyOpToWebCryptoUsage(const std::string& key_op,
|
|
|