Skip to content

Commit 8947c60

Browse files
committed
val
Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
1 parent 716d576 commit 8947c60

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

cyclonedx/validation/json.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
from ..schema import SchemaVersion
3131

3232
from ..exception import MissingOptionalDependencyException
33-
from ..schema._res import BOM_JSON as _S_BOM, BOM_JSON_STRICT as _S_BOM_STRICT, JSF as _S_JSF, SPDX_JSON as _S_SPDX
33+
from ..schema._res import BOM_JSON as _S_BOM, BOM_JSON_STRICT as _S_BOM_STRICT, JSF as _S_JSF, SPDX_JSON as _S_SPDX, CRYPTOGRAPHY_DEFS as _S_CDEFS
3434
from . import BaseSchemabasedValidator, SchemabasedValidator, ValidationError
3535

3636
_missing_deps_error: Optional[tuple[MissingOptionalDependencyException, ImportError]] = None
@@ -125,9 +125,10 @@ def _validator(self) -> 'JsonSchemaValidator':
125125
@staticmethod
126126
def __make_validator_registry() -> Registry[Any]:
127127
schema_prefix = 'http://cyclonedx.org/schema/'
128-
with open(_S_SPDX) as spdx, open(_S_JSF) as jsf:
128+
with open(_S_SPDX) as spdx, open(_S_JSF) as jsf, open(_S_CDEFS) as cdefs:
129129
return Registry().with_resources([
130130
(f'{schema_prefix}spdx.SNAPSHOT.schema.json', DRAFT7.create_resource(json_loads(spdx.read()))),
131+
(f'{schema_prefix}cryptography-defs.SNAPSHOT.schema.json', DRAFT7.create_resource(json_loads(cdefs.read()))),
131132
(f'{schema_prefix}jsf-0.82.SNAPSHOT.schema.json', DRAFT7.create_resource(json_loads(jsf.read()))),
132133
])
133134

0 commit comments

Comments
 (0)