<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[209900] trunk/Source/WebCore</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/209900">209900</a></dd>
<dt>Author</dt> <dd>commit-queue@webkit.org</dd>
<dt>Date</dt> <dd>2016-12-15 19:01:14 -0800 (Thu, 15 Dec 2016)</dd>
</dl>

<h3>Log Message</h3>
<pre>[WebIDL] Remove use of Dictionary from JSCryptoAlgorithmDictionary
https://bugs.webkit.org/show_bug.cgi?id=165919

Patch by Sam Weinig &lt;sam@webkit.org&gt; on 2016-12-15
Reviewed by Darin Adler.

* bindings/js/JSCryptoAlgorithmDictionary.cpp:
* bindings/js/JSCryptoAlgorithmDictionary.h:
* bindings/js/JSCryptoOperationData.cpp:
* bindings/js/JSCryptoOperationData.h:
* bindings/js/JSWebKitSubtleCryptoCustom.cpp:
Replace simplistic use of Dictionary with simplistic use of direct JSObject
functions. Also, pass the ExecState by reference.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCryptoAlgorithmDictionarycpp">trunk/Source/WebCore/bindings/js/JSCryptoAlgorithmDictionary.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCryptoAlgorithmDictionaryh">trunk/Source/WebCore/bindings/js/JSCryptoAlgorithmDictionary.h</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCryptoOperationDatacpp">trunk/Source/WebCore/bindings/js/JSCryptoOperationData.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCryptoOperationDatah">trunk/Source/WebCore/bindings/js/JSCryptoOperationData.h</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSWebKitSubtleCryptoCustomcpp">trunk/Source/WebCore/bindings/js/JSWebKitSubtleCryptoCustom.cpp</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (209899 => 209900)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2016-12-16 02:38:27 UTC (rev 209899)
+++ trunk/Source/WebCore/ChangeLog        2016-12-16 03:01:14 UTC (rev 209900)
</span><span class="lines">@@ -1,3 +1,18 @@
</span><ins>+2016-12-15  Sam Weinig  &lt;sam@webkit.org&gt;
+
+        [WebIDL] Remove use of Dictionary from JSCryptoAlgorithmDictionary
+        https://bugs.webkit.org/show_bug.cgi?id=165919
+
+        Reviewed by Darin Adler.
+
+        * bindings/js/JSCryptoAlgorithmDictionary.cpp:
+        * bindings/js/JSCryptoAlgorithmDictionary.h:
+        * bindings/js/JSCryptoOperationData.cpp:
+        * bindings/js/JSCryptoOperationData.h:
+        * bindings/js/JSWebKitSubtleCryptoCustom.cpp:
+        Replace simplistic use of Dictionary with simplistic use of direct JSObject
+        functions. Also, pass the ExecState by reference.
+
</ins><span class="cx"> 2016-12-15  Filip Pizlo  &lt;fpizlo@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Get rid of HeapRootVisitor and make SlotVisitor less painful to use
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCryptoAlgorithmDictionarycpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCryptoAlgorithmDictionary.cpp (209899 => 209900)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCryptoAlgorithmDictionary.cpp        2016-12-16 02:38:27 UTC (rev 209899)
+++ trunk/Source/WebCore/bindings/js/JSCryptoAlgorithmDictionary.cpp        2016-12-16 03:01:14 UTC (rev 209900)
</span><span class="lines">@@ -32,12 +32,12 @@
</span><span class="cx"> #include &quot;CryptoAlgorithmAesKeyGenParamsDeprecated.h&quot;
</span><span class="cx"> #include &quot;CryptoAlgorithmHmacKeyParamsDeprecated.h&quot;
</span><span class="cx"> #include &quot;CryptoAlgorithmHmacParamsDeprecated.h&quot;
</span><ins>+#include &quot;CryptoAlgorithmParameters.h&quot;
</ins><span class="cx"> #include &quot;CryptoAlgorithmRegistry.h&quot;
</span><span class="cx"> #include &quot;CryptoAlgorithmRsaKeyGenParamsDeprecated.h&quot;
</span><span class="cx"> #include &quot;CryptoAlgorithmRsaKeyParamsWithHashDeprecated.h&quot;
</span><span class="cx"> #include &quot;CryptoAlgorithmRsaOaepParamsDeprecated.h&quot;
</span><span class="cx"> #include &quot;CryptoAlgorithmRsaSsaParamsDeprecated.h&quot;
</span><del>-#include &quot;Dictionary.h&quot;
</del><span class="cx"> #include &quot;ExceptionCode.h&quot;
</span><span class="cx"> #include &quot;JSCryptoOperationData.h&quot;
</span><span class="cx"> #include &quot;JSDOMBinding.h&quot;
</span><span class="lines">@@ -52,21 +52,27 @@
</span><span class="cx">     Required, 
</span><span class="cx"> };
</span><span class="cx"> 
</span><del>-bool JSCryptoAlgorithmDictionary::getAlgorithmIdentifier(ExecState* exec, JSValue value, CryptoAlgorithmIdentifier&amp; algorithmIdentifier)
</del><ins>+static inline JSValue getProperty(ExecState&amp; state, JSObject* object, const char* name)
</ins><span class="cx"> {
</span><del>-    VM&amp; vm = exec-&gt;vm();
-    auto scope = DECLARE_THROW_SCOPE(vm);
</del><ins>+    return object-&gt;get(&amp;state, Identifier::fromString(&amp;state, name));
+}
</ins><span class="cx"> 
</span><ins>+bool JSCryptoAlgorithmDictionary::getAlgorithmIdentifier(ExecState&amp; state, JSValue value, CryptoAlgorithmIdentifier&amp; algorithmIdentifier)
+{
+    auto scope = DECLARE_THROW_SCOPE(state.vm());
+
</ins><span class="cx">     // typedef (Algorithm or DOMString) AlgorithmIdentifier;
</span><span class="cx"> 
</span><span class="cx">     String algorithmName;
</span><span class="cx"> 
</span><del>-    if (value.isString())
-        algorithmName = value.toWTFString(exec);
-    else if (value.isObject()) {
-        if (value.getObject()-&gt;inherits(StringObject::info()))
-            algorithmName = asString(asStringObject(value)-&gt;internalValue())-&gt;value(exec);
-        else {
</del><ins>+    if (value.isString()) {
+        algorithmName = value.toWTFString(&amp;state);
+        RETURN_IF_EXCEPTION(scope, false);
+    } else if (value.isObject()) {
+        if (asObject(value)-&gt;inherits(StringObject::info())) {
+            algorithmName = asString(asStringObject(value)-&gt;internalValue())-&gt;value(&amp;state);
+            RETURN_IF_EXCEPTION(scope, false);
+        } else {
</ins><span class="cx">             // FIXME: This doesn't perform some checks mandated by WebIDL for dictionaries:
</span><span class="cx">             // - null and undefined input should be treated as if all elements in the dictionary were undefined;
</span><span class="cx">             // - undefined elements should be treated as having a default value, or as not present if there isn't such;
</span><span class="lines">@@ -75,21 +81,22 @@
</span><span class="cx">             // This is partially because we don't implement it elsewhere in WebCore yet, and partially because
</span><span class="cx">             // WebCrypto doesn't yet clearly specify what to do with non-present values in most cases anyway.
</span><span class="cx"> 
</span><del>-            Dictionary dictionary(exec, value.getObject());
-            dictionary.get(&quot;name&quot;, algorithmName);
</del><ins>+            auto nameValue = getProperty(state, asObject(value), &quot;name&quot;);
+            RETURN_IF_EXCEPTION(scope, false);
+
+            algorithmName = convert&lt;IDLDOMString&gt;(state, nameValue);
+            RETURN_IF_EXCEPTION(scope, false);
</ins><span class="cx">         }
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    RETURN_IF_EXCEPTION(scope, false);
-
</del><span class="cx">     if (!algorithmName.containsOnlyASCII()) {
</span><del>-        throwSyntaxError(exec, scope);
</del><ins>+        throwSyntaxError(&amp;state, scope);
</ins><span class="cx">         return false;
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     auto identifier = CryptoAlgorithmRegistry::singleton().identifier(algorithmName);
</span><span class="cx">     if (!identifier) {
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return false;
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="lines">@@ -97,57 +104,44 @@
</span><span class="cx">     return true;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-static JSValue getProperty(ExecState* exec, JSObject* object, const char* name)
</del><ins>+static bool getHashAlgorithm(ExecState&amp; state, JSObject* object, CryptoAlgorithmIdentifier&amp; result, HashRequirement isRequired)
</ins><span class="cx"> {
</span><del>-    return object-&gt;get(exec, Identifier::fromString(exec, name));
-}
</del><ins>+    auto scope = DECLARE_THROW_SCOPE(state.vm());
</ins><span class="cx"> 
</span><del>-static bool getHashAlgorithm(Dictionary&amp; dictionary, CryptoAlgorithmIdentifier&amp; result, HashRequirement isRequired)
-{
-    // FIXME: Teach Dictionary how to return JSValues, and use that to get hash element value.
-
-    ExecState* exec = dictionary.execState();
-    VM&amp; vm = exec-&gt;vm();
-    auto scope = DECLARE_THROW_SCOPE(vm);
-    JSObject* object = dictionary.initializerObject();
-
-    Identifier identifier = Identifier::fromString(exec, &quot;hash&quot;);
-
-    JSValue hash = getProperty(exec, object, &quot;hash&quot;);
</del><ins>+    auto hash = getProperty(state, object, &quot;hash&quot;);
</ins><span class="cx">     RETURN_IF_EXCEPTION(scope, false);
</span><span class="cx"> 
</span><span class="cx">     if (hash.isUndefinedOrNull()) {
</span><span class="cx">         if (isRequired == HashRequirement::Required)
</span><del>-            setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+            setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return false;
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    return JSCryptoAlgorithmDictionary::getAlgorithmIdentifier(exec, hash, result);
</del><ins>+    return JSCryptoAlgorithmDictionary::getAlgorithmIdentifier(state, hash, result);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><del>-static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createAesCbcParams(ExecState* exec, JSValue value)
</del><ins>+static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createAesCbcParams(ExecState&amp; state, JSValue value)
</ins><span class="cx"> {
</span><del>-    VM&amp; vm = exec-&gt;vm();
-    auto scope = DECLARE_THROW_SCOPE(vm);
</del><ins>+    auto scope = DECLARE_THROW_SCOPE(state.vm());
</ins><span class="cx"> 
</span><span class="cx">     if (!value.isObject()) {
</span><del>-        throwTypeError(exec, scope);
</del><ins>+        throwTypeError(&amp;state, scope);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    JSValue iv = getProperty(exec, value.getObject(), &quot;iv&quot;);
</del><ins>+    auto iv = getProperty(state, asObject(value), &quot;iv&quot;);
</ins><span class="cx">     RETURN_IF_EXCEPTION(scope, nullptr);
</span><span class="cx"> 
</span><span class="cx">     auto result = adoptRef(*new CryptoAlgorithmAesCbcParamsDeprecated);
</span><span class="cx"> 
</span><span class="cx">     CryptoOperationData ivData;
</span><del>-    auto success = cryptoOperationDataFromJSValue(exec, iv, ivData);
</del><ins>+    auto success = cryptoOperationDataFromJSValue(state, iv, ivData);
</ins><span class="cx">     ASSERT(scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return nullptr;
</span><span class="cx"> 
</span><span class="cx">     if (ivData.second != 16) {
</span><del>-        throwException(exec, scope, createError(exec, &quot;AES-CBC initialization data must be 16 bytes&quot;));
</del><ins>+        throwException(&amp;state, scope, createError(&amp;state, &quot;AES-CBC initialization data must be 16 bytes&quot;));
</ins><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="lines">@@ -158,8 +152,7 @@
</span><span class="cx"> 
</span><span class="cx"> static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createAesKeyGenParams(ExecState&amp; state, JSValue value)
</span><span class="cx"> {
</span><del>-    VM&amp; vm = state.vm();
-    auto scope = DECLARE_THROW_SCOPE(vm);
</del><ins>+    auto scope = DECLARE_THROW_SCOPE(state.vm());
</ins><span class="cx"> 
</span><span class="cx">     if (!value.isObject()) {
</span><span class="cx">         throwTypeError(&amp;state, scope);
</span><span class="lines">@@ -168,7 +161,7 @@
</span><span class="cx"> 
</span><span class="cx">     auto result = adoptRef(*new CryptoAlgorithmAesKeyGenParamsDeprecated);
</span><span class="cx"> 
</span><del>-    JSValue lengthValue = getProperty(&amp;state, value.getObject(), &quot;length&quot;);
</del><ins>+    auto lengthValue = getProperty(state, asObject(value), &quot;length&quot;);
</ins><span class="cx">     RETURN_IF_EXCEPTION(scope, nullptr);
</span><span class="cx"> 
</span><span class="cx">     result-&gt;length = convert&lt;IDLUnsignedShort&gt;(state, lengthValue, IntegerConversionConfiguration::EnforceRange);
</span><span class="lines">@@ -178,8 +171,7 @@
</span><span class="cx"> 
</span><span class="cx"> static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createHmacParams(ExecState&amp; state, JSValue value)
</span><span class="cx"> {
</span><del>-    VM&amp; vm = state.vm();
-    auto scope = DECLARE_THROW_SCOPE(vm);
</del><ins>+    auto scope = DECLARE_THROW_SCOPE(state.vm());
</ins><span class="cx"> 
</span><span class="cx">     if (!value.isObject()) {
</span><span class="cx">         throwTypeError(&amp;state, scope);
</span><span class="lines">@@ -186,10 +178,9 @@
</span><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    Dictionary dictionary(&amp;state, value.getObject());
</del><span class="cx">     auto result = adoptRef(*new CryptoAlgorithmHmacParamsDeprecated);
</span><span class="cx"> 
</span><del>-    auto success = getHashAlgorithm(dictionary, result-&gt;hash, HashRequirement::Required);
</del><ins>+    auto success = getHashAlgorithm(state, asObject(value), result-&gt;hash, HashRequirement::Required);
</ins><span class="cx">     ASSERT_UNUSED(scope, scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return nullptr;
</span><span class="lines">@@ -199,8 +190,7 @@
</span><span class="cx"> 
</span><span class="cx"> static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createHmacKeyParams(ExecState&amp; state, JSValue value)
</span><span class="cx"> {
</span><del>-    VM&amp; vm = state.vm();
-    auto scope = DECLARE_THROW_SCOPE(vm);
</del><ins>+    auto scope = DECLARE_THROW_SCOPE(state.vm());
</ins><span class="cx"> 
</span><span class="cx">     if (!value.isObject()) {
</span><span class="cx">         throwTypeError(&amp;state, scope);
</span><span class="lines">@@ -207,24 +197,27 @@
</span><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    Dictionary dictionary(&amp;state, value.getObject());
</del><span class="cx">     auto result = adoptRef(*new CryptoAlgorithmHmacKeyParamsDeprecated);
</span><span class="cx"> 
</span><del>-    auto success = getHashAlgorithm(dictionary, result-&gt;hash, HashRequirement::Required);
</del><ins>+    auto success = getHashAlgorithm(state, asObject(value), result-&gt;hash, HashRequirement::Required);
</ins><span class="cx">     ASSERT(scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return nullptr;
</span><span class="cx"> 
</span><del>-    result-&gt;hasLength = dictionary.get(&quot;length&quot;, result-&gt;length);
</del><ins>+    auto lengthValue = getProperty(state, asObject(value), &quot;length&quot;);
</ins><span class="cx">     RETURN_IF_EXCEPTION(scope, nullptr);
</span><span class="cx"> 
</span><ins>+    result-&gt;length = convert&lt;IDLUnsignedShort&gt;(state, lengthValue, IntegerConversionConfiguration::Normal);
+    RETURN_IF_EXCEPTION(scope, nullptr);
+
+    result-&gt;hasLength = true;
+
</ins><span class="cx">     return WTFMove(result);
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createRsaKeyGenParams(ExecState&amp; state, JSValue value)
</span><span class="cx"> {
</span><del>-    VM&amp; vm = state.vm();
-    auto scope = DECLARE_THROW_SCOPE(vm);
</del><ins>+    auto scope = DECLARE_THROW_SCOPE(state.vm());
</ins><span class="cx"> 
</span><span class="cx">     if (!value.isObject()) {
</span><span class="cx">         throwTypeError(&amp;state, scope);
</span><span class="lines">@@ -231,10 +224,9 @@
</span><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    Dictionary dictionary(&amp;state, value.getObject());
</del><span class="cx">     auto result = adoptRef(*new CryptoAlgorithmRsaKeyGenParamsDeprecated);
</span><span class="cx"> 
</span><del>-    JSValue modulusLengthValue = getProperty(&amp;state, value.getObject(), &quot;modulusLength&quot;);
</del><ins>+    auto modulusLengthValue = getProperty(state, asObject(value), &quot;modulusLength&quot;);
</ins><span class="cx">     RETURN_IF_EXCEPTION(scope, nullptr);
</span><span class="cx"> 
</span><span class="cx">     // FIXME: Why no EnforceRange? Filed as &lt;https://www.w3.org/Bugs/Public/show_bug.cgi?id=23779&gt;.
</span><span class="lines">@@ -241,10 +233,10 @@
</span><span class="cx">     result-&gt;modulusLength = convert&lt;IDLUnsignedLong&gt;(state, modulusLengthValue, IntegerConversionConfiguration::Normal);
</span><span class="cx">     RETURN_IF_EXCEPTION(scope, nullptr);
</span><span class="cx"> 
</span><del>-    JSValue publicExponentValue = getProperty(&amp;state, value.getObject(), &quot;publicExponent&quot;);
</del><ins>+    auto publicExponentValue = getProperty(state, asObject(value), &quot;publicExponent&quot;);
</ins><span class="cx">     RETURN_IF_EXCEPTION(scope, nullptr);
</span><span class="cx"> 
</span><del>-    RefPtr&lt;Uint8Array&gt; publicExponentArray = toUnsharedUint8Array(publicExponentValue);
</del><ins>+    auto publicExponentArray = toUnsharedUint8Array(publicExponentValue);
</ins><span class="cx">     if (!publicExponentArray) {
</span><span class="cx">         throwTypeError(&amp;state, scope, ASCIILiteral(&quot;Expected a Uint8Array in publicExponent&quot;));
</span><span class="cx">         return nullptr;
</span><span class="lines">@@ -251,7 +243,7 @@
</span><span class="cx">     }
</span><span class="cx">     result-&gt;publicExponent.append(publicExponentArray-&gt;data(), publicExponentArray-&gt;byteLength());
</span><span class="cx"> 
</span><del>-    result-&gt;hasHash = getHashAlgorithm(dictionary, result-&gt;hash, HashRequirement::Optional); 
</del><ins>+    result-&gt;hasHash = getHashAlgorithm(state, asObject(value), result-&gt;hash, HashRequirement::Optional);
</ins><span class="cx"> 
</span><span class="cx">     return WTFMove(result);
</span><span class="cx"> }
</span><span class="lines">@@ -262,25 +254,23 @@
</span><span class="cx">     return adoptRef(*new CryptoAlgorithmRsaKeyParamsWithHashDeprecated);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createRsaOaepParams(ExecState* exec, JSValue value)
</del><ins>+static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createRsaOaepParams(ExecState&amp; state, JSValue value)
</ins><span class="cx"> {
</span><del>-    VM&amp; vm = exec-&gt;vm();
-    auto scope = DECLARE_THROW_SCOPE(vm);
</del><ins>+    auto scope = DECLARE_THROW_SCOPE(state.vm());
</ins><span class="cx"> 
</span><span class="cx">     if (!value.isObject()) {
</span><del>-        throwTypeError(exec, scope);
</del><ins>+        throwTypeError(&amp;state, scope);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    Dictionary dictionary(exec, value.getObject());
</del><span class="cx">     auto result = adoptRef(*new CryptoAlgorithmRsaOaepParamsDeprecated);
</span><span class="cx"> 
</span><del>-    auto success = getHashAlgorithm(dictionary, result-&gt;hash, HashRequirement::Required);
</del><ins>+    auto success = getHashAlgorithm(state, asObject(value), result-&gt;hash, HashRequirement::Required);
</ins><span class="cx">     ASSERT(scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return nullptr;
</span><span class="cx"> 
</span><del>-    JSValue labelValue = getProperty(exec, value.getObject(), &quot;label&quot;);
</del><ins>+    auto labelValue = getProperty(state, asObject(value), &quot;label&quot;);
</ins><span class="cx">     RETURN_IF_EXCEPTION(scope, nullptr);
</span><span class="cx"> 
</span><span class="cx">     result-&gt;hasLabel = !labelValue.isUndefinedOrNull();
</span><span class="lines">@@ -288,7 +278,7 @@
</span><span class="cx">         return WTFMove(result);
</span><span class="cx"> 
</span><span class="cx">     CryptoOperationData labelData;
</span><del>-    success = cryptoOperationDataFromJSValue(exec, labelValue, labelData);
</del><ins>+    success = cryptoOperationDataFromJSValue(state, labelValue, labelData);
</ins><span class="cx">     ASSERT(scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return nullptr;
</span><span class="lines">@@ -300,8 +290,7 @@
</span><span class="cx"> 
</span><span class="cx"> static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createRsaSsaParams(ExecState&amp; state, JSValue value)
</span><span class="cx"> {
</span><del>-    VM&amp; vm = state.vm();
-    auto scope = DECLARE_THROW_SCOPE(vm);
</del><ins>+    auto scope = DECLARE_THROW_SCOPE(state.vm());
</ins><span class="cx"> 
</span><span class="cx">     if (!value.isObject()) {
</span><span class="cx">         throwTypeError(&amp;state, scope);
</span><span class="lines">@@ -308,10 +297,9 @@
</span><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    Dictionary dictionary(&amp;state, value.getObject());
</del><span class="cx">     auto result = adoptRef(*new CryptoAlgorithmRsaSsaParamsDeprecated);
</span><span class="cx"> 
</span><del>-    auto success = getHashAlgorithm(dictionary, result-&gt;hash, HashRequirement::Required);
</del><ins>+    auto success = getHashAlgorithm(state, asObject(value), result-&gt;hash, HashRequirement::Required);
</ins><span class="cx">     ASSERT(scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return nullptr;
</span><span class="lines">@@ -319,7 +307,7 @@
</span><span class="cx">     return WTFMove(result);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForEncrypt(ExecState* exec, CryptoAlgorithmIdentifier algorithm, JSValue value)
</del><ins>+RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForEncrypt(ExecState&amp; state, CryptoAlgorithmIdentifier algorithm, JSValue value)
</ins><span class="cx"> {
</span><span class="cx">     switch (algorithm) {
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSAES_PKCS1_v1_5:
</span><span class="lines">@@ -326,21 +314,21 @@
</span><span class="cx">         return adoptRef(*new CryptoAlgorithmParametersDeprecated);
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSASSA_PKCS1_v1_5:
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSA_PSS:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSA_OAEP:
</span><del>-        return createRsaOaepParams(exec, value);
</del><ins>+        return createRsaOaepParams(state, value);
</ins><span class="cx">     case CryptoAlgorithmIdentifier::ECDSA:
</span><span class="cx">     case CryptoAlgorithmIdentifier::ECDH:
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_CTR:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_CBC:
</span><del>-        return createAesCbcParams(exec, value);
</del><ins>+        return createAesCbcParams(state, value);
</ins><span class="cx">     case CryptoAlgorithmIdentifier::AES_CMAC:
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_GCM:
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_CFB:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_KW:
</span><span class="cx">         return adoptRef(*new CryptoAlgorithmParametersDeprecated);
</span><span class="lines">@@ -354,7 +342,7 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::CONCAT:
</span><span class="cx">     case CryptoAlgorithmIdentifier::HKDF_CTR:
</span><span class="cx">     case CryptoAlgorithmIdentifier::PBKDF2:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx">     RELEASE_ASSERT_NOT_REACHED();
</span><span class="lines">@@ -361,7 +349,7 @@
</span><span class="cx">     return nullptr;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForDecrypt(ExecState* exec, CryptoAlgorithmIdentifier algorithm, JSValue value)
</del><ins>+RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForDecrypt(ExecState&amp; state, CryptoAlgorithmIdentifier algorithm, JSValue value)
</ins><span class="cx"> {
</span><span class="cx">     switch (algorithm) {
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSAES_PKCS1_v1_5:
</span><span class="lines">@@ -368,21 +356,21 @@
</span><span class="cx">         return adoptRef(*new CryptoAlgorithmParametersDeprecated);
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSASSA_PKCS1_v1_5:
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSA_PSS:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSA_OAEP:
</span><del>-        return createRsaOaepParams(exec, value);
</del><ins>+        return createRsaOaepParams(state, value);
</ins><span class="cx">     case CryptoAlgorithmIdentifier::ECDSA:
</span><span class="cx">     case CryptoAlgorithmIdentifier::ECDH:
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_CTR:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_CBC:
</span><del>-        return createAesCbcParams(exec, value);
</del><ins>+        return createAesCbcParams(state, value);
</ins><span class="cx">     case CryptoAlgorithmIdentifier::AES_CMAC:
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_GCM:
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_CFB:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_KW:
</span><span class="cx">         return adoptRef(*new CryptoAlgorithmParametersDeprecated);
</span><span class="lines">@@ -396,7 +384,7 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::CONCAT:
</span><span class="cx">     case CryptoAlgorithmIdentifier::HKDF_CTR:
</span><span class="cx">     case CryptoAlgorithmIdentifier::PBKDF2:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx">     RELEASE_ASSERT_NOT_REACHED();
</span><span class="lines">@@ -403,14 +391,14 @@
</span><span class="cx">     return nullptr;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForSign(ExecState* exec, CryptoAlgorithmIdentifier algorithm, JSValue value)
</del><ins>+RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForSign(ExecState&amp; state, CryptoAlgorithmIdentifier algorithm, JSValue value)
</ins><span class="cx"> {
</span><span class="cx">     switch (algorithm) {
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSAES_PKCS1_v1_5:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSASSA_PKCS1_v1_5:
</span><del>-        return createRsaSsaParams(*exec, value);
</del><ins>+        return createRsaSsaParams(state, value);
</ins><span class="cx">     case CryptoAlgorithmIdentifier::RSA_PSS:
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSA_OAEP:
</span><span class="cx">     case CryptoAlgorithmIdentifier::ECDSA:
</span><span class="lines">@@ -421,10 +409,10 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_GCM:
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_CFB:
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_KW:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     case CryptoAlgorithmIdentifier::HMAC:
</span><del>-        return createHmacParams(*exec, value);
</del><ins>+        return createHmacParams(state, value);
</ins><span class="cx">     case CryptoAlgorithmIdentifier::DH:
</span><span class="cx">     case CryptoAlgorithmIdentifier::SHA_1:
</span><span class="cx">     case CryptoAlgorithmIdentifier::SHA_224:
</span><span class="lines">@@ -434,7 +422,7 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::CONCAT:
</span><span class="cx">     case CryptoAlgorithmIdentifier::HKDF_CTR:
</span><span class="cx">     case CryptoAlgorithmIdentifier::PBKDF2:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx">     RELEASE_ASSERT_NOT_REACHED();
</span><span class="lines">@@ -441,14 +429,14 @@
</span><span class="cx">     return nullptr;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForVerify(ExecState* exec, CryptoAlgorithmIdentifier algorithm, JSValue value)
</del><ins>+RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForVerify(ExecState&amp; state, CryptoAlgorithmIdentifier algorithm, JSValue value)
</ins><span class="cx"> {
</span><span class="cx">     switch (algorithm) {
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSAES_PKCS1_v1_5:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSASSA_PKCS1_v1_5:
</span><del>-        return createRsaSsaParams(*exec, value);
</del><ins>+        return createRsaSsaParams(state, value);
</ins><span class="cx">     case CryptoAlgorithmIdentifier::RSA_PSS:
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSA_OAEP:
</span><span class="cx">     case CryptoAlgorithmIdentifier::ECDSA:
</span><span class="lines">@@ -459,10 +447,10 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_GCM:
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_CFB:
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_KW:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     case CryptoAlgorithmIdentifier::HMAC:
</span><del>-        return createHmacParams(*exec, value);
</del><ins>+        return createHmacParams(state, value);
</ins><span class="cx">     case CryptoAlgorithmIdentifier::DH:
</span><span class="cx">     case CryptoAlgorithmIdentifier::SHA_1:
</span><span class="cx">     case CryptoAlgorithmIdentifier::SHA_224:
</span><span class="lines">@@ -472,7 +460,7 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::CONCAT:
</span><span class="cx">     case CryptoAlgorithmIdentifier::HKDF_CTR:
</span><span class="cx">     case CryptoAlgorithmIdentifier::PBKDF2:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx">     RELEASE_ASSERT_NOT_REACHED();
</span><span class="lines">@@ -479,7 +467,7 @@
</span><span class="cx">     return nullptr;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForDigest(ExecState* exec, CryptoAlgorithmIdentifier algorithm, JSValue)
</del><ins>+RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForDigest(ExecState&amp; state, CryptoAlgorithmIdentifier algorithm, JSValue)
</ins><span class="cx"> {
</span><span class="cx">     switch (algorithm) {
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSAES_PKCS1_v1_5:
</span><span class="lines">@@ -496,7 +484,7 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_KW:
</span><span class="cx">     case CryptoAlgorithmIdentifier::HMAC:
</span><span class="cx">     case CryptoAlgorithmIdentifier::DH:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     case CryptoAlgorithmIdentifier::SHA_1:
</span><span class="cx">     case CryptoAlgorithmIdentifier::SHA_224:
</span><span class="lines">@@ -507,7 +495,7 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::CONCAT:
</span><span class="cx">     case CryptoAlgorithmIdentifier::HKDF_CTR:
</span><span class="cx">     case CryptoAlgorithmIdentifier::PBKDF2:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx">     RELEASE_ASSERT_NOT_REACHED();
</span><span class="lines">@@ -514,7 +502,7 @@
</span><span class="cx">     return nullptr;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForGenerateKey(ExecState* exec, CryptoAlgorithmIdentifier algorithm, JSValue value)
</del><ins>+RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForGenerateKey(ExecState&amp; state, CryptoAlgorithmIdentifier algorithm, JSValue value)
</ins><span class="cx"> {
</span><span class="cx">     switch (algorithm) {
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSAES_PKCS1_v1_5:
</span><span class="lines">@@ -521,10 +509,10 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSASSA_PKCS1_v1_5:
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSA_PSS:
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSA_OAEP:
</span><del>-        return createRsaKeyGenParams(*exec, value);
</del><ins>+        return createRsaKeyGenParams(state, value);
</ins><span class="cx">     case CryptoAlgorithmIdentifier::ECDSA:
</span><span class="cx">     case CryptoAlgorithmIdentifier::ECDH:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_CTR:
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_CBC:
</span><span class="lines">@@ -532,9 +520,9 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_GCM:
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_CFB:
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_KW:
</span><del>-        return createAesKeyGenParams(*exec, value);
</del><ins>+        return createAesKeyGenParams(state, value);
</ins><span class="cx">     case CryptoAlgorithmIdentifier::HMAC:
</span><del>-        return createHmacKeyParams(*exec, value);
</del><ins>+        return createHmacKeyParams(state, value);
</ins><span class="cx">     case CryptoAlgorithmIdentifier::DH:
</span><span class="cx">     case CryptoAlgorithmIdentifier::SHA_1:
</span><span class="cx">     case CryptoAlgorithmIdentifier::SHA_224:
</span><span class="lines">@@ -544,7 +532,7 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::CONCAT:
</span><span class="cx">     case CryptoAlgorithmIdentifier::HKDF_CTR:
</span><span class="cx">     case CryptoAlgorithmIdentifier::PBKDF2:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx">     RELEASE_ASSERT_NOT_REACHED();
</span><span class="lines">@@ -551,7 +539,7 @@
</span><span class="cx">     return nullptr;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForDeriveKey(ExecState* exec, CryptoAlgorithmIdentifier algorithm, JSValue)
</del><ins>+RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForDeriveKey(ExecState&amp; state, CryptoAlgorithmIdentifier algorithm, JSValue)
</ins><span class="cx"> {
</span><span class="cx">     switch (algorithm) {
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSAES_PKCS1_v1_5:
</span><span class="lines">@@ -576,7 +564,7 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::CONCAT:
</span><span class="cx">     case CryptoAlgorithmIdentifier::HKDF_CTR:
</span><span class="cx">     case CryptoAlgorithmIdentifier::PBKDF2:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx">     RELEASE_ASSERT_NOT_REACHED();
</span><span class="lines">@@ -583,7 +571,7 @@
</span><span class="cx">     return nullptr;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForDeriveBits(ExecState* exec, CryptoAlgorithmIdentifier algorithm, JSValue)
</del><ins>+RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForDeriveBits(ExecState&amp; state, CryptoAlgorithmIdentifier algorithm, JSValue)
</ins><span class="cx"> {
</span><span class="cx">     switch (algorithm) {
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSAES_PKCS1_v1_5:
</span><span class="lines">@@ -608,7 +596,7 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::CONCAT:
</span><span class="cx">     case CryptoAlgorithmIdentifier::HKDF_CTR:
</span><span class="cx">     case CryptoAlgorithmIdentifier::PBKDF2:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx">     RELEASE_ASSERT_NOT_REACHED();
</span><span class="lines">@@ -615,7 +603,7 @@
</span><span class="cx">     return nullptr;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForImportKey(ExecState* exec, CryptoAlgorithmIdentifier algorithm, JSValue value)
</del><ins>+RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForImportKey(ExecState&amp; state, CryptoAlgorithmIdentifier algorithm, JSValue value)
</ins><span class="cx"> {
</span><span class="cx">     switch (algorithm) {
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSAES_PKCS1_v1_5:
</span><span class="lines">@@ -622,7 +610,7 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSASSA_PKCS1_v1_5:
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSA_PSS:
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSA_OAEP:
</span><del>-        return createRsaKeyParamsWithHash(*exec, value);
</del><ins>+        return createRsaKeyParamsWithHash(state, value);
</ins><span class="cx">     case CryptoAlgorithmIdentifier::ECDSA:
</span><span class="cx">     case CryptoAlgorithmIdentifier::ECDH:
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_CTR:
</span><span class="lines">@@ -633,7 +621,7 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::AES_KW:
</span><span class="cx">         return adoptRef(*new CryptoAlgorithmParametersDeprecated);
</span><span class="cx">     case CryptoAlgorithmIdentifier::HMAC:
</span><del>-        return createHmacParams(*exec, value);
</del><ins>+        return createHmacParams(state, value);
</ins><span class="cx">     case CryptoAlgorithmIdentifier::DH:
</span><span class="cx">         return adoptRef(*new CryptoAlgorithmParametersDeprecated);
</span><span class="cx">     case CryptoAlgorithmIdentifier::SHA_1:
</span><span class="lines">@@ -644,7 +632,7 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::CONCAT:
</span><span class="cx">     case CryptoAlgorithmIdentifier::HKDF_CTR:
</span><span class="cx">     case CryptoAlgorithmIdentifier::PBKDF2:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx">     RELEASE_ASSERT_NOT_REACHED();
</span><span class="lines">@@ -651,7 +639,7 @@
</span><span class="cx">     return nullptr;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForExportKey(ExecState* exec, CryptoAlgorithmIdentifier algorithm, JSValue)
</del><ins>+RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; JSCryptoAlgorithmDictionary::createParametersForExportKey(ExecState&amp; state, CryptoAlgorithmIdentifier algorithm, JSValue)
</ins><span class="cx"> {
</span><span class="cx">     switch (algorithm) {
</span><span class="cx">     case CryptoAlgorithmIdentifier::RSAES_PKCS1_v1_5:
</span><span class="lines">@@ -677,7 +665,7 @@
</span><span class="cx">     case CryptoAlgorithmIdentifier::CONCAT:
</span><span class="cx">     case CryptoAlgorithmIdentifier::HKDF_CTR:
</span><span class="cx">     case CryptoAlgorithmIdentifier::PBKDF2:
</span><del>-        setDOMException(exec, NOT_SUPPORTED_ERR);
</del><ins>+        setDOMException(&amp;state, NOT_SUPPORTED_ERR);
</ins><span class="cx">         return nullptr;
</span><span class="cx">     }
</span><span class="cx">     RELEASE_ASSERT_NOT_REACHED();
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCryptoAlgorithmDictionaryh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCryptoAlgorithmDictionary.h (209899 => 209900)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCryptoAlgorithmDictionary.h        2016-12-16 02:38:27 UTC (rev 209899)
+++ trunk/Source/WebCore/bindings/js/JSCryptoAlgorithmDictionary.h        2016-12-16 03:01:14 UTC (rev 209900)
</span><span class="lines">@@ -41,18 +41,18 @@
</span><span class="cx"> 
</span><span class="cx"> class JSCryptoAlgorithmDictionary {
</span><span class="cx"> public:
</span><del>-    static bool getAlgorithmIdentifier(JSC::ExecState*, JSC::JSValue, CryptoAlgorithmIdentifier&amp;);
</del><ins>+    static bool getAlgorithmIdentifier(JSC::ExecState&amp;, JSC::JSValue, CryptoAlgorithmIdentifier&amp;);
</ins><span class="cx"> 
</span><del>-    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForEncrypt(JSC::ExecState*, CryptoAlgorithmIdentifier, JSC::JSValue);
-    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForDecrypt(JSC::ExecState*, CryptoAlgorithmIdentifier, JSC::JSValue);
-    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForSign(JSC::ExecState*, CryptoAlgorithmIdentifier, JSC::JSValue);
-    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForVerify(JSC::ExecState*, CryptoAlgorithmIdentifier, JSC::JSValue);
-    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForDigest(JSC::ExecState*, CryptoAlgorithmIdentifier, JSC::JSValue);
-    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForGenerateKey(JSC::ExecState*, CryptoAlgorithmIdentifier, JSC::JSValue);
-    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForDeriveKey(JSC::ExecState*, CryptoAlgorithmIdentifier, JSC::JSValue);
-    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForDeriveBits(JSC::ExecState*, CryptoAlgorithmIdentifier, JSC::JSValue);
-    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForImportKey(JSC::ExecState*, CryptoAlgorithmIdentifier, JSC::JSValue);
-    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForExportKey(JSC::ExecState*, CryptoAlgorithmIdentifier, JSC::JSValue);
</del><ins>+    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForEncrypt(JSC::ExecState&amp;, CryptoAlgorithmIdentifier, JSC::JSValue);
+    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForDecrypt(JSC::ExecState&amp;, CryptoAlgorithmIdentifier, JSC::JSValue);
+    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForSign(JSC::ExecState&amp;, CryptoAlgorithmIdentifier, JSC::JSValue);
+    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForVerify(JSC::ExecState&amp;, CryptoAlgorithmIdentifier, JSC::JSValue);
+    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForDigest(JSC::ExecState&amp;, CryptoAlgorithmIdentifier, JSC::JSValue);
+    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForGenerateKey(JSC::ExecState&amp;, CryptoAlgorithmIdentifier, JSC::JSValue);
+    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForDeriveKey(JSC::ExecState&amp;, CryptoAlgorithmIdentifier, JSC::JSValue);
+    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForDeriveBits(JSC::ExecState&amp;, CryptoAlgorithmIdentifier, JSC::JSValue);
+    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForImportKey(JSC::ExecState&amp;, CryptoAlgorithmIdentifier, JSC::JSValue);
+    static RefPtr&lt;CryptoAlgorithmParametersDeprecated&gt; createParametersForExportKey(JSC::ExecState&amp;, CryptoAlgorithmIdentifier, JSC::JSValue);
</ins><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCryptoOperationDatacpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCryptoOperationData.cpp (209899 => 209900)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCryptoOperationData.cpp        2016-12-16 02:38:27 UTC (rev 209899)
+++ trunk/Source/WebCore/bindings/js/JSCryptoOperationData.cpp        2016-12-16 03:01:14 UTC (rev 209900)
</span><span class="lines">@@ -34,10 +34,9 @@
</span><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><del>-bool cryptoOperationDataFromJSValue(ExecState* exec, JSValue value, CryptoOperationData&amp; result)
</del><ins>+bool cryptoOperationDataFromJSValue(ExecState&amp; state, JSValue value, CryptoOperationData&amp; result)
</ins><span class="cx"> {
</span><del>-    VM&amp; vm = exec-&gt;vm();
-    auto scope = DECLARE_THROW_SCOPE(vm);
</del><ins>+    auto scope = DECLARE_THROW_SCOPE(state.vm());
</ins><span class="cx"> 
</span><span class="cx">     if (ArrayBuffer* buffer = toUnsharedArrayBuffer(value))
</span><span class="cx">         result = std::make_pair(static_cast&lt;uint8_t*&gt;(buffer-&gt;data()), buffer-&gt;byteLength());
</span><span class="lines">@@ -44,7 +43,7 @@
</span><span class="cx">     else if (RefPtr&lt;ArrayBufferView&gt; bufferView = toUnsharedArrayBufferView(value))
</span><span class="cx">         result = std::make_pair(static_cast&lt;uint8_t*&gt;(bufferView-&gt;baseAddress()), bufferView-&gt;byteLength());
</span><span class="cx">     else {
</span><del>-        throwTypeError(exec, scope, ASCIILiteral(&quot;Only ArrayBuffer and ArrayBufferView objects can be passed as CryptoOperationData&quot;));
</del><ins>+        throwTypeError(&amp;state, scope, ASCIILiteral(&quot;Only ArrayBuffer and ArrayBufferView objects can be passed as CryptoOperationData&quot;));
</ins><span class="cx">         return false;
</span><span class="cx">     }
</span><span class="cx">     return true;
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCryptoOperationDatah"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCryptoOperationData.h (209899 => 209900)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCryptoOperationData.h        2016-12-16 02:38:27 UTC (rev 209899)
+++ trunk/Source/WebCore/bindings/js/JSCryptoOperationData.h        2016-12-16 03:01:14 UTC (rev 209900)
</span><span class="lines">@@ -36,7 +36,7 @@
</span><span class="cx"> 
</span><span class="cx"> typedef std::pair&lt;const uint8_t*, size_t&gt; CryptoOperationData;
</span><span class="cx"> 
</span><del>-bool cryptoOperationDataFromJSValue(JSC::ExecState*, JSC::JSValue, CryptoOperationData&amp;);
</del><ins>+bool cryptoOperationDataFromJSValue(JSC::ExecState&amp;, JSC::JSValue, CryptoOperationData&amp;);
</ins><span class="cx"> 
</span><span class="cx"> } // namespace WebCore
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSWebKitSubtleCryptoCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSWebKitSubtleCryptoCustom.cpp (209899 => 209900)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSWebKitSubtleCryptoCustom.cpp        2016-12-16 02:38:27 UTC (rev 209899)
+++ trunk/Source/WebCore/bindings/js/JSWebKitSubtleCryptoCustom.cpp        2016-12-16 03:01:14 UTC (rev 209900)
</span><span class="lines">@@ -68,7 +68,7 @@
</span><span class="cx">     auto scope = DECLARE_THROW_SCOPE(vm);
</span><span class="cx"> 
</span><span class="cx">     CryptoAlgorithmIdentifier algorithmIdentifier;
</span><del>-    auto success = JSCryptoAlgorithmDictionary::getAlgorithmIdentifier(&amp;state, value, algorithmIdentifier);
</del><ins>+    auto success = JSCryptoAlgorithmDictionary::getAlgorithmIdentifier(state, value, algorithmIdentifier);
</ins><span class="cx">     ASSERT_UNUSED(scope, scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return nullptr;
</span><span class="lines">@@ -151,7 +151,7 @@
</span><span class="cx">     if (!algorithm)
</span><span class="cx">         return jsUndefined();
</span><span class="cx"> 
</span><del>-    auto parameters = JSCryptoAlgorithmDictionary::createParametersForEncrypt(&amp;state, algorithm-&gt;identifier(), state.uncheckedArgument(0));
</del><ins>+    auto parameters = JSCryptoAlgorithmDictionary::createParametersForEncrypt(state, algorithm-&gt;identifier(), state.uncheckedArgument(0));
</ins><span class="cx">     ASSERT(scope.exception() || parameters);
</span><span class="cx">     if (!parameters)
</span><span class="cx">         return jsUndefined();
</span><span class="lines">@@ -167,7 +167,7 @@
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     CryptoOperationData data;
</span><del>-    auto success = cryptoOperationDataFromJSValue(&amp;state, state.uncheckedArgument(2), data);
</del><ins>+    auto success = cryptoOperationDataFromJSValue(state, state.uncheckedArgument(2), data);
</ins><span class="cx">     ASSERT(scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return jsUndefined();
</span><span class="lines">@@ -203,7 +203,7 @@
</span><span class="cx">     if (!algorithm)
</span><span class="cx">         return jsUndefined();
</span><span class="cx"> 
</span><del>-    auto parameters = JSCryptoAlgorithmDictionary::createParametersForDecrypt(&amp;state, algorithm-&gt;identifier(), state.uncheckedArgument(0));
</del><ins>+    auto parameters = JSCryptoAlgorithmDictionary::createParametersForDecrypt(state, algorithm-&gt;identifier(), state.uncheckedArgument(0));
</ins><span class="cx">     ASSERT(scope.exception() || parameters);
</span><span class="cx">     if (!parameters)
</span><span class="cx">         return jsUndefined();
</span><span class="lines">@@ -219,7 +219,7 @@
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     CryptoOperationData data;
</span><del>-    auto success = cryptoOperationDataFromJSValue(&amp;state, state.uncheckedArgument(2), data);
</del><ins>+    auto success = cryptoOperationDataFromJSValue(state, state.uncheckedArgument(2), data);
</ins><span class="cx">     ASSERT(scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return jsUndefined();
</span><span class="lines">@@ -255,7 +255,7 @@
</span><span class="cx">     if (!algorithm)
</span><span class="cx">         return jsUndefined();
</span><span class="cx"> 
</span><del>-    auto parameters = JSCryptoAlgorithmDictionary::createParametersForSign(&amp;state, algorithm-&gt;identifier(), state.uncheckedArgument(0));
</del><ins>+    auto parameters = JSCryptoAlgorithmDictionary::createParametersForSign(state, algorithm-&gt;identifier(), state.uncheckedArgument(0));
</ins><span class="cx">     ASSERT(scope.exception() || parameters);
</span><span class="cx">     if (!parameters)
</span><span class="cx">         return jsUndefined();
</span><span class="lines">@@ -271,7 +271,7 @@
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     CryptoOperationData data;
</span><del>-    auto success = cryptoOperationDataFromJSValue(&amp;state, state.uncheckedArgument(2), data);
</del><ins>+    auto success = cryptoOperationDataFromJSValue(state, state.uncheckedArgument(2), data);
</ins><span class="cx">     ASSERT(scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return jsUndefined();
</span><span class="lines">@@ -307,7 +307,7 @@
</span><span class="cx">     if (!algorithm)
</span><span class="cx">         return jsUndefined();
</span><span class="cx"> 
</span><del>-    auto parameters = JSCryptoAlgorithmDictionary::createParametersForVerify(&amp;state, algorithm-&gt;identifier(), state.uncheckedArgument(0));
</del><ins>+    auto parameters = JSCryptoAlgorithmDictionary::createParametersForVerify(state, algorithm-&gt;identifier(), state.uncheckedArgument(0));
</ins><span class="cx">     ASSERT(scope.exception() || parameters);
</span><span class="cx">     if (!parameters)
</span><span class="cx">         return jsUndefined();
</span><span class="lines">@@ -323,13 +323,13 @@
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     CryptoOperationData signature;
</span><del>-    auto success = cryptoOperationDataFromJSValue(&amp;state, state.uncheckedArgument(2), signature);
</del><ins>+    auto success = cryptoOperationDataFromJSValue(state, state.uncheckedArgument(2), signature);
</ins><span class="cx">     ASSERT(scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return jsUndefined();
</span><span class="cx"> 
</span><span class="cx">     CryptoOperationData data;
</span><del>-    success = cryptoOperationDataFromJSValue(&amp;state, state.uncheckedArgument(3), data);
</del><ins>+    success = cryptoOperationDataFromJSValue(state, state.uncheckedArgument(3), data);
</ins><span class="cx">     ASSERT(scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return jsUndefined();
</span><span class="lines">@@ -365,13 +365,13 @@
</span><span class="cx">     if (!algorithm)
</span><span class="cx">         return jsUndefined();
</span><span class="cx"> 
</span><del>-    auto parameters = JSCryptoAlgorithmDictionary::createParametersForDigest(&amp;state, algorithm-&gt;identifier(), state.uncheckedArgument(0));
</del><ins>+    auto parameters = JSCryptoAlgorithmDictionary::createParametersForDigest(state, algorithm-&gt;identifier(), state.uncheckedArgument(0));
</ins><span class="cx">     ASSERT(scope.exception() || parameters);
</span><span class="cx">     if (!parameters)
</span><span class="cx">         return jsUndefined();
</span><span class="cx"> 
</span><span class="cx">     CryptoOperationData data;
</span><del>-    auto success = cryptoOperationDataFromJSValue(&amp;state, state.uncheckedArgument(1), data);
</del><ins>+    auto success = cryptoOperationDataFromJSValue(state, state.uncheckedArgument(1), data);
</ins><span class="cx">     ASSERT(scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return jsUndefined();
</span><span class="lines">@@ -407,7 +407,7 @@
</span><span class="cx">     if (!algorithm)
</span><span class="cx">         return jsUndefined();
</span><span class="cx"> 
</span><del>-    auto parameters = JSCryptoAlgorithmDictionary::createParametersForGenerateKey(&amp;state, algorithm-&gt;identifier(), state.uncheckedArgument(0));
</del><ins>+    auto parameters = JSCryptoAlgorithmDictionary::createParametersForGenerateKey(state, algorithm-&gt;identifier(), state.uncheckedArgument(0));
</ins><span class="cx">     ASSERT(scope.exception() || parameters);
</span><span class="cx">     if (!parameters)
</span><span class="cx">         return jsUndefined();
</span><span class="lines">@@ -521,7 +521,7 @@
</span><span class="cx">         return jsUndefined();
</span><span class="cx"> 
</span><span class="cx">     CryptoOperationData data;
</span><del>-    success = cryptoOperationDataFromJSValue(&amp;state, state.uncheckedArgument(1), data);
</del><ins>+    success = cryptoOperationDataFromJSValue(state, state.uncheckedArgument(1), data);
</ins><span class="cx">     ASSERT(scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return jsUndefined();
</span><span class="lines">@@ -534,7 +534,7 @@
</span><span class="cx">         if (!algorithm)
</span><span class="cx">             return jsUndefined();
</span><span class="cx"> 
</span><del>-        parameters = JSCryptoAlgorithmDictionary::createParametersForImportKey(&amp;state, algorithm-&gt;identifier(), state.uncheckedArgument(2));
</del><ins>+        parameters = JSCryptoAlgorithmDictionary::createParametersForImportKey(state, algorithm-&gt;identifier(), state.uncheckedArgument(2));
</ins><span class="cx">         ASSERT(scope.exception() || parameters);
</span><span class="cx">         if (!parameters)
</span><span class="cx">             return jsUndefined();
</span><span class="lines">@@ -669,7 +669,7 @@
</span><span class="cx">     if (!algorithm)
</span><span class="cx">         return jsUndefined();
</span><span class="cx"> 
</span><del>-    auto parameters = JSCryptoAlgorithmDictionary::createParametersForEncrypt(&amp;state, algorithm-&gt;identifier(), state.uncheckedArgument(3));
</del><ins>+    auto parameters = JSCryptoAlgorithmDictionary::createParametersForEncrypt(state, algorithm-&gt;identifier(), state.uncheckedArgument(3));
</ins><span class="cx">     ASSERT(scope.exception() || parameters);
</span><span class="cx">     if (!parameters)
</span><span class="cx">         return jsUndefined();
</span><span class="lines">@@ -715,7 +715,7 @@
</span><span class="cx">         return jsUndefined();
</span><span class="cx"> 
</span><span class="cx">     CryptoOperationData wrappedKeyData;
</span><del>-    success = cryptoOperationDataFromJSValue(&amp;state, state.uncheckedArgument(1), wrappedKeyData);
</del><ins>+    success = cryptoOperationDataFromJSValue(state, state.uncheckedArgument(1), wrappedKeyData);
</ins><span class="cx">     ASSERT(scope.exception() || success);
</span><span class="cx">     if (!success)
</span><span class="cx">         return jsUndefined();
</span><span class="lines">@@ -734,7 +734,7 @@
</span><span class="cx">     ASSERT(scope.exception() || unwrapAlgorithm);
</span><span class="cx">     if (!unwrapAlgorithm)
</span><span class="cx">         return jsUndefined();
</span><del>-    auto unwrapAlgorithmParameters = JSCryptoAlgorithmDictionary::createParametersForDecrypt(&amp;state, unwrapAlgorithm-&gt;identifier(), state.uncheckedArgument(3));
</del><ins>+    auto unwrapAlgorithmParameters = JSCryptoAlgorithmDictionary::createParametersForDecrypt(state, unwrapAlgorithm-&gt;identifier(), state.uncheckedArgument(3));
</ins><span class="cx">     ASSERT(scope.exception() || unwrapAlgorithmParameters);
</span><span class="cx">     if (!unwrapAlgorithmParameters)
</span><span class="cx">         return jsUndefined();
</span><span class="lines">@@ -747,7 +747,7 @@
</span><span class="cx">         if (!unwrappedKeyAlgorithm)
</span><span class="cx">             return jsUndefined();
</span><span class="cx"> 
</span><del>-        unwrappedKeyAlgorithmParameters = JSCryptoAlgorithmDictionary::createParametersForImportKey(&amp;state, unwrappedKeyAlgorithm-&gt;identifier(), state.uncheckedArgument(4));
</del><ins>+        unwrappedKeyAlgorithmParameters = JSCryptoAlgorithmDictionary::createParametersForImportKey(state, unwrappedKeyAlgorithm-&gt;identifier(), state.uncheckedArgument(4));
</ins><span class="cx">         ASSERT(scope.exception() || unwrappedKeyAlgorithmParameters);
</span><span class="cx">         if (!unwrappedKeyAlgorithmParameters)
</span><span class="cx">             return jsUndefined();
</span></span></pre>
</div>
</div>

</body>
</html>