*) Program...........: GtMD5.PRG * Author............: Daniel Gramunt * Project...........: Netting * Created...........: 05.02.2002 - 11:53:50 (Visual FoxPro 07.00.0000.9465) * Copyright.........: (c) Nokia, 2002 *) Description.......: Returns a 128-bit "fingerprint" of < tcString >. *) : *) : MD5 was developed by Professor Ronald L. Rivest of MIT. Here's *) : a description of MD5 taken from the executive summary of rfc1321: *) : [The MD5 alogirthm] takes as input a message of arbitrary length and *) : produces as output a 128-bit "fingerprint" or "message digest" of the *) : input. It is conjectured that it is computationally infeasible to *) : produce two messages having the same message digest, or to produce *) : any message having a given prespecified target message digest. *) : The MD5 algorithm is intended for digital signature applications, *) : where a large file must be "compressed" in a secure manner before *) : being encrypted with a private (secret) key under a public-key *) : cryptosystem such as RSA. *) : In essence, MD5 is a way to verify data integrity, and is much more *) : reliabe than checksum and many other commonly used methods. *) : *) : Dependencies: This program uses Albert Ballinger's great *) : utility FoxCrypto.fll *) : http://fox.wikis.com/wc.dll?Wiki~FoxCrypto~VFP * Calling Samples...: lcFingerPrint = GtMd5(FILETOSTR("c:\temp\import.txt")) * : IF SEEK(lcFingerPrint) * : *-- file already processed * : ELSE * : *-- new file * : ENDIF * Parameter List....: tcString - character expression for which we return * : the MD5 fingerprint. * Major change list.: *-------------------------------------------------------------------------------------------------- LPARAMETERS tcString IF NOT "FOXCRYPTO.DLL" $ UPPER(SET("LIBRARY")) SET LIBRARY TO FoxCrypto.fll ADDITIVE ENDIF RETURN MD5(tcString) *-- EOF GtMD5.PRG --------------------------------------------------------------------------------->Hi All