You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CIP-0072/README.md
+5-352
Original file line number
Diff line number
Diff line change
@@ -89,153 +89,13 @@ The on-chain dApp registration certificate MUST follow canonical JSON and be ser
89
89
90
90
*`signature`*: The signature of the certificate. The publishers generate the signature is by first turning on-chain JSON into a canonical form (RFC 8765), hashing it with blake2b-256 and generating a signature of the hash. Stores / clients can verify the signature by repeating the process, they can use the public key to verify the signature of the certificate. Fields used for canonical JSON: ["subject", "rootHash", "metadata","type"]. Please note that a signature should be generated of blake2b-256 hash as a byte array, not as a hex represented string(!).
91
91
92
-
### Onchain CDDL for registration / de-registration
92
+
### On-chain Schemas
93
93
94
-
```
95
-
string = bstr .size (1..64) ; tstr / string from 1 up to 64 chars only
"description": "Registration of Cardano dApp claim.",
139
-
"type":"object",
140
-
"properties":{
141
-
"subject":{
142
-
"type":"string",
143
-
"minLength": 1,
144
-
"maxLength": 64,
145
-
"pattern":"^[0-9a-fA-F]{1,64}$",
146
-
"description":"Identifier of the claim subject (dApp). A UTF-8 encoded string, must be max 64 chars. Typically it is randomly generated hash by the dApp developer."
147
-
},
148
-
"rootHash":{
149
-
"type":"string",
150
-
"minLength": 64,
151
-
"maxLength": 64,
152
-
"pattern":"^[0-9a-fA-F]{64}$",
153
-
"description":"blake2b-256 hash of the metadata describing the off-chain part of the dApp."
154
-
},
155
-
"metadata": {
156
-
"type": "array",
157
-
"description": "An array of valid URLs pointing to off-chain CIP-72 compatible metadata document. If an individual URL is longer than 64 characters, it must be expressed as an array of strings (where each string may contain at most 64 characters).",
"description":"Describes the releases, if they are new or an updates.",
177
-
"properties":{
178
-
"action":{
179
-
"type":"string",
180
-
"enum":["REGISTER", "DE_REGISTER"],
181
-
"description":"Describes the action this certificate is claiming; i.e 'REGISTER', for a new dApp or an update, DE_REGISTER for asserting that the dApp's development is stopped, and it is deprecated. So, no further dApp's on-chain update is to be expected."
182
-
},
183
-
"comment": {
184
-
"type": "string",
185
-
"minLength": 1,
186
-
"maxLength": 64,
187
-
"description": "A free text field to provide details about this particular changes (64 chars limited)."
188
-
}
189
-
},
190
-
"required":[
191
-
"action"
192
-
]
193
-
},
194
-
"signature":{
195
-
"description":"Signature of the blake2b-256 hash of whole canonical (RFC 8785) JSON document (except signature property).",
196
-
"type":"object",
197
-
"properties":{
198
-
"r":{
199
-
"type":"string",
200
-
"description":"A hex representation of the R component of the signature.",
201
-
"minLength": 64,
202
-
"maxLength": 64,
203
-
"pattern":"^[0-9a-fA-F]{64}$"
204
-
},
205
-
"s":{
206
-
"type":"string",
207
-
"description":"A hex representation of the S component of the signature.",
208
-
"minLength": 64,
209
-
"maxLength": 64,
210
-
"pattern":"^[0-9a-fA-F]{64}$"
211
-
},
212
-
"algo":{
213
-
"const":"Ed25519-EdDSA"
214
-
},
215
-
"pub":{
216
-
"type":"string",
217
-
"description":"A hex representation of the public key.",
@@ -247,214 +107,7 @@ When submitting the transaction metadata pick the following value for `transacti
247
107
248
108
The dApp Registration certificate itself doesn't enforce a particular structure to the metadata you might fetch off-chain. However, we recommend that you use the following structure:
"description": "Semver compatible release number (major.minor.patch) or (major.minor.patch-some_text) e.g. 1.2.3 or 1.1.1-alpha"
339
-
},
340
-
"releaseName": {
341
-
"type": "string",
342
-
"description": "An optional human readable release name, e.g. V1"
343
-
},
344
-
"securityVulnerability": {
345
-
"type": "boolean",
346
-
"description": "Indicates that a given version has a security vulnerability."
347
-
},
348
-
"comment": {
349
-
"type": "string",
350
-
"description": "A free text field to provide comment about this particular release, e.g. new features it brings, etc."
351
-
},
352
-
"scripts": {
353
-
"type": "array",
354
-
"items": [
355
-
{
356
-
"type": "object",
357
-
"properties": {
358
-
"id": {
359
-
"type": "string"
360
-
},
361
-
"version": {
362
-
"type": "integer"
363
-
}
364
-
},
365
-
"required": [
366
-
"id",
367
-
"version"
368
-
]
369
-
}
370
-
]
371
-
}
372
-
},
373
-
"required": [
374
-
"releaseNumber"
375
-
]
376
-
}
377
-
]
378
-
},
379
-
"scripts": {
380
-
"type": "array",
381
-
"items": [
382
-
{
383
-
"type": "object",
384
-
"properties":{
385
-
"id": {
386
-
"type":"string",
387
-
"description": "Unique Script ID (across all scripts from this dApp)."
388
-
},
389
-
"name":{
390
-
"type":"string",
391
-
"description": "An optional script name usually related to it's function."
392
-
},
393
-
"purposes":{
394
-
"type":"array",
395
-
"items": {
396
-
"type": "string",
397
-
"enum":["SPEND", "MINT"]
398
-
},
399
-
"description": "Purposes of the script, SPEND or MINT (notice it can be both for some modern Cardano languages)."
400
-
},
401
-
"type":{
402
-
"enum":["PLUTUS", "NATIVE"],
403
-
"description": "Script Type. PLUTUS refers to the typical PlutusV1 or PlutusV2 scripts, where as NATIVE means there has been no Plutus directly used by this is a native script."
This schema describes the minimum required fields for a store to be able to display and validate your dApp. You can add any other fields you want to the metadata, but we recommend that you use at least the ones described above.
0 commit comments