gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] r30869 - gnunet/src/revocation


From: gnunet
Subject: [GNUnet-SVN] r30869 - gnunet/src/revocation
Date: Tue, 26 Nov 2013 13:09:21 +0100

Author: wachs
Date: 2013-11-26 13:09:21 +0100 (Tue, 26 Nov 2013)
New Revision: 30869

Added:
   gnunet/src/revocation/test_local_revocation.sh
Modified:
   gnunet/src/revocation/Makefile.am
   gnunet/src/revocation/test_revocation.conf
Log:
local revocation test


Modified: gnunet/src/revocation/Makefile.am
===================================================================
--- gnunet/src/revocation/Makefile.am   2013-11-26 09:49:15 UTC (rev 30868)
+++ gnunet/src/revocation/Makefile.am   2013-11-26 12:09:21 UTC (rev 30869)
@@ -56,6 +56,12 @@
 gnunet_service_revocation_DEPENDENCIES = \
   libgnunetrevocation.la
 
+check_SCRIPTS = \
+       test_local_revocation.sh
 
+if ENABLE_TEST_RUN
+ TESTS = $(check_SCRIPTS)
+endif
+
 EXTRA_DIST = test_revocation.conf
 

Added: gnunet/src/revocation/test_local_revocation.sh
===================================================================
--- gnunet/src/revocation/test_local_revocation.sh                              
(rev 0)
+++ gnunet/src/revocation/test_local_revocation.sh      2013-11-26 12:09:21 UTC 
(rev 30869)
@@ -0,0 +1,27 @@
+#!/bin/bash
+TEST_CONFIGURATION="test_revocation.conf"
+TEST_REVOCATION_EGO="revoc_test"
+
+which timeout &> /dev/null && DO_TIMEOUT="timeout 5"
+trap "gnunet-arm -e -c test_revocation.conf" SIGINT
+
+# clean up
+rm -rf `gnunet-config -c test_revocation.conf -s PATHS -o GNUNET_HOME -f`
+
+# Start 
+gnunet-arm -s -c $TEST_CONFIGURATION
+gnunet-identity -C $TEST_REVOCATION_EGO -c $TEST_CONFIGURATION
+TEST_REVOCATION_KEY=$(gnunet-identity -d | awk '{split($0,a," "); print a[3]}')
+
+echo Testing key $TEST_REVOCATION_KEY
+OUTPUT_NOT_REVOKED=$(gnunet-revocation -t $TEST_REVOCATION_KEY -c 
$TEST_CONFIGURATION )
+
+echo Revoking key $TEST_REVOCATION_KEY
+gnunet-revocation -R $TEST_REVOCATION_EGO -p -c $TEST_CONFIGURATION 1> 
/dev/null 2> /dev/null
+
+echo Testing revoked key $TEST_REVOCATION_KEY
+OUTPUT_REVOKED=$(gnunet-revocation -t $TEST_REVOCATION_KEY -c 
$TEST_CONFIGURATION)
+
+#clean up
+gnunet-arm -e -c test_revocation.conf
+rm -rf `gnunet-config -c test_revocation.conf -s PATHS -o GNUNET_HOME -f`


Property changes on: gnunet/src/revocation/test_local_revocation.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Modified: gnunet/src/revocation/test_revocation.conf
===================================================================
--- gnunet/src/revocation/test_revocation.conf  2013-11-26 09:49:15 UTC (rev 
30868)
+++ gnunet/src/revocation/test_revocation.conf  2013-11-26 12:09:21 UTC (rev 
30869)
@@ -1,2 +1,14 @@
+[paths]
+GNUNET_HOME=/tmp/test-revocation-service
+SERVICEHOME=/tmp/test-revocation-service
+
 [revocation]
 WORKBITS = 5
+
+[identity]
+# Directory where we store information about our egos
+EGODIR = $GNUNET_HOME/identity/egos/
+SUBSYSTEM_CFG = $SERVICEHOME/s.conf
+
+[hostlist]
+SERVER = dummy
\ No newline at end of file




reply via email to

[Prev in Thread] Current Thread [Next in Thread]