145 lines
5.3 KiB
HTML
Executable File
145 lines
5.3 KiB
HTML
Executable File
<?xml version="1.0" ?>
|
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<title>MD5</title>
|
|
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
|
<link rev="made" href="mailto:root@localhost" />
|
|
</head>
|
|
|
|
<body style="background-color: white">
|
|
|
|
|
|
<!-- INDEX BEGIN -->
|
|
<div name="index">
|
|
<p><a name="__index__"></a></p>
|
|
|
|
<ul>
|
|
|
|
<li><a href="#name">NAME</a></li>
|
|
<li><a href="#synopsis">SYNOPSIS</a></li>
|
|
<li><a href="#description">DESCRIPTION</a></li>
|
|
<li><a href="#note">NOTE</a></li>
|
|
<li><a href="#return_values">RETURN VALUES</a></li>
|
|
<li><a href="#conforming_to">CONFORMING TO</a></li>
|
|
<li><a href="#see_also">SEE ALSO</a></li>
|
|
<li><a href="#history">HISTORY</a></li>
|
|
<li><a href="#copyright">COPYRIGHT</a></li>
|
|
</ul>
|
|
|
|
<hr name="index" />
|
|
</div>
|
|
<!-- INDEX END -->
|
|
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="name">NAME</a></h1>
|
|
<p>MD2, MD4, MD5, MD2_Init, MD2_Update, MD2_Final, MD4_Init, MD4_Update,
|
|
MD4_Final, MD5_Init, MD5_Update, MD5_Final - MD2, MD4, and MD5 hash functions</p>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="synopsis">SYNOPSIS</a></h1>
|
|
<pre>
|
|
#include <openssl/md2.h></pre>
|
|
<p>Deprecated since OpenSSL 3.0, can be hidden entirely by defining
|
|
<strong>OPENSSL_API_COMPAT</strong> with a suitable version value, see
|
|
<em>openssl_user_macros(7)</em>:</p>
|
|
<pre>
|
|
unsigned char *MD2(const unsigned char *d, unsigned long n, unsigned char *md);</pre>
|
|
<pre>
|
|
int MD2_Init(MD2_CTX *c);
|
|
int MD2_Update(MD2_CTX *c, const unsigned char *data, unsigned long len);
|
|
int MD2_Final(unsigned char *md, MD2_CTX *c);</pre>
|
|
<pre>
|
|
#include <openssl/md4.h></pre>
|
|
<p>Deprecated since OpenSSL 3.0, can be hidden entirely by defining
|
|
<strong>OPENSSL_API_COMPAT</strong> with a suitable version value, see
|
|
<em>openssl_user_macros(7)</em>:</p>
|
|
<pre>
|
|
unsigned char *MD4(const unsigned char *d, unsigned long n, unsigned char *md);</pre>
|
|
<pre>
|
|
int MD4_Init(MD4_CTX *c);
|
|
int MD4_Update(MD4_CTX *c, const void *data, unsigned long len);
|
|
int MD4_Final(unsigned char *md, MD4_CTX *c);</pre>
|
|
<pre>
|
|
#include <openssl/md5.h></pre>
|
|
<p>Deprecated since OpenSSL 3.0, can be hidden entirely by defining
|
|
<strong>OPENSSL_API_COMPAT</strong> with a suitable version value, see
|
|
<em>openssl_user_macros(7)</em>:</p>
|
|
<pre>
|
|
unsigned char *MD5(const unsigned char *d, unsigned long n, unsigned char *md);</pre>
|
|
<pre>
|
|
int MD5_Init(MD5_CTX *c);
|
|
int MD5_Update(MD5_CTX *c, const void *data, unsigned long len);
|
|
int MD5_Final(unsigned char *md, MD5_CTX *c);</pre>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="description">DESCRIPTION</a></h1>
|
|
<p>All of the functions described on this page are deprecated.
|
|
Applications should instead use <em>EVP_DigestInit_ex(3)</em>, <em>EVP_DigestUpdate(3)</em>
|
|
and <em>EVP_DigestFinal_ex(3)</em>.</p>
|
|
<p>MD2, MD4, and MD5 are cryptographic hash functions with a 128 bit output.</p>
|
|
<p>MD2(), MD4(), and MD5() compute the MD2, MD4, and MD5 message digest
|
|
of the <strong>n</strong> bytes at <strong>d</strong> and place it in <strong>md</strong> (which must have space
|
|
for MD2_DIGEST_LENGTH == MD4_DIGEST_LENGTH == MD5_DIGEST_LENGTH == 16
|
|
bytes of output). If <strong>md</strong> is NULL, the digest is placed in a static
|
|
array.</p>
|
|
<p>The following functions may be used if the message is not completely
|
|
stored in memory:</p>
|
|
<p>MD2_Init() initializes a <strong>MD2_CTX</strong> structure.</p>
|
|
<p>MD2_Update() can be called repeatedly with chunks of the message to
|
|
be hashed (<strong>len</strong> bytes at <strong>data</strong>).</p>
|
|
<p>MD2_Final() places the message digest in <strong>md</strong>, which must have space
|
|
for MD2_DIGEST_LENGTH == 16 bytes of output, and erases the <strong>MD2_CTX</strong>.</p>
|
|
<p>MD4_Init(), MD4_Update(), MD4_Final(), MD5_Init(), MD5_Update(), and
|
|
MD5_Final() are analogous using an <strong>MD4_CTX</strong> and <strong>MD5_CTX</strong> structure.</p>
|
|
<p>Applications should use the higher level functions
|
|
<em>EVP_DigestInit(3)</em>
|
|
etc. instead of calling the hash functions directly.</p>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="note">NOTE</a></h1>
|
|
<p>MD2, MD4, and MD5 are recommended only for compatibility with existing
|
|
applications. In new applications, SHA-1 or RIPEMD-160 should be
|
|
preferred.</p>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="return_values">RETURN VALUES</a></h1>
|
|
<p>MD2(), MD4(), and MD5() return pointers to the hash value.</p>
|
|
<p>MD2_Init(), MD2_Update(), MD2_Final(), MD4_Init(), MD4_Update(),
|
|
MD4_Final(), MD5_Init(), MD5_Update(), and MD5_Final() return 1 for
|
|
success, 0 otherwise.</p>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="conforming_to">CONFORMING TO</a></h1>
|
|
<p>RFC 1319, <a href="http://www.ietf.org/rfc/rfc1320.txt" class="rfc">RFC 1320</a>, <a href="http://www.ietf.org/rfc/rfc1321.txt" class="rfc">RFC 1321</a></p>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="see_also">SEE ALSO</a></h1>
|
|
<p><em>EVP_DigestInit(3)</em></p>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="history">HISTORY</a></h1>
|
|
<p>All of these functions were deprecated in OpenSSL 3.0.</p>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="copyright">COPYRIGHT</a></h1>
|
|
<p>Copyright 2000-2016 The OpenSSL Project Authors. All Rights Reserved.</p>
|
|
<p>Licensed under the Apache License 2.0 (the "License"). You may not use
|
|
this file except in compliance with the License. You can obtain a copy
|
|
in the file LICENSE in the source distribution or at
|
|
<a href="https://www.openssl.org/source/license.html">https://www.openssl.org/source/license.html</a>.</p>
|
|
|
|
</body>
|
|
|
|
</html>
|