Review main Merged

5665[BUGFIX] md5.js fails with non-ascii-characters

Stefan Neufeind CR +2 V +2 Hard +192 −364 updated 06/03/13, 20:49

Commit message

Current implementation of md5.js only considers a very
limited range of characters.
The implementation from webtoolkit.info uses correct
unicode-representation.

Review

  • Code review CR +2
    • Xavier Perseguers +2
  • Verified V +2
    • Oliver Hader +2
    • Xavier Perseguers +1

Issues 1

Files 1

Review log 8

  1. Stefan Neufeind commented on patch set 1 10/10/11, 22:27

    Old implementation uses a fixed table of characters. All others are not taken into account when calculating the md5 and thus result in a "wrong" value. The new implementation uses Unicode-representation and thus encodes those characters "correctly" the old one simply left out. On the net both of these implementations are very commonly used. The file in this patchset is also the one attached in the forge-issue. Licensing: On http://www.webtoolkit.info/license it's stated that "their" sources are free for use. So can we use it in TYPO3? Do we need to add part of the license to the file-header? Testing: Tested this against 4.5 / 4.6 running with UTF-8 (default) as FE-charset. By default the superchallenged FE-login is used which uses md5.js. Try to login with a username containing for example German Umlaute. Works after changing to the md5.js-implementation provided here. Server-side uses the PHP-md5-implementation.
  2. Stefan Neufeind uploaded patch set 2 10/10/11, 22:27

  3. Stefan Neufeind commented on patch set 2 10/10/11, 22:27

    removed whitespaces from lineendings
  4. Oliver Hader commented on patch set 2 V 0 10/10/11, 22:27

    by team member Code review is a bit difficult... ;-) However it works as expected.
  5. Xavier Perseguers commented on patch set 2 10/10/11, 22:27

    Verified; Looks good to me, approved Tested the library with a few random strings, with and without diacritics and compared with backend output of same hash
  6. Mr. Jenkins commented on patch set 1 10/10/11, 22:27

  7. Mr. Jenkins commented on patch set 2 10/10/11, 22:27

  8. Xavier Perseguers merged patch set 2 10/10/11, 22:27