Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2888)

Unified Diff: content/renderer/webcrypto/platform_crypto.h

Issue 178073007: [webcrypto] Update to use the KeyAlgorithm. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove unrelated change that makes public keys extractable Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/renderer/webcrypto/jwk.cc ('k') | content/renderer/webcrypto/platform_crypto_nss.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/webcrypto/platform_crypto.h
diff --git a/content/renderer/webcrypto/platform_crypto.h b/content/renderer/webcrypto/platform_crypto.h
index 0dd575fd8cfc029e9bd7a4a453ec737605ca662d..4b79fd875eaa26fcf139a91c16e5b834ff8f534f 100644
--- a/content/renderer/webcrypto/platform_crypto.h
+++ b/content/renderer/webcrypto/platform_crypto.h
@@ -122,10 +122,18 @@ Status GenerateSecretKey(const blink::WebCryptoAlgorithm& algorithm,
// Preconditions:
// * algorithm.id() is for an RSA algorithm.
-// * algorithm.rsaKeyGenParams() is non-null.
+// * public_exponent, modulus_length_bits and hash_or_null are the same as what
+// is in algorithm. They are split out for convenience.
+// * hash_or_null.isNull() may be true if a hash is not applicable to the
+// algorithm
+// * modulus_length_bits is not 0
+// * public_exponent is not empty.
Status GenerateRsaKeyPair(const blink::WebCryptoAlgorithm& algorithm,
bool extractable,
blink::WebCryptoKeyUsageMask usage_mask,
+ unsigned int modulus_length_bits,
+ const CryptoData& public_exponent,
+ const blink::WebCryptoAlgorithm& hash,
blink::WebCryptoKey* public_key,
blink::WebCryptoKey* private_key);
« no previous file with comments | « content/renderer/webcrypto/jwk.cc ('k') | content/renderer/webcrypto/platform_crypto_nss.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698