MjSip Stack
v1.6

org.zoolu.tools
Class MD5

java.lang.Object
  |
  +--org.zoolu.tools.MessageDigest
        |
        +--org.zoolu.tools.MD5

public class MD5
extends MessageDigest

MD5 hash algorithm.

Implements the RSA Data Security, Inc. MD5 Message-Digest Algorithm. This is almoust straight implementation of the reference implementation given in RFC1321 by RSA.


Constructor Summary
MD5()
          Constructor
MD5(byte[] buffer)
          Constructor
MD5(byte[] buffer, int offset, int len)
          Constructor
MD5(java.lang.String str)
          Constructor
 
Method Summary
static byte[] digest(byte[] buffer)
          Calculates the MD5.
static byte[] digest(byte[] buffer, int offset, int len)
          Calculates the MD5.
static byte[] digest(java.lang.String str)
          Calculates the MD5.
 byte[] doFinal()
          MessageDigest finalization.
 MessageDigest update(byte[] buffer, int offset, int len)
          MessageDigest block update operation.
 
Methods inherited from class org.zoolu.tools.MessageDigest
asHex, asHex, getDigest, update, update
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MD5

public MD5()
Constructor

MD5

public MD5(byte[] buffer)
Constructor

MD5

public MD5(byte[] buffer,
           int offset,
           int len)
Constructor

MD5

public MD5(java.lang.String str)
Constructor
Method Detail

update

public MessageDigest update(byte[] buffer,
                            int offset,
                            int len)
MessageDigest block update operation. Continues a message-digest operation, processing another message block, and updating the context.
Overrides:
update in class MessageDigest

doFinal

public byte[] doFinal()
MessageDigest finalization. Ends a message-digest operation, writing the the message digest and zeroizing the context.
Overrides:
doFinal in class MessageDigest

digest

public static byte[] digest(byte[] buffer,
                            int offset,
                            int len)
Calculates the MD5.

digest

public static byte[] digest(byte[] buffer)
Calculates the MD5.

digest

public static byte[] digest(java.lang.String str)
Calculates the MD5.

MjSip Stack
v1.6