mei_rt2mei_rt2_fix_1
Last change
on this file since 2be9809 was
08b8da7,
checked in by Mei <mei@…>, 12 years ago
|
1) rework examples directory with Makefile
2) update scaling with plotting scripts
3) add more doc in there
|
-
Property mode set to
100755
|
File size:
1.3 KB
|
Rev | Line | |
---|
[10e1588] | 1 | |
---|
[9502c50] | 2 | |
---|
| 3 | # access_rt2_typed |
---|
[10e1588] | 4 | |
---|
[c469edf] | 5 | pwd=`pwd` |
---|
| 6 | |
---|
[08b8da7] | 7 | eloc=`which abac_prover_yap | sed 's/\/abac_prover_yap//'` |
---|
| 8 | if [ "$eloc" = "" ]; then |
---|
| 9 | echo "ERROR: abac_prover_yap is not in the search path!!!" |
---|
| 10 | exit 1 |
---|
| 11 | fi |
---|
| 12 | |
---|
[c469edf] | 13 | keyloc=$pwd |
---|
[10e1588] | 14 | |
---|
| 15 | alpha=`creddy --keyid --cert $keyloc/Alpha_ID.pem` |
---|
| 16 | bob=`creddy --keyid --cert $keyloc/Bob_ID.pem` |
---|
| 17 | joe=`creddy --keyid --cert $keyloc/Joe_ID.pem` |
---|
| 18 | |
---|
| 19 | bob_prin="[keyid:$bob]" |
---|
| 20 | |
---|
[9806e76] | 21 | access_fileA="[keyid:$alpha].role:access([string:'Read'],[urn:'file//fileA'])" |
---|
[10e1588] | 22 | team_proj2="[keyid:$alpha].role:team([string:'proj2'])" |
---|
| 23 | bob_prin="[keyid:$bob]" |
---|
| 24 | joe_prin="[keyid:$joe]" |
---|
| 25 | |
---|
[7b548fa] | 26 | ## dump all credentials |
---|
[e88c95b] | 27 | $eloc/abac_prover_yap --keystore $keyloc --dump creds_dump |
---|
[10e1588] | 28 | |
---|
[8bd77b5] | 29 | # double check |
---|
| 30 | #creddy --roles --cert Alpha_access_qFqP__alpha_team_qP_attr.der |
---|
| 31 | |
---|
[9806e76] | 32 | #[keyid:Alpha].role:access([string:'Read'],[urn:'file//fileA']) <-?- [keyid:bob] (yes) |
---|
[36b100a] | 33 | echo " " |
---|
[9502c50] | 34 | echo "===good============ Alpha.access(Read,fileA)<-?-Bob" |
---|
[10e1588] | 35 | $eloc/abac_prover_yap --keystore $keyloc --role "$access_fileA" --principal "$bob_prin" |
---|
| 36 | |
---|
[36b100a] | 37 | echo " " |
---|
[9502c50] | 38 | echo "===bad============ Alpha.access(Read,fileA)<-?-Joe" |
---|
[10e1588] | 39 | $eloc/abac_prover_yap --keystore $keyloc --role "$access_fileA" --principal "$joe_prin" |
---|
| 40 | |
---|
[36b100a] | 41 | echo " " |
---|
[9502c50] | 42 | echo "===good============ Alpha.team(proj2)<-?-Joe" |
---|
[5110d42] | 43 | #[keyid:alpha].role:team([string:'proj2'])<-[keyid:Joe] |
---|
[e88c95b] | 44 | $eloc/abac_prover_yap --keystore $keyloc --role "$team_proj2" --principal "$joe_prin" |
---|
[10e1588] | 45 | |
---|
Note: See
TracBrowser
for help on using the repository browser.