(use md5 test) (test-group "MD5 Strings" (test-group "RFC1321 tests" (test "d41d8cd98f00b204e9800998ecf8427e" (md5-digest "")) (test "0cc175b9c0f1b6a831c399e269772661" (md5-digest "a")) (test "900150983cd24fb0d6963f7d28e17f72" (md5-digest "abc")) (test "f96b697d7cb7938d525a2f31aaf161d0" (md5-digest "message digest")) (test "c3fcd3d76192e4007dfb496cca67e13b" (md5-digest "abcdefghijklmnopqrstuvwxyz")) (test "d174ab98d277d9f5a5611c2c9f419d9f" (md5-digest "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789")) (test "57edf4a22be3c955ac49da2e2107b67a" (md5-digest "12345678901234567890123456789012345678901234567890123456789012345678901234567890"))) ;; These tests from "a fast implementation of MD5" for CL: ;; http://www.pmsf.de/resources/lisp/MD5.html (test-group "Padding tests" ;; From padding bug report by Edi Weitz (test "d734945e5930bb28859ccd13c830358b" (md5-digest "1631901HERR BUCHHEISTERCITROEN NORD1043360796beckenbauer")) ;; Test padding for strings from 0 to 69*8 bits in size. (test "d41d8cd98f00b204e9800998ecf8427e" (md5-digest "")) (test "0cc175b9c0f1b6a831c399e269772661" (md5-digest "a")) (test "4124bc0a9335c27f086f24ba207a4912" (md5-digest "aa")) (test "47bce5c74f589f4867dbd57e9ca9f808" (md5-digest "aaa")) (test "74b87337454200d4d33f80c4663dc5e5" (md5-digest "aaaa")) (test "594f803b380a41396ed63dca39503542" (md5-digest "aaaaa")) (test "0b4e7a0e5fe84ad35fb5f95b9ceeac79" (md5-digest "aaaaaa")) (test "5d793fc5b00a2348c3fb9ab59e5ca98a" (md5-digest "aaaaaaa")) (test "3dbe00a167653a1aaee01d93e77e730e" (md5-digest "aaaaaaaa")) (test "552e6a97297c53e592208cf97fbb3b60" (md5-digest "aaaaaaaaa")) (test "e09c80c42fda55f9d992e59ca6b3307d" (md5-digest "aaaaaaaaaa")) (test "d57f21e6a273781dbf8b7657940f3b03" (md5-digest "aaaaaaaaaaa")) (test "45e4812014d83dde5666ebdf5a8ed1ed" (md5-digest "aaaaaaaaaaaa")) (test "c162de19c4c3731ca3428769d0cd593d" (md5-digest "aaaaaaaaaaaaa")) (test "451599a5f9afa91a0f2097040a796f3d" (md5-digest "aaaaaaaaaaaaaa")) (test "12f9cf6998d52dbe773b06f848bb3608" (md5-digest "aaaaaaaaaaaaaaa")) (test "23ca472302f49b3ea5592b146a312da0" (md5-digest "aaaaaaaaaaaaaaaa")) (test "88e42e96cc71151b6e1938a1699b0a27" (md5-digest "aaaaaaaaaaaaaaaaa")) (test "2c60c24e7087e18e45055a33f9a5be91" (md5-digest "aaaaaaaaaaaaaaaaaa")) (test "639d76897485360b3147e66e0a8a3d6c" (md5-digest "aaaaaaaaaaaaaaaaaaa")) (test "22d42eb002cefa81e9ad604ea57bc01d" (md5-digest "aaaaaaaaaaaaaaaaaaaa")) (test "bd049f221af82804c5a2826809337c9b" (md5-digest "aaaaaaaaaaaaaaaaaaaaa")) (test "ff49cfac3968dbce26ebe7d4823e58bd" (md5-digest "aaaaaaaaaaaaaaaaaaaaaa")) (test "d95dbfee231e34cccb8c04444412ed7d" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaa")) (test "40edae4bad0e5bf6d6c2dc5615a86afb" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaa")) (test "a5a8bfa3962f49330227955e24a2e67c" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaa")) (test "ae791f19bdf77357ff10bb6b0e97e121" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "aaab9c59a88bf0bdfcb170546c5459d6" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "b0f0545856af1a340acdedce23c54b97" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "f7ce3d7d44f3342107d884bfa90c966a" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "59e794d45697b360e18ba972bada0123" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "3b0845db57c200be6052466f87b2198a" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "5eca9bd3eb07c006cd43ae48dfde7fd3" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "b4f13cb081e412f44e99742cb128a1a5" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "4c660346451b8cf91ef50f4634458d41" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "11db24dc3f6c2145701db08625dd6d76" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "80dad3aad8584778352c68ab06250327" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "1227fe415e79db47285cb2689c93963f" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "8e084f489f1bdf08c39f98ff6447ce6d" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "08b2f2b0864bac1ba1585043362cbec9" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "4697843037d962f62a5a429e611e0f5f" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "10c4da18575c092b486f8ab96c01c02f" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "af205d729450b663f48b11d839a1c8df" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "0d3f91798fac6ee279ec2485b25f1124" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "4c3c7c067634daec9716a80ea886d123" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "d1e358e6e3b707282cdd06e919f7e08c" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "8c6ded4f0af86e0a7e301f8a716c4363" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "4c2d8bcb02d982d7cb77f649c0a2dea8" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "bdb662f765cd310f2a547cab1cfecef6" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "08ff5f7301d30200ab89169f6afdb7af" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "6eb6a030bcce166534b95bc2ab45d9cf" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "1bb77918e5695c944be02c16ae29b25e" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "b6fe77c19f0f0f4946c761d62585bfea" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "e9e7e260dce84ffa6e0e7eb5fd9d37fc" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "eced9e0b81ef2bba605cbc5e2e76a1d0" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "ef1772b6dff9a122358552954ad0df65" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "3b0c8ac703f828b04c6c197006d17218" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "652b906d60af96844ebd21b674f35e93" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "dc2f2f2462a0d72358b2f99389458606" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "762fc2665994b217c52c3c2eb7d9f406" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "cc7ed669cf88f201c3297c6a91e1d18d" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "cced11f7bbbffea2f718903216643648" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "24612f0ce2c9d2cf2b022ef1e027a54f" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "b06521f39153d618550606be297466d5" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "014842d480b571495a4a0363793f7367" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "c743a45e0d2e6a95cb859adae0248435" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "def5d97e01e1219fb2fc8da6c4d6ba2f" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "92cb737f8687ccb93022fdb411a77cca" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "a0d1395c7fb36247bfe2d49376d9d133" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")) (test "ab75504250558b788f99d1ebd219abf2" (md5-digest "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"))))