fork-openpgpjs/doc/global.html
Michal Kolodziej 23295342fc Added utf8 awareness to the literal and userid packet classes. Made s2k
work correctly with utf8 strings. Fixeda visibility issue with the
testing suite and added relevant unit tests.
2013-04-16 10:47:17 +02:00

8228 lines
112 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>JSDoc: Global</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">Global</h1>
<section>
<header>
<h2>
</h2>
</header>
<article>
<div class="container-overview">
<dl class="details">
</dl>
</div>
<h3 class="subsection-title">Members</h3>
<dl>
<dt>
<h4 class="name" id="bin2str"><span class="type-signature"></span>bin2str<span class="type-signature"></span></h4>
</dt>
<dd>
<div class="description">
Convert an array of integers(0.255) to a string
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 141
</li></ul></dd>
</dl>
</dd>
<dt>
<h4 class="name" id="crc_table"><span class="type-signature"></span>crc_table<span class="type-signature"></span></h4>
</dt>
<dd>
<div class="description">
Internal function to calculate a CRC-24 checksum over a given string (data)
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.encoding.asciiarmor.js.html">encoding/openpgp.encoding.asciiarmor.js</a>, line 211
</li></ul></dd>
</dl>
</dd>
<dt>
<h4 class="name" id="hash_headers"><span class="type-signature"></span>hash_headers<span class="type-signature"></span></h4>
</dt>
<dd>
<div class="description">
ASN1 object identifiers for hashes (See RFC4880 5.2.2)
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.encoding.js.html">encoding/openpgp.encoding.js</a>, line 90
</li></ul></dd>
</dl>
</dd>
<dt>
<h4 class="name" id="Uint8Array2str"><span class="type-signature"></span>Uint8Array2str<span class="type-signature"></span></h4>
</dt>
<dd>
<div class="description">
Convert a Uint8Array to a string. This currently functions
the same as bin2str.
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 158
</li></ul></dd>
</dl>
</dd>
<dt>
<h4 class="name" id="util"><span class="type-signature"></span>util<span class="type-signature"></span></h4>
</dt>
<dd>
<div class="description">
an instance that should be used.
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 304
</li></ul></dd>
</dl>
</dd>
</dl>
<h3 class="subsection-title">Methods</h3>
<dl>
<dt>
<h4 class="name" id="calc_checksum"><span class="type-signature"></span>calc_checksum<span class="signature">(text)</span><span class="type-signature"> &rarr; {Integer}</span></h4>
</dt>
<dd>
<div class="description">
Calculates a 16bit sum of a string by adding each character
codes modulus 65535
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>text</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">String to create a sum of</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 167
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
An integer containing the sum of all character
codes % 65535
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">Integer</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="decode_utf8"><span class="type-signature"></span>decode_utf8<span class="signature">(utf8)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Convert a string of utf8 bytes to a native javascript string
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>utf8</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">A valid squence of utf8 bytes</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 104
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
A native javascript string
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="encode_utf8"><span class="type-signature"></span>encode_utf8<span class="signature">(str)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Convert a native javascript string to a string of utf8 bytes
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>str</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">The string to convert</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 95
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
A valid squence of utf8 bytes
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="get_hashAlgorithmString"><span class="type-signature"></span>get_hashAlgorithmString<span class="signature">()</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Return the algorithm type as string
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 280
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
String representing the message type
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="getCheckSum"><span class="type-signature"></span>getCheckSum<span class="signature">(data)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Calculates a checksum over the given data and returns it base64 encoded
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Data to create a CRC-24 checksum for</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.encoding.asciiarmor.js.html">encoding/openpgp.encoding.asciiarmor.js</a>, line 186
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Base64 encoded checksum
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="getPGPMessageType"><span class="type-signature"></span>getPGPMessageType<span class="signature">(text)</span><span class="type-signature"> &rarr; {Integer}</span></h4>
</dt>
<dd>
<div class="description">
Finds out which Ascii Armoring type is used. This is an internal function
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>text</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">[String] ascii armored text</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.encoding.asciiarmor.js.html">encoding/openpgp.encoding.asciiarmor.js</a>, line 59
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
0 = MESSAGE PART n of m
1 = MESSAGE PART n
2 = SIGNED MESSAGE
3 = PGP MESSAGE
4 = PUBLIC KEY BLOCK
5 = PRIVATE KEY BLOCK
null = unknown
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">Integer</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="hex2bin"><span class="type-signature"></span>hex2bin<span class="signature">(str)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Create binary string from a hex encoded string
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>str</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Hex string to convert</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 64
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
String containing the binary values
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="hexidump"><span class="type-signature"></span>hexidump<span class="signature">(str)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Creating a hex string from an binary array of integers (0..255)
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>str</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Array of bytes to convert</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 76
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Hexadecimal representation of the array
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="hexstrdump"><span class="type-signature"></span>hexstrdump<span class="signature">(str)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Create hexstring from a binary
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>str</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">String to convert</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 44
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
String containing the hexadecimal values
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="MD5"><span class="type-signature"></span>MD5<span class="signature">()</span><span class="type-signature"></span></h4>
</dt>
<dd>
<div class="description">
A fast MD5 JavaScript implementation
Copyright (c) 2012 Joseph Myers
http://www.myersdaily.org/joseph/javascript/md5-text.html
Permission to use, copy, modify, and distribute this software
and its documentation for any purposes and without
fee is hereby granted provided that this copyright notice
appears in all copies.
Of course, this soft is provided "as is" without express or implied
warranty of any kind.
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="md5.js.html">ciphers/hash/md5.js</a>, line 15
</li></ul></dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_cfb_decrypt"><span class="type-signature"></span>openpgp_cfb_decrypt<span class="signature">(blockcipherfn, block_size, plaintext, key, resync)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
This function decrypts a given plaintext using the specified
blockcipher to decrypt a message
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>blockcipherfn</code></td>
<td class="type">
<span class="param-type"><a href="global.html#openpgp_cipher_block_fn">openpgp_cipher_block_fn</a></span>
</td>
<td class="description last">The algorithm _encrypt_ function to encrypt
data in one block_size encryption.</td>
</tr>
<tr>
<td class="name"><code>block_size</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">the block size in bytes of the algorithm used</td>
</tr>
<tr>
<td class="name"><code>plaintext</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">ciphertext to be decrypted provided as a string</td>
</tr>
<tr>
<td class="name"><code>key</code></td>
<td class="type">
<span class="param-type"><a href="global.html#openpgp_byte_array">openpgp_byte_array</a></span>
</td>
<td class="description last">key to be used to decrypt the ciphertext. This will be passed to the
blockcipherfn</td>
</tr>
<tr>
<td class="name"><code>resync</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last">a boolean value specifying if a resync of the
IV should be used or not. The encrypteddatapacket uses the
"old" style with a resync. Decryption within an
encryptedintegrityprotecteddata packet is not resyncing the IV.</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.cfb.js.html">ciphers/openpgp.cfb.js</a>, line 183
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
a string with the plaintext data
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_cfb_encrypt"><span class="type-signature"></span>openpgp_cfb_encrypt<span class="signature">(prefixrandom, blockcipherfn, block_size, plaintext, key, resync)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
This function encrypts a given with the specified prefixrandom
using the specified blockcipher to encrypt a message
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>prefixrandom</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">random bytes of block_size length provided
as a string to be used in prefixing the data</td>
</tr>
<tr>
<td class="name"><code>blockcipherfn</code></td>
<td class="type">
<span class="param-type"><a href="global.html#openpgp_cipher_block_fn">openpgp_cipher_block_fn</a></span>
</td>
<td class="description last">the algorithm encrypt function to encrypt
data in one block_size encryption.</td>
</tr>
<tr>
<td class="name"><code>block_size</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">the block size in bytes of the algorithm used</td>
</tr>
<tr>
<td class="name"><code>plaintext</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">data to be encrypted provided as a string</td>
</tr>
<tr>
<td class="name"><code>key</code></td>
<td class="type">
<span class="param-type"><a href="global.html#openpgp_byte_array">openpgp_byte_array</a></span>
</td>
<td class="description last">key to be used to encrypt the data. This will be passed to the
blockcipherfn</td>
</tr>
<tr>
<td class="name"><code>resync</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last">a boolean value specifying if a resync of the
IV should be used or not. The encrypteddatapacket uses the
"old" style with a resync. Encryption within an
encryptedintegrityprotecteddata packet is not resyncing the IV.</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.cfb.js.html">ciphers/openpgp.cfb.js</a>, line 50
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
a string with the encrypted data
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_cfb_mdc"><span class="type-signature"></span>openpgp_cfb_mdc<span class="signature">(blockcipherencryptfn, block_size, key, ciphertext)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Decrypts the prefixed data for the Modification Detection Code (MDC) computation
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>blockcipherencryptfn</code></td>
<td class="type">
<span class="param-type">openpgp_block_cipher_fn</span>
</td>
<td class="description last">Cipher function to use</td>
</tr>
<tr>
<td class="name"><code>block_size</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Blocksize of the algorithm</td>
</tr>
<tr>
<td class="name"><code>key</code></td>
<td class="type">
<span class="param-type"><a href="global.html#openpgp_byte_array">openpgp_byte_array</a></span>
</td>
<td class="description last">The key for encryption</td>
</tr>
<tr>
<td class="name"><code>ciphertext</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">The encrypted data</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.cfb.js.html">ciphers/openpgp.cfb.js</a>, line 146
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
plaintext Data of D(ciphertext) with blocksize length +2
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_asymetricDecrypt"><span class="type-signature"></span>openpgp_crypto_asymetricDecrypt<span class="signature">(algo, publicMPIs, secretMPIs, data)</span><span class="type-signature"> &rarr; {BigInteger}</span></h4>
</dt>
<dd>
<div class="description">
Decrypts data using the specified public key multiprecision integers of the private key,
the specified secretMPIs of the private key and the specified algorithm.
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>algo</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Algorithm to be used (See RFC4880 9.1)</td>
</tr>
<tr>
<td class="name"><code>publicMPIs</code></td>
<td class="type">
<span class="param-type">openpgp_type_mpi[]</span>
</td>
<td class="description last">Algorithm dependent multiprecision integers
of the public key part of the private key</td>
</tr>
<tr>
<td class="name"><code>secretMPIs</code></td>
<td class="type">
<span class="param-type">openpgp_type_mpi[]</span>
</td>
<td class="description last">Algorithm dependent multiprecision integers
of the private key used</td>
</tr>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type"><a href="openpgp_type_mpi.html">openpgp_type_mpi</a></span>
</td>
<td class="description last">Data to be encrypted as MPI</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 63
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
returns a big integer containing the decrypted data; otherwise null
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">BigInteger</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_asymetricEncrypt"><span class="type-signature"></span>openpgp_crypto_asymetricEncrypt<span class="signature">(algo, publicMPIs, data)</span><span class="type-signature"> &rarr; {<a href="openpgp_type_mpi.html">openpgp_type_mpi</a>|Array.&lt;<a href="openpgp_type_mpi.html">openpgp_type_mpi</a>>}</span></h4>
</dt>
<dd>
<div class="description">
Encrypts data using the specified public key multiprecision integers
and the specified algorithm.
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>algo</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Algorithm to be used (See RFC4880 9.1)</td>
</tr>
<tr>
<td class="name"><code>publicMPIs</code></td>
<td class="type">
<span class="param-type">openpgp_type_mpi[]</span>
</td>
<td class="description last">Algorithm dependent multiprecision integers</td>
</tr>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type"><a href="openpgp_type_mpi.html">openpgp_type_mpi</a></span>
</td>
<td class="description last">Data to be encrypted as MPI</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 29
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
if RSA an openpgp_type_mpi;
if elgamal encryption an array of two openpgp_type_mpi is returned; otherwise null
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="openpgp_type_mpi.html">openpgp_type_mpi</a></span>
|
<span class="param-type">Array.&lt;<a href="openpgp_type_mpi.html">openpgp_type_mpi</a>></span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_generateKeyPair"><span class="type-signature"></span>openpgp_crypto_generateKeyPair<span class="signature">(keyType, numBits)</span><span class="type-signature"> &rarr; {<a href="global.html#openpgp_keypair">openpgp_keypair</a>}</span></h4>
</dt>
<dd>
<div class="description">
Calls the necessary crypto functions to generate a keypair.
Called directly by openpgp.js
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>keyType</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Follows OpenPGP algorithm convention.</td>
</tr>
<tr>
<td class="name"><code>numBits</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Number of bits to make the key to be generated</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 413
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="global.html#openpgp_keypair">openpgp_keypair</a></span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_generateSessionKey"><span class="type-signature"></span>openpgp_crypto_generateSessionKey<span class="signature">(algo)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Generating a session key for the specified symmetric algorithm
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>algo</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Algorithm to use (see RFC4880 9.2)</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 146
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Random bytes as a string to be used as a key
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_getHashByteLength"><span class="type-signature"></span>openpgp_crypto_getHashByteLength<span class="signature">(algo)</span><span class="type-signature"> &rarr; {Integer}</span></h4>
</dt>
<dd>
<div class="description">
Returns the hash size in bytes of the specified hash algorithm type
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>algo</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Hash algorithm type (See RFC4880 9.4)</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 293
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Size in bytes of the resulting hash
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">Integer</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_getPrefixRandom"><span class="type-signature"></span>openpgp_crypto_getPrefixRandom<span class="signature">(algo)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
generate random byte prefix as string for the specified algorithm
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>algo</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Algorithm to use (see RFC4880 9.2)</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 94
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Random bytes with length equal to the block
size of the cipher
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_getPseudoRandom"><span class="type-signature"></span>openpgp_crypto_getPseudoRandom<span class="signature">(from, to)</span><span class="type-signature"> &rarr; {Integer}</span></h4>
</dt>
<dd>
<div class="description">
Return a pseudo-random number in the specified range
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>from</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Min of the random number</td>
</tr>
<tr>
<td class="name"><code>to</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Max of the random number (max 32bit)</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 332
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
A pseudo random number
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">Integer</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_getRandomBigInteger"><span class="type-signature"></span>openpgp_crypto_getRandomBigInteger<span class="signature">(bits)</span><span class="type-signature"> &rarr; {BigInteger}</span></h4>
</dt>
<dd>
<div class="description">
Create a secure random big integer of bits length
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>bits</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Bit length of the MPI to create</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 362
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Resulting big integer
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">BigInteger</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_getRandomBytes"><span class="type-signature"></span>openpgp_crypto_getRandomBytes<span class="signature">(length)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Retrieve secure random byte string of the specified length
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>length</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Length in bytes to generate</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 318
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Random byte string
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_getSecureRandom"><span class="type-signature"></span>openpgp_crypto_getSecureRandom<span class="signature">(from, to)</span><span class="type-signature"> &rarr; {Integer}</span></h4>
</dt>
<dd>
<div class="description">
Return a secure random number in the specified range
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>from</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Min of the random number</td>
</tr>
<tr>
<td class="name"><code>to</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Max of the random number (max 32bit)</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 342
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
A secure random number
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">Integer</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_hashData"><span class="type-signature"></span>openpgp_crypto_hashData<span class="signature">(algo, data)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Create a hash on the specified data using the specified algorithm
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>algo</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Hash algorithm type (see RFC4880 9.4)</td>
</tr>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Data to be hashed</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 259
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
hash value
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_MDCSystemBytes"><span class="type-signature"></span>openpgp_crypto_MDCSystemBytes<span class="signature">(algo, key, data)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
retrieve the MDC prefixed bytes by decrypting them
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>algo</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Algorithm to use (see RFC4880 9.2)</td>
</tr>
<tr>
<td class="name"><code>key</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Key as string. length is depending on the algorithm used</td>
</tr>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Encrypted data where the prefix is decrypted from</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 117
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Plain text data of the prefixed data
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_signData"><span class="type-signature"></span>openpgp_crypto_signData<span class="signature">(hash_algo, algo, publicMPIs, secretMPIs, data)</span><span class="type-signature"> &rarr; {String|<a href="openpgp_type_mpi.html">openpgp_type_mpi</a>}</span></h4>
</dt>
<dd>
<div class="description">
Create a signature on data using the specified algorithm
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>hash_algo</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">hash Algorithm to use (See RFC4880 9.4)</td>
</tr>
<tr>
<td class="name"><code>algo</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Asymmetric cipher algorithm to use (See RFC4880 9.1)</td>
</tr>
<tr>
<td class="name"><code>publicMPIs</code></td>
<td class="type">
<span class="param-type">openpgp_type_mpi[]</span>
</td>
<td class="description last">Public key multiprecision integers
of the private key</td>
</tr>
<tr>
<td class="name"><code>secretMPIs</code></td>
<td class="type">
<span class="param-type">openpgp_type_mpi[]</span>
</td>
<td class="description last">Private key multiprecision
integers which is used to sign the data</td>
</tr>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Data to be signed</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 221
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
|
<span class="param-type"><a href="openpgp_type_mpi.html">openpgp_type_mpi</a></span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_symmetricDecrypt"><span class="type-signature"></span>openpgp_crypto_symmetricDecrypt<span class="signature">(algo, key, data, openpgp_cfb)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Symmetrically decrypts data using a key with length depending on the
algorithm in openpgp_cfb mode with or without resync (MDC style)
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>algo</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Algorithm to use (see RFC4880 9.2)</td>
</tr>
<tr>
<td class="name"><code>key</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Key as string. length is depending on the algorithm used</td>
</tr>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Data to be decrypted</td>
</tr>
<tr>
<td class="name"><code>openpgp_cfb</code></td>
<td class="type">
<span class="param-type">Boolean</span>
</td>
<td class="description last">If true use the resync (for encrypteddata);
otherwise use without the resync (for MDC encrypted data)</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.sym.js.html">ciphers/openpgp.crypto.sym.js</a>, line 67
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Plaintext data
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_symmetricEncrypt"><span class="type-signature"></span>openpgp_crypto_symmetricEncrypt<span class="signature">(prefixrandom, algo, key, data, openpgp_cfb)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Symmetrically encrypts data using prefixedrandom, a key with length
depending on the algorithm in openpgp_cfb mode with or without resync
(MDC style)
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>prefixrandom</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Secure random bytes as string in
length equal to the block size of the algorithm used (use
openpgp_crypto_getPrefixRandom(algo) to retrieve that string</td>
</tr>
<tr>
<td class="name"><code>algo</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Algorithm to use (see RFC4880 9.2)</td>
</tr>
<tr>
<td class="name"><code>key</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Key as string. length is depending on the algorithm used</td>
</tr>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Data to encrypt</td>
</tr>
<tr>
<td class="name"><code>openpgp_cfb</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="openpgp.crypto.sym.js.html">ciphers/openpgp.crypto.sym.js</a>, line 33
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Encrypted data
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_crypto_verifySignature"><span class="type-signature"></span>openpgp_crypto_verifySignature<span class="signature">(algo, hash_algo, msg_MPIs, publickey_MPIs, data)</span><span class="type-signature"> &rarr; {Boolean}</span></h4>
</dt>
<dd>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>algo</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">public Key algorithm</td>
</tr>
<tr>
<td class="name"><code>hash_algo</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Hash algorithm</td>
</tr>
<tr>
<td class="name"><code>msg_MPIs</code></td>
<td class="type">
<span class="param-type">openpgp_type_mpi[]</span>
</td>
<td class="description last">Signature multiprecision integers</td>
</tr>
<tr>
<td class="name"><code>publickey_MPIs</code></td>
<td class="type">
<span class="param-type">openpgp_type_mpi[]</span>
</td>
<td class="description last">Public key multiprecision integers</td>
</tr>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Data on where the signature was computed on.</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 172
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
true if signature (sig_data was equal to data over hash)
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">Boolean</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_encoding_armor"><span class="type-signature"></span>openpgp_encoding_armor<span class="signature">(messagetype, data, partindex, parttotal)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Armor an OpenPGP binary packet block
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>messagetype</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">type of the message</td>
</tr>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>partindex</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>parttotal</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="openpgp.encoding.asciiarmor.js.html">encoding/openpgp.encoding.asciiarmor.js</a>, line 129
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Armored text
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_encoding_armor_addheader"><span class="type-signature"></span>openpgp_encoding_armor_addheader<span class="signature">()</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Add additional information to the armor version of an OpenPGP binary
packet block.
</div>
<dl class="details">
<dt class="tag-version">Version:</dt>
<dd class="tag-version"><ul class="dummy"><li>2011-12-16</li></ul></dd>
<dt class="tag-author">Author:</dt>
<dd class="tag-author">
<ul>
<li>Alex</li>
</ul>
</dd>
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.encoding.asciiarmor.js.html">encoding/openpgp.encoding.asciiarmor.js</a>, line 109
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
The header information
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_encoding_base64_decode"><span class="type-signature"></span>openpgp_encoding_base64_decode<span class="signature">(message)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Wrapper function for the base64 codec.
This function decodes a String(message) in base64 (radix-64)
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>message</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Base64 encoded data</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.encoding.js.html">encoding/openpgp.encoding.js</a>, line 35
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Raw data after decoding
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_encoding_base64_encode"><span class="type-signature"></span>openpgp_encoding_base64_encode<span class="signature">(message)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Wrapper function for the base64 codec.
This function encodes a String (message) in base64 (radix-64)
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>message</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">The message to encode</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.encoding.js.html">encoding/openpgp.encoding.js</a>, line 24
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
The base64 encoded data
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_encoding_deArmor"><span class="type-signature"></span>openpgp_encoding_deArmor<span class="signature">(text)</span><span class="type-signature"> &rarr; {String|Object}</span></h4>
</dt>
<dd>
<div class="description">
DeArmor an OpenPGP armored message; verify the checksum and return
the encoded bytes
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>text</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">OpenPGP armored message</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.encoding.asciiarmor.js.html">encoding/openpgp.encoding.asciiarmor.js</a>, line 26
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Either the bytes of the decoded message
or an object with attribute "text" containing the message text
and an attribute "openpgp" containing the bytes.
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
|
<span class="param-type">Object</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_encoding_eme_pkcs1_decode"><span class="type-signature"></span>openpgp_encoding_eme_pkcs1_decode<span class="signature">(message)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
decodes a EME-PKCS1-v1_5 padding (See RFC4880 13.1.2)
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>message</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">EME-PKCS1 padded message</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.encoding.js.html">encoding/openpgp.encoding.js</a>, line 77
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
decoded message
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_encoding_eme_pkcs1_encode"><span class="type-signature"></span>openpgp_encoding_eme_pkcs1_encode<span class="signature">(message, length)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
create a EME-PKCS1-v1_5 padding (See RFC4880 13.1.1)
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>message</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">message to be padded</td>
</tr>
<tr>
<td class="name"><code>length</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Length to the resulting message</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.encoding.js.html">encoding/openpgp.encoding.js</a>, line 58
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
EME-PKCS1 padded message
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_encoding_emsa_pkcs1_decode"><span class="type-signature"></span>openpgp_encoding_emsa_pkcs1_decode<span class="signature">(data)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
extract the hash out of an EMSA-PKCS1-v1.5 padding (See RFC4880 13.1.3)
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Hash in pkcs1 encoding</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.encoding.js.html">encoding/openpgp.encoding.js</a>, line 126
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
The hash as string
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_encoding_emsa_pkcs1_encode"><span class="type-signature"></span>openpgp_encoding_emsa_pkcs1_encode<span class="signature">(algo, data, keylength)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
create a EMSA-PKCS1-v1_5 padding (See RFC4880 13.1.3)
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>algo</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Hash algorithm type used</td>
</tr>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Data to be hashed</td>
</tr>
<tr>
<td class="name"><code>keylength</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Key size of the public mpi in bytes</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.encoding.js.html">encoding/openpgp.encoding.js</a>, line 106
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Hashcode with pkcs1padding as string
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_encoding_html_encode"><span class="type-signature"></span>openpgp_encoding_html_encode<span class="signature">(message)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Wrapper function for jquery library.
This function escapes HTML characters within a string. This is used
to prevent XSS.
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>message</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Message to escape</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.encoding.js.html">encoding/openpgp.encoding.js</a>, line 46
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Html encoded string
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="print_debug"><span class="type-signature"></span>print_debug<span class="signature">(str)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Helper function to print a debug message. Debug
messages are only printed if
openpgp.config.debug is set to true. The calling
Javascript context MUST define
a "showMessages(text)" function. Line feeds ('\n')
are automatically converted to HTML line feeds '<br/>'
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>str</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">String of the debug message</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 186
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
An HTML tt entity containing a paragraph with a
style attribute where the debug message is HTMLencoded in.
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="print_debug_hexstr_dump"><span class="type-signature"></span>print_debug_hexstr_dump<span class="signature">(str)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Helper function to print a debug message. Debug
messages are only printed if
openpgp.config.debug is set to true. The calling
Javascript context MUST define
a "showMessages(text)" function. Line feeds ('\n')
are automatically converted to HTML line feeds '<br/>'
Different than print_debug because will call hexstrdump iff necessary.
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>str</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">String of the debug message</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 205
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
An HTML tt entity containing a paragraph with a
style attribute where the debug message is HTMLencoded in.
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="print_error"><span class="type-signature"></span>print_error<span class="signature">(str)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Helper function to print an error message.
The calling Javascript context MUST define
a "showMessages(text)" function. Line feeds ('\n')
are automatically converted to HTML line feeds '<br/>'
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>str</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">String of the error message</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 222
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
A HTML paragraph entity with a style attribute
containing the HTML encoded error message
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="print_info"><span class="type-signature"></span>print_info<span class="signature">(str)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Helper function to print an info message.
The calling Javascript context MUST define
a "showMessages(text)" function. Line feeds ('\n')
are automatically converted to HTML line feeds '<br/>'.
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>str</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">String of the info message</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 236
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
A HTML paragraph entity with a style attribute
containing the HTML encoded info message
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="shiftRight"><span class="type-signature"></span>shiftRight<span class="signature">(value, bitcount)</span><span class="type-signature"> &rarr; {String}</span></h4>
</dt>
<dd>
<div class="description">
Shifting a string to n bits right
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>value</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">The string to shift</td>
</tr>
<tr>
<td class="name"><code>bitcount</code></td>
<td class="type">
<span class="param-type">Integer</span>
</td>
<td class="description last">Amount of bits to shift (MUST be smaller
than 9)</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 262
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Resulting string.
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="str2bin"><span class="type-signature"></span>str2bin<span class="signature">(str)</span><span class="type-signature"> &rarr; {Integer[]}</span></h4>
</dt>
<dd>
<div class="description">
Convert a string to an array of integers(0.255)
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>str</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">String to convert</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 131
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
An array of (binary) integers
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">Integer[]</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="str2Uint8Array"><span class="type-signature"></span>str2Uint8Array<span class="signature">(str)</span><span class="type-signature"> &rarr; {Uint8Array}</span></h4>
</dt>
<dd>
<div class="description">
Convert a string to a Uint8Array
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>str</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">String to convert</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="util.js.html">util/util.js</a>, line 148
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
The array of (binary) integers
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">Uint8Array</span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="verifyCheckSum"><span class="type-signature"></span>verifyCheckSum<span class="signature">(data, checksum)</span><span class="type-signature"> &rarr; {Boolean}</span></h4>
</dt>
<dd>
<div class="description">
Calculates the checksum over the given data and compares it with the
given base64 encoded checksum
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>data</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Data to create a CRC-24 checksum for</td>
</tr>
<tr>
<td class="name"><code>checksum</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last">Base64 encoded checksum</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.encoding.asciiarmor.js.html">encoding/openpgp.encoding.asciiarmor.js</a>, line 201
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
True if the given checksum is correct; otherwise false
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type">Boolean</span>
</dd>
</dl>
</dd>
</dl>
<h3 class="subsection-title">Type Definitions</h3>
<dl>
<dt>
<h4 class="name" id="openpgp_byte_array">openpgp_byte_array</h4>
</dt>
<dd>
<div class="description">
An array of bytes, that is integers with values from 0 to 255
</div>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.cfb.js.html">ciphers/openpgp.cfb.js</a>, line 7
</li></ul></dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_cipher_block_fn"><span class="type-signature"></span>openpgp_cipher_block_fn<span class="signature">(block, key)</span><span class="type-signature"> &rarr; {<a href="global.html#openpgp_byte_array">openpgp_byte_array</a>}</span></h4>
</dt>
<dd>
<div class="description">
Block cipher function
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>block</code></td>
<td class="type">
<span class="param-type"><a href="global.html#openpgp_byte_array">openpgp_byte_array</a></span>
</td>
<td class="description last">A block to perform operations on</td>
</tr>
<tr>
<td class="name"><code>key</code></td>
<td class="type">
<span class="param-type"><a href="global.html#openpgp_byte_array">openpgp_byte_array</a></span>
</td>
<td class="description last">to use in encryption/decryption</td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.cfb.js.html">ciphers/openpgp.cfb.js</a>, line 9
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
Encrypted/decrypted block
</div>
<dl>
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="global.html#openpgp_byte_array">openpgp_byte_array</a></span>
</dd>
</dl>
</dd>
<dt>
<h4 class="name" id="openpgp_keypair">openpgp_keypair</h4>
</dt>
<dd>
<dl class="details">
<h5 class="subsection-title">Properties:</h5>
<dl>
<table class="props">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>privateKey</code></td>
<td class="type">
<span class="param-type"><a href="openpgp_packet_keymaterial.html">openpgp_packet_keymaterial</a></span>
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>publicKey</code></td>
<td class="type">
<span class="param-type"><a href="openpgp_packet_keymaterial.html">openpgp_packet_keymaterial</a></span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table></dl>
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="openpgp.crypto.js.html">ciphers/openpgp.crypto.js</a>, line 400
</li></ul></dd>
</dl>
</dd>
</dl>
</article>
</section>
</div>
<nav>
<h2><a href="index.html">Index</a></h2><h3>Classes</h3><ul><li><a href="_openpgp_packet.html">_openpgp_packet</a></li><li><a href="JXG.Util.html">Util</a></li><li><a href="openpgp.html">openpgp</a></li><li><a href="openpgp_config.html">openpgp_config</a></li><li><a href="openpgp_keyring.html">openpgp_keyring</a></li><li><a href="openpgp_msg_message.html">openpgp_msg_message</a></li><li><a href="openpgp_msg_privatekey.html">openpgp_msg_privatekey</a></li><li><a href="openpgp_msg_publickey.html">openpgp_msg_publickey</a></li><li><a href="openpgp_packet_compressed.html">openpgp_packet_compressed</a></li><li><a href="openpgp_packet_encrypteddata.html">openpgp_packet_encrypteddata</a></li><li><a href="openpgp_packet_encryptedintegrityprotecteddata.html">openpgp_packet_encryptedintegrityprotecteddata</a></li><li><a href="openpgp_packet_encryptedsessionkey.html">openpgp_packet_encryptedsessionkey</a></li><li><a href="openpgp_packet_keymaterial.html">openpgp_packet_keymaterial</a></li><li><a href="openpgp_packet_literaldata.html">openpgp_packet_literaldata</a></li><li><a href="openpgp_packet_marker.html">openpgp_packet_marker</a></li><li><a href="openpgp_packet_modificationdetectioncode.html">openpgp_packet_modificationdetectioncode</a></li><li><a href="openpgp_packet_onepasssignature.html">openpgp_packet_onepasssignature</a></li><li><a href="openpgp_packet_signature.html">openpgp_packet_signature</a></li><li><a href="openpgp_packet_userattribute.html">openpgp_packet_userattribute</a></li><li><a href="openpgp_packet_userid.html">openpgp_packet_userid</a></li><li><a href="openpgp_type_keyid.html">openpgp_type_keyid</a></li><li><a href="openpgp_type_mpi.html">openpgp_type_mpi</a></li><li><a href="openpgp_type_s2k.html">openpgp_type_s2k</a></li></ul><h3>Global</h3><ul><li><a href="global.html#bin2str">bin2str</a></li><li><a href="global.html#calc_checksum">calc_checksum</a></li><li><a href="global.html#crc_table">crc_table</a></li><li><a href="global.html#decode_utf8">decode_utf8</a></li><li><a href="global.html#encode_utf8">encode_utf8</a></li><li><a href="global.html#get_hashAlgorithmString">get_hashAlgorithmString</a></li><li><a href="global.html#getCheckSum">getCheckSum</a></li><li><a href="global.html#getPGPMessageType">getPGPMessageType</a></li><li><a href="global.html#hash_headers">hash_headers</a></li><li><a href="global.html#hex2bin">hex2bin</a></li><li><a href="global.html#hexidump">hexidump</a></li><li><a href="global.html#hexstrdump">hexstrdump</a></li><li><a href="global.html#MD5">MD5</a></li><li><a href="global.html#openpgp_cfb_decrypt">openpgp_cfb_decrypt</a></li><li><a href="global.html#openpgp_cfb_encrypt">openpgp_cfb_encrypt</a></li><li><a href="global.html#openpgp_cfb_mdc">openpgp_cfb_mdc</a></li><li><a href="global.html#openpgp_crypto_asymetricDecrypt">openpgp_crypto_asymetricDecrypt</a></li><li><a href="global.html#openpgp_crypto_asymetricEncrypt">openpgp_crypto_asymetricEncrypt</a></li><li><a href="global.html#openpgp_crypto_generateKeyPair">openpgp_crypto_generateKeyPair</a></li><li><a href="global.html#openpgp_crypto_generateSessionKey">openpgp_crypto_generateSessionKey</a></li><li><a href="global.html#openpgp_crypto_getHashByteLength">openpgp_crypto_getHashByteLength</a></li><li><a href="global.html#openpgp_crypto_getPrefixRandom">openpgp_crypto_getPrefixRandom</a></li><li><a href="global.html#openpgp_crypto_getPseudoRandom">openpgp_crypto_getPseudoRandom</a></li><li><a href="global.html#openpgp_crypto_getRandomBigInteger">openpgp_crypto_getRandomBigInteger</a></li><li><a href="global.html#openpgp_crypto_getRandomBytes">openpgp_crypto_getRandomBytes</a></li><li><a href="global.html#openpgp_crypto_getSecureRandom">openpgp_crypto_getSecureRandom</a></li><li><a href="global.html#openpgp_crypto_hashData">openpgp_crypto_hashData</a></li><li><a href="global.html#openpgp_crypto_MDCSystemBytes">openpgp_crypto_MDCSystemBytes</a></li><li><a href="global.html#openpgp_crypto_signData">openpgp_crypto_signData</a></li><li><a href="global.html#openpgp_crypto_symmetricDecrypt">openpgp_crypto_symmetricDecrypt</a></li><li><a href="global.html#openpgp_crypto_symmetricEncrypt">openpgp_crypto_symmetricEncrypt</a></li><li><a href="global.html#openpgp_crypto_verifySignature">openpgp_crypto_verifySignature</a></li><li><a href="global.html#openpgp_encoding_armor">openpgp_encoding_armor</a></li><li><a href="global.html#openpgp_encoding_armor_addheader">openpgp_encoding_armor_addheader</a></li><li><a href="global.html#openpgp_encoding_base64_decode">openpgp_encoding_base64_decode</a></li><li><a href="global.html#openpgp_encoding_base64_encode">openpgp_encoding_base64_encode</a></li><li><a href="global.html#openpgp_encoding_deArmor">openpgp_encoding_deArmor</a></li><li><a href="global.html#openpgp_encoding_eme_pkcs1_decode">openpgp_encoding_eme_pkcs1_decode</a></li><li><a href="global.html#openpgp_encoding_eme_pkcs1_encode">openpgp_encoding_eme_pkcs1_encode</a></li><li><a href="global.html#openpgp_encoding_emsa_pkcs1_decode">openpgp_encoding_emsa_pkcs1_decode</a></li><li><a href="global.html#openpgp_encoding_emsa_pkcs1_encode">openpgp_encoding_emsa_pkcs1_encode</a></li><li><a href="global.html#openpgp_encoding_html_encode">openpgp_encoding_html_encode</a></li><li><a href="global.html#print_debug">print_debug</a></li><li><a href="global.html#print_debug_hexstr_dump">print_debug_hexstr_dump</a></li><li><a href="global.html#print_error">print_error</a></li><li><a href="global.html#print_info">print_info</a></li><li><a href="global.html#shiftRight">shiftRight</a></li><li><a href="global.html#str2bin">str2bin</a></li><li><a href="global.html#str2Uint8Array">str2Uint8Array</a></li><li><a href="global.html#Uint8Array2str">Uint8Array2str</a></li><li><a href="global.html#util">util</a></li><li><a href="global.html#verifyCheckSum">verifyCheckSum</a></li></ul>
</nav>
<br clear="both">
<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.2.0-dev</a> on Tue Apr 16 2013 10:42:40 GMT+0200 (CEST)
</footer>
<script> prettyPrint(); </script>
</body>
</html>