summaryrefslogtreecommitdiff
path: root/usr/src/man/man3lib/libmd.3lib
blob: b6dbc5ba19a014d8f502fb709b921d4fa8f89af5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
.\"
.\" Copyright (c) 2008, Sun Microsystems, Inc.  All Rights Reserved.
.\" Copyright 2022 Oxide Computer Company
.\"
.\" The contents of this file are subject to the terms of the
.\" Common Development and Distribution License (the "License").
.\" You may not use this file except in compliance with the License.
.\"
.\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
.\" or http://www.opensolaris.org/os/licensing.
.\" See the License for the specific language governing permissions
.\" and limitations under the License.
.\"
.\" When distributing Covered Code, include this CDDL HEADER in each
.\" file and include the License file at usr/src/OPENSOLARIS.LICENSE.
.\" If applicable, add the following below this CDDL HEADER, with the
.\" fields enclosed by brackets "[]" replaced with your own identifying
.\" information: Portions Copyright [yyyy] [name of copyright owner]
.\"
.Dd January 16, 2022
.Dt LIBMD 3LIB
.Os
.Sh NAME
.Nm libmd
.Nd Message Digest library
.Sh LIBRARY
.Lb libmd
.Sh SYNOPSIS
.In md4.h
.In md5.h
.In sha1.h
.In sha2.h
.Sh DESCRIPTION
This library provides hashing routines for the following suites of hash
functions:
.Bl -bullet -offset indent -compact
.It
MD4
.Pq RFC1320
.It
MD5
.Pq RFC1321
.It
SHA1
.Pq RFC3174
.It
SHA256
.Pq FIPS 180-2
.It
SHA384
.Pq FIPS 180-2
.It
SHA512
.Pq FIPS 180-2
.El
.Sh INTERFACES
The shared object
.Sy libmd.so.1
provides the public interfaces defined below.
See
.Xr Intro 3
for additional information on shared object interfaces.
.Bl -column -offset indent ".Sy SHA2Update" ".Sy SHA2Update"
.It Sy MD4Final Ta Sy MD4Init
.It Sy MD4Update Ta Sy md5_calc
.It Sy MD5Final Ta Sy MD5Init
.It Sy MD5Update Ta Sy SHA1Final
.It Sy SHA1Init Ta Sy SHA1Update
.It Sy SHA2Final Ta Sy SHA2Init
.It Sy SHA2Update Ta ""
.El
.Sh SECURITY
The MD4 and MD5 algorithms are currently considered weak for cryptographic use.
The algorithms should be used only for compatibility with legacy systems or
protocols.
.Pp
The SHA1 algorithm is also believed to have some weaknesses.
Migration to one of the SHA2 algorithms \(em including SHA256, SHA386 or SHA512
\(em is highly recommended when data formats and on wire protocols support the
use of SHA2.
.Sh FILES
.Bl -tag -width Ds
.It Pa /lib/libmd.so.1
32-bit shared object
.It Pa /lib/64/libmd.so.1
64-bit shared object
.El
.Sh INTERFACE STABILITY
.Sy Committed
.Sh MT-LEVEL
.Sy MT-Safe