jsdsi.util
Class DigestEnum

java.lang.Object
  extended byjsdsi.util.AlgorithmEnum
      extended byjsdsi.util.DigestEnum

public class DigestEnum
extends AlgorithmEnum

Experimental class and as such may be removed without warning.

Enum class for MessageDigest algorythms.

Version:
$Revision: 1.4 $ $Date: 2004/06/09 16:34:41 $
Author:
Sean Radford

Field Summary
static DigestEnum MD2
          The MD2 message digest algorithm as defined in RFC 1319.
static DigestEnum MD5
          The MD5 message digest algorithm as defined in RFC 1321.
static DigestEnum SHA1
          The Secure Hash Algorithm, as defined in Secure Hash Standard, NIST FIPS 180-1.
static DigestEnum SHA256
          256-bit hash function intended to provide 128 bits of security against collision attacks.
static DigestEnum SHA384
          384 byte SHA
static DigestEnum SHA512
          512-bit hash function intended to provide 256 bits of security.
 
Constructor Summary
protected DigestEnum(java.lang.String jdkName, java.lang.String spkiName)
           
protected DigestEnum(java.lang.String jdkName, java.lang.String spkiName, java.lang.String jdkSigName)
           
 
Method Summary
static DigestEnum fromJdk(java.lang.String jdkName)
          Given a JDK name for a MessageDigest algorythm, return its DigestEnum
static DigestEnum fromJdkSignature(java.lang.String jdkName)
          Given a name for a MessageDigest algorythm from a JDK Signature, return its DigestEnum
static DigestEnum fromSpki(java.lang.String spkiName)
          Given a SPKI name for a MessageDigest algorythm, return its DigestEnum
 java.lang.String jdkSignatureName()
          Returns the name of this digest when part of a JDK Signature algorythm
 
Methods inherited from class jsdsi.util.AlgorithmEnum
jdkName, spkiName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MD2

public static final DigestEnum MD2
The MD2 message digest algorithm as defined in RFC 1319.


MD5

public static final DigestEnum MD5
The MD5 message digest algorithm as defined in RFC 1321.


SHA1

public static final DigestEnum SHA1
The Secure Hash Algorithm, as defined in Secure Hash Standard, NIST FIPS 180-1.


SHA256

public static final DigestEnum SHA256
256-bit hash function intended to provide 128 bits of security against collision attacks.


SHA384

public static final DigestEnum SHA384
384 byte SHA


SHA512

public static final DigestEnum SHA512
512-bit hash function intended to provide 256 bits of security.

Constructor Detail

DigestEnum

protected DigestEnum(java.lang.String jdkName,
                     java.lang.String spkiName)
Parameters:
jdkName -
spkiName -

DigestEnum

protected DigestEnum(java.lang.String jdkName,
                     java.lang.String spkiName,
                     java.lang.String jdkSigName)
Parameters:
jdkName -
spkiName -
Method Detail

fromJdk

public static DigestEnum fromJdk(java.lang.String jdkName)
Given a JDK name for a MessageDigest algorythm, return its DigestEnum

Parameters:
jdkName - JDK name
Returns:
the DigestEnum

fromJdkSignature

public static DigestEnum fromJdkSignature(java.lang.String jdkName)
Given a name for a MessageDigest algorythm from a JDK Signature, return its DigestEnum

Parameters:
jdkName - JDK name
Returns:
the DigestEnum

fromSpki

public static DigestEnum fromSpki(java.lang.String spkiName)
Given a SPKI name for a MessageDigest algorythm, return its DigestEnum

Parameters:
spkiName - SPKI name
Returns:
the DigestEnum

jdkSignatureName

public java.lang.String jdkSignatureName()
Returns the name of this digest when part of a JDK Signature algorythm

Returns:
the name


Copyright © 2002-2004 M.I.T. All Rights Reserved.