source: examples/alumni3_rt1_typed/rr @ 4b8e1c9

mei_rt2mei_rt2_fix_1meiyap-rt1rt2
Last change on this file since 4b8e1c9 was acf3ff9, checked in by Mei <mei@…>, 13 years ago

1) add alumni3_rt1_typed

(multiple static target range constraint - string & int types)

  • Property mode set to 100755
File size: 2.2 KB
Line 
1rm -rf creds_dump
2
3pwd=`pwd`
4
5#eloc=/home/mei/Deter/abac/libabac
6eloc=$pwd/../../libabac
7#keyloc=/home/mei/Deter/abac/examples/alumni3_rt1_typed
8keyloc=$pwd
9
10stateU=`creddy --keyid --cert $keyloc/StateU_ID.pem`
11
12bob=`creddy --keyid --cert $keyloc/Bob_ID.pem`
13mark=`creddy --keyid --cert $keyloc/Mark_ID.pem`
14joe=`creddy --keyid --cert $keyloc/Joe_ID.pem`
15maryann=`creddy --keyid --cert $keyloc/Maryann_ID.pem`
16jan=`creddy --keyid --cert $keyloc/Jan_ID.pem`
17
18stateU_foundingAlumni="[keyid:$stateU].role:foundingAlumni"
19bob_prin="[keyid:$bob]"
20maryann_prin="[keyid:$maryann]"
21joe_prin="[keyid:$joe]"
22mark_prin="[keyid:$mark]"
23jan_prin="[keyid:$jan]"
24
25# [keyid:stateU].role:foundingAlumni <-?- [keyid:Bob] (yes)
26# [keyid:stateU].role:foundingAlumni <-?- [keyid:Mark] (no)
27# [keyid:stateU].role:foundingAlumni <-?- [keyid:Joe] (no)
28# [keyid:stateU].role:foundingAlumni <-?- [keyid:Maryann] (no)
29# [keyid:stateU].role:foundingAlumni <-?- [keyid:Jan] (yes)
30
31## dump all credentials
32$eloc/abac_prover_yap  --keystore $keyloc --dump creds_dump
33
34# [keyid:stateU].role:foundingAlumni <-?- [keyid:Bob] (yes)
35echo " "
36echo "===good============ stateU.foundingAlumni <- Bob yap "
37$eloc/abac_prover_yap  --keystore $keyloc --role "$stateU_foundingAlumni" --principal "$bob_prin"
38
39# [keyid:stateU].role:foundingAlumni <-?- [keyid:Mark] (no)
40echo " "
41echo "===bad============ stateU.foundingAlumni <- Mark yap "
42$eloc/abac_prover_yap  --keystore $keyloc --role "$stateU_foundingAlumni" --principal "$mark_prin"
43
44# [keyid:stateU].role:foundingAlumni <-?- [keyid:Joe] (no)
45echo " "
46echo "===bad============ stateU.foundingAlumni <- Joe yap "
47$eloc/abac_prover_yap  --keystore $keyloc --role "$stateU_foundingAlumni" --principal "$joe_prin"
48
49# [keyid:stateU].role:foundingAlumni <-?- [keyid:Maryann] (no)
50# asking, isMember(pMaryann,role(pStateU,foundingAlumni),C).
51echo " "
52echo "===bad============ stateU.foundingAlumni <- Maryann yap "
53$eloc/abac_prover_yap  --keystore $keyloc --role "$stateU_foundingAlumni" --principal "$maryann_prin"
54
55# [keyid:stateU].role:foundingAlumni <-?- [keyid:Jan] (yes)
56echo " "
57echo "===good============ stateU.foundingAlumni <- Jan yap "
58$eloc/abac_prover_yap  --keystore $keyloc --role "$stateU_foundingAlumni" --principal "$jan_prin"
59
60
Note: See TracBrowser for help on using the repository browser.