openpgpjs/docs/module-config.html
Daniel Huigens 96b13a468b
6.1.0
2025-01-30 14:15:35 +01:00

4015 lines
59 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>JSDoc: Module: config</title>
<script src="scripts/prettify/prettify.js"> </script>
<script src="scripts/prettify/lang-css.js"> </script>
<!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css">
<link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css">
</head>
<body>
<div id="main">
<h1 class="page-title">Module: config</h1>
<section>
<header>
</header>
<article>
<div class="container-overview">
<div class="description"><p>This object contains global configuration values.</p></div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/index.js">config/index.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/index.js#L1">line 1</a>
</li></ul></dd>
<dt class="tag-see">See:</dt>
<dd class="tag-see">
<ul>
<li>module:config/config</li>
</ul>
</dd>
</dl>
</div>
<h3 class="subsection-title">Members</h3>
<h4 class="name" id=".additionalAllowedPackets"><span class="type-signature">(static) </span>additionalAllowedPackets<span class="type-signature"></span></h4>
<div class="description">
<p>Parsing of packets is normally restricted to a predefined set of packets. For example a Sym. Encrypted Integrity Protected Data Packet can only
contain a certain set of packets including LiteralDataPacket. With this setting we can allow additional packets, which is probably not advisable
as a global config setting, but can be used for specific function calls (e.g. decrypt method of Message).</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>additionalAllowedPackets</code></td>
<td class="type">
<span class="param-type">Array</span>
</td>
<td class="description last"><p>Allow additional packets on parsing. Defined as array of packet classes, e.g. [PublicKeyPacket]</p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L226">line 226</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".aeadChunkSizeByte"><span class="type-signature">(static) </span>aeadChunkSizeByte<span class="type-signature"></span></h4>
<div class="description">
<p>Chunk Size Byte for Authenticated Encryption with Additional Data (AEAD) mode
Only has an effect when aeadProtect is set to true.
Must be an integer value from 0 to 56.</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>aeadChunkSizeByte</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L75">line 75</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".aeadProtect"><span class="type-signature">(static) </span>aeadProtect<span class="type-signature"></span></h4>
<div class="description">
<p>Use Authenticated Encryption with Additional Data (AEAD) protection for symmetric encryption.
This option is applicable to:</p>
<ul>
<li>key generation (encryption key preferences),</li>
<li>password-based message encryption, and</li>
<li>private key encryption.
In the case of message encryption using public keys, the encryption key preferences are respected instead.
Note: not all OpenPGP implementations are compatible with this option.</li>
</ul>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>aeadProtect</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L52">line 52</a>
</li></ul></dd>
<dt class="tag-see">See:</dt>
<dd class="tag-see">
<ul>
<li><a href="https://tools.ietf.org/html/draft-ietf-openpgp-crypto-refresh-10.html">draft-crypto-refresh-10</a></li>
</ul>
</dd>
</dl>
<h4 class="name" id=".allowInsecureDecryptionWithSigningKeys"><span class="type-signature">(static) </span>allowInsecureDecryptionWithSigningKeys<span class="type-signature"></span></h4>
<div class="description">
<p>Allow decryption using RSA keys without <code>encrypt</code> flag.
This setting is potentially insecure, but it is needed to get around an old openpgpjs bug
where key flags were ignored when selecting a key for encryption.</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>allowInsecureDecryptionWithSigningKeys</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L173">line 173</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".allowInsecureVerificationWithReformattedKeys"><span class="type-signature">(static) </span>allowInsecureVerificationWithReformattedKeys<span class="type-signature"></span></h4>
<div class="description">
<p>Allow verification of message signatures with keys whose validity at the time of signing cannot be determined.
Instead, a verification key will also be consider valid as long as it is valid at the current time.
This setting is potentially insecure, but it is needed to verify messages signed with keys that were later reformatted,
and have self-signature's creation date that does not match the primary key creation date.</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>allowInsecureDecryptionWithSigningKeys</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L182">line 182</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".allowUnauthenticatedMessages"><span class="type-signature">(static) </span>allowUnauthenticatedMessages<span class="type-signature"></span></h4>
<div class="description">
<p>Allow decryption of messages without integrity protection.
This is an <strong>insecure</strong> setting:</p>
<ul>
<li>message modifications cannot be detected, thus processing the decrypted data is potentially unsafe.</li>
<li>it enables downgrade attacks against integrity-protected messages.</li>
</ul>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>allowUnauthenticatedMessages</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L136">line 136</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".allowUnauthenticatedStream"><span class="type-signature">(static) </span>allowUnauthenticatedStream<span class="type-signature"></span></h4>
<div class="description">
<p>Allow streaming unauthenticated data before its integrity has been checked. This would allow the application to
process large streams while limiting memory usage by releasing the decrypted chunks as soon as possible
and deferring checking their integrity until the decrypted stream has been read in full.</p>
<p>This setting is <strong>insecure</strong> if the encrypted data has been corrupted by a malicious entity:</p>
<ul>
<li>if the partially decrypted message is processed further or displayed to the user, it opens up the possibility of attacks such as EFAIL
(see https://efail.de/).</li>
<li>an attacker with access to traces or timing info of internal processing errors could learn some info about the data.</li>
</ul>
<p>NB: this setting does not apply to AEAD-encrypted data, where the AEAD data chunk is never released until integrity is confirmed.</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>allowUnauthenticatedStream</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L151">line 151</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".commentString"><span class="type-signature">(static) </span>commentString<span class="type-signature"></span></h4>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>commentString</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last"><p>A comment string to be included in armored messages</p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L246">line 246</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".constantTimePKCS1Decryption"><span class="type-signature">(static) </span>constantTimePKCS1Decryption<span class="type-signature"></span></h4>
<div class="description">
<p>Enable constant-time decryption of RSA- and ElGamal-encrypted session keys, to hinder Bleichenbacher-like attacks (https://link.springer.com/chapter/10.1007/BFb0055716).
This setting has measurable performance impact and it is only helpful in application scenarios where both of the following conditions apply:</p>
<ul>
<li>new/incoming messages are automatically decrypted (without user interaction);</li>
<li>an attacker can determine how long it takes to decrypt each message (e.g. due to decryption errors being logged remotely).
See also <code>constantTimePKCS1DecryptionSupportedSymmetricAlgorithms</code>.</li>
</ul>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>constantTimePKCS1Decryption</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L200">line 200</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".constantTimePKCS1DecryptionSupportedSymmetricAlgorithms"><span class="type-signature">(static) </span>constantTimePKCS1DecryptionSupportedSymmetricAlgorithms<span class="type-signature"></span></h4>
<div class="description">
<p>This setting is only meaningful if <code>constantTimePKCS1Decryption</code> is enabled.
Decryption of RSA- and ElGamal-encrypted session keys of symmetric algorithms different from the ones specified here will fail.
However, the more algorithms are added, the slower the decryption procedure becomes.</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>constantTimePKCS1DecryptionSupportedSymmetricAlgorithms</code></td>
<td class="type">
<span class="param-type">Set.&lt;Integer></span>
</td>
<td class="description last"><p><a href="module-enums.html#.symmetric">module:enums.symmetric</a></p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L208">line 208</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".ignoreMalformedPackets"><span class="type-signature">(static) </span>ignoreMalformedPackets<span class="type-signature"></span></h4>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>ignoreMalformedPackets</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last"><p>Ignore malformed packets on parsing instead of throwing an error</p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L218">line 218</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".ignoreUnsupportedPackets"><span class="type-signature">(static) </span>ignoreUnsupportedPackets<span class="type-signature"></span></h4>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>ignoreUnsupportedPackets</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last"><p>Ignore unsupported/unrecognizable packets on parsing instead of throwing an error</p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L213">line 213</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".knownNotations"><span class="type-signature">(static) </span>knownNotations<span class="type-signature"></span></h4>
<div class="description">
<p>Contains notatations that are considered &quot;known&quot;. Known notations do not trigger
validation error when the notation is marked as critical.</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>knownNotations</code></td>
<td class="type">
<span class="param-type">Array</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L260">line 260</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".maxUserIDLength"><span class="type-signature">(static) </span>maxUserIDLength<span class="type-signature"></span></h4>
<div class="description">
<p>Max userID string length (used for parsing)</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>maxUserIDLength</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L253">line 253</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".minRSABits"><span class="type-signature">(static) </span>minRSABits<span class="type-signature"></span></h4>
<div class="description">
<p>Minimum RSA key size allowed for key generation and message signing, verification and encryption.
The default is 2047 since due to a bug, previous versions of OpenPGP.js could generate 2047-bit keys instead of 2048-bit ones.</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>minRSABits</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L158">line 158</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".passwordCollisionCheck"><span class="type-signature">(static) </span>passwordCollisionCheck<span class="type-signature"></span></h4>
<div class="description">
<p>Work-around for rare GPG decryption bug when encrypting with multiple passwords.
<strong>Slower and slightly less secure</strong></p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>passwordCollisionCheck</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L165">line 165</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".preferredAEADAlgorithm"><span class="type-signature">(static) </span>preferredAEADAlgorithm<span class="type-signature"></span></h4>
<div class="description">
<p>Default Authenticated Encryption with Additional Data (AEAD) encryption mode
Only has an effect when aeadProtect is set to true.</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>preferredAEADAlgorithm</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last"><p>Default AEAD mode <a href="module-enums.html#.aead">module:enums.aead</a></p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L67">line 67</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".preferredCompressionAlgorithm"><span class="type-signature">(static) </span>preferredCompressionAlgorithm<span class="type-signature"></span></h4>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>compression</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last"><p>Default compression algorithm <a href="module-enums.html#.compression">module:enums.compression</a></p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L39">line 39</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".preferredHashAlgorithm"><span class="type-signature">(static) </span>preferredHashAlgorithm<span class="type-signature"></span></h4>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>preferredHashAlgorithm</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last"><p>Default hash algorithm <a href="module-enums.html#.hash">module:enums.hash</a></p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L29">line 29</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".preferredSymmetricAlgorithm"><span class="type-signature">(static) </span>preferredSymmetricAlgorithm<span class="type-signature"></span></h4>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>preferredSymmetricAlgorithm</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last"><p>Default encryption cipher <a href="module-enums.html#.symmetric">module:enums.symmetric</a></p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L34">line 34</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".rejectCurves"><span class="type-signature">(static) </span>rejectCurves<span class="type-signature"></span></h4>
<div class="description">
<p>Reject non-standard curves for key generation, message encryption, signing or verification</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>rejectCurves</code></td>
<td class="type">
<span class="param-type">Set.&lt;String></span>
</td>
<td class="description last"><p><a href="module-enums.html#.curve">module:enums.curve</a></p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L299">line 299</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".rejectHashAlgorithms"><span class="type-signature">(static) </span>rejectHashAlgorithms<span class="type-signature"></span></h4>
<div class="description">
<p>Reject insecure hash algorithms</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>rejectHashAlgorithms</code></td>
<td class="type">
<span class="param-type">Set.&lt;Integer></span>
</td>
<td class="description last"><p><a href="module-enums.html#.hash">module:enums.hash</a></p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L281">line 281</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".rejectMessageHashAlgorithms"><span class="type-signature">(static) </span>rejectMessageHashAlgorithms<span class="type-signature"></span></h4>
<div class="description">
<p>Reject insecure message hash algorithms</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>rejectMessageHashAlgorithms</code></td>
<td class="type">
<span class="param-type">Set.&lt;Integer></span>
</td>
<td class="description last"><p><a href="module-enums.html#.hash">module:enums.hash</a></p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L287">line 287</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".rejectPublicKeyAlgorithms"><span class="type-signature">(static) </span>rejectPublicKeyAlgorithms<span class="type-signature"></span></h4>
<div class="description">
<p>Reject insecure public key algorithms for key generation and message encryption, signing or verification</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>rejectPublicKeyAlgorithms</code></td>
<td class="type">
<span class="param-type">Set.&lt;Integer></span>
</td>
<td class="description last"><p><a href="module-enums.html#.publicKey">module:enums.publicKey</a></p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L293">line 293</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".s2kArgon2Params"><span class="type-signature">(static) </span>s2kArgon2Params<span class="type-signature"></span></h4>
<div class="description">
<p><a href="https://tools.ietf.org/html/draft-ietf-openpgp-crypto-refresh-07.html#section-3.7.1.4"> draft-crypto-refresh 3.7.1.4</a>:
Argon2 parameters for S2K (String to Key).
Only relevant if <code>config.s2kType</code> is set to <code>enums.s2k.argon2</code>.
Default settings correspond to the second recommendation from RFC9106 (&quot;uniformly safe option&quot;),
to ensure compatibility with memory-constrained environments.
For more details on the choice of parameters, see https://tools.ietf.org/html/rfc9106#section-4.</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>params</code></td>
<td class="type">
<span class="param-type">Object</span>
</td>
<td class="description last">
<h6>Properties</h6>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>passes</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last"><p>number of iterations t</p></td>
</tr>
<tr>
<td class="name"><code>parallelism</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last"><p>degree of parallelism p</p></td>
</tr>
<tr>
<td class="name"><code>memoryExponent</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last"><p>one-octet exponent indicating the memory size, which will be: 2**memoryExponent kibibytes.</p></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L123">line 123</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".s2kIterationCountByte"><span class="type-signature">(static) </span>s2kIterationCountByte<span class="type-signature"></span></h4>
<div class="description">
<p><a href="https://tools.ietf.org/html/rfc4880#section-3.7.1.3"> RFC4880 3.7.1.3</a>:
Iteration Count Byte for Iterated and Salted S2K (String to Key).
Only relevant if <code>config.s2kType</code> is set to <code>enums.s2k.iterated</code>.
Note: this is the exponent value, not the final number of iterations (refer to specs for more details).</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>s2kIterationCountByte</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L109">line 109</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".s2kType"><span class="type-signature">(static) </span>s2kType<span class="type-signature"></span></h4>
<div class="description">
<p>S2K (String to Key) type, used for key derivation in the context of secret key encryption
and password-encrypted data. Weaker s2k options are not allowed.
Note: Argon2 is the strongest option but not all OpenPGP implementations are compatible with it
(pending standardisation).</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>s2kType</code></td>
<td class="type">
<span class="param-type">enums.s2k.argon2</span>
|
<span class="param-type">enums.s2k.iterated</span>
</td>
<td class="description last"><p><a href="module-enums.html#.s2k">module:enums.s2k</a></p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L100">line 100</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".showComment"><span class="type-signature">(static) </span>showComment<span class="type-signature"></span></h4>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>showComment</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last"><p>Whether to include module:config/config.commentString in armored messages</p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L236">line 236</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".showVersion"><span class="type-signature">(static) </span>showVersion<span class="type-signature"></span></h4>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>showVersion</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last"><p>Whether to include module:config/config.versionString in armored messages</p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L231">line 231</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".useEllipticFallback"><span class="type-signature">(static) </span>useEllipticFallback<span class="type-signature"></span></h4>
<div class="description">
<p>Whether to use the the noble-curves library for curves (other than Curve25519) that are not supported by the available native crypto API.
When false, certain standard curves will not be supported (depending on the platform).</p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>useEllipticFallback</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L275">line 275</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".v6Keys"><span class="type-signature">(static) </span>v6Keys<span class="type-signature"></span></h4>
<div class="description">
<p>Use v6 keys.
Note: not all OpenPGP implementations are compatible with this option.
<strong>FUTURE OPENPGP.JS VERSIONS MAY BREAK COMPATIBILITY WHEN USING THIS OPTION</strong></p>
</div>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>v6Keys</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L83">line 83</a>
</li></ul></dd>
</dl>
<h4 class="name" id=".versionString"><span class="type-signature">(static) </span>versionString<span class="type-signature"></span></h4>
<h5 class="subsection-title">Properties:</h5>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>versionString</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last"><p>A version string to be included in armored messages</p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js">config/config.js</a>, <a href="https://github.com/openpgpjs/openpgpjs/blob/v6.1.0/src/config/config.js#L241">line 241</a>
</li></ul></dd>
</dl>
</article>
</section>
</div>
<nav>
<h2><a href="index.html">Home</a></h2><h3>Functions</h3><ul><li><a href="global.html#armor">armor</a></li><li><a href="global.html#createCleartextMessage">createCleartextMessage</a></li><li><a href="global.html#createKey">createKey</a></li><li><a href="global.html#createMessage">createMessage</a></li><li><a href="global.html#decrypt">decrypt</a></li><li><a href="global.html#decryptKey">decryptKey</a></li><li><a href="global.html#decryptSessionKeys">decryptSessionKeys</a></li><li><a href="global.html#encrypt">encrypt</a></li><li><a href="global.html#encryptKey">encryptKey</a></li><li><a href="global.html#encryptSessionKey">encryptSessionKey</a></li><li><a href="global.html#formatObject">formatObject</a></li><li><a href="global.html#generateKey">generateKey</a></li><li><a href="global.html#generateSessionKey">generateSessionKey</a></li><li><a href="global.html#getCipherBlockSize">getCipherBlockSize</a></li><li><a href="global.html#getCipherKeySize">getCipherKeySize</a></li><li><a href="global.html#getCipherParams">getCipherParams</a></li><li><a href="global.html#getCompressionStreamInstantiators">getCompressionStreamInstantiators</a></li><li><a href="global.html#newPacketFromTag">newPacketFromTag</a></li><li><a href="global.html#newS2KFromConfig">newS2KFromConfig</a></li><li><a href="global.html#newS2KFromType">newS2KFromType</a></li><li><a href="global.html#produceEncryptionKey">produceEncryptionKey</a></li><li><a href="global.html#readCleartextMessage">readCleartextMessage</a></li><li><a href="global.html#readKey">readKey</a></li><li><a href="global.html#readKeys">readKeys</a></li><li><a href="global.html#readMessage">readMessage</a></li><li><a href="global.html#readPrivateKey">readPrivateKey</a></li><li><a href="global.html#readPrivateKeys">readPrivateKeys</a></li><li><a href="global.html#readSignature">readSignature</a></li><li><a href="global.html#reformatKey">reformatKey</a></li><li><a href="global.html#revokeKey">revokeKey</a></li><li><a href="global.html#runAEAD">runAEAD</a></li><li><a href="global.html#sign">sign</a></li><li><a href="global.html#unarmor">unarmor</a></li><li><a href="global.html#verify">verify</a></li><li><a href="global.html#wrapKeyObject">wrapKeyObject</a></li><li><a href="global.html#zlib">zlib</a></li></ul><h3>Modules</h3><ul><li><a href="module-config.html">config</a></li><li><a href="module-crypto.html">crypto</a></li><li><a href="module-crypto_aes_kw.html">crypto/aes_kw</a></li><li><a href="module-crypto_cipherMode.html">crypto/cipherMode</a></li><li><a href="module-crypto_cmac.html">crypto/cmac</a></li><li><a href="module-crypto_crypto.html">crypto/crypto</a></li><li><a href="module-crypto_hash.html">crypto/hash</a></li><li><a href="module-crypto_hkdf.html">crypto/hkdf</a></li><li><a href="module-crypto_mode_cfb.html">crypto/mode/cfb</a></li><li><a href="module-crypto_mode_eax.html">crypto/mode/eax</a></li><li><a href="module-crypto_mode_gcm.html">crypto/mode/gcm</a></li><li><a href="module-crypto_mode_ocb.html">crypto/mode/ocb</a></li><li><a href="module-crypto_pkcs1.html">crypto/pkcs1</a></li><li><a href="module-crypto_public_key.html">crypto/public_key</a></li><li><a href="module-crypto_public_key_dsa.html">crypto/public_key/dsa</a></li><li><a href="module-crypto_public_key_elgamal.html">crypto/public_key/elgamal</a></li><li><a href="module-crypto_public_key_elliptic.html">crypto/public_key/elliptic</a></li><li><a href="module-crypto_public_key_elliptic_curve.html">crypto/public_key/elliptic/curve</a></li><li><a href="module-crypto_public_key_elliptic_ecdh.html">crypto/public_key/elliptic/ecdh</a></li><li><a href="module-crypto_public_key_elliptic_ecdsa.html">crypto/public_key/elliptic/ecdsa</a></li><li><a href="module-crypto_public_key_elliptic_eddsa.html">crypto/public_key/elliptic/eddsa</a></li><li><a href="module-crypto_public_key_elliptic_eddsa_legacy.html">crypto/public_key/elliptic/eddsa_legacy</a></li><li><a href="module-crypto_public_key_rsa.html">crypto/public_key/rsa</a></li><li><a href="module-crypto_random.html">crypto/random</a></li><li><a href="module-crypto_signature.html">crypto/signature</a></li><li><a href="module-encoding_base64.html">encoding/base64</a></li><li><a href="module-enums.html">enums</a></li><li><a href="module-key_helper.html">key/helper</a></li><li><a href="module-key_Subkey.html">key/Subkey</a></li><li><a href="module-key_User.html">key/User</a></li><li><a href="module-packet_packet.html">packet/packet</a></li><li><a href="module-type_ecdh_symkey.html">type/ecdh_symkey</a></li><li><a href="module-type_keyid.html">type/keyid</a></li><li><a href="module-type_oid.html">type/oid</a></li><li><a href="module-type_s2k.html">type/s2k</a></li><li><a href="module-type_x25519x448_symkey.html">type/x25519x448_symkey</a></li><li><a href="module-util.html">util</a></li></ul><h3>Classes</h3><ul><li><a href="AEADEncryptedDataPacket.html">AEADEncryptedDataPacket</a></li><li><a href="Argon2S2K.html">Argon2S2K</a></li><li><a href="CleartextMessage.html">CleartextMessage</a></li><li><a href="CompressedDataPacket.html">CompressedDataPacket</a></li><li><a href="Key.html">Key</a></li><li><a href="LiteralDataPacket.html">LiteralDataPacket</a></li><li><a href="MarkerPacket.html">MarkerPacket</a></li><li><a href="Message.html">Message</a></li><li><a href="module-key_Subkey-Subkey.html">Subkey</a></li><li><a href="module-key_User-User.html">User</a></li><li><a href="module-type_kdf_params-KDFParams.html">KDFParams</a></li><li><a href="module-type_keyid-KeyID.html">KeyID</a></li><li><a href="module-type_s2k-GenericS2K.html">GenericS2K</a></li><li><a href="OnePassSignaturePacket.html">OnePassSignaturePacket</a></li><li><a href="PacketList.html">PacketList</a></li><li><a href="PaddingPacket.html">PaddingPacket</a></li><li><a href="PrivateKey.html">PrivateKey</a></li><li><a href="PublicKey.html">PublicKey</a></li><li><a href="PublicKeyEncryptedSessionKeyPacket.html">PublicKeyEncryptedSessionKeyPacket</a></li><li><a href="PublicKeyPacket.html">PublicKeyPacket</a></li><li><a href="PublicSubkeyPacket.html">PublicSubkeyPacket</a></li><li><a href="SecretKeyPacket.html">SecretKeyPacket</a></li><li><a href="SecretSubkeyPacket.html">SecretSubkeyPacket</a></li><li><a href="Signature.html">Signature</a></li><li><a href="SignaturePacket.html">SignaturePacket</a></li><li><a href="SymEncryptedIntegrityProtectedDataPacket.html">SymEncryptedIntegrityProtectedDataPacket</a></li><li><a href="SymEncryptedSessionKeyPacket.html">SymEncryptedSessionKeyPacket</a></li><li><a href="SymmetricallyEncryptedDataPacket.html">SymmetricallyEncryptedDataPacket</a></li><li><a href="TrustPacket.html">TrustPacket</a></li><li><a href="UserAttributePacket.html">UserAttributePacket</a></li><li><a href="UserIDPacket.html">UserIDPacket</a></li></ul>
</nav>
<br class="clear">
<footer>
Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 3.6.11</a>
</footer>
<script> prettyPrint(); </script>
<script src="scripts/linenumber.js"> </script>
</body>
</html>