Skip to content

Commit 94bb7aa

Browse files
committed
Initial prototype of hashlib running atop HACL*'s blake2
1 parent b6b8ea9 commit 94bb7aa

18 files changed

+3629
-571
lines changed

Makefile.pre.in

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -811,7 +811,7 @@ coverage-lcov:
811811
@ # remove 3rd party modules, system headers and internal files with
812812
@ # debug, test or dummy functions.
813813
@lcov $(COVERAGE_LCOV_OPTIONS) --remove $(COVERAGE_INFO) \
814-
'*/Modules/_blake2/impl/*' \
814+
'*/Modules/_hacl/*' \
815815
'*/Modules/_ctypes/libffi*/*' \
816816
'*/Modules/_decimal/libmpdec/*' \
817817
'*/Modules/expat/*' \
@@ -841,7 +841,7 @@ coverage-report: regen-token regen-frozen
841841

842842
# Run "Argument Clinic" over all source files
843843
.PHONY: clinic
844-
clinic: check-clean-src $(srcdir)/Modules/_blake2/blake2s_impl.c
844+
clinic: check-clean-src
845845
$(PYTHON_FOR_REGEN) $(srcdir)/Tools/clinic/clinic.py --make --exclude Lib/test/clinic.test.c --srcdir $(srcdir)
846846

847847
.PHONY: clinic-tests
@@ -871,11 +871,6 @@ pybuilddir.txt: $(PYTHON_FOR_BUILD_DEPS)
871871
exit 1 ; \
872872
fi
873873

874-
# blake2s is auto-generated from blake2b
875-
$(srcdir)/Modules/_blake2/blake2s_impl.c: $(srcdir)/Modules/_blake2/blake2b_impl.c $(srcdir)/Modules/_blake2/blake2b2s.py
876-
$(PYTHON_FOR_REGEN) $(srcdir)/Modules/_blake2/blake2b2s.py
877-
$(PYTHON_FOR_REGEN) $(srcdir)/Tools/clinic/clinic.py -f $@
878-
879874
# Build static library
880875
$(LIBRARY): $(LIBRARY_OBJS)
881876
-rm -f $@

Modules/Setup.stdlib.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@
8282
@MODULE__SHA1_TRUE@_sha1 sha1module.c -I$(srcdir)/Modules/_hacl/include _hacl/Hacl_Hash_SHA1.c -D_BSD_SOURCE -D_DEFAULT_SOURCE
8383
@MODULE__SHA2_TRUE@_sha2 sha2module.c -I$(srcdir)/Modules/_hacl/include Modules/_hacl/libHacl_Hash_SHA2.a
8484
@MODULE__SHA3_TRUE@_sha3 sha3module.c -I$(srcdir)/Modules/_hacl/include _hacl/Hacl_Hash_SHA3.c -D_BSD_SOURCE -D_DEFAULT_SOURCE
85-
@MODULE__BLAKE2_TRUE@_blake2 blake2module.c -I$(srcdir)/Modules/_hacl/include _hacl/Hacl_Hash_Blake2s.c _hacl/Hacl_Hash_Blake2b.c -D_BSD_SOURCE -D_DEFAULT_SOURCE
85+
@MODULE__BLAKE2_TRUE@_blake2 blake2module.c -I$(srcdir)/Modules/_hacl/ -I$(srcdir)/Modules/_hacl/include _hacl/Hacl_Hash_Blake2s.c _hacl/Hacl_Hash_Blake2b.c _hacl/Lib_Memzero0.c -D_BSD_SOURCE -D_DEFAULT_SOURCE
8686

8787
############################################################################
8888
# XML and text

0 commit comments

Comments
 (0)