shithub: mc

ref: 6b0f942d7b95740123e84dbd8aeab15f336a18c6
dir: /libcryptohash/test/sha1-test.myr/

View raw version
use std
use cryptohash

use "printhash.use"

const main = {
	print(cryptohash.sha1("")[:])
	print(cryptohash.sha1("h")[:])
	/* 64 byte block */
	print(cryptohash.sha1("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")[:])
	/* tail spanning */
	print(cryptohash.sha1("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabbbbb")[:])
}