Skip to content

Commit 678a3ba

Browse files
committed
Add Settings ref and cleanup
1 parent 8fd3cb9 commit 678a3ba

File tree

10 files changed

+4837
-142
lines changed

10 files changed

+4837
-142
lines changed

_data/Builder.schema.json

Lines changed: 1534 additions & 0 deletions
Large diffs are not rendered by default.

_data/ManifestDefinition.schema.json

Lines changed: 1295 additions & 0 deletions
Large diffs are not rendered by default.

_data/ManifestDefinition_schema.json

Lines changed: 173 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"default": [
1818
{
1919
"name": "c2pa-rs",
20-
"version": "0.49.5"
20+
"version": "0.64.0"
2121
}
2222
],
2323
"type": "array",
@@ -26,7 +26,7 @@
2626
}
2727
},
2828
"claim_version": {
29-
"description": "The version of the claim. Defaults to 1.",
29+
"description": "The version of the claim. Defaults to 2.",
3030
"type": [
3131
"integer",
3232
"null"
@@ -49,7 +49,7 @@
4949
},
5050
"instance_id": {
5151
"description": "Instance ID from `xmpMM:InstanceID` in XMP metadata.",
52-
"default": "xmp:iid:dde3986c-d7b2-4256-b5dd-acc8ed9aada3",
52+
"default": "xmp:iid:f8f5adf0-f9ee-4168-8f62-520d718bf08f",
5353
"type": "string"
5454
},
5555
"label": {
@@ -66,7 +66,7 @@
6666
"null"
6767
],
6868
"items": {
69-
"$ref": "#/definitions/Metadata"
69+
"$ref": "#/definitions/AssertionMetadata"
7070
}
7171
},
7272
"redactions": {
@@ -146,11 +146,91 @@
146146
"data": {
147147
"$ref": "#/definitions/AssertionData"
148148
},
149+
"kind": {
150+
"anyOf": [
151+
{
152+
"$ref": "#/definitions/ManifestAssertionKind"
153+
},
154+
{
155+
"type": "null"
156+
}
157+
]
158+
},
149159
"label": {
150160
"type": "string"
151161
}
152162
}
153163
},
164+
"AssertionMetadata": {
165+
"description": "The AssertionMetadata structure can be used as part of other assertions or on its own to reference others",
166+
"type": "object",
167+
"properties": {
168+
"dataSource": {
169+
"anyOf": [
170+
{
171+
"$ref": "#/definitions/DataSource"
172+
},
173+
{
174+
"type": "null"
175+
}
176+
]
177+
},
178+
"dateTime": {
179+
"anyOf": [
180+
{
181+
"$ref": "#/definitions/DateT"
182+
},
183+
{
184+
"type": "null"
185+
}
186+
]
187+
},
188+
"localizations": {
189+
"type": [
190+
"array",
191+
"null"
192+
],
193+
"items": {
194+
"type": "object",
195+
"additionalProperties": {
196+
"type": "object",
197+
"additionalProperties": {
198+
"type": "string"
199+
}
200+
}
201+
}
202+
},
203+
"reference": {
204+
"anyOf": [
205+
{
206+
"$ref": "#/definitions/HashedUri"
207+
},
208+
{
209+
"type": "null"
210+
}
211+
]
212+
},
213+
"regionOfInterest": {
214+
"anyOf": [
215+
{
216+
"$ref": "#/definitions/RegionOfInterest"
217+
},
218+
{
219+
"type": "null"
220+
}
221+
]
222+
},
223+
"reviewRatings": {
224+
"type": [
225+
"array",
226+
"null"
227+
],
228+
"items": {
229+
"$ref": "#/definitions/ReviewRating"
230+
}
231+
}
232+
}
233+
},
154234
"AssetType": {
155235
"type": "object",
156236
"required": [
@@ -257,6 +337,9 @@
257337
}
258338
}
259339
},
340+
"DateT": {
341+
"type": "string"
342+
},
260343
"Frame": {
261344
"description": "A frame range representing starting and ending frames or pages.\n\nIf both `start` and `end` are missing, the frame will span the entire asset.",
262345
"type": "object",
@@ -405,13 +488,22 @@
405488
"description": "Any additional [`Metadata`] as defined in the C2PA spec.\n\n[`Metadata`]: crate::Metadata",
406489
"anyOf": [
407490
{
408-
"$ref": "#/definitions/Metadata"
491+
"$ref": "#/definitions/AssertionMetadata"
409492
},
410493
{
411494
"type": "null"
412495
}
413496
]
414497
},
498+
"ocsp_responses": {
499+
"type": [
500+
"array",
501+
"null"
502+
],
503+
"items": {
504+
"$ref": "#/definitions/ResourceRef"
505+
}
506+
},
415507
"provenance": {
416508
"description": "URI from `dcterms:provenance` in XMP metadata.",
417509
"type": [
@@ -428,6 +520,14 @@
428520
}
429521
]
430522
},
523+
"resources": {
524+
"readOnly": true,
525+
"allOf": [
526+
{
527+
"$ref": "#/definitions/ResourceStore"
528+
}
529+
]
530+
},
431531
"thumbnail": {
432532
"description": "A thumbnail image capturing the visual state at the time of import.\n\nA tuple of thumbnail MIME format (for example `image/jpeg`) and binary bits of the image.",
433533
"anyOf": [
@@ -509,61 +609,15 @@
509609
}
510610
}
511611
},
512-
"Metadata": {
513-
"description": "The Metadata structure can be used as part of other assertions or on its own to reference others",
514-
"type": "object",
515-
"properties": {
516-
"dataSource": {
517-
"anyOf": [
518-
{
519-
"$ref": "#/definitions/DataSource"
520-
},
521-
{
522-
"type": "null"
523-
}
524-
]
525-
},
526-
"dateTime": {
527-
"anyOf": [
528-
{
529-
"type": "string"
530-
},
531-
{
532-
"type": "null"
533-
}
534-
]
535-
},
536-
"reference": {
537-
"anyOf": [
538-
{
539-
"$ref": "#/definitions/HashedUri"
540-
},
541-
{
542-
"type": "null"
543-
}
544-
]
545-
},
546-
"regionOfInterest": {
547-
"anyOf": [
548-
{
549-
"$ref": "#/definitions/RegionOfInterest"
550-
},
551-
{
552-
"type": "null"
553-
}
554-
]
555-
},
556-
"reviewRatings": {
557-
"type": [
558-
"array",
559-
"null"
560-
],
561-
"items": {
562-
"$ref": "#/definitions/ReviewRating"
563-
}
564-
}
565-
},
566-
"additionalProperties": true
612+
"ManifestAssertionKind": {
613+
"description": "Assertions in C2PA can be stored in several formats",
614+
"type": "string",
615+
"enum": [
616+
"Cbor",
617+
"Json",
618+
"Binary",
619+
"Uri"
620+
]
567621
},
568622
"Range": {
569623
"description": "A spatial, temporal, frame, or textual range describing the region of interest.",
@@ -678,7 +732,7 @@
678732
]
679733
},
680734
"RegionOfInterest": {
681-
"description": "A region of interest within an asset describing the change.\n\nThis struct can be used from [`Action::changes`][crate::assertions::Action::changes] or [`Metadata::region_of_interest`][crate::assertions::Metadata::region_of_interest].",
735+
"description": "A region of interest within an asset describing the change.\n\nThis struct can be used from [`Action::changes`][crate::assertions::Action::changes], [`AssertionMetadata::region_of_interest`][crate::assertions::AssertionMetadata::region_of_interest], or [`SoftBindingScope::region`][crate::assertions::soft_binding::SoftBindingScope::region].",
682736
"type": "object",
683737
"required": [
684738
"region"
@@ -702,7 +756,7 @@
702756
"description": "Additional information about the asset.",
703757
"anyOf": [
704758
{
705-
"$ref": "#/definitions/Metadata"
759+
"$ref": "#/definitions/AssertionMetadata"
706760
},
707761
{
708762
"type": "null"
@@ -744,11 +798,29 @@
744798
}
745799
},
746800
"Relationship": {
747-
"type": "string",
748-
"enum": [
749-
"parentOf",
750-
"componentOf",
751-
"inputTo"
801+
"description": "The relationship of the ingredient to the current asset.",
802+
"oneOf": [
803+
{
804+
"description": "The current asset is derived from this ingredient.",
805+
"type": "string",
806+
"enum": [
807+
"parentOf"
808+
]
809+
},
810+
{
811+
"description": "The current asset is a part of this ingredient.",
812+
"type": "string",
813+
"enum": [
814+
"componentOf"
815+
]
816+
},
817+
{
818+
"description": "The ingredient was used as an input to a computational process to create or modify the asset.",
819+
"type": "string",
820+
"enum": [
821+
"inputTo"
822+
]
823+
}
752824
]
753825
},
754826
"ResourceRef": {
@@ -793,8 +865,40 @@
793865
}
794866
}
795867
},
868+
"ResourceStore": {
869+
"description": "Resource store to contain binary objects referenced from JSON serializable structures",
870+
"type": "object",
871+
"required": [
872+
"resources"
873+
],
874+
"properties": {
875+
"base_path": {
876+
"type": [
877+
"string",
878+
"null"
879+
]
880+
},
881+
"label": {
882+
"type": [
883+
"string",
884+
"null"
885+
]
886+
},
887+
"resources": {
888+
"type": "object",
889+
"additionalProperties": {
890+
"type": "array",
891+
"items": {
892+
"type": "integer",
893+
"format": "uint8",
894+
"minimum": 0.0
895+
}
896+
}
897+
}
898+
}
899+
},
796900
"ReviewRating": {
797-
"description": "A rating on an Assertion.\n\nSee <https://c2pa.org/specifications/specifications/1.0/specs/C2PA_Specification.html#_claim_review>.",
901+
"description": "A rating on an Assertion.\n\nSee <https://c2pa.org/specifications/specifications/2.2/specs/C2PA_Specification.html#_review_ratings>.",
798902
"type": "object",
799903
"required": [
800904
"explanation",
@@ -1177,7 +1281,7 @@
11771281
}
11781282
},
11791283
"ValidationStatus": {
1180-
"description": "A `ValidationStatus` struct describes the validation status of a specific part of a manifest.\n\nSee <https://c2pa.org/specifications/specifications/1.0/specs/C2PA_Specification.html#_existing_manifests>.",
1284+
"description": "A `ValidationStatus` struct describes the validation status of a specific part of a manifest.\n\nSee <https://c2pa.org/specifications/specifications/2.2/specs/C2PA_Specification.html#_existing_manifests>.",
11811285
"type": "object",
11821286
"required": [
11831287
"code"

0 commit comments

Comments
 (0)