home *** CD-ROM | disk | FTP | other *** search
-
- <HTML>
- <HEAD>
- <TITLE>Digest::HMAC - Keyed-Hashing for Message Authentication</TITLE>
- <LINK REL="stylesheet" HREF="../../../Active.css" TYPE="text/css">
- <LINK REV="made" HREF="mailto:">
- </HEAD>
-
- <BODY>
- <TABLE BORDER=0 CELLPADDING=0 CELLSPACING=0 WIDTH=100%>
- <TR><TD CLASS=block VALIGN=MIDDLE WIDTH=100% BGCOLOR="#cccccc">
- <STRONG><P CLASS=block> Digest::HMAC - Keyed-Hashing for Message Authentication</P></STRONG>
- </TD></TR>
- </TABLE>
-
- <A NAME="__index__"></A>
- <!-- INDEX BEGIN -->
-
- <UL>
-
- <LI><A HREF="#name">NAME</A></LI><LI><A HREF="#supportedplatforms">SUPPORTED PLATFORMS</A></LI>
-
- <LI><A HREF="#synopsis">SYNOPSIS</A></LI>
- <LI><A HREF="#description">DESCRIPTION</A></LI>
- <LI><A HREF="#see also">SEE ALSO</A></LI>
- <LI><A HREF="#authors">AUTHORS</A></LI>
- </UL>
- <!-- INDEX END -->
-
- <HR>
- <P>
- <H1><A NAME="name">NAME</A></H1>
- <P>Digest::HMAC - Keyed-Hashing for Message Authentication</P>
- <P>
- <HR>
- <H1><A NAME="supportedplatforms">SUPPORTED PLATFORMS</A></H1>
- <UL>
- <LI>Linux</LI>
- <LI>Solaris</LI>
- <LI>Windows</LI>
- </UL>
- <HR>
- <H1><A NAME="synopsis">SYNOPSIS</A></H1>
- <PRE>
- # Functional style
- use Digest::HMAC qw(hmac hmac_hex);
- $digest = hmac($data, $key, \&myhash);
- print hmac_hex($data, $key, \&myhash);</PRE>
- <PRE>
- # OO style
- use Digest::HMAC;
- $hmac = Digest::HMAC->new($key, "Digest::MyHash");</PRE>
- <PRE>
- $hmac->add($data);
- $hmac->addfile(*FILE);</PRE>
- <PRE>
- $digest = $hmac->digest;
- $digest = $hmac->hexdigest;
- $digest = $hmac->b64digest;</PRE>
- <P>
- <HR>
- <H1><A NAME="description">DESCRIPTION</A></H1>
- <P>HMAC is used for message integrity checks between two parties that
- share a secret key, and works in combination with some other Digest
- algorithm, usually MD5 or SHA-1. The HMAC mechanism is described in
- RFC 2104.</P>
- <P>HMAC follow the common <CODE>Digest::</CODE> interface, but the constructor
- takes the secret key and the name of some other simple <CODE>Digest::</CODE>
- as argument.</P>
- <P>
- <HR>
- <H1><A NAME="see also">SEE ALSO</A></H1>
- <P><A HREF="../../../site/lib/Digest/HMAC_MD5.html">the Digest::HMAC_MD5 manpage</A>, <A HREF="../../../site/lib/Digest/HMAC_SHA1.html">the Digest::HMAC_SHA1 manpage</A></P>
- <P>RFC 2104</P>
- <P>
- <HR>
- <H1><A NAME="authors">AUTHORS</A></H1>
- <P>Graham Barr <<A HREF="mailto:gbarr@ti.com">gbarr@ti.com</A>>, Gisle Aas <<A HREF="mailto:gisle@aas.no">gisle@aas.no</A>></P>
- <TABLE BORDER=0 CELLPADDING=0 CELLSPACING=0 WIDTH=100%>
- <TR><TD CLASS=block VALIGN=MIDDLE WIDTH=100% BGCOLOR="#cccccc">
- <STRONG><P CLASS=block> Digest::HMAC - Keyed-Hashing for Message Authentication</P></STRONG>
- </TD></TR>
- </TABLE>
-
- </BODY>
-
- </HTML>
-