Index: content/child/webcrypto/shared_crypto.h |
diff --git a/content/child/webcrypto/shared_crypto.h b/content/child/webcrypto/shared_crypto.h |
index 57627d60b0dad359a47ce5a620517ab5d95a9fd2..d9e5a959db71e4a8a697a49b6be2c63614975ece 100644 |
--- a/content/child/webcrypto/shared_crypto.h |
+++ b/content/child/webcrypto/shared_crypto.h |
@@ -174,6 +174,12 @@ Status ToPlatformPublicKey(const blink::WebCryptoKey& key, |
Status ToPlatformPrivateKey(const blink::WebCryptoKey& key, |
platform::PrivateKey** out); |
+// Returns Staus::Success() if |usages| is valid for |key_type| and |algorithm|. |
+// Otherwise returns a failure |
+Status CheckKeyUsages(blink::WebCryptoAlgorithmId algorithm, |
+ blink::WebCryptoKeyType key_type, |
+ blink::WebCryptoKeyUsageMask usages); |
+ |
} // namespace webcrypto |
} // namespace content |