CryproJS md5 & sha1 vs utility

JavaScript performance comparison

Revision 6 of this test case created by Xotic750 and last updated

Preparation code

<script src="//rghost.net/download/44831119/7479df174275b70db5008492464e07238c269d18/utility3.js">
</script>
<script src="//crypto-js.googlecode.com/svn/tags/3.1.2/build/rollups/md5.js">
</script>
<script src="//crypto-js.googlecode.com/svn/tags/3.1.2/build/rollups/sha1.js">
</script>
<script src="//crypto-js.googlecode.com/svn/tags/3.1.2/build/rollups/sha256.js">
</script>
<script src="//tiny-sha1.googlecode.com/files/tinySHA1.r4.js"></script>
<script src="//bitbucket.org/keesey/sha1/raw/fcbee69dcc6f6e9038e7d78376ab207e0816896a/bin/sha1.js"></script>

<script>
  var str = "kjabefkjvejfvoafnvoafgvoeirgoierjghobnipuvnciuwerg46uii89p90ppöäåå'öpoolk,i,il.imyujmntrntrtvvcecedcxqwerfewrfezqwsxwd<";
</script>

Preparation code output

Test runner

Warning! For accurate results, please disable Firebug before running the tests. (Why?)

Java applet disabled.

Testing in unknown unknown
Test Ops/sec
CryptoJs md5
CryptoJS.MD5(str).toString();
pending…
utility md5
$u.md5(str);
pending…
crypto sha1
CryptoJS.SHA1(str).toString();
pending…
utility sha1
$u.sha1(str);
pending…
tiny sha1
SHA1(str);
pending…
utility sha1ArrayBuffer
$u.sha1ArrayBuffer(str);
pending…
other sha1
sha1.hash(str);
pending…
crypto sha256
CryptoJS.SHA256(str).toString();
pending…
utility sha256
$u.sha256(str);
pending…

Compare results of other browsers

Revisions

You can edit these tests or add even more tests to this page by appending /edit to the URL. Here’s a list of current revisions for this page:

0 comments

Add a comment