From 692fccc5ddbdd1b208913481884f1e6507e30665 Mon Sep 17 00:00:00 2001 From: Brindusan Cristian Date: Sat, 13 Jun 2020 00:57:51 +0300 Subject: [PATCH] Backed out changeset 99ea9e6229cb (bug 1286250) for wpt failures at AES-CBC.https.any.html. CLOSED TREE --- dom/crypto/WebCryptoTask.cpp | 2 +- dom/crypto/test/test_WebCrypto.html | 15 --------------- 2 files changed, 1 insertion(+), 16 deletions(-) diff --git a/dom/crypto/WebCryptoTask.cpp b/dom/crypto/WebCryptoTask.cpp index a8c4839fd98d..7ff0edd39c3d 100644 --- a/dom/crypto/WebCryptoTask.cpp +++ b/dom/crypto/WebCryptoTask.cpp @@ -208,7 +208,7 @@ inline nsresult GetKeyLengthForAlgorithm(JSContext* aCx, if (params.mLength != 128 && params.mLength != 192 && params.mLength != 256) { - return NS_ERROR_DOM_OPERATION_ERR; + return NS_ERROR_DOM_DATA_ERR; } aLength = params.mLength; diff --git a/dom/crypto/test/test_WebCrypto.html b/dom/crypto/test/test_WebCrypto.html index db2f22646b63..788e4647cdfa 100644 --- a/dom/crypto/test/test_WebCrypto.html +++ b/dom/crypto/test/test_WebCrypto.html @@ -381,21 +381,6 @@ TestArray.addTest( } ); -// ----------------------------------------------------------------------------- -TestArray.addTest( - "Fail generating an AES key of wrong length", - function() { - var that = this; - var alg = { name: "AES-CBC", length: 64 }; - crypto.subtle.generateKey(alg, false, ["encrypt"]).then( - error(that), - complete(that, function(e) { - return e.name == "OperationError"; - }) - ); - } -); - // ----------------------------------------------------------------------------- TestArray.addTest( "Generate a 1024-bit RSA key",