Add crypto hash SM3.
authorJia Zhang <qianyue.zj@alibaba-inc.com>
Tue, 24 Oct 2017 06:55:12 +0000 (15:55 +0900)
committerNIIBE Yutaka <gniibe@fsij.org>
Tue, 24 Oct 2017 07:18:55 +0000 (16:18 +0900)
commit4423bf3cc4432b9bfe801ff74cb05e6f0dd3eccd
tree55932118b9f72e87e179b252ae9e4d0a5138672c
parent5b31e22d9fc542bdccb1586ef2c83d9794a731d3
Add crypto hash SM3.

* configure.ac (available_digests): Add sm3.
* src/cipher.h: Add declarations for SM3.
* cipher/Makefile.am (EXTRA_libcipher_la_SOURCES): Add sm3.c.
* cipher/md.c [USE_SM3] (digest_list): Add _gcry_digest_spec_sm3.
* cipher/pubkey-util.c (hashnames): Add "sm3".
* cipher/sm3.c: New.
* tests/basic.c (check_digests): Add test vectors for SM3.
* tests/hashtest-256g.in (algos): Add SM3.
* tests/hashtest.c (testvectors): Add for SM3.

--

GnuPG-bug-id: 3454
Signed-off-by: Jia Zhang <qianyue.zj@alibaba-inc.com>
cipher/Makefile.am
cipher/md.c
cipher/pubkey-util.c
cipher/sm3.c [new file with mode: 0644]
configure.ac
src/cipher.h
tests/basic.c
tests/hashtest-256g.in
tests/hashtest.c