-
Notifications
You must be signed in to change notification settings - Fork 516
/
Copy pathtaa-txn-author-acceptance.feature
250 lines (231 loc) · 13.9 KB
/
taa-txn-author-acceptance.feature
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
Feature: TAA Transaction Author Agreement related tests
# Note that these tests require a ledger with TAA enabled
# you can run von-network as `./manage start --taa-sample --logs`
@T001-TAA @taa_required
Scenario Outline: accept the ledger TAA and write to the ledger
Given we have "1" agents
| name | role | capabilities |
| Acme | issuer | <Acme_capabilities> |
And "Acme" connects to a ledger that requires acceptance of the TAA
When "Acme" accepts the TAA
Then "Acme" is ready to issue a credential for <Schema_name>
Examples:
| Acme_capabilities | Schema_name |
| --taa-accept | driverslicense |
| --taa-accept --multitenant | driverslicense |
| --taa-accept --revocation | driverslicense |
| --taa-accept --multi-ledger | driverslicense |
| --taa-accept --multitenant --multi-ledger | driverslicense |
@T001a-TAA @taa_required
Scenario Outline: accept the ledger TAA and write to the ledger via endorser
Given we have "2" agents
| name | role | capabilities |
| Acme | endorser | <Acme_capabilities> |
| Bob | author | <Bob_capabilities> |
And "Acme" connects to a ledger that requires acceptance of the TAA
And "Bob" connects to a ledger that requires acceptance of the TAA
And "Acme" and "Bob" have an existing connection
When "Acme" accepts the TAA
And "Bob" accepts the TAA
And "Acme" has a DID with role "ENDORSER"
And "Acme" connection has job role "TRANSACTION_ENDORSER"
And "Bob" connection has job role "TRANSACTION_AUTHOR"
And "Bob" connection sets endorser info
And "Bob" has a DID with role "AUTHOR"
And "Bob" authors a schema transaction with <Schema_name>
And "Bob" requests endorsement for the transaction
And "Acme" endorses the transaction
Then "Bob" can write the transaction to the ledger
And "Bob" has written the schema <Schema_name> to the ledger
Examples:
| Acme_capabilities | Bob_capabilities | Schema_name |
| --taa-accept | --taa-accept | driverslicense |
| --taa-accept --multitenant | --taa-accept --multitenant | driverslicense |
@T002-TAA @taa_required
Scenario Outline: Revoke credential using a ledger with TAA required
Given we have "2" agents
| name | role | capabilities |
| Faber | verifier | <Acme_capabilities> |
| Bob | prover | <Bob_capabilities> |
And "Faber" connects to a ledger that requires acceptance of the TAA
And "Faber" accepts the TAA
And "Faber" and "Bob" have an existing connection
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
When "Faber" sends a request for proof presentation <Proof_request> to "Bob"
Then "Faber" has the proof verification fail
Examples:
| issuer | Acme_capabilities | Bob_capabilities | Schema_name | Credential_data | Proof_request |
| Faber | --taa-accept --revocation --public-did | | driverslicense_v2 | Data_DL_MaxValues | DL_age_over_19_v2 |
@T003-TAA @taa_required
Scenario Outline: Fail to publish revoked credential using a ledger with TAA required, and fix the ledger
Given we have "2" agents
| name | role | capabilities |
| Faber | verifier | <Acme_capabilities> |
| Bob | prover | <Bob_capabilities> |
And "Faber" connects to a ledger that requires acceptance of the TAA
And "Faber" accepts the TAA
And "Faber" and "Bob" have an existing connection
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
When "Faber" rejects the TAA
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
Then "Faber" accepts the TAA
And "Faber" posts a revocation correction to the ledger
And "Faber" successfully revoked the credential
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
Examples:
| issuer | Acme_capabilities | Bob_capabilities | Schema_name | Credential_data | Proof_request |
| Faber | --taa-accept --revocation --public-did | | driverslicense_v2 | Data_DL_MaxValues | DL_age_over_19_v2 |
@T004-TAA @taa_required
Scenario Outline: Fail to publish revoked credential using a ledger with TAA required, and fix the ledger authomatically with the next revoked credential
Given we have "2" agents
| name | role | capabilities |
| Faber | verifier | <Acme_capabilities> |
| Bob | prover | <Bob_capabilities> |
And "Faber" connects to a ledger that requires acceptance of the TAA
And "Faber" accepts the TAA
And "Faber" and "Bob" have an existing connection
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
When "Faber" rejects the TAA
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
And "Faber" accepts the TAA
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
Examples:
| issuer | Acme_capabilities | Bob_capabilities | Schema_name | Credential_data | Proof_request |
| Faber | --taa-accept --revocation --public-did | | driverslicense_v2 | Data_DL_MaxValues | DL_age_over_19_v2 |
@T004.0-TAA @taa_required
Scenario Outline: Fail to publish revoked credential using a ledger with TAA required, and fix the ledger manually before revoking more credentials
Given we have "2" agents
| name | role | capabilities |
| Faber | verifier | <Acme_capabilities> |
| Bob | prover | <Bob_capabilities> |
And "Faber" connects to a ledger that requires acceptance of the TAA
And "Faber" accepts the TAA
And "Faber" and "Bob" have an existing connection
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
When "Faber" rejects the TAA
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
And "Faber" accepts the TAA
Then "Faber" posts a revocation correction to the ledger
And "Faber" successfully revoked the credential
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
Examples:
| issuer | Acme_capabilities | Bob_capabilities | Schema_name | Credential_data | Proof_request |
| Faber | --taa-accept --revocation --public-did | | driverslicense_v2 | Data_DL_MaxValues | DL_age_over_19_v2 |
@T004.1-TAA @taa_required
Scenario Outline: Fail to publish revoked credential using a ledger with TAA required, and fix the ledger by manually applying a correction
Given we have "2" agents
| name | role | capabilities |
| Faber | verifier | <Acme_capabilities> |
| Bob | prover | <Bob_capabilities> |
And "Faber" connects to a ledger that requires acceptance of the TAA
And "Faber" accepts the TAA
And "Faber" and "Bob" have an existing connection
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
When "Faber" rejects the TAA
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
And "Faber" accepts the TAA
Then "Faber" posts a revocation correction to the ledger
And "Faber" successfully revoked the credential
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
Examples:
| issuer | Acme_capabilities | Bob_capabilities | Schema_name | Credential_data | Proof_request |
| Faber | --taa-accept --revocation --public-did | | driverslicense_v2 | Data_DL_MaxValues | DL_age_over_19_v2 |
@T004.2-TAA @taa_required
Scenario Outline: Fail to publish revoked credential using a ledger with TAA required, and fix the ledger automatically with the next revocation
Given we have "2" agents
| name | role | capabilities |
| Faber | verifier | <Acme_capabilities> |
| Bob | prover | <Bob_capabilities> |
And "Faber" connects to a ledger that requires acceptance of the TAA
And "Faber" accepts the TAA
And "Faber" and "Bob" have an existing connection
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
When "Faber" rejects the TAA
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
And "Faber" accepts the TAA
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
Examples:
| issuer | Acme_capabilities | Bob_capabilities | Schema_name | Credential_data | Proof_request |
| Faber | --taa-accept --revocation --public-did | | driverslicense_v2 | Data_DL_MaxValues | DL_age_over_19_v2 |
@T004.5-TAA @taa_required
Scenario Outline: Fail to publish revoked credential using a ledger with TAA required, and fix the ledger authomatically by revoking the last credential
Given we have "2" agents
| name | role | capabilities |
| Faber | verifier | <Acme_capabilities> |
| Bob | prover | <Bob_capabilities> |
And "Faber" connects to a ledger that requires acceptance of the TAA
And "Faber" accepts the TAA
And "Faber" and "Bob" have an existing connection
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
When "Faber" rejects the TAA
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
And "Faber" accepts the TAA
And "Faber" attempts to revoke the credential
And "Faber" fails to publish the credential revocation
And "Bob" has an issued <Schema_name> credential <Credential_data> from "<issuer>"
And "Faber" revokes the credential
And "Faber" successfully revoked the credential
Examples:
| issuer | Acme_capabilities | Bob_capabilities | Schema_name | Credential_data | Proof_request |
| Faber | --taa-accept --revocation --public-did | | driverslicense_v2 | Data_DL_MaxValues | DL_age_over_19_v2 |