MD5Stream.st
changeset 14787 497cefec769f
parent 14723 8657c48a4c03
child 15624 11ce1e9cf098
child 18027 3621469cc5e8
equal deleted inserted replaced
14786:6371a5ee38ea 14787:497cefec769f
    53 "
    53 "
    54     Generate a MD5 hash value as defined in RFC 1321.
    54     Generate a MD5 hash value as defined in RFC 1321.
    55     This may be used as checksum or for generating cryptographic signatures.
    55     This may be used as checksum or for generating cryptographic signatures.
    56 
    56 
    57     Note:
    57     Note:
    58 	in August 2004, some researchers have found a way to generate full collisions for MD5.
    58         in August 2004, some researchers have found a way to generate full collisions for MD5.
    59 	Therefore, for new applications, it may be wise to choose another hash function for security stuff.
    59         Therefore, for new applications, it may be wise to choose another hash function for security stuff.
    60 	See a hash-collision example in the examples method.
    60         See a hash-collision example in the examples method.
    61 
    61 
    62 	So, the MD5 algorithm has severe weaknesses, for example it is easy to compute two messages yielding
    62         So, the MD5 algorithm has severe weaknesses, for example it is easy to compute two messages yielding
    63 	the same hash (collision attack).
    63         the same hash (collision attack).
    64 	The use of this algorithm is only justified for non-cryptographic application.
    64         The use of this algorithm is only justified for non-cryptographic application.
    65 
    65 
    66 
    66 
    67     performance: roughly
    67     performance: roughly
    68 			80000 Kb/s on a 2Ghz Duo
    68                        104000 Kb/s on a 2.5Ghz 64X2 Athlon 4800+ (64bit)
    69 			27200 Kb/s on a 1.2Ghz Athlon
    69                         80000 Kb/s on a 2Ghz Duo
    70 			12600 Kb/s on a 400Mhz PIII
    70                         27200 Kb/s on a 1.2Ghz Athlon
    71 			 9150 Kb/s on a 300Mhz Sparc.
    71                         12600 Kb/s on a 400Mhz PIII
    72 	performance is almost completely limited by the speed of the md5-routine, which is the reference
    72                          9150 Kb/s on a 300Mhz Sparc.
    73 	implementation in C from md5lib.
    73         performance is almost completely limited by the speed of the md5-routine, which is the reference
       
    74         implementation in C from md5lib.
    74 
    75 
    75     [author:]
    76     [author:]
    76 	Stefan Vogel
    77         Stefan Vogel
    77 
    78 
    78     [see also:]
    79     [see also:]
    79 	SHA1Stream
    80         SHA1Stream
    80 	SHA256Stream SHA512Stream (in libcrypt)
    81         SHA256Stream SHA512Stream (in libcrypt)
    81 
    82 
    82     [class variables:]
    83     [class variables:]
    83 	HashSize        size of returned hash value
    84         HashSize        size of returned hash value
    84 	ContextSize     (implementation) size of hash context
    85         ContextSize     (implementation) size of hash context
    85 
    86 
    86     [instance variables:]
    87     [instance variables:]
    87 	hashContext     (implementation)
    88         hashContext     (implementation)
    88 			internal buffer for computation of the hash value
    89                         internal buffer for computation of the hash value
    89 "
    90 "
    90 !
    91 !
    91 
    92 
    92 examples
    93 examples
    93 "
    94 "
   383 ! !
   384 ! !
   384 
   385 
   385 !MD5Stream class methodsFor:'documentation'!
   386 !MD5Stream class methodsFor:'documentation'!
   386 
   387 
   387 version
   388 version
   388     ^ '$Header: /cvs/stx/stx/libbasic/MD5Stream.st,v 1.24 2013-01-27 13:55:22 cg Exp $'
   389     ^ '$Header: /cvs/stx/stx/libbasic/MD5Stream.st,v 1.25 2013-02-20 15:39:28 cg Exp $'
   389 !
   390 !
   390 
   391 
   391 version_CVS
   392 version_CVS
   392     ^ '$Header: /cvs/stx/stx/libbasic/MD5Stream.st,v 1.24 2013-01-27 13:55:22 cg Exp $'
   393     ^ '$Header: /cvs/stx/stx/libbasic/MD5Stream.st,v 1.25 2013-02-20 15:39:28 cg Exp $'
   393 ! !
   394 ! !
   394 
   395 
   395 
   396 
   396 MD5Stream initialize!
   397 MD5Stream initialize!