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

Unified Diff: Source/platform/exported/WebCryptoAlgorithm.cpp

Issue 195543002: [webcrypto] Implement structured clone of keys (blink-side). (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Update serialized-script-value.html for version bump Created 6 years, 9 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 | « Source/modules/crypto/NormalizeAlgorithm.cpp ('k') | Source/platform/exported/WebCryptoKeyAlgorithm.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/exported/WebCryptoAlgorithm.cpp
diff --git a/Source/platform/exported/WebCryptoAlgorithm.cpp b/Source/platform/exported/WebCryptoAlgorithm.cpp
index ece201a7cc0261de90f92b8109d1f3b30a2987ff..918a2b8d884112c43607fa6fcc34dd883bd40800 100644
--- a/Source/platform/exported/WebCryptoAlgorithm.cpp
+++ b/Source/platform/exported/WebCryptoAlgorithm.cpp
@@ -163,6 +163,27 @@ const WebCryptoRsaHashedKeyGenParams* WebCryptoAlgorithm::rsaHashedKeyGenParams(
return 0;
}
+bool WebCryptoAlgorithm::isHash(WebCryptoAlgorithmId id)
+{
+ switch (id) {
+ case WebCryptoAlgorithmIdSha1:
+ case WebCryptoAlgorithmIdSha256:
+ case WebCryptoAlgorithmIdSha384:
+ case WebCryptoAlgorithmIdSha512:
+ return true;
+ case WebCryptoAlgorithmIdAesCbc:
+ case WebCryptoAlgorithmIdHmac:
+ case WebCryptoAlgorithmIdRsaSsaPkcs1v1_5:
+ case WebCryptoAlgorithmIdRsaEsPkcs1v1_5:
+ case WebCryptoAlgorithmIdAesGcm:
+ case WebCryptoAlgorithmIdRsaOaep:
+ case WebCryptoAlgorithmIdAesCtr:
+ case WebCryptoAlgorithmIdAesKw:
+ break;
+ }
+ return false;
+}
+
void WebCryptoAlgorithm::assign(const WebCryptoAlgorithm& other)
{
m_private = other.m_private;
« no previous file with comments | « Source/modules/crypto/NormalizeAlgorithm.cpp ('k') | Source/platform/exported/WebCryptoKeyAlgorithm.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698