Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update README.md #716

Merged
merged 1 commit into from
May 23, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions cyclonedx-bom/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

The [CycloneDX](https://cyclonedx.org/) library provides JSON and XML serialization and derserialization of Software Bill-of-Materials (SBOM) files.

CycloneDX is a lightweight SBOM specification that is easily created, human and machine-readable, and simple to parse.
CycloneDX is a full-stack SBOM/xBOM standard designed for use in application security contexts and supply chain component analysis.

The library is intended to enable developers to:

Expand All @@ -20,7 +20,7 @@ The library is intended to enable developers to:

## Supported CycloneDX versions

This library currently supports CycloneDX 1.3 and 1.4.
This library currently supports CycloneDX 1.3, 1.4 and 1.5.

## Usage

Expand All @@ -31,11 +31,11 @@ use cyclonedx_bom::prelude::*;

let bom_json = r#"{
"bomFormat": "CycloneDX",
"specVersion": "1.3",
"specVersion": "1.5",
"serialNumber": "urn:uuid:3e671687-395b-41f5-a30f-a58921a69b79",
"version": 1
}"#;
let bom = Bom::parse_from_json_v1_3(bom_json.as_bytes()).expect("Failed to parse BOM");
let bom = Bom::parse_from_json_v1_5(bom_json.as_bytes()).expect("Failed to parse BOM");

let validation_result = bom.validate().expect("Failed to validate BOM");
assert_eq!(validation_result, ValidationResult::Passed);
Expand Down Expand Up @@ -66,14 +66,14 @@ let bom = Bom {

let mut output = Vec::<u8>::new();

bom.output_as_json_v1_3(&mut output)
bom.output_as_json_v1_5(&mut output)
.expect("Failed to write BOM");
let output = String::from_utf8(output).expect("Failed to read output as a string");
assert_eq!(
output,
r#"{
"bomFormat": "CycloneDX",
"specVersion": "1.3",
"specVersion": "1.5",
"version": 1,
"serialNumber": "urn:uuid:3e671687-395b-41f5-a30f-a58921a69b79",
"metadata": {
Expand Down