mei_rt2mei_rt2_fix_1meiyap-rt1rt2
Last change
on this file since 923b4dd was
d5bbd3e,
checked in by Mei <mei@…>, 13 years ago
|
1) add alumni2_rt1_typed
(target static range constraint)
2) add another rule for fruits example
3) add target static range constraint handling for string & urn
|
-
Property mode set to
100755
|
File size:
1.5 KB
|
Line | |
---|
1 | rm -rf creds_dump |
---|
2 | |
---|
3 | pwd=`pwd` |
---|
4 | |
---|
5 | #eloc=/home/mei/Deter/abac/libabac |
---|
6 | eloc=$pwd/../../libabac |
---|
7 | #keyloc=/home/mei/Deter/abac/examples/alumni2_rt1_typed |
---|
8 | keyloc=$pwd |
---|
9 | |
---|
10 | stateU=`creddy --keyid --cert $keyloc/StateU_ID.pem` |
---|
11 | bob=`creddy --keyid --cert $keyloc/Bob_ID.pem` |
---|
12 | maryann=`creddy --keyid --cert $keyloc/Maryann_ID.pem` |
---|
13 | joe=`creddy --keyid --cert $keyloc/Joe_ID.pem` |
---|
14 | |
---|
15 | stateU_foundingAlumni="[keyid:$stateU].role:foundingAlumni" |
---|
16 | bob_prin="[keyid:$bob]" |
---|
17 | maryann_prin="[keyid:$maryann]" |
---|
18 | joe_prin="[keyid:$joe]" |
---|
19 | |
---|
20 | # [keyid:stateU].role:foundingAlumni <-?- [keyid:Bob] (yes) |
---|
21 | # [keyid:stateU].role:foundingAlumni <-?- [keyid:Maryann] (no) |
---|
22 | # [keyid:stateU].role:foundingAlumni <-?- [keyid:Joe] (no) |
---|
23 | |
---|
24 | ## dump all credentials |
---|
25 | $eloc/abac_prover_yap --keystore $keyloc --dump creds_dump |
---|
26 | |
---|
27 | # [keyid:stateU].role:foundingAlumni <-?- [keyid:Bob] (yes) |
---|
28 | echo " " |
---|
29 | echo "===good============ stateU.foundingAlumni <- Bob yap " |
---|
30 | $eloc/abac_prover_yap --keystore $keyloc --role "$stateU_foundingAlumni" --principal "$bob_prin" |
---|
31 | |
---|
32 | # [keyid:stateU].role:foundingAlumni <-?- [keyid:Maryann] (no) |
---|
33 | # asking, isMember(pMaryann,role(pStateU,foundingAlumni),C). |
---|
34 | echo " " |
---|
35 | echo "===bad============ stateU.foundingAlumni <- Maryann yap " |
---|
36 | $eloc/abac_prover_yap --keystore $keyloc --role "$stateU_foundingAlumni" --principal "$maryann_prin" |
---|
37 | |
---|
38 | # [keyid:stateU].role:foundingAlumni <-?- [keyid:Joe] (no) |
---|
39 | echo " " |
---|
40 | echo "===bad============ stateU.foundingAlumni <- Joe yap " |
---|
41 | $eloc/abac_prover_yap --keystore $keyloc --role "$stateU_foundingAlumni" --principal "$joe_prin" |
---|
42 | |
---|
43 | |
---|
Note: See
TracBrowser
for help on using the repository browser.