sbom-cyclonedx 0.1.0 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.gitignore +15 -0
- data/.gitlab-ci.yml +49 -0
- data/.rspec +3 -0
- data/.rubocop.yml +72 -0
- data/.vscode/settings.json +6 -0
- data/CHANGELOG.md +9 -0
- data/CODE_OF_CONDUCT.md +132 -0
- data/Gemfile +26 -0
- data/Gemfile.lock +179 -0
- data/LICENSE.txt +21 -0
- data/README.md +39 -0
- data/Rakefile +36 -0
- data/Steepfile +14 -0
- data/bin/console +11 -0
- data/bin/rbs_spec +9 -0
- data/bin/setup +8 -0
- data/bom-1.6.schema.json +7334 -0
- data/lib/email_address_extension.rb +26 -0
- data/lib/sbom/cyclone_dx/enum.rb +2178 -0
- data/lib/sbom/cyclone_dx/field.rb +404 -0
- data/lib/sbom/cyclone_dx/pattern.rb +43 -0
- data/lib/sbom/cyclone_dx/record/advisory.rb +17 -0
- data/lib/sbom/cyclone_dx/record/annotation.rb +46 -0
- data/lib/sbom/cyclone_dx/record/attachment.rb +21 -0
- data/lib/sbom/cyclone_dx/record/base.rb +244 -0
- data/lib/sbom/cyclone_dx/record/cipher_suite.rb +23 -0
- data/lib/sbom/cyclone_dx/record/co2_measure.rb +18 -0
- data/lib/sbom/cyclone_dx/record/command.rb +18 -0
- data/lib/sbom/cyclone_dx/record/commit.rb +25 -0
- data/lib/sbom/cyclone_dx/record/component.rb +126 -0
- data/lib/sbom/cyclone_dx/record/component_data.rb +46 -0
- data/lib/sbom/cyclone_dx/record/component_evidence.rb +68 -0
- data/lib/sbom/cyclone_dx/record/component_identity_evidence.rb +36 -0
- data/lib/sbom/cyclone_dx/record/composition.rb +33 -0
- data/lib/sbom/cyclone_dx/record/condition.rb +20 -0
- data/lib/sbom/cyclone_dx/record/copyright.rb +16 -0
- data/lib/sbom/cyclone_dx/record/crypto_properties.rb +137 -0
- data/lib/sbom/cyclone_dx/record/data_governance.rb +21 -0
- data/lib/sbom/cyclone_dx/record/data_governance_responsible_party.rb +22 -0
- data/lib/sbom/cyclone_dx/record/declarations.rb +193 -0
- data/lib/sbom/cyclone_dx/record/definitions.rb +17 -0
- data/lib/sbom/cyclone_dx/record/dependency.rb +21 -0
- data/lib/sbom/cyclone_dx/record/diff.rb +18 -0
- data/lib/sbom/cyclone_dx/record/energy_consumption.rb +31 -0
- data/lib/sbom/cyclone_dx/record/energy_measure.rb +18 -0
- data/lib/sbom/cyclone_dx/record/energy_provider.rb +31 -0
- data/lib/sbom/cyclone_dx/record/environmental_consideration.rb +20 -0
- data/lib/sbom/cyclone_dx/record/event.rb +31 -0
- data/lib/sbom/cyclone_dx/record/external_reference.rb +25 -0
- data/lib/sbom/cyclone_dx/record/fairness_assessment.rb +22 -0
- data/lib/sbom/cyclone_dx/record/formula.rb +29 -0
- data/lib/sbom/cyclone_dx/record/graphic.rb +19 -0
- data/lib/sbom/cyclone_dx/record/graphics_collection.rb +19 -0
- data/lib/sbom/cyclone_dx/record/hash_data.rb +18 -0
- data/lib/sbom/cyclone_dx/record/identifiable_action.rb +21 -0
- data/lib/sbom/cyclone_dx/record/input.rb +34 -0
- data/lib/sbom/cyclone_dx/record/input_output_ml_parameter.rb +17 -0
- data/lib/sbom/cyclone_dx/record/issue.rb +36 -0
- data/lib/sbom/cyclone_dx/record/license.rb +90 -0
- data/lib/sbom/cyclone_dx/record/license_choice.rb +35 -0
- data/lib/sbom/cyclone_dx/record/metadata.rb +55 -0
- data/lib/sbom/cyclone_dx/record/model_card.rb +89 -0
- data/lib/sbom/cyclone_dx/record/note.rb +20 -0
- data/lib/sbom/cyclone_dx/record/organizational_contact.rb +26 -0
- data/lib/sbom/cyclone_dx/record/organizational_entity.rb +28 -0
- data/lib/sbom/cyclone_dx/record/output.rb +34 -0
- data/lib/sbom/cyclone_dx/record/parameter.rb +20 -0
- data/lib/sbom/cyclone_dx/record/patch.rb +23 -0
- data/lib/sbom/cyclone_dx/record/performance_metric.rb +30 -0
- data/lib/sbom/cyclone_dx/record/postal_address.rb +34 -0
- data/lib/sbom/cyclone_dx/record/property.rb +18 -0
- data/lib/sbom/cyclone_dx/record/rating.rb +27 -0
- data/lib/sbom/cyclone_dx/record/release_notes.rb +44 -0
- data/lib/sbom/cyclone_dx/record/resource_reference_choice.rb +22 -0
- data/lib/sbom/cyclone_dx/record/risk.rb +18 -0
- data/lib/sbom/cyclone_dx/record/root.rb +63 -0
- data/lib/sbom/cyclone_dx/record/secured_by.rb +20 -0
- data/lib/sbom/cyclone_dx/record/service.rb +54 -0
- data/lib/sbom/cyclone_dx/record/service_data.rb +32 -0
- data/lib/sbom/cyclone_dx/record/signature.rb +85 -0
- data/lib/sbom/cyclone_dx/record/standard.rb +72 -0
- data/lib/sbom/cyclone_dx/record/step.rb +24 -0
- data/lib/sbom/cyclone_dx/record/swid.rb +29 -0
- data/lib/sbom/cyclone_dx/record/task.rb +56 -0
- data/lib/sbom/cyclone_dx/record/tools.rb +20 -0
- data/lib/sbom/cyclone_dx/record/trigger.rb +48 -0
- data/lib/sbom/cyclone_dx/record/version.rb +24 -0
- data/lib/sbom/cyclone_dx/record/volume.rb +33 -0
- data/lib/sbom/cyclone_dx/record/vulnerability.rb +119 -0
- data/lib/sbom/cyclone_dx/record/vulnerability_source.rb +20 -0
- data/lib/sbom/cyclone_dx/record/workflow.rb +59 -0
- data/lib/sbom/cyclone_dx/record/workspace.rb +45 -0
- data/lib/sbom/cyclone_dx/record.rb +12 -0
- data/lib/sbom/cyclone_dx/validator/array_validator.rb +66 -0
- data/lib/sbom/cyclone_dx/validator/base_validator.rb +43 -0
- data/lib/sbom/cyclone_dx/validator/boolean_validator.rb +16 -0
- data/lib/sbom/cyclone_dx/validator/date_time_validator.rb +29 -0
- data/lib/sbom/cyclone_dx/validator/email_address_validator.rb +31 -0
- data/lib/sbom/cyclone_dx/validator/float_validator.rb +30 -0
- data/lib/sbom/cyclone_dx/validator/integer_validator.rb +30 -0
- data/lib/sbom/cyclone_dx/validator/record_validator.rb +26 -0
- data/lib/sbom/cyclone_dx/validator/string_validator.rb +33 -0
- data/lib/sbom/cyclone_dx/validator/union_validator.rb +39 -0
- data/lib/sbom/cyclone_dx/validator/uri_validator.rb +32 -0
- data/lib/sbom/cyclone_dx/validator.rb +32 -0
- data/lib/sbom/cyclone_dx/version.rb +7 -0
- data/lib/sbom/cyclone_dx.rb +39 -0
- data/rbs_collection.lock.yaml +288 -0
- data/rbs_collection.yaml +31 -0
- data/sbom-cyclone_dx.gemspec +32 -0
- data/sig/email_address_extension.rbs +14 -0
- data/sig/sbom/cyclone_dx/enum.rbs +93 -0
- data/sig/sbom/cyclone_dx/field.rbs +434 -0
- data/sig/sbom/cyclone_dx/pattern.rbs +24 -0
- data/sig/sbom/cyclone_dx/record/advisory.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/annotation.rbs +63 -0
- data/sig/sbom/cyclone_dx/record/attachment.rbs +24 -0
- data/sig/sbom/cyclone_dx/record/base.rbs +62 -0
- data/sig/sbom/cyclone_dx/record/cipher_suite.rbs +24 -0
- data/sig/sbom/cyclone_dx/record/co2_measure.rbs +14 -0
- data/sig/sbom/cyclone_dx/record/command.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/commit.rbs +34 -0
- data/sig/sbom/cyclone_dx/record/component.rbs +203 -0
- data/sig/sbom/cyclone_dx/record/component_data.rbs +73 -0
- data/sig/sbom/cyclone_dx/record/component_evidence.rbs +115 -0
- data/sig/sbom/cyclone_dx/record/component_identity_evidence.rbs +53 -0
- data/sig/sbom/cyclone_dx/record/composition.rbs +39 -0
- data/sig/sbom/cyclone_dx/record/condition.rbs +24 -0
- data/sig/sbom/cyclone_dx/record/copyright.rbs +14 -0
- data/sig/sbom/cyclone_dx/record/crypto_properties.rbs +268 -0
- data/sig/sbom/cyclone_dx/record/data_governance.rbs +24 -0
- data/sig/sbom/cyclone_dx/record/data_governance_responsible_party.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/declarations.rbs +352 -0
- data/sig/sbom/cyclone_dx/record/definitions.rbs +14 -0
- data/sig/sbom/cyclone_dx/record/dependency.rbs +24 -0
- data/sig/sbom/cyclone_dx/record/diff.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/energy_consumption.rbs +39 -0
- data/sig/sbom/cyclone_dx/record/energy_measure.rbs +14 -0
- data/sig/sbom/cyclone_dx/record/energy_provider.rbs +39 -0
- data/sig/sbom/cyclone_dx/record/environmental_consideration.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/event.rbs +44 -0
- data/sig/sbom/cyclone_dx/record/external_reference.rbs +29 -0
- data/sig/sbom/cyclone_dx/record/fairness_assessment.rbs +29 -0
- data/sig/sbom/cyclone_dx/record/formula.rbs +34 -0
- data/sig/sbom/cyclone_dx/record/graphic.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/graphics_collection.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/hash_data.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/identifiable_action.rbs +24 -0
- data/sig/sbom/cyclone_dx/record/input.rbs +44 -0
- data/sig/sbom/cyclone_dx/record/input_output_ml_parameter.rbs +14 -0
- data/sig/sbom/cyclone_dx/record/issue.rbs +53 -0
- data/sig/sbom/cyclone_dx/record/license.rbs +134 -0
- data/sig/sbom/cyclone_dx/record/license_choice.rbs +39 -0
- data/sig/sbom/cyclone_dx/record/metadata.rbs +82 -0
- data/sig/sbom/cyclone_dx/record/model_card.rbs +143 -0
- data/sig/sbom/cyclone_dx/record/note.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/organizational_contact.rbs +29 -0
- data/sig/sbom/cyclone_dx/record/organizational_entity.rbs +34 -0
- data/sig/sbom/cyclone_dx/record/output.rbs +44 -0
- data/sig/sbom/cyclone_dx/record/parameter.rbs +24 -0
- data/sig/sbom/cyclone_dx/record/patch.rbs +24 -0
- data/sig/sbom/cyclone_dx/record/performance_metric.rbs +43 -0
- data/sig/sbom/cyclone_dx/record/postal_address.rbs +44 -0
- data/sig/sbom/cyclone_dx/record/property.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/rating.rbs +39 -0
- data/sig/sbom/cyclone_dx/record/release_notes.rbs +64 -0
- data/sig/sbom/cyclone_dx/record/resource_reference_choice.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/risk.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/root.rbs +84 -0
- data/sig/sbom/cyclone_dx/record/secured_by.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/service.rbs +99 -0
- data/sig/sbom/cyclone_dx/record/service_data.rbs +44 -0
- data/sig/sbom/cyclone_dx/record/signature.rbs +130 -0
- data/sig/sbom/cyclone_dx/record/standard.rbs +132 -0
- data/sig/sbom/cyclone_dx/record/step.rbs +29 -0
- data/sig/sbom/cyclone_dx/record/swid.rbs +44 -0
- data/sig/sbom/cyclone_dx/record/task.rbs +84 -0
- data/sig/sbom/cyclone_dx/record/tools.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/trigger.rbs +69 -0
- data/sig/sbom/cyclone_dx/record/version.rbs +24 -0
- data/sig/sbom/cyclone_dx/record/volume.rbs +49 -0
- data/sig/sbom/cyclone_dx/record/vulnerability.rbs +209 -0
- data/sig/sbom/cyclone_dx/record/vulnerability_source.rbs +19 -0
- data/sig/sbom/cyclone_dx/record/workflow.rbs +94 -0
- data/sig/sbom/cyclone_dx/record/workspace.rbs +69 -0
- data/sig/sbom/cyclone_dx/record.rbs +161 -0
- data/sig/sbom/cyclone_dx/type.rbs +16 -0
- data/sig/sbom/cyclone_dx/validator/array_validator.rbs +31 -0
- data/sig/sbom/cyclone_dx/validator/base_validator.rbs +21 -0
- data/sig/sbom/cyclone_dx/validator/boolean_validator.rbs +9 -0
- data/sig/sbom/cyclone_dx/validator/date_time_validator.rbs +10 -0
- data/sig/sbom/cyclone_dx/validator/email_address_validator.rbs +10 -0
- data/sig/sbom/cyclone_dx/validator/float_validator.rbs +12 -0
- data/sig/sbom/cyclone_dx/validator/integer_validator.rbs +12 -0
- data/sig/sbom/cyclone_dx/validator/record_validator.rbs +12 -0
- data/sig/sbom/cyclone_dx/validator/string_validator.rbs +14 -0
- data/sig/sbom/cyclone_dx/validator/union_validator.rbs +24 -0
- data/sig/sbom/cyclone_dx/validator/uri_validator.rbs +10 -0
- data/sig/sbom/cyclone_dx/validator.rbs +66 -0
- data/sig/sbom/cyclone_dx.rbs +13 -0
- data/sig/types.rbs +45 -0
- data/spec/email_address_extension_spec.rb +27 -0
- data/spec/factories/factory_helper.rb +78 -0
- data/spec/factories/record/advisory_factory.rb +11 -0
- data/spec/factories/record/annotation_factory.rb +63 -0
- data/spec/factories/record/attachment_factory.rb +9 -0
- data/spec/factories/record/cipher_suite_factory.rb +26 -0
- data/spec/factories/record/co2_measure_factory.rb +9 -0
- data/spec/factories/record/command_factory.rb +10 -0
- data/spec/factories/record/commit_factory.rb +13 -0
- data/spec/factories/record/component_data_factory.rb +28 -0
- data/spec/factories/record/component_evidence_factory.rb +44 -0
- data/spec/factories/record/component_factory.rb +102 -0
- data/spec/factories/record/component_identity_evidence_factory.rb +25 -0
- data/spec/factories/record/composition_factory.rb +20 -0
- data/spec/factories/record/condition_factory.rb +11 -0
- data/spec/factories/record/copyright_factory.rb +9 -0
- data/spec/factories/record/crypto_properties_factory.rb +191 -0
- data/spec/factories/record/data_governance_factory.rb +11 -0
- data/spec/factories/record/data_governance_responsible_party_factory.rb +31 -0
- data/spec/factories/record/declarations_factory.rb +145 -0
- data/spec/factories/record/definitions_factory.rb +9 -0
- data/spec/factories/record/dependency_factory.rb +12 -0
- data/spec/factories/record/diff_factory.rb +24 -0
- data/spec/factories/record/energy_consumption_factory.rb +15 -0
- data/spec/factories/record/energy_measure_factory.rb +9 -0
- data/spec/factories/record/energy_provider_factory.rb +15 -0
- data/spec/factories/record/environmental_consideration_factory.rb +10 -0
- data/spec/factories/record/event_factory.rb +15 -0
- data/spec/factories/record/external_reference_factory.rb +13 -0
- data/spec/factories/record/fairness_assessment_factory.rb +12 -0
- data/spec/factories/record/formula_factory.rb +13 -0
- data/spec/factories/record/graphic_factory.rb +10 -0
- data/spec/factories/record/graphics_collection_factory.rb +10 -0
- data/spec/factories/record/hash_data_factory.rb +10 -0
- data/spec/factories/record/identifiable_action_factory.rb +11 -0
- data/spec/factories/record/input_factory.rb +36 -0
- data/spec/factories/record/input_output_ml_parameter_factory.rb +9 -0
- data/spec/factories/record/issue_factory.rb +22 -0
- data/spec/factories/record/license_choice_factory.rb +23 -0
- data/spec/factories/record/license_factory.rb +99 -0
- data/spec/factories/record/metadata_factory.rb +38 -0
- data/spec/factories/record/model_card_factory.rb +59 -0
- data/spec/factories/record/note_factory.rb +11 -0
- data/spec/factories/record/organizational_contact_factory.rb +12 -0
- data/spec/factories/record/organizational_entity_factory.rb +13 -0
- data/spec/factories/record/output_factory.rb +32 -0
- data/spec/factories/record/parameter_factory.rb +11 -0
- data/spec/factories/record/patch_factory.rb +12 -0
- data/spec/factories/record/performance_metric_factory.rb +20 -0
- data/spec/factories/record/postal_address_factory.rb +14 -0
- data/spec/factories/record/property_factory.rb +11 -0
- data/spec/factories/record/rating_factory.rb +14 -0
- data/spec/factories/record/release_notes_factory.rb +20 -0
- data/spec/factories/record/resource_reference_choice_factory.rb +27 -0
- data/spec/factories/record/risk_factory.rb +10 -0
- data/spec/factories/record/root_factory.rb +23 -0
- data/spec/factories/record/secured_by_factory.rb +10 -0
- data/spec/factories/record/service_data_factory.rb +16 -0
- data/spec/factories/record/service_factory.rb +27 -0
- data/spec/factories/record/signature_factory.rb +50 -0
- data/spec/factories/record/standard_factory.rb +37 -0
- data/spec/factories/record/step_factory.rb +12 -0
- data/spec/factories/record/swid_factory.rb +16 -0
- data/spec/factories/record/task_factory.rb +24 -0
- data/spec/factories/record/tools_factory.rb +10 -0
- data/spec/factories/record/trigger_factory.rb +21 -0
- data/spec/factories/record/version_factory.rb +19 -0
- data/spec/factories/record/volume_factory.rb +16 -0
- data/spec/factories/record/vulnerability_factory.rb +70 -0
- data/spec/factories/record/vulnerability_source_factory.rb +10 -0
- data/spec/factories/record/workflow_factory.rb +26 -0
- data/spec/factories/record/workspace_factory.rb +21 -0
- data/spec/factories/record_factory.rb +159 -0
- data/spec/fixtures/cipher_info.yml +948 -0
- data/spec/fixtures/purl_data.yml +0 -0
- data/spec/sbom/cyclone_dx/enum_spec.rb +30 -0
- data/spec/sbom/cyclone_dx/field_spec.rb +104 -0
- data/spec/sbom/cyclone_dx/pattern_spec.rb +18 -0
- data/spec/sbom/cyclone_dx/record/advisory_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/annotation_spec.rb +31 -0
- data/spec/sbom/cyclone_dx/record/attachment_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/base_spec.rb +363 -0
- data/spec/sbom/cyclone_dx/record/cipher_suite_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/co2_measure_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/command_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/commit_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/component_data_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/component_evidence_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/component_identity_evidence_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/component_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/composition_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/condition_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/copyright_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/crypto_properties_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/data_governance_responsible_party_spec.rb +19 -0
- data/spec/sbom/cyclone_dx/record/data_governance_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/declarations_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/definitions_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/dependency_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/diff_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/energy_consumption_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/energy_measure_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/energy_provider_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/environmental_consideration_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/event_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/external_reference_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/fairness_assessment_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/formula_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/graphic_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/graphics_collection_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/hash_data_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/identifiable_action_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/input_output_ml_parameter_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/input_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/issue_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/license_choice_spec.rb +26 -0
- data/spec/sbom/cyclone_dx/record/license_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/metadata_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/model_card_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/note_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/organizational_contact_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/organizational_entity_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/output_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/parameter_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/patch_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/performance_metric_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/postal_address_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/property_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/rating_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/release_notes_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/resource_reference_choice_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/risk_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/root_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/secured_by_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/service_data_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/service_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/signature_spec.rb +26 -0
- data/spec/sbom/cyclone_dx/record/standard_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/step_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/swid_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/task_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/tools_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/trigger_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/version_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/volume_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/vulnerability_source_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/vulnerability_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/workflow_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record/workspace_spec.rb +14 -0
- data/spec/sbom/cyclone_dx/record_spec.rb +7 -0
- data/spec/sbom/cyclone_dx/validator/array_validator_spec.rb +184 -0
- data/spec/sbom/cyclone_dx/validator/base_validator_spec.rb +71 -0
- data/spec/sbom/cyclone_dx/validator/boolean_validator_spec.rb +26 -0
- data/spec/sbom/cyclone_dx/validator/date_time_validator_spec.rb +28 -0
- data/spec/sbom/cyclone_dx/validator/email_address_validator_spec.rb +23 -0
- data/spec/sbom/cyclone_dx/validator/float_validator_spec.rb +71 -0
- data/spec/sbom/cyclone_dx/validator/integer_validator_spec.rb +71 -0
- data/spec/sbom/cyclone_dx/validator/record_validator_spec.rb +35 -0
- data/spec/sbom/cyclone_dx/validator/string_validator_spec.rb +94 -0
- data/spec/sbom/cyclone_dx/validator/union_validator_spec.rb +65 -0
- data/spec/sbom/cyclone_dx/validator/uri_validator_spec.rb +21 -0
- data/spec/sbom/cyclone_dx/validator_spec.rb +38 -0
- data/spec/sbom/cyclone_dx/version_spec.rb +9 -0
- data/spec/sbom/cyclone_dx_spec.rb +7 -0
- data/spec/spec_helper.rb +39 -0
- metadata +377 -6
@@ -0,0 +1,24 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class Dependency < Base
|
5
|
+
def initialize: (ref: String, ?depends_on: Array[String]?, ?provides: Array[String]?) -> void
|
6
|
+
|
7
|
+
def ref: () -> String
|
8
|
+
def ref=: (String) -> String
|
9
|
+
def ref?: () -> bool
|
10
|
+
def ref_valid?: () -> bool
|
11
|
+
|
12
|
+
def depends_on: () -> Array[String]?
|
13
|
+
def depends_on=: (Array[String]?) -> Array[String]?
|
14
|
+
def depends_on?: () -> bool
|
15
|
+
def depends_on_valid?: () -> bool
|
16
|
+
|
17
|
+
def provides: () -> Array[String]?
|
18
|
+
def provides=: (Array[String]?) -> Array[String]?
|
19
|
+
def provides?: () -> bool
|
20
|
+
def provides_valid?: () -> bool
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
@@ -0,0 +1,19 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class Diff < Base
|
5
|
+
def initialize: (?text: Attachment?, ?url: uri?) -> void
|
6
|
+
|
7
|
+
def text: () -> Attachment?
|
8
|
+
def text=: (Attachment?) -> Attachment?
|
9
|
+
def text?: () -> bool
|
10
|
+
def text_valid?: () -> bool
|
11
|
+
|
12
|
+
def url: () -> uri?
|
13
|
+
def url=: (uri?) -> uri?
|
14
|
+
def url?: () -> bool
|
15
|
+
def url_valid?: () -> bool
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class EnergyConsumption < Base
|
5
|
+
def initialize: (activity: String, energy_providers: Array[EnergyProvider], activity_energy_cost: EnergyMeasure, ?co2_cost_equivalent: CO2Measure?, ?co2_cost_offset: CO2Measure?, ?properties: Array[Property]?) -> void
|
6
|
+
|
7
|
+
def activity: () -> String
|
8
|
+
def activity=: (String) -> String
|
9
|
+
def activity?: () -> bool
|
10
|
+
def activity_valid?: () -> bool
|
11
|
+
|
12
|
+
def energy_providers: () -> Array[EnergyProvider]
|
13
|
+
def energy_providers=: (Array[EnergyProvider]) -> Array[EnergyProvider]
|
14
|
+
def energy_providers?: () -> bool
|
15
|
+
def energy_providers_valid?: () -> bool
|
16
|
+
|
17
|
+
def activity_energy_cost: () -> EnergyMeasure
|
18
|
+
def activity_energy_cost=: (EnergyMeasure) -> EnergyMeasure
|
19
|
+
def activity_energy_cost?: () -> bool
|
20
|
+
def activity_energy_cost_valid?: () -> bool
|
21
|
+
|
22
|
+
def co2_cost_equivalent: () -> CO2Measure?
|
23
|
+
def co2_cost_equivalent=: (CO2Measure?) -> CO2Measure?
|
24
|
+
def co2_cost_equivalent?: () -> bool
|
25
|
+
def co2_cost_equivalent_valid?: () -> bool
|
26
|
+
|
27
|
+
def co2_cost_offset: () -> CO2Measure?
|
28
|
+
def co2_cost_offset=: (CO2Measure?) -> CO2Measure?
|
29
|
+
def co2_cost_offset?: () -> bool
|
30
|
+
def co2_cost_offset_valid?: () -> bool
|
31
|
+
|
32
|
+
def properties: () -> Array[Property]?
|
33
|
+
def properties=: (Array[Property]?) -> Array[Property]?
|
34
|
+
def properties?: () -> bool
|
35
|
+
def properties_valid?: () -> bool
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -0,0 +1,14 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class EnergyMeasure < Base
|
5
|
+
def initialize: (value: Float) -> void
|
6
|
+
|
7
|
+
def value: () -> Float
|
8
|
+
def value=: (Float) -> Float
|
9
|
+
def value?: () -> bool
|
10
|
+
def value_valid?: () -> bool
|
11
|
+
end
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class EnergyProvider < Base
|
5
|
+
def initialize: (?bom_ref: String?, ?description: String?, organization: OrganizationalEntity, energy_source: String, energy_provided: EnergyMeasure, ?external_references: Array[ExternalReference]?) -> void
|
6
|
+
|
7
|
+
def bom_ref: () -> String?
|
8
|
+
def bom_ref=: (String?) -> String?
|
9
|
+
def bom_ref?: () -> bool
|
10
|
+
def bom_ref_valid?: () -> bool
|
11
|
+
|
12
|
+
def description: () -> String?
|
13
|
+
def description=: (String?) -> String?
|
14
|
+
def description?: () -> bool
|
15
|
+
def description_valid?: () -> bool
|
16
|
+
|
17
|
+
def organization: () -> OrganizationalEntity
|
18
|
+
def organization=: (OrganizationalEntity) -> OrganizationalEntity
|
19
|
+
def organization?: () -> bool
|
20
|
+
def organization_valid?: () -> bool
|
21
|
+
|
22
|
+
def energy_source: () -> String
|
23
|
+
def energy_source=: (String) -> String
|
24
|
+
def energy_source?: () -> bool
|
25
|
+
def energy_source_valid?: () -> bool
|
26
|
+
|
27
|
+
def energy_provided: () -> EnergyMeasure
|
28
|
+
def energy_provided=: (EnergyMeasure) -> EnergyMeasure
|
29
|
+
def energy_provided?: () -> bool
|
30
|
+
def energy_provided_valid?: () -> bool
|
31
|
+
|
32
|
+
def external_references: () -> Array[ExternalReference]?
|
33
|
+
def external_references=: (Array[ExternalReference]?) -> Array[ExternalReference]?
|
34
|
+
def external_references?: () -> bool
|
35
|
+
def external_references_valid?: () -> bool
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -0,0 +1,19 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class EnvironmentalConsideration < Base
|
5
|
+
def initialize: (?energy_consumptions: Array[EnergyConsumption]?, ?properties: Array[Property]?) -> void
|
6
|
+
|
7
|
+
def energy_consumptions: () -> Array[EnergyConsumption]?
|
8
|
+
def energy_consumptions=: (Array[EnergyConsumption]?) -> Array[EnergyConsumption]?
|
9
|
+
def energy_consumptions?: () -> bool
|
10
|
+
def energy_consumptions_valid?: () -> bool
|
11
|
+
|
12
|
+
def properties: () -> Array[Property]?
|
13
|
+
def properties=: (Array[Property]?) -> Array[Property]?
|
14
|
+
def properties?: () -> bool
|
15
|
+
def properties_valid?: () -> bool
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
@@ -0,0 +1,44 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class Event < Base
|
5
|
+
def initialize: (?uid: String?, ?description: String?, ?time_received: dateTime?, ?data: Attachment?, ?source: ResourceReferenceChoice?, ?target: ResourceReferenceChoice?, ?properties: Array[Property]?) -> void
|
6
|
+
|
7
|
+
def uid: () -> String?
|
8
|
+
def uid=: (String?) -> String?
|
9
|
+
def uid?: () -> bool
|
10
|
+
def uid_valid?: () -> bool
|
11
|
+
|
12
|
+
def description: () -> String?
|
13
|
+
def description=: (String?) -> String?
|
14
|
+
def description?: () -> bool
|
15
|
+
def description_valid?: () -> bool
|
16
|
+
|
17
|
+
def time_received: () -> dateTime?
|
18
|
+
def time_received=: (dateTime?) -> dateTime?
|
19
|
+
def time_received?: () -> bool
|
20
|
+
def time_received_valid?: () -> bool
|
21
|
+
|
22
|
+
def data: () -> Attachment?
|
23
|
+
def data=: (Attachment?) -> Attachment?
|
24
|
+
def data?: () -> bool
|
25
|
+
def data_valid?: () -> bool
|
26
|
+
|
27
|
+
def source: () -> ResourceReferenceChoice?
|
28
|
+
def source=: (ResourceReferenceChoice?) -> ResourceReferenceChoice?
|
29
|
+
def source?: () -> bool
|
30
|
+
def source_valid?: () -> bool
|
31
|
+
|
32
|
+
def target: () -> ResourceReferenceChoice?
|
33
|
+
def target=: (ResourceReferenceChoice?) -> ResourceReferenceChoice?
|
34
|
+
def target?: () -> bool
|
35
|
+
def target_valid?: () -> bool
|
36
|
+
|
37
|
+
def properties: () -> Array[Property]?
|
38
|
+
def properties=: (Array[Property]?) -> Array[Property]?
|
39
|
+
def properties?: () -> bool
|
40
|
+
def properties_valid?: () -> bool
|
41
|
+
end
|
42
|
+
end
|
43
|
+
end
|
44
|
+
end
|
@@ -0,0 +1,29 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class ExternalReference < Base
|
5
|
+
def initialize: (url: uri | String, ?comment: String?, type: String, ?hashes: Array[HashData]?) -> void
|
6
|
+
|
7
|
+
def url: () -> (uri | String)
|
8
|
+
def url=: (uri | String) -> (uri | String)
|
9
|
+
def url?: () -> bool
|
10
|
+
def url_valid?: () -> bool
|
11
|
+
|
12
|
+
def comment: () -> String?
|
13
|
+
def comment=: (String?) -> String?
|
14
|
+
def comment?: () -> bool
|
15
|
+
def comment_valid?: () -> bool
|
16
|
+
|
17
|
+
def type: () -> String
|
18
|
+
def type=: (String) -> String
|
19
|
+
def type?: () -> bool
|
20
|
+
def type_valid?: () -> bool
|
21
|
+
|
22
|
+
def hashes: () -> Array[HashData]?
|
23
|
+
def hashes=: (Array[HashData]?) -> Array[HashData]?
|
24
|
+
def hashes?: () -> bool
|
25
|
+
def hashes_valid?: () -> bool
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
29
|
+
end
|
@@ -0,0 +1,29 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class FairnessAssessment < Base
|
5
|
+
def initialize: (?group_at_risk: String?, ?benefits: String?, ?harms: String?, ?mitigation_strategy: String?) -> void
|
6
|
+
|
7
|
+
def group_at_risk: () -> String?
|
8
|
+
def group_at_risk=: (String?) -> String?
|
9
|
+
def group_at_risk?: () -> bool
|
10
|
+
def group_at_risk_valid?: () -> bool
|
11
|
+
|
12
|
+
def benefits: () -> String?
|
13
|
+
def benefits=: (String?) -> String?
|
14
|
+
def benefits?: () -> bool
|
15
|
+
def benefits_valid?: () -> bool
|
16
|
+
|
17
|
+
def harms: () -> String?
|
18
|
+
def harms=: (String?) -> String?
|
19
|
+
def harms?: () -> bool
|
20
|
+
def harms_valid?: () -> bool
|
21
|
+
|
22
|
+
def mitigation_strategy: () -> String?
|
23
|
+
def mitigation_strategy=: (String?) -> String?
|
24
|
+
def mitigation_strategy?: () -> bool
|
25
|
+
def mitigation_strategy_valid?: () -> bool
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
29
|
+
end
|
@@ -0,0 +1,34 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class Formula < Base
|
5
|
+
def initialize: (?bom_ref: String?, ?components: Array[Component]?, ?services: Array[Service]?, ?workflows: Array[Workflow]?, ?properties: Array[Property]?) -> void
|
6
|
+
|
7
|
+
def bom_ref: () -> String?
|
8
|
+
def bom_ref=: (String?) -> String?
|
9
|
+
def bom_ref?: () -> bool
|
10
|
+
def bom_ref_valid?: () -> bool
|
11
|
+
|
12
|
+
def components: () -> Array[Component]?
|
13
|
+
def components=: (Array[Component]?) -> Array[Component]?
|
14
|
+
def components?: () -> bool
|
15
|
+
def components_valid?: () -> bool
|
16
|
+
|
17
|
+
def services: () -> Array[Service]?
|
18
|
+
def services=: (Array[Service]?) -> Array[Service]?
|
19
|
+
def services?: () -> bool
|
20
|
+
def services_valid?: () -> bool
|
21
|
+
|
22
|
+
def workflows: () -> Array[Workflow]?
|
23
|
+
def workflows=: (Array[Workflow]?) -> Array[Workflow]?
|
24
|
+
def workflows?: () -> bool
|
25
|
+
def workflows_valid?: () -> bool
|
26
|
+
|
27
|
+
def properties: () -> Array[Property]?
|
28
|
+
def properties=: (Array[Property]?) -> Array[Property]?
|
29
|
+
def properties?: () -> bool
|
30
|
+
def properties_valid?: () -> bool
|
31
|
+
end
|
32
|
+
end
|
33
|
+
end
|
34
|
+
end
|
@@ -0,0 +1,19 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class Graphic < Base
|
5
|
+
def initialize: (?name: String?, ?image: Attachment?) -> void
|
6
|
+
|
7
|
+
def name: () -> String?
|
8
|
+
def name=: (String?) -> String?
|
9
|
+
def name?: () -> bool
|
10
|
+
def name_valid?: () -> bool
|
11
|
+
|
12
|
+
def image: () -> Attachment?
|
13
|
+
def image=: (Attachment?) -> Attachment?
|
14
|
+
def image?: () -> bool
|
15
|
+
def image_valid?: () -> bool
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
@@ -0,0 +1,19 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class GraphicsCollection < Base
|
5
|
+
def initialize: (?description: String?, ?collection: Array[Graphic]?) -> void
|
6
|
+
|
7
|
+
def description: () -> String?
|
8
|
+
def description=: (String?) -> String?
|
9
|
+
def description?: () -> bool
|
10
|
+
def description_valid?: () -> bool
|
11
|
+
|
12
|
+
def collection: () -> Array[Graphic]?
|
13
|
+
def collection=: (Array[Graphic]?) -> Array[Graphic]?
|
14
|
+
def collection?: () -> bool
|
15
|
+
def collection_valid?: () -> bool
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
@@ -0,0 +1,19 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class HashData < Base
|
5
|
+
def initialize: (alg: String, content: String) -> void
|
6
|
+
|
7
|
+
def alg: () -> String
|
8
|
+
def alg=: (String) -> String
|
9
|
+
def alg?: () -> bool
|
10
|
+
def alg_valid?: () -> bool
|
11
|
+
|
12
|
+
def content: () -> String
|
13
|
+
def content=: (String) -> String
|
14
|
+
def content?: () -> bool
|
15
|
+
def content_valid?: () -> bool
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
@@ -0,0 +1,24 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class IdentifiableAction < Base
|
5
|
+
def initialize: (?timestamp: dateTime?, ?name: String?, ?email: emailAddress?) -> void
|
6
|
+
|
7
|
+
def timestamp: () -> dateTime?
|
8
|
+
def timestamp=: (dateTime?) -> dateTime?
|
9
|
+
def timestamp?: () -> bool
|
10
|
+
def timestamp_valid?: () -> bool
|
11
|
+
|
12
|
+
def name: () -> String?
|
13
|
+
def name=: (String?) -> String?
|
14
|
+
def name?: () -> bool
|
15
|
+
def name_valid?: () -> bool
|
16
|
+
|
17
|
+
def email: () -> emailAddress?
|
18
|
+
def email=: (emailAddress?) -> emailAddress?
|
19
|
+
def email?: () -> bool
|
20
|
+
def email_valid?: () -> bool
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
@@ -0,0 +1,44 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class Input < Base
|
5
|
+
def initialize: (?source: ResourceReferenceChoice?, ?target: ResourceReferenceChoice?, ?resource: ResourceReferenceChoice?, ?parameters: Array[Parameter]?, ?environment_vars: Array[Property | String]?, ?data: Attachment?, ?properties: Array[Property]?) -> void
|
6
|
+
|
7
|
+
def source: () -> ResourceReferenceChoice?
|
8
|
+
def source=: (ResourceReferenceChoice?) -> ResourceReferenceChoice?
|
9
|
+
def source?: () -> bool
|
10
|
+
def source_valid?: () -> bool
|
11
|
+
|
12
|
+
def target: () -> ResourceReferenceChoice?
|
13
|
+
def target=: (ResourceReferenceChoice?) -> ResourceReferenceChoice?
|
14
|
+
def target?: () -> bool
|
15
|
+
def target_valid?: () -> bool
|
16
|
+
|
17
|
+
def resource: () -> ResourceReferenceChoice?
|
18
|
+
def resource=: (ResourceReferenceChoice?) -> ResourceReferenceChoice?
|
19
|
+
def resource?: () -> bool
|
20
|
+
def resource_valid?: () -> bool
|
21
|
+
|
22
|
+
def parameters: () -> Array[Parameter]?
|
23
|
+
def parameters=: (Array[Parameter]?) -> Array[Parameter]?
|
24
|
+
def parameters?: () -> bool
|
25
|
+
def parameters_valid?: () -> bool
|
26
|
+
|
27
|
+
def environment_vars: () -> (Array[Property | String])?
|
28
|
+
def environment_vars=: (Array[Property | String]?) -> (Array[Property | String])?
|
29
|
+
def environment_vars?: () -> bool
|
30
|
+
def environment_vars_valid?: () -> bool
|
31
|
+
|
32
|
+
def data: () -> Attachment?
|
33
|
+
def data=: (Attachment?) -> Attachment?
|
34
|
+
def data?: () -> bool
|
35
|
+
def data_valid?: () -> bool
|
36
|
+
|
37
|
+
def properties: () -> Array[Property]?
|
38
|
+
def properties=: (Array[Property]?) -> Array[Property]?
|
39
|
+
def properties?: () -> bool
|
40
|
+
def properties_valid?: () -> bool
|
41
|
+
end
|
42
|
+
end
|
43
|
+
end
|
44
|
+
end
|
@@ -0,0 +1,14 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class InputOutputMLParameter < Base
|
5
|
+
def initialize: (?format: String?) -> void
|
6
|
+
|
7
|
+
def format: () -> String?
|
8
|
+
def format=: (String?) -> String?
|
9
|
+
def format?: () -> bool
|
10
|
+
def format_valid?: () -> bool
|
11
|
+
end
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
@@ -0,0 +1,53 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class Issue < Base
|
5
|
+
class Source < Base
|
6
|
+
def initialize: (?name: String?, ?url: uri?) -> void
|
7
|
+
|
8
|
+
def name: () -> String?
|
9
|
+
def name=: (String?) -> String?
|
10
|
+
def name?: () -> bool
|
11
|
+
def name_valid?: () -> bool
|
12
|
+
|
13
|
+
def url: () -> uri?
|
14
|
+
def url=: (uri?) -> uri?
|
15
|
+
def url?: () -> bool
|
16
|
+
def url_valid?: () -> bool
|
17
|
+
end
|
18
|
+
|
19
|
+
def initialize: (type: String, ?id: String?, ?name: String?, ?description: String?, ?source: Source?, ?references: Array[uri]?) -> void
|
20
|
+
|
21
|
+
def type: () -> String
|
22
|
+
def type=: (String) -> String
|
23
|
+
def type?: () -> bool
|
24
|
+
def type_valid?: () -> bool
|
25
|
+
|
26
|
+
def id: () -> String?
|
27
|
+
def id=: (String?) -> String?
|
28
|
+
def id?: () -> bool
|
29
|
+
def id_valid?: () -> bool
|
30
|
+
|
31
|
+
def name: () -> String?
|
32
|
+
def name=: (String?) -> String?
|
33
|
+
def name?: () -> bool
|
34
|
+
def name_valid?: () -> bool
|
35
|
+
|
36
|
+
def description: () -> String?
|
37
|
+
def description=: (String?) -> String?
|
38
|
+
def description?: () -> bool
|
39
|
+
def description_valid?: () -> bool
|
40
|
+
|
41
|
+
def source: () -> Source?
|
42
|
+
def source=: (Source?) -> Source?
|
43
|
+
def source?: () -> bool
|
44
|
+
def source_valid?: () -> bool
|
45
|
+
|
46
|
+
def references: () -> Array[uri]?
|
47
|
+
def references=: (Array[uri]?) -> Array[uri]?
|
48
|
+
def references?: () -> bool
|
49
|
+
def references_valid?: () -> bool
|
50
|
+
end
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
@@ -0,0 +1,134 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
class License < Base
|
5
|
+
class Licensing < Base
|
6
|
+
class Licensee < Base
|
7
|
+
def initialize: (?organization: OrganizationalEntity?, ?individual: OrganizationalContact?) -> void
|
8
|
+
|
9
|
+
def organization: () -> OrganizationalEntity?
|
10
|
+
def organization=: (OrganizationalEntity?) -> OrganizationalEntity?
|
11
|
+
def organization?: () -> bool
|
12
|
+
def organization_valid?: () -> bool
|
13
|
+
|
14
|
+
def individual: () -> OrganizationalContact?
|
15
|
+
def individual=: (OrganizationalContact?) -> OrganizationalContact?
|
16
|
+
def individual?: () -> bool
|
17
|
+
def individual_valid?: () -> bool
|
18
|
+
end
|
19
|
+
|
20
|
+
class Licensor < Base
|
21
|
+
def initialize: (?organization: OrganizationalEntity?, ?individual: OrganizationalContact?) -> void
|
22
|
+
|
23
|
+
def organization: () -> OrganizationalEntity?
|
24
|
+
def organization=: (OrganizationalEntity?) -> OrganizationalEntity?
|
25
|
+
def organization?: () -> bool
|
26
|
+
def organization_valid?: () -> bool
|
27
|
+
|
28
|
+
def individual: () -> OrganizationalContact?
|
29
|
+
def individual=: (OrganizationalContact?) -> OrganizationalContact?
|
30
|
+
def individual?: () -> bool
|
31
|
+
def individual_valid?: () -> bool
|
32
|
+
end
|
33
|
+
|
34
|
+
class Purchaser < Base
|
35
|
+
def initialize: (?organization: OrganizationalEntity?, ?individual: OrganizationalContact?) -> void
|
36
|
+
|
37
|
+
def organization: () -> OrganizationalEntity?
|
38
|
+
def organization=: (OrganizationalEntity?) -> OrganizationalEntity?
|
39
|
+
def organization?: () -> bool
|
40
|
+
def organization_valid?: () -> bool
|
41
|
+
|
42
|
+
def individual: () -> OrganizationalContact?
|
43
|
+
def individual=: (OrganizationalContact?) -> OrganizationalContact?
|
44
|
+
def individual?: () -> bool
|
45
|
+
def individual_valid?: () -> bool
|
46
|
+
end
|
47
|
+
def initialize: (?alt_ids: Array[String]?, ?licensor: Licensor?, ?licensee: Licensee?, ?purchaser: Purchaser?, ?purchase_order: String?, ?license_types: Array[String]?, ?last_renewal: dateTime?, ?expiration: dateTime?) -> void
|
48
|
+
|
49
|
+
def alt_ids: () -> Array[String]?
|
50
|
+
def alt_ids=: (Array[String]?) -> Array[String]?
|
51
|
+
def alt_ids?: () -> bool
|
52
|
+
def alt_ids_valid?: () -> bool
|
53
|
+
|
54
|
+
def licensor: () -> Licensor?
|
55
|
+
def licensor=: (Licensor?) -> Licensor?
|
56
|
+
def licensor?: () -> bool
|
57
|
+
def licensor_valid?: () -> bool
|
58
|
+
|
59
|
+
def licensee: () -> Licensee?
|
60
|
+
def licensee=: (Licensee?) -> Licensee?
|
61
|
+
def licensee?: () -> bool
|
62
|
+
def licensee_valid?: () -> bool
|
63
|
+
|
64
|
+
def purchaser: () -> Purchaser?
|
65
|
+
def purchaser=: (Purchaser?) -> Purchaser?
|
66
|
+
def purchaser?: () -> bool
|
67
|
+
def purchaser_valid?: () -> bool
|
68
|
+
|
69
|
+
def purchase_order: () -> String?
|
70
|
+
def purchase_order=: (String?) -> String?
|
71
|
+
def purchase_order?: () -> bool
|
72
|
+
def purchase_order_valid?: () -> bool
|
73
|
+
|
74
|
+
def license_types: () -> Array[String]?
|
75
|
+
def license_types=: (Array[String]?) -> Array[String]?
|
76
|
+
def license_types?: () -> bool
|
77
|
+
def license_types_valid?: () -> bool
|
78
|
+
|
79
|
+
def last_renewal: () -> dateTime?
|
80
|
+
def last_renewal=: (dateTime?) -> dateTime?
|
81
|
+
def last_renewal?: () -> bool
|
82
|
+
def last_renewal_valid?: () -> bool
|
83
|
+
|
84
|
+
def expiration: () -> dateTime?
|
85
|
+
def expiration=: (dateTime?) -> dateTime?
|
86
|
+
def expiration?: () -> bool
|
87
|
+
def expiration_valid?: () -> bool
|
88
|
+
end
|
89
|
+
|
90
|
+
def initialize: (?bom_ref: String?, ?id: String?, ?name: String?, ?acknowledgement: String?, ?text: Attachment?, ?url: uri?, ?licensing: Licensing?, ?properties: Array[Property]?) -> void
|
91
|
+
|
92
|
+
def bom_ref: () -> String?
|
93
|
+
def bom_ref=: (String?) -> String?
|
94
|
+
def bom_ref?: () -> bool
|
95
|
+
def bom_ref_valid?: () -> bool
|
96
|
+
|
97
|
+
def id: () -> String?
|
98
|
+
def id=: (String?) -> String?
|
99
|
+
def id?: () -> bool
|
100
|
+
def id_valid?: () -> bool
|
101
|
+
|
102
|
+
def name: () -> String?
|
103
|
+
def name=: (String?) -> String?
|
104
|
+
def name?: () -> bool
|
105
|
+
def name_valid?: () -> bool
|
106
|
+
|
107
|
+
def acknowledgement: () -> String?
|
108
|
+
def acknowledgement=: (String?) -> String?
|
109
|
+
def acknowledgement?: () -> bool
|
110
|
+
def acknowledgement_valid?: () -> bool
|
111
|
+
|
112
|
+
def text: () -> Attachment?
|
113
|
+
def text=: (Attachment?) -> Attachment?
|
114
|
+
def text?: () -> bool
|
115
|
+
def text_valid?: () -> bool
|
116
|
+
|
117
|
+
def url: () -> uri?
|
118
|
+
def url=: (uri?) -> uri?
|
119
|
+
def url?: () -> bool
|
120
|
+
def url_valid?: () -> bool
|
121
|
+
|
122
|
+
def licensing: () -> Licensing?
|
123
|
+
def licensing=: (Licensing?) -> Licensing?
|
124
|
+
def licensing?: () -> bool
|
125
|
+
def licensing_valid?: () -> bool
|
126
|
+
|
127
|
+
def properties: () -> Array[Property]?
|
128
|
+
def properties=: (Array[Property]?) -> Array[Property]?
|
129
|
+
def properties?: () -> bool
|
130
|
+
def properties_valid?: () -> bool
|
131
|
+
end
|
132
|
+
end
|
133
|
+
end
|
134
|
+
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
module SBOM
|
2
|
+
module CycloneDX
|
3
|
+
module Record
|
4
|
+
module LicenseChoice
|
5
|
+
type licenseChoice = LicenseExpression | WrappedLicense
|
6
|
+
|
7
|
+
UNION_TYPE: [singleton(LicenseExpression), singleton(WrappedLicense)]
|
8
|
+
|
9
|
+
class WrappedLicense < Base
|
10
|
+
def initialize: (license: License) -> void
|
11
|
+
|
12
|
+
def license: () -> License
|
13
|
+
def license=: (License) -> License
|
14
|
+
def license?: () -> bool
|
15
|
+
def license_valid?: () -> bool
|
16
|
+
end
|
17
|
+
|
18
|
+
class LicenseExpression < Base
|
19
|
+
def initialize: (expression: String, ?acknowledgement: String?, ?bom_ref: String?) -> void
|
20
|
+
|
21
|
+
def expression: () -> String
|
22
|
+
def expression=: (String) -> String
|
23
|
+
def expression?: () -> bool
|
24
|
+
def expression_valid?: () -> bool
|
25
|
+
|
26
|
+
def acknowledgement: () -> String?
|
27
|
+
def acknowledgement=: (String?) -> String?
|
28
|
+
def acknowledgement?: () -> bool
|
29
|
+
def acknowledgement_valid?: () -> bool
|
30
|
+
|
31
|
+
def bom_ref: () -> String?
|
32
|
+
def bom_ref=: (String?) -> String?
|
33
|
+
def bom_ref?: () -> bool
|
34
|
+
def bom_ref_valid?: () -> bool
|
35
|
+
end
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|