From 7922c942540a202faffe8336d57322a39d78af1c Mon Sep 17 00:00:00 2001 From: Bernardo Cardoso <bernardo@elixxir.io> Date: Wed, 17 Apr 2019 18:16:08 -0600 Subject: [PATCH] Add E2E message sending to integration test --- basice2e/clients.goldoutput/client18.out | 1 + basice2e/clients.goldoutput/client9.out | 1 + basice2e/run.sh | 17 +++++++++++++++-- 3 files changed, 17 insertions(+), 2 deletions(-) diff --git a/basice2e/clients.goldoutput/client18.out b/basice2e/clients.goldoutput/client18.out index 0264639..af0833d 100644 --- a/basice2e/clients.goldoutput/client18.out +++ b/basice2e/clients.goldoutput/client18.out @@ -1 +1,2 @@ UDB search successful. Returned user [0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 9] +Sending Message to 9, Spencer: Hello, 9, with E2E Encryption diff --git a/basice2e/clients.goldoutput/client9.out b/basice2e/clients.goldoutput/client9.out index ce992b4..116f612 100644 --- a/basice2e/clients.goldoutput/client9.out +++ b/basice2e/clients.goldoutput/client9.out @@ -1 +1,2 @@ UDB search successful. Returned user [0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 18] +Message from 18, Bernardo Received: Hello, 9, with E2E Encryption diff --git a/basice2e/run.sh b/basice2e/run.sh index a0f50b7..654d5dc 100755 --- a/basice2e/run.sh +++ b/basice2e/run.sh @@ -119,13 +119,13 @@ do done # Register two users and then do UDB search on each other -CLIENTCMD="timeout 90s ../bin/client -f blob9 -g $GATEWAY -E "jake@elixxir.io" -i 9 -d 3 -c ../keys/gateway.cmix.rip.crt" +CLIENTCMD="timeout 90s ../bin/client -f blob9 -g $GATEWAY -E "spencer@elixxir.io" -i 9 -d 3 -c ../keys/gateway.cmix.rip.crt" eval $CLIENTCMD >> $CLIENTOUT/client9.out 2>&1 & PIDVAL=$! echo "$CLIENTCMD -- $PIDVAL" wait $PIDVAL -CLIENTCMD="timeout 90s ../bin/client -f blob18 -g $GATEWAY -E "bernardo@elixxir.io" -i 18 -d 3 -c ../keys/gateway.cmix.rip.crt -m \"SEARCH EMAIL jake@elixxir.io\"" +CLIENTCMD="timeout 90s ../bin/client -f blob18 -g $GATEWAY -E "bernardo@elixxir.io" -i 18 -d 3 -c ../keys/gateway.cmix.rip.crt -m \"SEARCH EMAIL spencer@elixxir.io\"" eval $CLIENTCMD >> $CLIENTOUT/client18.out 2>&1 & PIDVAL=$! echo "$CLIENTCMD -- $PIDVAL" @@ -137,6 +137,19 @@ PIDVAL=$! echo "$CLIENTCMD -- $PIDVAL" wait $PIDVAL +# Send E2E encrypted message between users that discovered each other +CLIENTCMD="timeout 60s ../bin/client -f blob18 -g $GATEWAY -i 18 -d 9 -c ../keys/gateway.cmix.rip.crt -m \"Hello, 9, with E2E Encryption\" --end2end" +eval $CLIENTCMD >> $CLIENTOUT/client18.out 2>&1 & +PIDVAL=$! +echo "$CLIENTCMD -- $PIDVAL" +wait $PIDVAL + +CLIENTCMD="timeout 60s ../bin/client -f blob9 -g $GATEWAY -i 9 -c ../keys/gateway.cmix.rip.crt" +eval $CLIENTCMD >> $CLIENTOUT/client9.out 2>&1 & +PIDVAL=$! +echo "$CLIENTCMD -- $PIDVAL" +wait $PIDVAL + # Send a channel message that all clients will receive CLIENTCMD="timeout 60s ../bin/client -f blob8 -c ../keys/gateway.cmix.rip.crt -g $GATEWAY -i 8 -d 31 -m \"Channel, Hello\"" eval $CLIENTCMD >> $CLIENTOUT/client8.out 2>&1 & -- GitLab