diff options
author | Andreas Ebner <a.e.bner@web.de> | 2019-09-20 11:32:00 +0200 |
---|---|---|
committer | Schanzenbach, Martin <mschanzenbach@posteo.de> | 2019-10-07 12:18:20 +0200 |
commit | 4d4a16e000683046ebb19e6efe15e11d60c2178d (patch) | |
tree | 291ce657e2eabe7bf89b4ca3c929f2331da16f23 /src/credential/test_credential_issue.sh | |
parent | 3099a7c25cf6b11b0f1909e5a2651d65c0e921c7 (diff) | |
download | gnunet-4d4a16e000683046ebb19e6efe15e11d60c2178d.tar.gz gnunet-4d4a16e000683046ebb19e6efe15e11d60c2178d.zip |
Test cleanup/fix:
- added missing "- -" to collect for macOS
- replaced 'import $SIGNED' with 'import=$SIGNED' to match all other parameters and better visibility
Diffstat (limited to 'src/credential/test_credential_issue.sh')
-rwxr-xr-x | src/credential/test_credential_issue.sh | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/credential/test_credential_issue.sh b/src/credential/test_credential_issue.sh index 833a094e6..3d4b82cf6 100755 --- a/src/credential/test_credential_issue.sh +++ b/src/credential/test_credential_issue.sh | |||
@@ -1,4 +1,4 @@ | |||
1 | #!/bin/sh | 1 | #!/usr/bin/env bash |
2 | trap "gnunet-arm -e -c test_credential_lookup.conf" SIGINT | 2 | trap "gnunet-arm -e -c test_credential_lookup.conf" SIGINT |
3 | 3 | ||
4 | LOCATION=$(which gnunet-config) | 4 | LOCATION=$(which gnunet-config) |
@@ -28,8 +28,8 @@ gnunet-identity -C testissuer -c test_credential_lookup.conf | |||
28 | gnunet-identity -C testsubject -c test_credential_lookup.conf | 28 | gnunet-identity -C testsubject -c test_credential_lookup.conf |
29 | SUBJECT_KEY=$(gnunet-identity -d -c test_credential_lookup.conf | grep testsubject | awk '{print $3}') | 29 | SUBJECT_KEY=$(gnunet-identity -d -c test_credential_lookup.conf | grep testsubject | awk '{print $3}') |
30 | ISSUER_KEY=$(gnunet-identity -d -c test_credential_lookup.conf | grep testissuer | awk '{print $3}') | 30 | ISSUER_KEY=$(gnunet-identity -d -c test_credential_lookup.conf | grep testissuer | awk '{print $3}') |
31 | |||
31 | # Get credential and store it with subject (3) | 32 | # Get credential and store it with subject (3) |
32 | #CRED=`$DO_TIMEOUT gnunet-credential --issue --ego=testissuer --subject=$SUBJECT_KEY --attribute=$TEST_ATTR --ttl=5m -c test_credential_lookup.conf` | ||
33 | SIGNED=`$DO_TIMEOUT gnunet-credential --signSubjectSide --ego=testissuer --attribute=$TEST_ATTR --subject=$SUBJECT_KEY --ttl="2019-12-12 10:00:00" -c test_credential_lookup.conf` | 33 | SIGNED=`$DO_TIMEOUT gnunet-credential --signSubjectSide --ego=testissuer --attribute=$TEST_ATTR --subject=$SUBJECT_KEY --ttl="2019-12-12 10:00:00" -c test_credential_lookup.conf` |
34 | 34 | ||
35 | STATUS=$? | 35 | STATUS=$? |
@@ -40,8 +40,7 @@ then | |||
40 | exit 1 | 40 | exit 1 |
41 | fi | 41 | fi |
42 | #Try import | 42 | #Try import |
43 | $DO_TIMEOUT gnunet-credential --createSubjectSide --ego=testsubject --import "$SIGNED" --private -c test_credential_lookup.conf | 43 | $DO_TIMEOUT gnunet-credential --createSubjectSide --ego=testsubject --import="$SIGNED" --private -c test_credential_lookup.conf |
44 | #$DO_TIMEOUT gnunet-namestore -a -z testsubject -n c1 -t CRED -V "$CRED" -e 5m -c test_credential_lookup.conf | ||
45 | RES=$? | 44 | RES=$? |
46 | gnunet-arm -e -c test_credential_lookup.conf | 45 | gnunet-arm -e -c test_credential_lookup.conf |
47 | exit $RES | 46 | exit $RES |