Ontology Version: 2.2.0

cacontology-forensics:ChainOfCustodyTemporalOrderingShape leaf node


URI

https://cacontology.projectvic.org/forensics#ChainOfCustodyTemporalOrderingShape

Label

ChainOfCustodyTemporalOrderingShape

Shape Properties

Instances of cacontology-forensics:ChainOfCustodyAction can have the following properties:

PROPERTY

MIN COUNT

MAX COUNT

TYPE

cacontology-forensics:ChainOfCustodyAction
1 xsd:string
cacontology-forensics:custodyReason 1 1 xsd:string
cacontology-forensics:custodyTransferredFrom 1 1 uco-core:UcoObject
cacontology-forensics:custodyTransferredTo 1 1 uco-core:UcoObject
1 1 xsd:dateTimeStamp
1 xsd:dateTimeStamp
1 1 xsd:dateTime

Implementation

@prefix cacontology-forensics: <https://cacontology.projectvic.org/forensics#> .
@prefix sh: <http://www.w3.org/ns/shacl#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
cacontology-forensics:ChainOfCustodyTemporalOrderingShape a sh:NodeShape ;
    sh:sparql [ sh:message "Chain of custody actions must maintain temporal ordering (gUFO temporal succession)"@en ;
            sh:prefixes [ sh:declare [ sh:namespace "https://cacontology.projectvic.org/forensics#"^^xsd:anyURI ;
                            sh:prefix "cacontology-forensics" ],
                        [ sh:namespace "https://ontology.unifiedcyberontology.org/uco/core/"^^xsd:anyURI ;
                            sh:prefix "uco-core" ] ] ;
            sh:select """
            SELECT $this
            WHERE {
                $this uco-core:startTime ?thisTime .
                ?previousAction uco-core:endTime ?previousTime .
                ?previousAction cacontology-forensics:custodyTransferredTo ?transferee .
                $this cacontology-forensics:custodyTransferredFrom ?transferee .
                FILTER (?thisTime < ?previousTime)
            }
        """ ] ;
    sh:targetClass cacontology-forensics:ChainOfCustodyAction .