source: examples/creddy_prover_tests/alice_rt1/README @ 340bd01

mei_rt2mei_rt2_fix_1
Last change on this file since 340bd01 was f824a9e, checked in by Mei <mei@…>, 13 years ago

1) add more doc to python_tests

  • Property mode set to 100755
File size: 10.1 KB
RevLine 
[a9494ad]1#!/bin/sh
2
3## trying out different data param types
4
[f824a9e]5# alice_rt1
[a9494ad]6
7creddy --generate --cn Alice
8creddy --generate --cn Hatter
9creddy --generate --cn MarchHare
10creddy --generate --cn Dormouse
11creddy --generate --cn Tea
12creddy --generate --cn Party
13
14alice_keyid=`creddy --keyid --cert Alice_ID.pem`
15party_keyid=`creddy --keyid --cert Party_ID.pem`
16tea_keyid=`creddy --keyid --cert Tea_ID.pem`
17hatter_keyid=`creddy --keyid --cert Hatter_ID.pem`
18marchhare_keyid=`creddy --keyid --cert MarchHare_ID.pem`
19dormouse_keyid=`creddy --keyid --cert Dormouse_ID.pem`
20
[efacf92]21friendof_alice="friendOf-alice([keyid:$alice_keyid])"
[a9494ad]22friendof_marchhare="friendOf([keyid:$marchhare_keyid])"
23guestof_marchhare="guestOf([keyid:$marchhare_keyid])"
24
[669b481]25about_party="about([keyid:$tea_keyid],[time:20101010T],[boolean:true],[integer:4],[float:-200.0],[float:8],[time:20120205T182930],[string:'guest'],[urn:'file://usr/local/party/~teaparty'])"
[a9494ad]26
[9806e76]27about_other_party="about_other_party([keyid:$tea_keyid],[?],[integer:99],[time:?AAA],[integer:?BBB],[boolean:true],[integer:?])"
28
[a9494ad]29about_time="about_time([time:20201101T])"
30about_another_time="about_another_time([time:20201101T182930])"
31about_key="about_key([keyid:$tea_keyid])"
32about_boolean="about_boolean([boolean:true])"
33about_integer="about_integer([integer:4])"
34about_another_integer="about_another_integer([integer:-7])"
35about_float="about_float([float:-200.0])"
36about_another_float="about_another_float([float:8])"
37about_third_float="about_another_float([float:0.22])"
38about_urn="about_urn([urn:'file://user/local/party/~sillyparty'])"
39about_string="about_string([string:'a confused party'])"
[da5afdf]40about_string2="about_string([string:'a mangled \'string\''])"
[a9494ad]41
42
43#[keyid:Party].role:about([keyid:tea],[time:201010],[string:'guest list'],[boolean:true],[integer:4]) <- [keyid:Party].role:guestOf([keyid:MarchHare])
[0d0c3a9]44#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$about_party\" --subject-cert Party_ID.pem --subject-role  \"$guestof_marchhare\" --out party_about_party__guestof_marchhare_attr.der"
[da5afdf]45creddy --attribute \
46       --issuer Party_ID.pem --key Party_private.pem --role "$about_party" \
47       --subject-cert Party_ID.pem --subject-role  "$guestof_marchhare" \
48       --out party_about_party__guestof_marchhare_attr.der
[a9494ad]49#echo "  "
50#echo "double checking with creddy --roles -certs party_about_party__guestof_marchhare_attr.der"
51#creddy --roles --cert party_about_party__guestof_marchhare_attr.der
52
[da5afdf]53#[keyid:Party].role:about_other_party([keyid:$tea_keyid],[time:?],[boolean:true]) <- [keyid:MarchHare]
[0d0c3a9]54#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$about_other_party\" --subject-cert MarchHare_ID.pem --out party_about_other_party__marchhare_attr.der"
[da5afdf]55creddy --attribute \
56       --issuer Party_ID.pem --key Party_private.pem --role "$about_other_party" \
57       --subject-cert MarchHare_ID.pem \
58       --out party_about_other_party__marchhare_attr.der
59
[a9494ad]60#[keyid:Party].role:about_string([string:'a confused party']) <- [keyid:MarchHare]
[0d0c3a9]61#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$about_string\" --subject-cert MarchHare_ID.pem --out party_about_string__marchhare_attr.der"
[a9494ad]62creddy --attribute \
63       --issuer Party_ID.pem --key Party_private.pem --role "$about_string" \
64       --subject-cert MarchHare_ID.pem \
65       --out party_about_string__marchhare_attr.der
66
[da5afdf]67#[keyid:Party].role:about_string2([string:'a mangled \'string\'']) <- [keyid:MarchHare]
68#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$about_string2\" --subject-cert MarchHare_ID.pem --out party_about_string2__marchhare_attr.der"
69creddy --attribute \
70       --issuer Party_ID.pem --key Party_private.pem --role "$about_string2" \
71       --subject-cert MarchHare_ID.pem \
72       --out party_about_string2__marchhare_attr.der
73
[a9494ad]74#[keyid:Party].role:about_urn([urn:'file://user/local/party/~sillyparty']) <- [keyid:MarchHare]
[0d0c3a9]75#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$about_urn\" --subject-cert MarchHare_ID.pem --out party_about_urn__marchhare_attr.der"
[a9494ad]76creddy --attribute \
77       --issuer Party_ID.pem --key Party_private.pem --role "$about_urn" \
78       --subject-cert MarchHare_ID.pem \
79       --out party_about_urn__marchhare_attr.der
80
81#[keyid:Party].role:about_third_float([float:0.22]) <- [keyid:MarchHare]
[0d0c3a9]82#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$about_third_float\" --subject-cert MarchHare_ID.pem --out party_about_third_float__marchhare_attr.der"
[a9494ad]83creddy --attribute \
84       --issuer Party_ID.pem --key Party_private.pem --role "$about_third_float" \
85       --subject-cert MarchHare_ID.pem \
86       --out party_about_third_float__marchhare_attr.der
87
88#[keyid:Party].role:about_another_float([float:8]) <- [keyid:MarchHare]
[0d0c3a9]89#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$about_another_float\" --subject-cert MarchHare_ID.pem --out party_about_another_float__marchhare_attr.der"
[a9494ad]90creddy --attribute \
91       --issuer Party_ID.pem --key Party_private.pem --role "$about_another_float" \
92       --subject-cert MarchHare_ID.pem \
93       --out party_about_another_float__marchhare_attr.der
94
95#[keyid:Party].role:about_float([float:-200.0]) <- [keyid:MarchHare]
[0d0c3a9]96#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$about_float\" --subject-cert MarchHare_ID.pem --out party_about_float__marchhare_attr.der"
[a9494ad]97creddy --attribute \
98       --issuer Party_ID.pem --key Party_private.pem --role "$about_float" \
99       --subject-cert MarchHare_ID.pem \
100       --out party_about_float__marchhare_attr.der
101
102#[keyid:Party].role:about_another_integer([integer:-7]) <- [keyid:MarchHare]
[0d0c3a9]103#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$about_another_integer\" --subject-cert MarchHare_ID.pem --out party_about_another_integer__marchhare_attr.der"
[a9494ad]104creddy --attribute \
105       --issuer Party_ID.pem --key Party_private.pem --role "$about_another_integer" \
106       --subject-cert MarchHare_ID.pem \
107       --out party_about_another_nteger__marchhare_attr.der
108
109#[keyid:Party].role:about_integer([integer:4]) <- [keyid:MarchHare]
[0d0c3a9]110#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$about_integer\" --subject-cert MarchHare_ID.pem --out party_about_integer__marchhare_attr.der"
[a9494ad]111creddy --attribute \
112       --issuer Party_ID.pem --key Party_private.pem --role "$about_integer" \
113       --subject-cert MarchHare_ID.pem \
114       --out party_about_integer__marchhare_attr.der
115
116#[keyid:Party].role:about_boolean([boolean:true]) <- [keyid:MarchHare]
[0d0c3a9]117#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$about_boolean\" --subject-cert MarchHare_ID.pem --out party_about_boolean__marchhare_attr.der"
[a9494ad]118creddy --attribute \
119       --issuer Party_ID.pem --key Party_private.pem --role "$about_boolean" \
120       --subject-cert MarchHare_ID.pem \
121       --out party_about_boolean__marchhare_attr.der
122
123#[keyid:Party].role:about_key([keyid:$tea_keyid]) <- [keyid:MarchHare]
[0d0c3a9]124#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$about_key\" --subject-cert MarchHare_ID.pem --out party_about_key__marchhare_attr.der"
[a9494ad]125creddy --attribute \
126       --issuer Party_ID.pem --key Party_private.pem --role "$about_key" \
127       --subject-cert MarchHare_ID.pem \
128       --out party_about_key__marchhare_attr.der
129
130#[keyid:Party].role:about_another_time([time:20201101T182930]) <- [keyid:MarchHare]
[0d0c3a9]131#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$about_another_time\" --subject-cert MarchHare_ID.pem --out party_about_another_time__marchhare_attr.der"
[a9494ad]132creddy --attribute \
133       --issuer Party_ID.pem --key Party_private.pem --role "$about_another_time" \
134       --subject-cert MarchHare_ID.pem \
135       --out party_about_another_time__marchhare_attr.der
136
137#[keyid:Party].role:about_time([time:20201101T]) <- [keyid:MarchHare]
[0d0c3a9]138#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$about_time\" --subject-cert MarchHare_ID.pem --out party_about_time__marchhare_attr.der"
[a9494ad]139creddy --attribute \
140       --issuer Party_ID.pem --key Party_private.pem --role "$about_time" \
141       --subject-cert MarchHare_ID.pem \
142       --out party_about_time__marchhare_attr.der
143
144#[keyid:Party].role:guestof([principal:?V]) <- [keyid:Party].role:friendOf([principal:?V])
[0d0c3a9]145#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role 'guestOf([principal:?V])' --subject-cert Party_ID.pem --subject-role 'friendOf([principal:?V])' --out party_guestof_qV__party_friendof_qV_attr.der"
[a9494ad]146creddy --attribute \
147       --issuer Party_ID.pem --key Party_private.pem --role 'guestOf([principal:?V])' \
148       --subject-cert Party_ID.pem --subject-role  'friendOf([principal:?V])' \
149       --out party_guestof_qV__party_friendof_qV_attr.der
150
151#[keyid:Party].role:guests <- [keyid:Party].role:friendOf([keyid:MarchHare])
[0d0c3a9]152#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role guests --subject-cert Party_ID.pem --subject-role  \"$friendof_marchhare\" --out party_guests__party_friendof_marchhare_attr.der"
[a9494ad]153creddy --attribute \
154       --issuer Party_ID.pem --key Party_private.pem --role guests \
[da5afdf]155       --subject-cert Party_ID.pem --subject-role  "$friendof_marchhare" \
[a9494ad]156       --out party_guests__party_friendof_marchhare_attr.der
157
158#[keyid:Party].role:friendOf([keyid:MarchHare]) <- [keyid:Dormouse]
[0d0c3a9]159#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$friendof_marchhare\" --subject-cert Dormouse_ID.pem --out party_friendof_marchhare__dormouse_attr.der"
[a9494ad]160creddy --attribute \
[da5afdf]161       --issuer Party_ID.pem --key Party_private.pem --role "$friendof_marchhare" \
[a9494ad]162       --subject-cert Dormouse_ID.pem \
163       --out party_friendof_marchhare__dormouse_attr.der
164
165#[keyid:Party].role:friendOf([keyid:Alice]) <- [keyid:Hatter]
[0d0c3a9]166#echo "creddy --attribute --issuer Party_ID.pem --key Party_private.pem --role \"$friendof_alice\" --subject-cert Hatter_ID.pem --out party_friendof_alice__hatter_attr.der"
[a9494ad]167creddy --attribute \
[da5afdf]168       --issuer Party_ID.pem --key Party_private.pem --role "$friendof_alice" \
[a9494ad]169       --subject-cert Hatter_ID.pem \
170       --out party_friendof_alice__hatter_attr.der
171
172
Note: See TracBrowser for help on using the repository browser.