mei_rt2mei_rt2_fix_1meiyap-rt1rt2
Last change
on this file since d5bbd3e 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.7 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/fruits_rt2_typed |
---|
8 | keyloc=$pwd |
---|
9 | |
---|
10 | ralphs=`creddy --keyid --cert $keyloc/Ralphs_ID.pem` |
---|
11 | bob=`creddy --keyid --cert $keyloc/Bob_ID.pem` |
---|
12 | mary=`creddy --keyid --cert $keyloc/Mary_ID.pem` |
---|
13 | |
---|
14 | mary_what2eat="[keyid:$mary].oset:what2eat" |
---|
15 | bob_what2eat="[keyid:$bob].oset:what2eat" |
---|
16 | ralphs_apple="[keyid:$ralphs].oset:fruitprice([float:1.50])" |
---|
17 | |
---|
18 | ## dump all credentials |
---|
19 | $eloc/abac_prover_yap --keystore $keyloc --dump creds_dump |
---|
20 | |
---|
21 | # [keyid:mary].oset:what2eat <-?- [string:'navel orange'] (yes) |
---|
22 | echo " " |
---|
23 | echo "===good============ mary.what2eat <- navel orange yap " |
---|
24 | $eloc/abac_prover_yap --keystore $keyloc --oset "$mary_what2eat" --object "[string:'navel orange']" |
---|
25 | |
---|
26 | # [keyid:mary].oset:what2eat <-?- [string:'kiwi'] (yes) |
---|
27 | echo " " |
---|
28 | echo "===good============ mary.what2eat <- kiwi yap " |
---|
29 | $eloc/abac_prover_yap --keystore $keyloc --oset "$mary_what2eat" --object "[string:'kiwi']" |
---|
30 | |
---|
31 | # [keyid:bob].oset:what2eat <-?- [string:'navel orange'] (no) |
---|
32 | echo " " |
---|
33 | echo "===bad============ bob.what2eat <- navel orange yap " |
---|
34 | $eloc/abac_prover_yap --keystore $keyloc --oset "$bob_what2eat" --object "[string:'navel orange']" |
---|
35 | |
---|
36 | # [keyid:$ralphs].oset:fruitprice([float:1.50]) <-?- [string:'apple'] (yes) |
---|
37 | echo " " |
---|
38 | echo "===good============ ralphs.fruitprice(1.50) <- apple yap " |
---|
39 | $eloc/abac_prover_yap --keystore $keyloc --oset "$ralphs_apple" --object "[string:'apple']" |
---|
40 | |
---|
41 | |
---|
42 | # [keyid:$ralphs].oset:fruitprice([float:1.50]) <-?- [string:'green apple'] (no) |
---|
43 | echo " " |
---|
44 | echo "===bad============ ralphs.fruitprice(1.50) <- green apple yap " |
---|
45 | $eloc/abac_prover_yap --keystore $keyloc --oset "$ralphs_apple" --object "[string:'green apple']" |
---|
46 | |
---|
47 | |
---|
Note: See
TracBrowser
for help on using the repository browser.