summaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2000-05-25 18:28:04 +0200
committerWerner Koch <wk@gnupg.org>2000-05-25 18:28:04 +0200
commitd1648b4d7a2e045bc8ee81f666627d6a792564d6 (patch)
treeda4ff62971292b007ac855b9bb9f096177ac0f6d /doc
parentSee ChangeLog: Fri Mar 24 11:25:45 CET 2000 Werner Koch (diff)
downloadgnupg2-d1648b4d7a2e045bc8ee81f666627d6a792564d6.tar.xz
gnupg2-d1648b4d7a2e045bc8ee81f666627d6a792564d6.zip
See ChangeLog: Thu May 25 18:39:11 CEST 2000 Werner Koch
Diffstat (limited to 'doc')
-rw-r--r--doc/gcryptref-digest.sgml17
1 files changed, 15 insertions, 2 deletions
diff --git a/doc/gcryptref-digest.sgml b/doc/gcryptref-digest.sgml
index f0d5efff4..a123c9b25 100644
--- a/doc/gcryptref-digest.sgml
+++ b/doc/gcryptref-digest.sgml
@@ -65,7 +65,10 @@
</indexterm>
<function>gcry_md_open</function> creates the context required for
the message digest functions. The hash algorithm may optionally be
- specified.
+ specified. It is possible to use these functions as MAC functons; therefore
+ the flag <literal/GCRY_MD_FLAG_HMAC/ must be given along with the
+ hash functions. Other MAC algorithms than HMAC are currently not
+ supported. The key for the MAC must be set using the gcry_md_setkey macro.
<function>gcry_md_close</function> releases all resources associated
with the context.
<function>gcry_md_enable</function> may be used to enable hash
@@ -149,6 +152,7 @@
<refnamediv>
<refname>gcry_md_ctl</refname>
<refname>gcry_md_final</refname>
+ <refname>gcry_md_setkey</refname>
<refpurpose>perform special operations on a digest context</refpurpose>
</refnamediv>
@@ -179,9 +183,18 @@
</para>
<para>
Currently defined values for <parameter>cmd</> are:
- <literal>GCRYCTL_FINALIZE</> and the conevnience macro
+ </para>
+ <para>
+ <literal>GCRYCTL_FINALIZE</> and the convenience macro
<function>gcry_md_final(a)</>
</para>
+ <para>
+ <literal>GCRYCTL_SET_KEY</> and the convenience macro
+ <function>gcry_md_setkey(a)</>. This is used to turn these
+ hash functions into MAC functions. The key may be any string
+ of the speicified length. The type of the MAC is determined
+ by special flags set with the open function.
+ </para>
</refentry>
<!--**********************************************