Class Digest

Description

class Digest

This class provides a simple interface to the mhash library. It can be used to create both salted and unsalted message digests. mhash was chosen because it supports a wide variety of hash algorithms. For a complete list of supported hashes, refer to the documentation of mhash.

Located in /digest.class.php (line 21)


	
			
Variable Summary
Method Summary
Digest __construct ()
string GetDigest (plaintext $plaintext)
boolean IsValidDigest (ciphertext $ciphertext, plaintext $plaintext)
Variables
mixed $Digest (line 23)
  • static:
  • access: private
mixed $digestAlgorithm (line 28)
  • access: private
mixed $digestAlgorithmBlockSize (line 29)
  • access: private
mixed $Hash (line 24)
  • access: private
mixed $randomDevice (line 30)
  • access: private
mixed $saltedS2kAlgorithm (line 27)
  • access: private
mixed $XmlConfigDao (line 25)
  • access: private
Methods
Constructor __construct (line 39)

function __construct

This method is executed when an object is instantiated from this class. Preprocessing can be done here before the object is put into service.

  • access: public
Digest __construct ()
GetDigest (line 78)

function GetDigest

This method generates a salted or unsalted message digest.

  • return: Base64 encoded ciphertext
  • access: public
string GetDigest (plaintext $plaintext)
  • plaintext $plaintext: Plaintext
GetInstance (line 62)

function GetInstance

This method instantiates a new object from this class; more specifically, it's a singleton instance.

  • return: object instance
  • static:
  • access: public
Digest GetInstance ()
IsValidDigest (line 97)

function IsValidDigest

This method validates a salted or unsalted message digest.

  • return: TRUE|FALSE
  • access: public
boolean IsValidDigest (ciphertext $ciphertext, plaintext $plaintext)
  • ciphertext $ciphertext: Ciphertext
  • plaintext $plaintext: Plaintext

Documentation generated on Thu, 9 Sep 2004 09:03:35 -0400 by phpDocumentor 1.3.0RC3