Skip to content

Commit

Permalink
Revert "Warn of coming constraints on observable:cpeid"
Browse files Browse the repository at this point in the history
This reverts commit 0377992.

The effects of Issue 626 are not ready for Issue 624.  This patch's
effects will move into 626's development.

References:
* #626

Signed-off-by: Alex Nelson <[email protected]>
  • Loading branch information
ajnelson-nist committed Nov 22, 2024
1 parent 0377992 commit 50ce7ee
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 124 deletions.
27 changes: 0 additions & 27 deletions ontology/uco/observable/observable.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -2265,12 +2265,6 @@ observable:DeviceFacet
sh:maxCount "1"^^xsd:integer ;
sh:nodeKind sh:Literal ;
sh:path observable:serialNumber ;
] ,
[
sh:message "In UCO 2.0.0, cpeid in DeviceFacet will be constrained to be a CPE version 2.3 hardware name."@en ;
sh:path observable:cpeid ;
sh:pattern "^cpe:2.3:h:.+" ;
sh:severity sh:Warning ;
]
;
sh:targetClass observable:DeviceFacet ;
Expand Down Expand Up @@ -5162,15 +5156,6 @@ observable:OperatingSystem
rdfs:subClassOf observable:ObservableObject ;
rdfs:label "OperatingSystem"@en ;
rdfs:comment "An operating system is the software that manages computer hardware, software resources, and provides common services for computer programs. [based on https://en.wikipedia.org/wiki/Operating_system]"@en ;
sh:property [
sh:message "In UCO 2.0.0, cpeid in any Facet attached to an OperatingSystem will be constrained to be a CPE version 2.3 operating system name."@en ;
sh:path (
core:hasFacet
observable:cpeid
) ;
sh:pattern "^cpe:2.3:o:.+" ;
sh:severity sh:Warning ;
] ;
sh:targetClass observable:OperatingSystem ;
.

Expand Down Expand Up @@ -5223,12 +5208,6 @@ observable:OperatingSystemFacet
sh:datatype xsd:string ;
sh:nodeKind sh:Literal ;
sh:path observable:advertisingID ;
] ,
[
sh:maxCount "0"^^xsd:integer ;
sh:message "observable:cpeid should appear on a SoftwareFacet instead of an OperatingSystemFacet."@en ;
sh:path observable:cpeid ;
sh:severity sh:Warning ;
]
;
sh:targetClass observable:OperatingSystemFacet ;
Expand Down Expand Up @@ -6234,12 +6213,6 @@ observable:SoftwareFacet
sh:maxCount "1"^^xsd:integer ;
sh:nodeKind sh:Literal ;
sh:path observable:version ;
] ,
[
sh:message "In UCO 2.0.0, cpeid in SoftwareFacet will be constrained to be a CPE version 2.3 application or operating system name."@en ;
sh:path observable:cpeid ;
sh:pattern "^cpe:2.3:[a,o]:.+" ;
sh:severity sh:Warning ;
]
;
sh:targetClass observable:SoftwareFacet ;
Expand Down
2 changes: 0 additions & 2 deletions tests/examples/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ all: \
co_XFAIL_validation.ttl \
configuration_setting_PASS_validation.ttl \
configuration_setting_XFAIL_validation.ttl \
cpe_PASS_validation.ttl \
database_records_PASS_validation.ttl \
database_records_XFAIL_validation.ttl \
dictionary_PASS_validation.ttl \
Expand Down Expand Up @@ -102,7 +101,6 @@ check: \
co_XFAIL_validation.ttl \
configuration_setting_PASS_validation.ttl \
configuration_setting_XFAIL_validation.ttl \
cpe_PASS_validation.ttl \
database_records_PASS_validation.ttl \
database_records_XFAIL_validation.ttl \
dictionary_PASS_validation.ttl \
Expand Down
84 changes: 0 additions & 84 deletions tests/examples/cpe_PASS.json

This file was deleted.

11 changes: 0 additions & 11 deletions tests/examples/test_validation.py
Original file line number Diff line number Diff line change
Expand Up @@ -200,17 +200,6 @@ def test_configuration_setting_XFAIL_validation() -> None:
}
)

def test_cpe_PASS_validation() -> None:
confirm_validation_results(
"cpe_PASS_validation.ttl",
True,
expected_focus_node_severities={
("http://example.org/kb/DeviceFacet-4a1cdff8-be81-46e3-8502-0f488d353ca0", str(NS_SH.Warning)),
("http://example.org/kb/OperatingSystem-628d531f-254c-4efb-aaa0-0874306afa01", str(NS_SH.Warning)),
("http://example.org/kb/OperatingSystemFacet-872c1ba2-e1b4-4bc6-8267-6dbed687d0be", str(NS_SH.Warning)),
}
)

def test_database_records_PASS() -> None:
confirm_validation_results(
"database_records_PASS_validation.ttl",
Expand Down

0 comments on commit 50ce7ee

Please sign in to comment.