summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorMagnus Ahltorp <map@kth.se>2015-03-31 16:49:53 +0200
committerMagnus Ahltorp <map@kth.se>2015-03-31 17:04:07 +0200
commit1f9535763a3a5c49728c375988a83897fad48142 (patch)
treee873885a78a8512d81bc13ebb88051b63dfbae40 /Makefile
parent07bbae40520a0fe5e893f73a29d785d2f3b59eed (diff)
Generate test authentication keys dynamically
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile8
1 files changed, 6 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index bda7f3a..51fd786 100644
--- a/Makefile
+++ b/Makefile
@@ -24,8 +24,6 @@ tests-prepare:
touch $(PREFIX)/tests/mergedb/logorder
mkdir $(PREFIX)/tests/known_roots
cp tools/testcerts/roots/* $(PREFIX)/tests/known_roots
- cp -r test/config/privatekeys $(PREFIX)/tests
- cp -r test/config/publickeys $(PREFIX)/tests
@for machine in $(MACHINES); do \
(cd $(PREFIX); ../tools/compileconfig.py --config=../test/catlfish-test.cfg --localconfig ../test/catlfish-test-local-$$machine.cfg) ; \
mkdir -p $(PREFIX)/tests/machine/machine-$$machine/db ; \
@@ -33,9 +31,15 @@ tests-prepare:
touch $(PREFIX)/tests/machine/machine-$$machine/db/newentries ; \
done
(cd $(PREFIX); ../tools/compileconfig.py --config=../test/catlfish-test.cfg --localconfig ../test/catlfish-test-local-signing.cfg)
+ mkdir $(PREFIX)/tests/privatekeys
+ mkdir $(PREFIX)/tests/publickeys
@for node in $(NODES); do \
+ (cd $(PREFIX)/tests/privatekeys ; ../../../tools/create-key.sh $$node) ; \
+ mv $(PREFIX)/tests/privatekeys/$$node.pem $(PREFIX)/tests/publickeys/ ; \
mkdir -p test/nodes/$$node/log ; \
done
+ (cd $(PREFIX)/tests/privatekeys ; ../../../tools/create-key.sh merge-1)
+ mv $(PREFIX)/tests/privatekeys/merge-1.pem $(PREFIX)/tests/publickeys/
tests-start:
@for node in $(NODES); do \