Skip to content

Commit 61ce379

Browse files
authored
Refine/eves 003 (#29)
* add review remarks regarding database synchronization * clarify linked assets --------- Signed-off-by: jdsika <carlo.van-driesten@vdl.digital>
1 parent 6debfd9 commit 61ce379

2 files changed

Lines changed: 19 additions & 9 deletions

File tree

EVES/EVES-003/eves-003.md

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,10 @@ The following process is implemented in the [ENVITED-X Data Space][12] portal de
8383
- Validate the `domainMetadata.json`:
8484
1. Extract SHACL constraints from the `domainMetadata.json` context.
8585
2. Validate JSON structure against domain-specific SHACLs.
86+
- Validate if items in `hasReferencedArtifacts` are available:
87+
1. Check if access role is `isPublic`, OPTIONALLY check if filePath resolves.
88+
2. Check if access role is `isOwner` or `isRegistered` and if `@id` of asset is known in the database.
89+
3. It is RECOMMENDED to warn the user if references do not exist.
8690

8791
#### Step 2: Upload Asset to ENVITED-X Data Space
8892

@@ -93,7 +97,8 @@ The following process is implemented in the [ENVITED-X Data Space][12] portal de
9397
- Store `isPublic` metadata at `https://ipfs.envited-x.net/Asset-CID/Data-CID`.
9498
- Calculate CIDs for all `isPublic` data.
9599
- Create `tzip21_manifest.json` by replacing relative paths in `manifest_reference.json` with IPFS/envited-x.net URLs.
96-
- Replace `@id` from `manifest_reference.json` with generated UUID in `tzip21_manifest.json`.
100+
- Replace the paths of items in `hasReferencedArtifacts` to the correct filePaths.
101+
- Replace `@id` from `manifest_reference.json` with generated database `UUID` in `tzip21_manifest.json`.
97102
- Create `tzip21_token_metadata.json` and map the metadata fields OPTIONALLY use an application/ld+json conform to the [tzip21 ontology][19].
98103

99104
#### Step 3: Preview Data
@@ -113,10 +118,14 @@ The following process is implemented in the [ENVITED-X Data Space][12] portal de
113118
#### Step 5: Listener and Database Synchronization
114119

115120
- Use a listener to detect mint events and synchronize data with the ENVITED-X Data Space portal database.
116-
- Verify that data referenced in the token metadata is the same as stored in Step 2).
117-
- If asset is not yet in DB then mark it as foreign asset and add the `publisher` information to the DB.
118-
- Verify the asset in reverse order as in step 1).
119-
- Only public information of assets can be verified if uploaded through another application than ENVITED-X.
121+
- A data space like the ENVITED-X Data Space MUST check if the asset was uploaded through its respective portal:
122+
- `UUID` from step 2) has an entry in the database.
123+
- Confirm that `contract` + `CID` and `minter` of tzip21_token_metadata.json are the same as in the database.
124+
- Confirm that the entries `UUID` and `@id` of the asset are unique.
125+
- OPTIONALLY check if the EIP-712 signature of the tzip21_token_metadata.json matches the user who initiated the mint (SHALL only be known to the respective portal).
126+
- If the asset is not yet in DB OPTIONALLY mark it as foreign asset and add the `publisher` information to the DB.
127+
- It is RECOMMENDED to verify the asset in reverse order as in step 1).
128+
- Only public information of assets can be verified if uploaded through another portal than ENVITED-X data space.
120129

121130
### 5. Database Synchronization
122131

@@ -127,6 +136,7 @@ The following process is implemented in the [ENVITED-X Data Space][12] portal de
127136
- The CIDs MAY be signed by the user according to EIP-712.
128137
- A UUID MUST be generated for the `tzip21_manifest.json` pre-mint to link the asset with the ENVITED-X database securely.
129138
- The DID of the member associated with the user minting the asset MUST be known.
139+
- DID of the user minting the asset SHALL be stored pre-mint in the database.
130140

131141
#### Pre-Mint Information
132142

@@ -155,10 +165,10 @@ Examples are the first five tags or "publishers", which is always ENVITED-X and
155165
| "name" | envited-x:DataResource:gx:name | |
156166
| "description" | envited-x:DataResource:gx:description | |
157167
| "tags" | $TAG = format:formatType + " " + format:version | "tags": ["GaiaX","ASCS","ENVITED-X","EVES","nft", "$TAG"] |
158-
| "minter" | Member DID associated with user initiating the mint | Returned by the View from the DEMIM revocation registry |
168+
| "minter" | Member DID (CAIP-10) associated with user | Returned by the View from the DEMIM revocation registry |
159169
| "creators" | Name of the company | Taken from the company profile the user belongs to |
160-
| "date" | [System date-time][14] | |
161-
| "rights" | manifest:hasLicense:gx:license | [SPDX identifier][15] |
170+
| "date" | [System date-time][14] | |
171+
| "rights" | manifest:hasLicense:gx:license | [SPDX identifier][15] |
162172
| "rightsUri" | manifest:hasLicense:licenseData:hasFileMetadata:filePath | Full os license text URL OR policy smart contract did |
163173
| "artifactUri" | <https://assets.envited-x.net/Asset-CID> | |
164174
| "identifier" | Simulation Asset @id | Unique identifier from the domainMetadata.json |

EVES/EVES-003/example/tzip21_token_metadata.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
"nft",
1212
"ASAM OpenDRIVE 1.6"
1313
],
14-
"minter": "tz1cZaiTjNSN7x4VZjTQGYBVz4p8eEcVcYkz",
14+
"minter": "did:pkh:tezos:NetXnHfVqm9iesp:tz1cZaiTjNSN7x4VZjTQGYBVz4p8eEcVcYkz",
1515
"creators": [
1616
"Automotive Solution Center for Simulation e.V."
1717
],

0 commit comments

Comments
 (0)