diff --git a/ontology/uco/observable/observable.ttl b/ontology/uco/observable/observable.ttl index bf90249b..dbffe8db 100644 --- a/ontology/uco/observable/observable.ttl +++ b/ontology/uco/observable/observable.ttl @@ -428,6 +428,14 @@ observable:Application rdfs:subClassOf observable:ObservableObject ; rdfs:label "Application"@en ; rdfs:comment "An application is a particular software program designed for end users."@en ; + rdfs:seeAlso [ + a sh:NodeShape ; + rdfs:comment "This anonymous shape is attached with rdfs:seeAlso in order to associate a warning-severity class constraint, that will only be necessary as an independent shape until UCO 2.0.0."@en ; + sh:class observable:Software ; + sh:message "In UCO 2.0.0, uco-observable:Application will be a subclass of uco-observable:Software. In preparation for UCO 2.0.0, the additional type uco-observable:Software should be assigned to this node."@en ; + sh:severity sh:Warning ; + sh:targetClass observable:Application ; + ] ; sh:targetClass observable:Application ; . @@ -865,6 +873,15 @@ observable:BrowserCookieFacet sh:targetClass observable:BrowserCookieFacet ; . +observable:BuildUtility + a + owl:Class , + sh:NodeShape + ; + rdfs:subClassOf observable:Software ; + rdfs:comment "A Build Utility is a software-based tool that automates portions or all of the process of creating executable software from source code."@en ; + . + observable:Calendar a owl:Class , @@ -1204,9 +1221,26 @@ observable:Code rdfs:subClassOf observable:ObservableObject ; rdfs:label "Code"@en ; rdfs:comment "Code is a direct representation (source, byte or binary) of a collection of computer instructions that form software which tell a computer how to work. [based on https://en.wikipedia.org/wiki/Software]"@en ; + rdfs:seeAlso [ + a sh:NodeShape ; + rdfs:comment "This anonymous shape is attached with rdfs:seeAlso in order to associate a warning-severity class constraint, that will only be necessary as an independent shape until UCO 2.0.0."@en ; + sh:class observable:Software ; + sh:message "In UCO 2.0.0, uco-observable:Code will be a subclass of uco-observable:Software. In preparation for UCO 2.0.0, the additional type uco-observable:Software should be assigned to this node."@en ; + sh:severity sh:Warning ; + sh:targetClass observable:Code ; + ] ; sh:targetClass observable:Code ; . +observable:Compiler + a + owl:Class , + sh:NodeShape + ; + rdfs:subClassOf observable:Software ; + rdfs:comment "A Compiler is a software program that translates source code written in a high-level language (e.g., C++, Python, Java) into machine code that can be understood and executed by a computer processor."@en ; + . + observable:CompressedStreamFacet a owl:Class , @@ -2216,6 +2250,15 @@ observable:DefinedEffectFacet sh:targetClass observable:DefinedEffectFacet ; . +observable:DeploymentScript + a + owl:Class , + sh:NodeShape + ; + rdfs:subClassOf observable:Script ; + rdfs:comment "A Deployment Script is a software script used to deploy artifacts, packages, modules, patches, or other resources into an intended execution environment."@en ; + . + observable:Device a owl:Class , @@ -3985,6 +4028,14 @@ observable:Library rdfs:subClassOf observable:ObservableObject ; rdfs:label "Library"@en ; rdfs:comment "A library is a suite of data and programming code that is used to develop software programs and applications. [based on https://www.techopedia.com/definition/3828/software-library]"@en ; + rdfs:seeAlso [ + a sh:NodeShape ; + rdfs:comment "This anonymous shape is attached with rdfs:seeAlso in order to associate a warning-severity class constraint, that will only be necessary as an independent shape until UCO 2.0.0."@en ; + sh:class observable:Software ; + sh:message "In UCO 2.0.0, uco-observable:Library will be a subclass of uco-observable:Software. In preparation for UCO 2.0.0, the additional type uco-observable:Software should be assigned to this node."@en ; + sh:severity sh:Warning ; + sh:targetClass observable:Library ; + ] ; sh:targetClass observable:Library ; . @@ -4005,6 +4056,26 @@ observable:LibraryFacet sh:targetClass observable:LibraryFacet ; . +observable:LinuxService + a + owl:Class , + sh:NodeShape + ; + rdfs:subClassOf observable:Service ; + rdfs:label "LinuxService"@en ; + rdfs:comment "A Linux Service (often referred to as a daemon) is a Service running within a Linux operating system, similar to the way a Windows Service runs on Windows."@en ; + sh:targetClass observable:LinuxService ; + . + +observable:LinuxTask + a + owl:Class , + sh:NodeShape + ; + rdfs:subClassOf observable:Task ; + rdfs:comment "A Linux Task is a set of software computer instructions loaded into memory with the potential to be scheduled for execution within the Linux operating system."@en ; + . + observable:MACAddress a owl:Class , @@ -5314,6 +5385,15 @@ observable:PUK rdfs:range xsd:string ; . +observable:Package + a + owl:Class , + sh:NodeShape + ; + rdfs:subClassOf observable:Software ; + rdfs:comment "A Package is a body of software consisting of a collection of individual software (programs, libraries, files, etc.) packaged together to collectively serve a broader purpose."@en ; + . + observable:PathRelationFacet a owl:Class , @@ -5398,7 +5478,15 @@ observable:Process ; rdfs:subClassOf observable:ObservableObject ; rdfs:label "Process"@en ; - rdfs:comment "A process is an instance of a computer program executed on an operating system."@en ; + rdfs:comment "A Process is an instance of a software program that is being executed within a scope having dedicated memory, address space, execution variables, code instructions, state, security info, file handles, etc. Process execution consists of one or more component threads sharing the process resources."@en ; + rdfs:seeAlso [ + a sh:NodeShape ; + rdfs:comment "This anonymous shape is attached with rdfs:seeAlso in order to associate a warning-severity class constraint, that will only be necessary as an independent shape until UCO 2.0.0."@en ; + sh:class observable:Software ; + sh:message "In UCO 2.0.0, uco-observable:Process will be a subclass of uco-observable:Software. In preparation for UCO 2.0.0, the additional type uco-observable:Software should be assigned to this node."@en ; + sh:severity sh:Warning ; + sh:targetClass observable:Process ; + ] ; sh:targetClass observable:Process ; . @@ -5493,7 +5581,15 @@ observable:ProcessThread ; rdfs:subClassOf observable:ObservableObject ; rdfs:label "ProcessThread"@en ; - rdfs:comment "A process thread is the smallest sequence of programmed instructions that can be managed independently by a scheduler on a computer, which is typically a part of the operating system. It is a component of a process. Multiple threads can exist within one process, executing concurrently and sharing resources such as memory, while different processes do not share these resources. In particular, the threads of a process share its executable code and the values of its dynamically allocated variables and non-thread-local global variables at any given time. [based on https://en.wikipedia.org/wiki/Thread_(computing)]"@en ; + rdfs:comment "A Process Thread is the smallest sequence of programmed instructions that can be managed independently by a scheduler on a computer, which is typically a part of the operating system. It is a scheduled running instantiation of one or more tasks (including CPU flags, counters, timers, stack, etc.) as a component of a process. Multiple threads can exist within one process, executing concurrently and sharing resources such as memory, while different processes do not share these resources. In particular, the threads of a process share its executable code and the values of its dynamically allocated variables and non-thread-local global variables at any given time. [based on https://en.wikipedia.org/wiki/Thread_(computing)]"@en ; + rdfs:seeAlso [ + a sh:NodeShape ; + rdfs:comment "This anonymous shape is attached with rdfs:seeAlso in order to associate a warning-severity class constraint, that will only be necessary as an independent shape until UCO 2.0.0."@en ; + sh:class observable:Software ; + sh:message "In UCO 2.0.0, uco-observable:ProcessThread will be a subclass of uco-observable:Software. In preparation for UCO 2.0.0, the additional type uco-observable:Software should be assigned to this node."@en ; + sh:severity sh:Warning ; + sh:targetClass observable:ProcessThread ; + ] ; sh:targetClass observable:ProcessThread ; . @@ -6066,6 +6162,15 @@ observable:SQLiteBlobFacet sh:targetClass observable:SQLiteBlobFacet ; . +observable:Script + a + owl:Class , + sh:NodeShape + ; + rdfs:subClassOf observable:Software ; + rdfs:comment "A Script is a software consisting of computer instructions that can be interpreted and executed in real-time (typically by an interpreter rather than directly by a computer processor) without requiring advance compilation."@en ; + . + observable:SecurityAppliance a owl:Class , @@ -6116,6 +6221,24 @@ observable:Server sh:targetClass observable:Server ; . +observable:Service + a + owl:Class , + sh:NodeShape + ; + rdfs:subClassOf observable:Process ; + rdfs:comment "A Service is a process that runs in the background rather than under the control of an interactive user. Services are typically long-running and can be configured to start when the operating system starts and continue as long as the operating system is running."@en ; + . + +observable:ServicePack + a + owl:Class , + sh:NodeShape + ; + rdfs:subClassOf observable:Software ; + rdfs:comment "A Service Pack is a software consisting of a collection of software updates or fixes (patches) for a software delivered as an aggregated single package for ease of installation."@en ; + . + observable:ShopListing a owl:Class , @@ -6197,6 +6320,15 @@ observable:Software sh:targetClass observable:Software ; . +observable:SoftwareBuild + a + owl:Class , + sh:NodeShape + ; + rdfs:subClassOf observable:Software ; + rdfs:comment "A Software Build is a particular executable version of software that has been created from source code and is ready for testing or deployment."@en ; + . + observable:SoftwareFacet a owl:Class , @@ -6479,6 +6611,15 @@ observable:Tablet sh:targetClass observable:Tablet ; . +observable:Task + a + owl:Class , + sh:NodeShape + ; + rdfs:subClassOf observable:Software ; + rdfs:comment "A Task is a set of software computer instructions loaded into memory with the potential to be scheduled for execution."@en ; + . + observable:TaskActionType a owl:Class , @@ -7795,7 +7936,7 @@ observable:WindowsComputerSpecification ; rdfs:subClassOf observable:ObservableObject ; rdfs:label "WindowsComputerSpecification"@en ; - rdfs:comment "A Windows computer specification is the hardware ans software of a programmable electronic device that can store, retrieve, and process data running a Microsoft Windows operating system. [based on merriam-webster.com/dictionary/computer]"@en ; + rdfs:comment "A Windows computer specification is the hardware and software of a programmable electronic device that can store, retrieve, and process data running a Microsoft Windows operating system. [based on merriam-webster.com/dictionary/computer]"@en ; sh:targetClass observable:WindowsComputerSpecification ; . @@ -8528,7 +8669,15 @@ observable:WindowsService ; rdfs:subClassOf observable:ObservableObject ; rdfs:label "WindowsService"@en ; - rdfs:comment "A Windows service is a specific Windows service (a computer program that operates in the background of a Windows operating system, similar to the way a UNIX daemon runs on UNIX). [based on https://en.wikipedia.org/wiki/Windows_service]"@en ; + rdfs:comment "A Windows Service is a Service running within a Windows operating system, similar to the way a UNIX daemon runs on UNIX. [based on https://en.wikipedia.org/wiki/Windows_service]"@en ; + rdfs:seeAlso [ + a sh:NodeShape ; + rdfs:comment "This anonymous shape is attached with rdfs:seeAlso in order to associate a warning-severity class constraint, that will only be necessary as an independent shape until UCO 2.0.0."@en ; + sh:class observable:Service ; + sh:message "In UCO 2.0.0, uco-observable:WindowsService will be a subclass of uco-observable:Service. In preparation for UCO 2.0.0, the additional type uco-observable:Service should be assigned to this node."@en ; + sh:severity sh:Warning ; + sh:targetClass observable:WindowsService ; + ] ; sh:targetClass observable:WindowsService ; . @@ -8653,7 +8802,15 @@ observable:WindowsTask ; rdfs:subClassOf observable:ObservableObject ; rdfs:label "WindowsTask"@en ; - rdfs:comment "A Windows task is a process that is scheduled to execute on a Windows operating system by the Windows Task Scheduler. [based on http://msdn.microsoft.com/en-us/library/windows/desktop/aa381311(v=vs.85).aspx]"@en ; + rdfs:comment "A Windows Task is a set of software computer instructions loaded into memory with the potential to be scheduled for execution within the Windows operating system."@en ; + rdfs:seeAlso [ + a sh:NodeShape ; + rdfs:comment "This anonymous shape is attached with rdfs:seeAlso in order to associate a warning-severity class constraint, that will only be necessary as an independent shape until UCO 2.0.0."@en ; + sh:class observable:Task ; + sh:message "In UCO 2.0.0, uco-observable:WindowsTask will be a subclass of uco-observable:Task. In preparation for UCO 2.0.0, the additional type uco-observable:Task should be assigned to this node."@en ; + sh:severity sh:Warning ; + sh:targetClass observable:WindowsTask ; + ] ; sh:targetClass observable:WindowsTask ; . @@ -8924,7 +9081,7 @@ observable:WindowsThread ; rdfs:subClassOf observable:ProcessThread ; rdfs:label "WindowsThread"@en ; - rdfs:comment "A Windows thread is a single thread of execution within a Windows process."@en ; + rdfs:comment "A Windows thread is a Process Thread within a Windows process."@en ; sh:targetClass observable:WindowsThread ; . diff --git a/tests/examples/observable_creation_time_PASS_validation.ttl b/tests/examples/observable_creation_time_PASS_validation.ttl index 60605c2c..d900aa5f 100644 --- a/tests/examples/observable_creation_time_PASS_validation.ttl +++ b/tests/examples/observable_creation_time_PASS_validation.ttl @@ -8,20 +8,38 @@ [] a sh:ValidationReport ; sh:conforms "true"^^xsd:boolean ; - sh:result [ - a sh:ValidationResult ; - sh:focusNode ; - sh:resultMessage "observable:creationTime is deprecated, and will be an error to use in UCO 2.0.0. observable:observableCreatedTime should be used instead."@en ; - sh:resultPath observable:creationTime ; - sh:resultSeverity sh:Warning ; - sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; - sh:sourceShape [ - a sh:PropertyShape ; - sh:maxCount "0"^^xsd:integer ; - sh:message "observable:creationTime is deprecated, and will be an error to use in UCO 2.0.0. observable:observableCreatedTime should be used instead."@en ; - sh:path observable:creationTime ; - sh:severity sh:Warning ; - ] ; - ] ; + sh:result + [ + a sh:ValidationResult ; + sh:focusNode ; + sh:resultMessage "In UCO 2.0.0, uco-observable:ProcessThread will be a subclass of uco-observable:Process. In preparation for UCO 2.0.0, the additional type uco-observable:Process should be assigned to this node."@en ; + sh:resultSeverity sh:Warning ; + sh:sourceConstraintComponent sh:ClassConstraintComponent ; + sh:sourceShape [ + a sh:NodeShape ; + rdfs:comment "This anonymous shape is attached with rdfs:seeAlso in order to associate a warning-severity class constraint, that will only be necessary as an independent shape until UCO 2.0.0."@en ; + sh:class observable:Process ; + sh:message "In UCO 2.0.0, uco-observable:ProcessThread will be a subclass of uco-observable:Process. In preparation for UCO 2.0.0, the additional type uco-observable:Process should be assigned to this node."@en ; + sh:severity sh:Warning ; + sh:targetClass observable:ProcessThread ; + ] ; + sh:value ; + ] , + [ + a sh:ValidationResult ; + sh:focusNode ; + sh:resultMessage "observable:creationTime is deprecated, and will be an error to use in UCO 2.0.0. observable:observableCreatedTime should be used instead."@en ; + sh:resultPath observable:creationTime ; + sh:resultSeverity sh:Warning ; + sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; + sh:sourceShape [ + a sh:PropertyShape ; + sh:maxCount "0"^^xsd:integer ; + sh:message "observable:creationTime is deprecated, and will be an error to use in UCO 2.0.0. observable:observableCreatedTime should be used instead."@en ; + sh:path observable:creationTime ; + sh:severity sh:Warning ; + ] ; + ] + ; . diff --git a/tests/examples/test_validation.py b/tests/examples/test_validation.py index 5bdb4a26..715158ec 100644 --- a/tests/examples/test_validation.py +++ b/tests/examples/test_validation.py @@ -455,6 +455,10 @@ def test_observable_creation_time_PASS() -> None: "observable_creation_time_PASS_validation.ttl", True, expected_focus_node_severities={ + ( + "http://example.org/kb/windows-thread-da52a01e-41cc-42d5-85be-ca14bfa10fd6", + str(NS_SH.Warning) + ), ( "http://example.org/kb/windows-thread-facet-4967ae35-f00b-49c8-9dd2-38e3bdf851e1", str(NS_SH.Warning)