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

Unified Diff: LayoutTests/crypto/subtle/rsa-oaep-generate-non-extractable-key.html

Issue 957713004: [WebCrypto] Split LayoutTests/crypto/subtle into per-algorithm directories (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Updated to latest master Created 5 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
Index: LayoutTests/crypto/subtle/rsa-oaep-generate-non-extractable-key.html
diff --git a/LayoutTests/crypto/subtle/rsa-oaep-generate-non-extractable-key.html b/LayoutTests/crypto/subtle/rsa-oaep-generate-non-extractable-key.html
deleted file mode 100644
index 431b89b34858e509001a43cb6a0ab1a5a1bcfc5c..0000000000000000000000000000000000000000
--- a/LayoutTests/crypto/subtle/rsa-oaep-generate-non-extractable-key.html
+++ /dev/null
@@ -1,46 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<script src="../../resources/js-test.js"></script>
-<script src="resources/common.js"></script>
-</head>
-<body>
-<p id="description"></p>
-<div id="console"></div>
-
-<script>
-description("Test that even when non-extractability is requested, the public key is still extractable.");
-
-jsTestIsAsync = true;
-
-var algorithmKeyGen = {
- name: "RSA-OAEP",
- hash: {name: "sha-256"},
- // RsaKeyGenParams
- modulusLength: 512,
- publicExponent: new Uint8Array([0x01, 0x00, 0x01]), // Equivalent to 65537
-};
-var nonExtractable = false;
-
-debug("Generating a key pair...");
-crypto.subtle.generateKey(algorithmKeyGen, nonExtractable, ['decrypt']).then(function(result) {
- keyPair = result;
- shouldBe("keyPair.toString()", "'[object Object]'");
- shouldBe("keyPair.publicKey.type", "'public'");
- shouldBe("keyPair.publicKey.extractable", "true");
- shouldBe("keyPair.publicKey.algorithm.name", "'RSA-OAEP'");
- shouldBe("keyPair.publicKey.algorithm.modulusLength", "512");
- shouldBe("bytesToHexString(keyPair.publicKey.algorithm.publicExponent)", "'010001'");
- shouldBe("keyPair.publicKey.algorithm.hash.name", "'SHA-256'");
- shouldBe("keyPair.privateKey.type", "'private'");
- shouldBe("keyPair.privateKey.extractable", "false");
- shouldBe("keyPair.privateKey.algorithm.name", "'RSA-OAEP'");
- shouldBe("keyPair.privateKey.algorithm.modulusLength", "512");
- shouldBe("bytesToHexString(keyPair.privateKey.algorithm.publicExponent)", "'010001'");
- shouldBe("keyPair.privateKey.algorithm.hash.name", "'SHA-256'");
-}).then(finishJSTest, failAndFinishJSTest);
-
-</script>
-
-</body>
-</html>

Powered by Google App Engine
This is Rietveld 408576698