Tiger st; st.start(); st.put(cast(ubyte[])"The quick brown fox jumps over the lazy dog"); assert(st.finish() == hexString!"6D12A41E72E644F017B6F0E2F7B44C6285F06DD5D2C5B075"); // Template API assert(digest!Tiger("abc") == hexString!"2AAB1484E8C158F2BFB8C5FF41B57A525129131C957B5F93"); assert(digest!Tiger160("abc") == hexString!"2AAB1484E8C158F2BFB8C5FF41B57A525129131C"); assert(digest!Tiger128("abc") == hexString!"2AAB1484E8C158F2BFB8C5FF41B57A52"); assert(digest!Tiger2("abc") == hexString!"F68D7BC5AF4B43A06E048D7829560D4A9415658BB0B1F3BF"); // OOP API Digest t = new TigerDigest; t.put(cast(ubyte[])"Tiger"); assert(t.finish() == hexString!"DD00230799F5009FEC6DEBC838BB6A27DF2B9D6F110C7937"); t = new Tiger160Digest; t.put(cast(ubyte[])"Tiger"); assert(t.finish() == hexString!"DD00230799F5009FEC6DEBC838BB6A27DF2B9D6F"); t = new Tiger128Digest; t.put(cast(ubyte[])"Tiger"); assert(t.finish() == hexString!"DD00230799F5009FEC6DEBC838BB6A27"); t = new Tiger2Digest; t.put(cast(ubyte[])"Tiger"); assert(t.finish() == hexString!"FE40798B8EB937FD977608930548D6A894C20B04CBEF7A42");
OOP API for Tiger2-128(3 pass)