From a6267d51e267ba205a54f3211880047c5a574526 Mon Sep 17 00:00:00 2001 From: Ryan Williams <44342099+Ryun1@users.noreply.github.com> Date: Mon, 22 Jan 2024 15:04:52 +0000 Subject: [PATCH] CIP-0100 | Small clean up on example files (#736) * small clean up on example files * change hashing algo used in examples * align hashing algo through example files * changed links from to github * update example hash in readme --- CIP-0100/README.md | 2 +- CIP-0100/cip-0100.common.jsonld | 33 ++++++++++++------------- CIP-0100/cip-0100.common.schema.json | 2 +- CIP-0100/example.body.canonical | 18 +++++++------- CIP-0100/example.canonical | 18 +++++++------- CIP-0100/example.json | 37 ++++++++++++++-------------- 6 files changed, 54 insertions(+), 56 deletions(-) diff --git a/CIP-0100/README.md b/CIP-0100/README.md index 64d4c9b578..0830a24944 100644 --- a/CIP-0100/README.md +++ b/CIP-0100/README.md @@ -273,7 +273,7 @@ An example document with an inline context is provided in [this](./example.json) Canonicalization should produce the following blak2b-256 hash: -34cbb91e044cbd1dbda9e5aa542a74e712d23d0bf151c436c52920dcac03629c +`6ea05c0e97b1b7316d48b5587a9e60d47c0c44993c8609c9544d88c111814819` ## Path to Active diff --git a/CIP-0100/cip-0100.common.jsonld b/CIP-0100/cip-0100.common.jsonld index 9316379229..4c11457f8b 100644 --- a/CIP-0100/cip-0100.common.jsonld +++ b/CIP-0100/cip-0100.common.jsonld @@ -1,42 +1,41 @@ { "@context": { - "Proposal": "https://cips.cardano.org/cip/CIP-0100#Proposal", - "hashAlgorithm": "https://cips.cardano.org/cip/CIP-0100#hashAlgorithm", + "hashAlgorithm": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#hashAlgorithm", "body": { - "@id": "https://cips.cardano.org/cip/CIP-0100#body", + "@id": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#body", "@context": { "references": { - "@id": "https://cips.cardano.org/cip/CIP-0100#references", + "@id": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#references", "@container": "@set", "@context": { - "GovernanceMetadata": "https://cips.cardano.org/cip/CIP-0100#GovernanceMetadataReference", - "Other": "https://cips.cardano.org/cip/CIP-0100#OtherReference", - "label": "https://cips.cardano.org/cip/CIP-0100#reference-label", - "uri": "https://cips.cardano.org/cip/CIP-0100#reference-uri" + "governanceMetadata": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#GovernanceMetadataReference", + "other": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#OtherReference", + "label": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#reference-label", + "uri": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#reference-uri" } }, - "comment": "https://cips.cardano.org/cip/CIP-0100#comment", + "comment": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#comment", "externalUpdates": { - "@id": "https://cips.cardano.org/cip/CIP-0100#externalUpdates", + "@id": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#externalUpdates", "@context": { - "title": "https://cips.cardano.org/cip/CIP-0100#update-title", - "uri": "https://cips.cardano.org/cip/CIP-0100#update-uri" + "title": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#update-title", + "uri": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#update-uri" } } } }, "authors": { - "@id": "https://cips.cardano.org/cip/CIP-0100#authors", + "@id": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#authors", "@container": "@set", "@context": { "did": "@id", "name": "http://xmlns.com/foaf/0.1/name", "witness": { - "@id": "https://cips.cardano.org/cip/CIP-0100#witness", + "@id": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#witness", "@context": { - "witnessAlgorithm": "https://cips.cardano.org/cip/CIP-0100#witnessAlgorithm", - "publicKey": "https://cips.cardano.org/cip/CIP-0100#publicKey", - "signature": "https://cips.cardano.org/cip/CIP-0100#signature" + "witnessAlgorithm": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#witnessAlgorithm", + "publicKey": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#publicKey", + "signature": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#signature" } } } diff --git a/CIP-0100/cip-0100.common.schema.json b/CIP-0100/cip-0100.common.schema.json index 8cc15369ed..40af004169 100644 --- a/CIP-0100/cip-0100.common.schema.json +++ b/CIP-0100/cip-0100.common.schema.json @@ -29,7 +29,7 @@ "description": "The hash algorithm used to authenticate this document externally", "type": "string", "enum": [ - "blake2b-224" + "blake2b-256" ] }, "Author": { diff --git a/CIP-0100/example.body.canonical b/CIP-0100/example.body.canonical index fda1165f35..89bd675e0b 100644 --- a/CIP-0100/example.body.canonical +++ b/CIP-0100/example.body.canonical @@ -1,9 +1,9 @@ -_:c14n0 "Blog"@en-us . -_:c14n0 "https://314pool.com"@en-us . -_:c14n2 _:c14n5 . -_:c14n3 . -_:c14n3 "CIP-100"@en-us . -_:c14n3 "https://cips.cardano.org/cip/CIP-0100"@en-us . -_:c14n5 "This is a test vector for CIP-100"@en-us . -_:c14n5 _:c14n0 . -_:c14n5 _:c14n3 . +_:c14n0 "Blog"@en-us . +_:c14n0 "https://314pool.com"@en-us . +_:c14n2 _:c14n5 . +_:c14n3 . +_:c14n3 "CIP-100"@en-us . +_:c14n3 "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md"@en-us . +_:c14n5 "This is a test vector for CIP-100"@en-us . +_:c14n5 _:c14n0 . +_:c14n5 _:c14n3 . diff --git a/CIP-0100/example.canonical b/CIP-0100/example.canonical index f0f95ac811..a2d1de9c84 100644 --- a/CIP-0100/example.canonical +++ b/CIP-0100/example.canonical @@ -1,10 +1,10 @@ -_:c14n0 "Blog"@en-us . -_:c14n0 "https://314pool.com"@en-us . -_:c14n2 _:c14n5 . -_:c14n3 . -_:c14n3 "CIP-100"@en-us . -_:c14n3 "https://cips.cardano.org/cip/CIP-0100"@en-us . +_:c14n0 "Blog"@en-us . +_:c14n0 "https://314pool.com"@en-us . +_:c14n2 _:c14n5 . +_:c14n3 . +_:c14n3 "CIP-100"@en-us . +_:c14n3 "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md"@en-us . _:c14n4 "Pi Lanningham"@en-us . -_:c14n5 "This is a test vector for CIP-100"@en-us . -_:c14n5 _:c14n0 . -_:c14n5 _:c14n3 . +_:c14n5 "This is a test vector for CIP-100"@en-us . +_:c14n5 _:c14n0 . +_:c14n5 _:c14n3 . diff --git a/CIP-0100/example.json b/CIP-0100/example.json index d0add95a6d..0af613616b 100644 --- a/CIP-0100/example.json +++ b/CIP-0100/example.json @@ -1,55 +1,54 @@ { "@context": { "@language": "en-us", - "Proposal": "https://cips.cardano.org/cip/CIP-0100#Proposal", - "hashAlgorithm": "https://cips.cardano.org/cip/CIP-0100#hashAlgorithm", + "hashAlgorithm": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#hashAlgorithm", "body": { - "@id": "https://cips.cardano.org/cip/CIP-0100#body", + "@id": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#body", "@context": { "references": { - "@id": "https://cips.cardano.org/cip/CIP-0100#references", + "@id": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#references", "@container": "@set", "@context": { - "GovernanceMetadata": "https://cips.cardano.org/cip/CIP-0100#GovernanceMetadataReference", - "Other": "https://cips.cardano.org/cip/CIP-0100#OtherReference", - "label": "https://cips.cardano.org/cip/CIP-0100#reference-label", - "uri": "https://cips.cardano.org/cip/CIP-0100#reference-uri" + "governanceMetadata": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#GovernanceMetadataReference", + "other": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#OtherReference", + "label": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#reference-label", + "uri": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#reference-uri" } }, - "comment": "https://cips.cardano.org/cip/CIP-0100#comment", + "comment": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#comment", "externalUpdates": { - "@id": "https://cips.cardano.org/cip/CIP-0100#externalUpdates", + "@id": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#externalUpdates", "@context": { - "title": "https://cips.cardano.org/cip/CIP-0100#update-title", - "uri": "https://cips.cardano.org/cip/CIP-0100#update-uri" + "title": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#update-title", + "uri": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#update-uri" } } } }, "authors": { - "@id": "https://cips.cardano.org/cip/CIP-0100#authors", + "@id": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#authors", "@container": "@set", "@context": { "did": "@id", "name": "http://xmlns.com/foaf/0.1/name", "witness": { - "@id": "https://cips.cardano.org/cip/CIP-0100#witness", + "@id": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#witness", "@context": { - "witnessAlgorithm": "https://cips.cardano.org/cip/CIP-0100#witnessAlgorithm", - "publicKey": "https://cips.cardano.org/cip/CIP-0100#publicKey", - "signature": "https://cips.cardano.org/cip/CIP-0100#signature" + "witnessAlgorithm": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#witnessAlgorithm", + "publicKey": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#publicKey", + "signature": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md#signature" } } } } }, - "hashAlgorithm": "blake2b-224", + "hashAlgorithm": "blake2b-256", "authors": [ { "name": "Pi Lanningham", "witness": { "witnessAlgorithm": "ed25519", "publicKey": "46e4db7f87497ba232977ccd591b3d040316b155e8c60e3ea49176c03fa269de", "signature": "abcd"}} ], "body": { "references": [ - { "@type": "Other", "label": "CIP-100", "uri": "https://cips.cardano.org/cip/CIP-0100" } + { "@type": "other", "label": "CIP-100", "uri": "https://github.com/cardano-foundation/CIPs/blob/master/CIP-0100/README.md" } ], "comment": "This is a test vector for CIP-100", "externalUpdates": [