summaryrefslogtreecommitdiff
path: root/src/credential/test_credential_bi_bw.sh
diff options
context:
space:
mode:
authorAndreas Ebner <a.e.bner@web.de>2019-09-14 16:58:39 +0200
committerSchanzenbach, Martin <mschanzenbach@posteo.de>2019-10-07 12:17:29 +0200
commit5be14856a356b087ad97b479efd9b06172fdfd2f (patch)
tree724a52f386be772cd8605224c47017f3b4d64e20 /src/credential/test_credential_bi_bw.sh
parentd4790594a33a4688641f66841f05533b3c0956b9 (diff)
downloadgnunet-5be14856a356b087ad97b479efd9b06172fdfd2f.tar.gz
gnunet-5be14856a356b087ad97b479efd9b06172fdfd2f.zip
Bugfixes, changed test reporting behavior, modified intermediate result reporting:
- fixed a memory error when serializing the delegations - all tests now handle the returned error code from the gnunet-credential.c via "ret" variable - intermediate reporting excluded during collect message - intermediate reporting now contains the direction (bw/fw)
Diffstat (limited to 'src/credential/test_credential_bi_bw.sh')
-rwxr-xr-xsrc/credential/test_credential_bi_bw.sh11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/credential/test_credential_bi_bw.sh b/src/credential/test_credential_bi_bw.sh
index ae5549a1d..eedcea7eb 100755
--- a/src/credential/test_credential_bi_bw.sh
+++ b/src/credential/test_credential_bi_bw.sh
@@ -64,7 +64,9 @@ echo "+++ Starting to Resolve +++"
64DELS=`$DO_TIMEOUT gnunet-credential --collect --issuer=$AKEY --attribute="a" --ego=f --forward --backward -c test_credential_lookup.conf | paste -d, -s - -` 64DELS=`$DO_TIMEOUT gnunet-credential --collect --issuer=$AKEY --attribute="a" --ego=f --forward --backward -c test_credential_lookup.conf | paste -d, -s - -`
65echo $DELS 65echo $DELS
66echo gnunet-credential --verify --issuer=$AKEY --attribute="a" --subject=$FKEY --delegate=\'$DELS\' --forward --backward -c test_credential_lookup.conf 66echo gnunet-credential --verify --issuer=$AKEY --attribute="a" --subject=$FKEY --delegate=\'$DELS\' --forward --backward -c test_credential_lookup.conf
67RES_DELS=`gnunet-credential --verify --issuer=$AKEY --attribute="a" --subject=$FKEY --delegate="$DELS" --forward --backward -c test_credential_lookup.conf` 67gnunet-credential --verify --issuer=$AKEY --attribute="a" --subject=$FKEY --delegate="$DELS" --forward --backward -c test_credential_lookup.conf
68
69RES = $?
68 70
69# Cleanup properly 71# Cleanup properly
70gnunet-namestore -z a -d -n "a" -t ATTR -c test_credential_lookup.conf 72gnunet-namestore -z a -d -n "a" -t ATTR -c test_credential_lookup.conf
@@ -75,13 +77,10 @@ gnunet-namestore -z f -d -n "@" -t DEL -c test_credential_lookup.conf
75 77
76gnunet-arm -e -c test_credential_lookup.conf 78gnunet-arm -e -c test_credential_lookup.conf
77 79
78if [ "$RES_DELS" != "Failed." ] 80if [ $RES == 0 ]
79then 81then
80 # TODO: replace echo -e bashism
81 echo -e "${RES_DELS}"
82 exit 0 82 exit 0
83else 83else
84 echo "FAIL: Failed to verify credential $RES_DELS." 84 echo "FAIL: Failed to verify credential."
85 exit 1 85 exit 1
86fi 86fi
87