@cyclonedx/cyclonedx-library 6.7.2 → 6.8.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.
- package/README.md +1 -1
- package/dist.d/builders/fromNodePackageJson.node.d.ts +5 -4
- package/dist.d/builders/fromNodePackageJson.node.d.ts.map +1 -1
- package/dist.d/factories/fromNodePackageJson.node.d.ts +7 -6
- package/dist.d/factories/fromNodePackageJson.node.d.ts.map +1 -1
- package/dist.d/factories/license.d.ts +2 -2
- package/dist.d/factories/license.d.ts.map +1 -1
- package/dist.d/factories/packageUrl.d.ts +1 -1
- package/dist.d/factories/packageUrl.d.ts.map +1 -1
- package/dist.d/index.node.d.ts.map +1 -1
- package/dist.d/models/attachment.d.ts +1 -1
- package/dist.d/models/attachment.d.ts.map +1 -1
- package/dist.d/models/bom.d.ts +2 -2
- package/dist.d/models/bom.d.ts.map +1 -1
- package/dist.d/models/component.d.ts +1 -1
- package/dist.d/models/component.d.ts.map +1 -1
- package/dist.d/models/externalReference.d.ts +1 -1
- package/dist.d/models/externalReference.d.ts.map +1 -1
- package/dist.d/models/hash.d.ts +1 -1
- package/dist.d/models/hash.d.ts.map +1 -1
- package/dist.d/models/license.d.ts +1 -1
- package/dist.d/models/license.d.ts.map +1 -1
- package/dist.d/models/lifecycle.d.ts +1 -1
- package/dist.d/models/lifecycle.d.ts.map +1 -1
- package/dist.d/models/swid.d.ts +1 -1
- package/dist.d/models/swid.d.ts.map +1 -1
- package/dist.d/models/vulnerability/analysis.d.ts +1 -1
- package/dist.d/models/vulnerability/analysis.d.ts.map +1 -1
- package/dist.d/models/vulnerability/vulnerability.d.ts +1 -1
- package/dist.d/models/vulnerability/vulnerability.d.ts.map +1 -1
- package/dist.d/serialize/json/normalize.d.ts +1 -1
- package/dist.d/serialize/json/normalize.d.ts.map +1 -1
- package/dist.d/serialize/jsonSerializer.d.ts +1 -1
- package/dist.d/serialize/jsonSerializer.d.ts.map +1 -1
- package/dist.d/serialize/xml/normalize.d.ts +1 -1
- package/dist.d/serialize/xml/normalize.d.ts.map +1 -1
- package/dist.d/serialize/xmlBaseSerializer.d.ts.map +1 -1
- package/dist.d/spec/consts.d.ts.map +1 -1
- package/dist.d/spec/errors.d.ts +21 -0
- package/dist.d/spec/errors.d.ts.map +1 -0
- package/dist.d/spec/index.d.ts +1 -2
- package/dist.d/spec/index.d.ts.map +1 -1
- package/dist.node/builders/fromNodePackageJson.node.js +11 -8
- package/dist.node/builders/fromNodePackageJson.node.js.map +1 -1
- package/dist.node/factories/fromNodePackageJson.node.js +5 -5
- package/dist.node/factories/fromNodePackageJson.node.js.map +1 -1
- package/dist.node/factories/license.js +4 -4
- package/dist.node/factories/license.js.map +1 -1
- package/dist.node/factories/packageUrl.js +3 -3
- package/dist.node/factories/packageUrl.js.map +1 -1
- package/dist.node/index.node.js.map +1 -1
- package/dist.node/models/bom.js +3 -3
- package/dist.node/models/bom.js.map +1 -1
- package/dist.node/models/component.js +2 -2
- package/dist.node/models/component.js.map +1 -1
- package/dist.node/models/swid.js +2 -2
- package/dist.node/models/swid.js.map +1 -1
- package/dist.node/models/vulnerability/analysis.js +2 -2
- package/dist.node/models/vulnerability/analysis.js.map +1 -1
- package/dist.node/models/vulnerability/vulnerability.js +2 -2
- package/dist.node/models/vulnerability/vulnerability.js.map +1 -1
- package/dist.node/resources.node.js +28 -28
- package/dist.node/resources.node.js.map +1 -1
- package/dist.node/serialize/json/normalize.js +17 -15
- package/dist.node/serialize/json/normalize.js.map +1 -1
- package/dist.node/serialize/jsonSerializer.js +4 -3
- package/dist.node/serialize/jsonSerializer.js.map +1 -1
- package/dist.node/serialize/xml/normalize.js +19 -17
- package/dist.node/serialize/xml/normalize.js.map +1 -1
- package/dist.node/serialize/xmlBaseSerializer.js +4 -3
- package/dist.node/serialize/xmlBaseSerializer.js.map +1 -1
- package/dist.node/spec/consts.js +281 -278
- package/dist.node/spec/consts.js.map +1 -1
- package/dist.node/spec/errors.js +25 -0
- package/dist.node/spec/errors.js.map +1 -0
- package/dist.node/spec/index.js +1 -4
- package/dist.node/spec/index.js.map +1 -1
- package/dist.web/lib.dev.js +378 -338
- package/dist.web/lib.dev.js.map +1 -1
- package/dist.web/lib.js +1 -1
- package/dist.web/lib.js.map +1 -1
- package/package.json +72 -10
- package/src/builders/fromNodePackageJson.node.ts +12 -9
- package/src/factories/fromNodePackageJson.node.ts +13 -12
- package/src/factories/license.ts +2 -2
- package/src/factories/packageUrl.ts +2 -2
- package/src/index.node.ts +4 -0
- package/src/models/attachment.ts +1 -1
- package/src/models/bom.ts +3 -3
- package/src/models/component.ts +2 -2
- package/src/models/externalReference.ts +1 -1
- package/src/models/hash.ts +1 -1
- package/src/models/license.ts +1 -1
- package/src/models/lifecycle.ts +1 -1
- package/src/models/swid.ts +2 -2
- package/src/models/vulnerability/analysis.ts +1 -1
- package/src/models/vulnerability/vulnerability.ts +1 -1
- package/src/resources.node.ts +24 -24
- package/src/serialize/json/normalize.ts +13 -10
- package/src/serialize/jsonSerializer.ts +3 -2
- package/src/serialize/xml/normalize.ts +13 -10
- package/src/serialize/xmlBaseSerializer.ts +2 -1
- package/src/spec/consts.ts +23 -20
- package/src/spec/errors.ts +21 -0
- package/src/spec/index.ts +1 -3
package/dist.web/lib.dev.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"lib.dev.js","mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD,O;;;;;;;;;;;ACVA;;;;;;;;;;;;;;;;;EAiBE;;;AAIF,SAAgB,cAAc,CAAK,KAAoB;IACrD,OAAO,KAAK,KAAK,SAAS;AAC5B,CAAC;AAFD,wCAEC;;;;;;;;;;;;ACvBD;;;;;;;;;;;;;;;;;EAiBE;;;AAUF,IAAkB,wBAIjB;AAJD,WAAkB,wBAAwB;IACxC,wDAA4B;IAC5B,8CAAkB;IAClB,iDAAqB;AACvB,CAAC,EAJiB,wBAAwB,wCAAxB,wB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C,CAAC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC;IAC3C,OAAO,YAAY,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE;AAChF,CAAC;AAdD,gDAcC;;;;;;;;;;;;;;AClBD,0FAA0C;;;;;;;;;;;;AClB1C;;;;;;;;;;;;;;;;;EAiBE;;;AAIF,MAAa,mBAAoB,SAAQ,KAAK;IAC5C,YAAa,OAAgB;QAC3B,KAAK,CAAC,0CAA0C,OAAO,EAAE,CAAC;IAC5D,CAAC;CACF;AAJD,kDAIC;AAED,MAAa,8BAA+B,SAAQ,KAAK;IAGvD,YAAa,OAAe,EAAE,KAAW;QACvC,KAAK,CAAC,OAAO,CAAC;QACd,IAAI,CAAC,KAAK,GAAG,KAAK;IACpB,CAAC;CACF;AAPD,wEAOC;;;;;;;;;;;;AClCD;;;;;;;;;;;;;;;;;EAiBE;;;;;;;;;;;;;;;;;AAEF,yFAAwB;AACxB,gFAAgC;;;;;;;;;;;;ACpBhC;;;;;;;;;;;;;;;;;EAiBE;;;;;;;;;;;;;;;;AAEF,qGAA8B;;;;;;;;;;;;ACnB9B;;;;;;;;;;;;;;;;;EAiBE;;;;;;;;;;;;ACjBF;;;;;;;;;;ACAA;;;;;;;;;;;;;;;;UCAA;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;;;UEtBA;UACA;UACA;UACA","sources":["webpack://CycloneDX_library/webpack/universalModuleDefinition","webpack://CycloneDX_library/./src/_helpers/notUndefined.ts","webpack://CycloneDX_library/./src/_helpers/packageUrl.ts","webpack://CycloneDX_library/./src/_helpers/sortable.ts","webpack://CycloneDX_library/./src/_helpers/tree.ts","webpack://CycloneDX_library/./src/_helpers/uri.ts","webpack://CycloneDX_library/./src/enums/attachmentEncoding.ts","webpack://CycloneDX_library/./src/enums/componentScope.ts","webpack://CycloneDX_library/./src/enums/componentType.ts","webpack://CycloneDX_library/./src/enums/externalReferenceType.ts","webpack://CycloneDX_library/./src/enums/hashAlogorithm.ts","webpack://CycloneDX_library/./src/enums/index.ts","webpack://CycloneDX_library/./src/enums/licenseAcknowledgement.ts","webpack://CycloneDX_library/./src/enums/lifecyclePhase.ts","webpack://CycloneDX_library/./src/enums/vulnerability/affectStatus.ts","webpack://CycloneDX_library/./src/enums/vulnerability/analysisJustification.ts","webpack://CycloneDX_library/./src/enums/vulnerability/analysisResponse.ts","webpack://CycloneDX_library/./src/enums/vulnerability/analysisState.ts","webpack://CycloneDX_library/./src/enums/vulnerability/index.ts","webpack://CycloneDX_library/./src/enums/vulnerability/ratingMethod.ts","webpack://CycloneDX_library/./src/enums/vulnerability/severity.ts","webpack://CycloneDX_library/./src/factories/index.common.ts","webpack://CycloneDX_library/./src/factories/index.web.ts","webpack://CycloneDX_library/./src/factories/license.ts","webpack://CycloneDX_library/./src/factories/packageUrl.ts","webpack://CycloneDX_library/./src/index.common.ts","webpack://CycloneDX_library/./src/index.web.ts","webpack://CycloneDX_library/./src/models/attachment.ts","webpack://CycloneDX_library/./src/models/bom.ts","webpack://CycloneDX_library/./src/models/bomLink.ts","webpack://CycloneDX_library/./src/models/bomRef.ts","webpack://CycloneDX_library/./src/models/component.ts","webpack://CycloneDX_library/./src/models/externalReference.ts","webpack://CycloneDX_library/./src/models/hash.ts","webpack://CycloneDX_library/./src/models/index.ts","webpack://CycloneDX_library/./src/models/license.ts","webpack://CycloneDX_library/./src/models/lifecycle.ts","webpack://CycloneDX_library/./src/models/metadata.ts","webpack://CycloneDX_library/./src/models/organizationalContact.ts","webpack://CycloneDX_library/./src/models/organizationalEntity.ts","webpack://CycloneDX_library/./src/models/property.ts","webpack://CycloneDX_library/./src/models/swid.ts","webpack://CycloneDX_library/./src/models/tool.ts","webpack://CycloneDX_library/./src/models/vulnerability/advisory.ts","webpack://CycloneDX_library/./src/models/vulnerability/affect.ts","webpack://CycloneDX_library/./src/models/vulnerability/analysis.ts","webpack://CycloneDX_library/./src/models/vulnerability/credits.ts","webpack://CycloneDX_library/./src/models/vulnerability/index.ts","webpack://CycloneDX_library/./src/models/vulnerability/rating.ts","webpack://CycloneDX_library/./src/models/vulnerability/reference.ts","webpack://CycloneDX_library/./src/models/vulnerability/source.ts","webpack://CycloneDX_library/./src/models/vulnerability/vulnerability.ts","webpack://CycloneDX_library/./src/serialize/baseSerializer.ts","webpack://CycloneDX_library/./src/serialize/bomRefDiscriminator.ts","webpack://CycloneDX_library/./src/serialize/index.common.ts","webpack://CycloneDX_library/./src/serialize/index.web.ts","webpack://CycloneDX_library/./src/serialize/json/index.ts","webpack://CycloneDX_library/./src/serialize/json/normalize.ts","webpack://CycloneDX_library/./src/serialize/json/types.ts","webpack://CycloneDX_library/./src/serialize/jsonSerializer.ts","webpack://CycloneDX_library/./src/serialize/types.ts","webpack://CycloneDX_library/./src/serialize/xml/index.ts","webpack://CycloneDX_library/./src/serialize/xml/normalize.ts","webpack://CycloneDX_library/./src/serialize/xml/types.ts","webpack://CycloneDX_library/./src/serialize/xmlBaseSerializer.ts","webpack://CycloneDX_library/./src/serialize/xmlSerializer.web.ts","webpack://CycloneDX_library/./src/spdx.ts","webpack://CycloneDX_library/./src/spec/_protocol.ts","webpack://CycloneDX_library/./src/spec/consts.ts","webpack://CycloneDX_library/./src/spec/enums.ts","webpack://CycloneDX_library/./src/spec/index.ts","webpack://CycloneDX_library/./src/types/cpe.ts","webpack://CycloneDX_library/./src/types/cwe.ts","webpack://CycloneDX_library/./src/types/index.ts","webpack://CycloneDX_library/./src/types/integer.ts","webpack://CycloneDX_library/./src/types/mimeType.ts","webpack://CycloneDX_library/./src/utils/bomUtility.ts","webpack://CycloneDX_library/./src/utils/index.ts","webpack://CycloneDX_library/./src/validation/errors.ts","webpack://CycloneDX_library/./src/validation/index.common.ts","webpack://CycloneDX_library/./src/validation/index.web.ts","webpack://CycloneDX_library/./src/validation/types.ts","webpack://CycloneDX_library/external commonjs \"packageurl-js\"","webpack://CycloneDX_library/external commonjs \"spdx-expression-parse\"","webpack://CycloneDX_library/webpack/bootstrap","webpack://CycloneDX_library/webpack/before-startup","webpack://CycloneDX_library/webpack/startup","webpack://CycloneDX_library/webpack/after-startup"],"sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"CycloneDX_library\"] = factory();\n\telse\n\t\troot[\"CycloneDX_library\"] = factory();\n})(self, () => {\nreturn ","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport type NotUndefined<T> = T extends undefined ? never : T\n\nexport function isNotUndefined<T> (value: T | undefined): value is NotUndefined<T> {\n return value !== undefined\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * Known PURL qualifier names.\n * To be used until {@link https://github.com/package-url/packageurl-js/pull/34 | PackageURL PR#34} gets merged and released,\n * and {@link https://github.com/package-url/packageurl-js/issues/35 | PackageURL Issue#35} gets sorted out.\n *\n * For the list/spec of the well-known keys,\n * see {@link https://github.com/package-url/purl-spec/blob/master/PURL-SPECIFICATION.rst#known-qualifiers-keyvalue-pairs | known qualifiers key/value-pairs}\n */\nexport const enum PackageUrlQualifierNames {\n DownloadURL = 'download_url',\n VcsUrl = 'vcs_url',\n Checksum = 'checksum',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Stringable } from './stringable'\n\nexport interface Sortable<TItem> {\n sorted: () => TItem[]\n}\n\nexport interface Comparable<TOther> {\n /**\n * Compare one object with another.\n *\n * The purpose of this method is not to test for equality, but have deterministic comparability.\n * As long as this method is deterministic, there is no need for a proper ordering in any result/downstream.\n */\n compare: (other: TOther) => number\n}\n\nexport const compareObjectsSymbol = Symbol('internal compare function')\n\nexport type SortableIterable<TItem> = Iterable<TItem> & Sortable<TItem>\n\nexport abstract class SortableSet<TItem> extends Set<TItem> implements SortableIterable<TItem>, Comparable<Sortable<TItem>> {\n /**\n * Comparator function to apply to two items.\n */\n protected abstract [compareObjectsSymbol] (a: TItem, b: TItem): number\n\n /**\n * Get a sorted array of all items in the collection..\n */\n sorted (): TItem[] {\n return Array.from(this).sort(this[compareObjectsSymbol])\n }\n\n /**\n * Comparator function to apply to two objects of the collection..\n */\n compare (other: Sortable<TItem>): number {\n const sortedOther = other.sorted()\n const sortedSelf = this.sorted()\n\n if (sortedSelf.length !== sortedOther.length) {\n return sortedSelf.length - sortedOther.length\n }\n\n // it was asserted, that both lists have equal length -> zip-like compare\n for (let i = sortedSelf.length - 1; i >= 0; --i) {\n const iCompared = this[compareObjectsSymbol](sortedSelf[i], sortedOther[i])\n if (iCompared !== 0) {\n return iCompared\n }\n }\n\n return 0\n }\n}\n\nexport class SortableComparables<TItem extends Comparable<any>> extends SortableSet<TItem> {\n protected [compareObjectsSymbol] (a: TItem, b: TItem): number {\n if (a.constructor === b.constructor) {\n return a.compare(b)\n }\n return a.constructor.name.localeCompare(b.constructor.name)\n }\n}\n\nexport class SortableStringables<TItem extends Stringable = Stringable> extends SortableSet<TItem> {\n protected [compareObjectsSymbol] (a: TItem, b: TItem): number {\n return a.toString().localeCompare(b.toString())\n }\n}\n\nexport class SortableNumbers<TItem extends number = number> extends SortableSet<TItem> {\n protected [compareObjectsSymbol] (a: TItem, b: TItem): number {\n return a - b\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport const treeIteratorSymbol = Symbol('iterator of a tree/nesting-like structure')\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nconst escapeMap: Readonly<Record<string, string>> = Object.freeze({\n ' ': '%20',\n '[': '%5B',\n ']': '%5D',\n '<': '%3C',\n '>': '%3E',\n '{': '%7B',\n '}': '%7D'\n})\n\n/**\n * Make a string valid to\n * - XML::anyURI spec.\n * - JSON::iri-reference spec.\n *\n * BEST EFFORT IMPLEMENTATION\n *\n * @see http://www.w3.org/TR/xmlschema-2/#anyURI\n * @see http://www.datypic.com/sc/xsd/t-xsd_anyURI.html\n * @see https://datatracker.ietf.org/doc/html/rfc2396\n * @see https://datatracker.ietf.org/doc/html/rfc3987\n */\nexport function escapeUri<T extends (string | undefined)> (value: T): T {\n if (value === undefined) {\n return value\n }\n for (const [s, r] of Object.entries(escapeMap)) {\n /* @ts-expect-error -- TS does not properly detect that value is to be forced as string, here */\n value = value.replace(s, r)\n }\n return value\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum AttachmentEncoding {\n Base64 = 'base64',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum ComponentScope {\n Required = 'required',\n Optional = 'optional',\n Excluded = 'excluded',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum ComponentType {\n Application = 'application',\n Framework = 'framework',\n Library = 'library',\n Container = 'container',\n Platform = 'platform',\n OperatingSystem = 'operating-system',\n Device = 'device',\n DeviceDriver = 'device-driver',\n Firmware = 'firmware',\n File = 'file',\n MachineLearningModel = 'machine-learning-model',\n Data = 'data',\n CryptographicAsset = 'cryptographic-asset',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum ExternalReferenceType {\n VCS = 'vcs',\n IssueTracker = 'issue-tracker',\n Website = 'website',\n Advisories = 'advisories',\n BOM = 'bom',\n MailingList = 'mailing-list',\n Social = 'social',\n Chat = 'chat',\n Documentation = 'documentation',\n Support = 'support',\n SourceDistribution = 'source-distribution',\n Distribution = 'distribution',\n DistributionIntake = 'distribution-intake',\n License = 'license',\n BuildMeta = 'build-meta',\n BuildSystem = 'build-system',\n ReleaseNotes = 'release-notes',\n SecurityContact = 'security-contact',\n ModelCard = 'model-card',\n Log = 'log',\n Configuration = 'configuration',\n Evidence = 'evidence',\n Formulation = 'formulation',\n Attestation = 'attestation',\n ThreatModel = 'threat-model',\n AdversaryModel = 'adversary-model',\n RiskAssessment = 'risk-assessment',\n VulnerabilityAssertion = 'vulnerability-assertion',\n ExploitabilityStatement = 'exploitability-statement',\n PentestReport = 'pentest-report',\n StaticAnalysisReport = 'static-analysis-report',\n DynamicAnalysisReport = 'dynamic-analysis-report',\n RuntimeAnalysisReport = 'runtime-analysis-report',\n ComponentAnalysisReport = 'component-analysis-report',\n MaturityReport = 'maturity-report',\n CertificationReport = 'certification-report',\n CodifiedInfrastructure = 'codified-infrastructure',\n QualityMetrics = 'quality-metrics',\n POAM = 'poam',\n ElectronicSignature = 'electronic-signature',\n DigitalSignature = 'digital-signature',\n RFC9116 = 'rfc-9116',\n\n // --\n\n Other = 'other',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum HashAlgorithm {\n MD5 = 'MD5',\n 'SHA-1' = 'SHA-1',\n 'SHA-256' = 'SHA-256',\n 'SHA-384' = 'SHA-384',\n 'SHA-512' = 'SHA-512',\n 'SHA3-256' = 'SHA3-256',\n 'SHA3-384' = 'SHA3-384',\n 'SHA3-512' = 'SHA3-512',\n 'BLAKE2b-256' = 'BLAKE2b-256',\n 'BLAKE2b-384' = 'BLAKE2b-384',\n 'BLAKE2b-512' = 'BLAKE2b-512',\n BLAKE3 = 'BLAKE3',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './attachmentEncoding'\nexport * from './componentScope'\nexport * from './componentType'\nexport * from './externalReferenceType'\nexport * from './hashAlogorithm'\nexport * from './licenseAcknowledgement'\nexport * from './lifecyclePhase'\nexport * as Vulnerability from './vulnerability'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum LicenseAcknowledgement {\n Declared = 'declared',\n Concluded = 'concluded',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum LifecyclePhase {\n Design = 'design',\n PreBuild = 'pre-build',\n Build = 'build',\n PostBuild = 'post-build',\n Operations = 'operations',\n Discovery = 'discovery',\n Decommission = 'decommission',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum AffectStatus {\n Affected = 'affected',\n Unaffected = 'unaffected',\n Unknown = 'unknown',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum AnalysisJustification {\n CodeNotPresent = 'code_not_present',\n CodeNotReachable = 'code_not_reachable',\n RequiresConfiguration = 'requires_configuration',\n RequiresDependency = 'requires_dependency',\n RequiresEnvironment = 'requires_environment',\n ProtectedByCompiler = 'protected_by_compiler',\n ProtectedAtRuntime = 'protected_at_runtime',\n ProtectedAtPerimeter = 'protected_at_perimeter',\n ProtectedByMitigatingControl = 'protected_by_mitigating_control',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { SortableStringables } from '../../_helpers/sortable'\n\nexport enum AnalysisResponse {\n CanNotFix = 'can_not_fix',\n WillNotFix = 'will_not_fix',\n Update = 'update',\n Rollback = 'rollback',\n WorkaroundAvailable = 'workaround_available',\n}\n\nexport class AnalysisResponseRepository extends SortableStringables<AnalysisResponse> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum AnalysisState {\n Resolved = 'resolved',\n ResolvedWithPedigree = 'resolved_with_pedigree',\n Exploitable = 'exploitable',\n InTriage = 'in_triage',\n FalsePositive = 'false_positive',\n NotAffected = 'not_affected',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './affectStatus'\nexport * from './analysisJustification'\nexport * from './analysisResponse'\nexport * from './analysisState'\nexport * from './ratingMethod'\nexport * from './severity'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * Specifies the severity or risk scoring methodology or standard used.\n */\nexport enum RatingMethod {\n /** CVSSv2 - [Common Vulnerability Scoring System v2](https://www.first.org/cvss/v2/) */\n CVSSv2 = 'CVSSv2',\n /** CVSSv3 - [Common Vulnerability Scoring System v3](https://www.first.org/cvss/v3-0/) */\n CVSSv3 = 'CVSSv3',\n /** CVSSv31 - [Common Vulnerability Scoring System v3.1](https://www.first.org/cvss/v3-1/) */\n CVSSv31 = 'CVSSv31',\n /** CVSSv4 - [Common Vulnerability Scoring System v4](https://www.first.org/cvss/v4-0/) */\n CVSSv4 = 'CVSSv4',\n /** OWASP - [OWASP Risk Rating Methodology](https://owasp.org/www-community/OWASP_Risk_Rating_Methodology) */\n OWASP = 'OWASP',\n /** SSVC - [Stakeholder Specific Vulnerability Categorization](https://github.com/CERTCC/SSVC) (all versions) */\n SSVC = 'SSVC',\n\n // --\n\n /** any other */\n Other = 'other',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * Textual representation of the severity of the vulnerability adopted by the analysis method.\n * If the analysis method uses values other than what is provided, the user is expected to translate appropriately.\n */\nexport enum Severity {\n Critical = 'critical',\n High = 'high',\n Medium = 'medium',\n Low = 'low',\n Info = 'info',\n None = 'none',\n Unknown = 'unknown',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n// not everything is public, yet\n\nexport * from './license'\nexport * from './packageUrl'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './index.common'\n\n// region web-specifics\n\n// ... nothing yet\n\n// endregion web-specifics\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { DisjunctiveLicense, License } from '../models'\nimport { LicenseExpression, NamedLicense, SpdxLicense } from '../models'\nimport { fixupSpdxId, isValidSpdxLicenseExpression } from '../spdx'\n\nexport class LicenseFactory {\n makeFromString (value: string): License {\n try {\n return this.makeSpdxLicense(value)\n } catch {\n /* pass */\n }\n\n try {\n return this.makeExpression(value)\n } catch {\n /* pass */\n }\n\n return this.makeNamedLicense(value)\n }\n\n /**\n * @throws {@link RangeError} if expression is not eligible\n */\n makeExpression (value: string | any): LicenseExpression {\n const expression = String(value)\n if (isValidSpdxLicenseExpression(expression)) {\n return new LicenseExpression(expression)\n }\n throw new RangeError('Invalid SPDX license expression')\n }\n\n makeDisjunctive (value: string): DisjunctiveLicense {\n try {\n return this.makeSpdxLicense(value)\n } catch {\n return this.makeNamedLicense(value)\n }\n }\n\n /**\n * @throws {@link RangeError} if value is not supported SPDX id\n */\n makeSpdxLicense (value: string | any): SpdxLicense {\n const fixed = fixupSpdxId(String(value))\n if (undefined === fixed) {\n throw new RangeError('Unsupported SPDX license ID')\n }\n\n return new SpdxLicense(fixed)\n }\n\n makeNamedLicense (value: string | any): NamedLicense {\n return new NamedLicense(String(value))\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { PackageURL } from 'packageurl-js'\n\nimport { PackageUrlQualifierNames } from '../_helpers/packageUrl'\nimport { ExternalReferenceType } from '../enums'\nimport type { Component } from '../models'\n\nexport class PackageUrlFactory {\n readonly #type: PackageURL['type']\n\n constructor (type: PackageUrlFactory['type']) {\n this.#type = type\n }\n\n get type (): PackageURL['type'] {\n return this.#type\n }\n\n makeFromComponent (component: Component, sort: boolean = false): PackageURL | undefined {\n const qualifiers: PackageURL['qualifiers'] = {}\n let subpath: PackageURL['subpath']\n\n // sorting to allow reproducibility: use the last instance for a `extRef.type`, if multiples exist\n const extRefs = sort\n ? component.externalReferences.sorted()\n : component.externalReferences\n for (const extRef of extRefs) {\n const url = extRef.url.toString()\n if (url.length <= 0) {\n continue\n }\n // No further need for validation.\n // According to https://github.com/package-url/purl-spec/blob/master/PURL-TYPES.rst\n // there is no formal requirement to a `..._url`.\n // Everything is possible: URL-encoded, not encoded, with schema, without schema\n switch (extRef.type) {\n case ExternalReferenceType.VCS:\n [qualifiers[PackageUrlQualifierNames.VcsUrl], subpath] = url.split('#', 2)\n break\n case ExternalReferenceType.Distribution:\n qualifiers[PackageUrlQualifierNames.DownloadURL] = url\n break\n }\n }\n\n const hashes = component.hashes\n if (hashes.size > 0) {\n qualifiers[PackageUrlQualifierNames.Checksum] = Array.from(\n sort\n ? hashes.sorted()\n : hashes,\n ([hashAlgo, hashCont]) => `${hashAlgo.toLowerCase()}:${hashCont.toLowerCase()}`\n ).join(',')\n }\n\n try {\n // Do not beautify the parameters here, because that is in the domain of PackageURL and its representation.\n // No need to convert an empty \"subpath\" string to `undefined` and such.\n return new PackageURL(\n this.#type,\n component.group,\n component.name,\n component.version,\n qualifiers,\n subpath\n )\n } catch {\n return undefined\n }\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * as Enums from './enums'\nexport * as Models from './models'\nexport * as SPDX from './spdx'\nexport * as Spec from './spec'\nexport * as Types from './types'\nexport * as Utils from './utils'\n// do not export the _helpers, they are for internal use only\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './index.common'\n\n// region web-specifics\n\nexport * as Factories from './factories/index.web'\nexport * as Serialize from './serialize/index.web'\nexport * as Validation from './validation/index.web'\n\n// endregion web-specifics\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Stringable } from '../_helpers/stringable'\nimport type { AttachmentEncoding } from '../enums'\n\nexport interface OptionalAttachmentProperties {\n contentType?: Attachment['contentType']\n encoding?: Attachment['encoding']\n}\n\nexport class Attachment {\n contentType?: string\n content: Stringable\n encoding?: AttachmentEncoding\n\n constructor (content: Attachment['content'], op: OptionalAttachmentProperties = {}) {\n this.contentType = op.contentType\n this.content = content\n this.encoding = op.encoding\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { PositiveInteger } from '../types'\nimport { isPositiveInteger } from '../types'\nimport { ComponentRepository } from './component'\nimport { Metadata } from './metadata'\nimport { VulnerabilityRepository } from './vulnerability'\n\nexport interface OptionalBomProperties {\n metadata?: Bom['metadata']\n components?: Bom['components']\n version?: Bom['version']\n vulnerabilities?: Bom['vulnerabilities']\n serialNumber?: Bom['serialNumber']\n}\n\nexport class Bom {\n metadata: Metadata\n components: ComponentRepository\n vulnerabilities: VulnerabilityRepository\n\n /** @see {@link version} */\n #version: PositiveInteger = 1\n\n /** @see {@link serialNumber} */\n #serialNumber?: string\n\n // Property `bomFormat` is not part of model, it is runtime information.\n // Property `specVersion` is not part of model, it is runtime information.\n\n // Property `dependencies` is not part of this model, but part of `Component` and other models.\n // The dependency graph can be normalized on render-time, no need to store it in the bom model.\n\n /**\n * @throws {@link TypeError} if `op.version` is neither {@link PositiveInteger} nor `undefined`\n */\n constructor (op: OptionalBomProperties = {}) {\n this.metadata = op.metadata ?? new Metadata()\n this.components = op.components ?? new ComponentRepository()\n this.version = op.version ?? this.version\n this.vulnerabilities = op.vulnerabilities ?? new VulnerabilityRepository()\n this.serialNumber = op.serialNumber\n }\n\n get version (): PositiveInteger {\n return this.#version\n }\n\n /**\n * @throws {@link TypeError} if value is not {@link PositiveInteger}\n */\n set version (value: PositiveInteger) {\n if (!isPositiveInteger(value)) {\n throw new TypeError('Not PositiveInteger')\n }\n this.#version = value\n }\n\n get serialNumber (): string | undefined {\n return this.#serialNumber\n }\n\n set serialNumber (value: string | undefined) {\n this.#serialNumber = value === ''\n ? undefined\n : value\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../_helpers/sortable'\nimport type { Stringable } from '../_helpers/stringable'\n\nabstract class BomLinkBase implements Stringable, Comparable<Stringable> {\n /* @ts-expect-error TS2564 */\n #value: string\n\n /** @internal */\n protected abstract _isValid (value: any): boolean\n\n /**\n * @throws {@link RangeError} if value is invalid\n */\n constructor (value: string) {\n this.value = value\n }\n\n /**\n * @throws {@link RangeError} if value is invalid\n */\n set value (value: string) {\n if (!this._isValid(value)) {\n throw new RangeError('invalid value')\n }\n this.#value = value\n }\n\n get value (): string {\n return this.#value\n }\n\n compare (other: Stringable): number {\n return this.toString().localeCompare(other.toString())\n }\n\n toString (): string {\n return this.value\n }\n}\n\n/**\n * Descriptor for another BOM document.\n *\n * See [the docs](https://cyclonedx.org/capabilities/bomlink/)\n */\nexport class BomLinkDocument extends BomLinkBase {\n /* regular expressions were taken from the CycloneDX schema definitions. */\n static readonly #pattern = /^urn:cdx:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\\/[1-9][0-9]*$/\n\n /**\n * Whether the `value` is a valid descriptor for another BOM document.\n */\n static isValid (value: any): boolean {\n return typeof value === 'string' &&\n this.#pattern.test(value)\n }\n\n /** @internal */\n protected _isValid (value: any): boolean {\n return BomLinkDocument.isValid(value)\n }\n}\n\n/**\n * Descriptor for an element in a BOM document.\n *\n * See [the docs](https://cyclonedx.org/capabilities/bomlink/)\n */\nexport class BomLinkElement extends BomLinkBase {\n /* regular expressions were taken from the CycloneDX schema definitions. */\n static readonly #pattern = /^urn:cdx:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\\/[1-9][0-9]*#.+$/\n\n /**\n * Whether the `value` is a valid descriptor for an element in a BOM document.\n */\n static isValid (value: any): boolean {\n return typeof value === 'string' &&\n this.#pattern.test(value)\n }\n\n /** @internal */\n protected _isValid (value: any): boolean {\n return BomLinkElement.isValid(value)\n }\n}\n\n/**\n * Either {@link BomLinkDocument} or {@link BomLinkElement}.\n *\n * See [the docs](https://cyclonedx.org/capabilities/bomlink/)\n */\nexport type BomLink = BomLinkDocument | BomLinkElement\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../_helpers/sortable'\nimport type { Stringable } from '../_helpers/stringable'\n\n/**\n * Proxy for the BomRef.\n * This way a `BomRef` gets unique by the in-memory-address of the object.\n */\nexport class BomRef implements Stringable, Comparable<Stringable> {\n value?: string\n\n constructor (value?: BomRef['value']) {\n this.value = value\n }\n\n compare (other: Stringable): number {\n return this.toString().localeCompare(other.toString())\n }\n\n toString (): string {\n return this.value ?? ''\n }\n}\n\nexport class BomRefRepository extends Set<BomRef> {\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { PackageURL } from 'packageurl-js'\n\nimport type { Comparable } from '../_helpers/sortable'\nimport { SortableComparables, SortableStringables } from '../_helpers/sortable'\nimport type { Stringable } from '../_helpers/stringable'\nimport { treeIteratorSymbol } from '../_helpers/tree'\nimport type { ComponentScope, ComponentType } from '../enums'\nimport type { CPE } from '../types'\nimport { isCPE } from '../types'\nimport { BomRef, BomRefRepository } from './bomRef'\nimport { ExternalReferenceRepository } from './externalReference'\nimport { HashDictionary } from './hash'\nimport { LicenseRepository } from './license'\nimport type { OrganizationalEntity } from './organizationalEntity'\nimport { PropertyRepository } from './property'\nimport type { SWID } from './swid'\n\nexport interface OptionalComponentProperties {\n bomRef?: BomRef['value']\n author?: Component['author']\n copyright?: Component['copyright']\n description?: Component['description']\n externalReferences?: Component['externalReferences']\n group?: Component['group']\n hashes?: Component['hashes']\n licenses?: Component['licenses']\n publisher?: Component['publisher']\n purl?: Component['purl']\n scope?: Component['scope']\n supplier?: Component['supplier']\n swid?: Component['swid']\n version?: Component['version']\n dependencies?: Component['dependencies']\n components?: Component['components']\n cpe?: Component['cpe']\n properties?: Component['properties']\n evidence?: Component['evidence']\n}\n\nexport class Component implements Comparable<Component> {\n type: ComponentType\n name: string\n author?: string\n copyright?: Stringable\n description?: string\n externalReferences: ExternalReferenceRepository\n group?: string\n hashes: HashDictionary\n licenses: LicenseRepository\n publisher?: string\n purl?: PackageURL\n scope?: ComponentScope\n supplier?: OrganizationalEntity\n swid?: SWID\n version?: string\n dependencies: BomRefRepository\n components: ComponentRepository\n properties: PropertyRepository\n evidence?: ComponentEvidence\n\n /** @see {@link bomRef} */\n readonly #bomRef: BomRef\n\n /** @see {@link cpe} */\n #cpe?: CPE\n\n /**\n * @throws {@link TypeError} if `op.cpe` is neither {@link CPE} nor `undefined`\n */\n constructor (type: Component['type'], name: Component['name'], op: OptionalComponentProperties = {}) {\n this.#bomRef = new BomRef(op.bomRef)\n this.type = type\n this.name = name\n this.supplier = op.supplier\n this.author = op.author\n this.copyright = op.copyright\n this.externalReferences = op.externalReferences ?? new ExternalReferenceRepository()\n this.group = op.group\n this.hashes = op.hashes ?? new HashDictionary()\n this.licenses = op.licenses ?? new LicenseRepository()\n this.publisher = op.publisher\n this.purl = op.purl\n this.scope = op.scope\n this.swid = op.swid\n this.version = op.version\n this.description = op.description\n this.dependencies = op.dependencies ?? new BomRefRepository()\n this.components = op.components ?? new ComponentRepository()\n this.cpe = op.cpe\n this.properties = op.properties ?? new PropertyRepository()\n this.evidence = op.evidence\n }\n\n get bomRef (): BomRef {\n return this.#bomRef\n }\n\n get cpe (): CPE | undefined {\n return this.#cpe\n }\n\n /**\n * @throws {@link TypeError} if value is neither {@link CPE} nor `undefined`\n */\n set cpe (value: CPE | undefined) {\n if (value !== undefined && !isCPE(value)) {\n throw new TypeError('Not CPE nor undefined')\n }\n this.#cpe = value\n }\n\n compare (other: Component): number {\n // The purpose of this method is not to test for equality, but have deterministic comparability.\n const bomRefCompare = this.bomRef.compare(other.bomRef)\n if (bomRefCompare !== 0) {\n return bomRefCompare\n }\n if (this.purl !== undefined && other.purl !== undefined) {\n return this.purl.toString().localeCompare(other.purl.toString())\n }\n if (this.#cpe !== undefined && other.#cpe !== undefined) {\n return this.#cpe.localeCompare(other.#cpe)\n }\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.group ?? '').localeCompare(other.group ?? '') ||\n this.name.localeCompare(other.name) ||\n (this.version ?? '').localeCompare(other.version ?? '')\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class ComponentRepository extends SortableComparables<Component> {\n * [treeIteratorSymbol] (): Generator<Component> {\n for (const component of this) {\n yield component\n yield * component.components[treeIteratorSymbol]()\n }\n }\n}\n\nexport interface OptionalComponentEvidenceProperties {\n licenses?: ComponentEvidence['licenses']\n copyright?: ComponentEvidence['copyright']\n}\n\nexport class ComponentEvidence {\n licenses: LicenseRepository\n copyright: SortableStringables\n\n constructor (op: OptionalComponentEvidenceProperties = {}) {\n this.licenses = op.licenses ?? new LicenseRepository()\n this.copyright = op.copyright ?? new SortableStringables()\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../_helpers/sortable'\nimport { SortableComparables } from '../_helpers/sortable'\nimport type { ExternalReferenceType } from '../enums'\nimport type { BomLink } from './bomLink'\nimport { HashDictionary } from './hash'\n\nexport interface OptionalExternalReferenceProperties {\n hashes?: ExternalReference['hashes']\n comment?: ExternalReference['comment']\n}\n\nexport class ExternalReference implements Comparable<ExternalReference> {\n url: URL | BomLink | string\n type: ExternalReferenceType\n hashes: HashDictionary\n comment?: string\n\n constructor (url: ExternalReference['url'], type: ExternalReference['type'], op: OptionalExternalReferenceProperties = {}) {\n this.url = url\n this.type = type\n this.hashes = op.hashes ?? new HashDictionary()\n this.comment = op.comment\n }\n\n compare (other: ExternalReference): number {\n // The purpose of this method is not to test for equality, but have deterministic comparability.\n /* eslint-disable-next-line @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return this.type.localeCompare(other.type) ||\n this.url.toString().localeCompare(other.url.toString())\n }\n}\n\nexport class ExternalReferenceRepository extends SortableComparables<ExternalReference> {\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Sortable } from '../_helpers/sortable'\nimport type { HashAlgorithm } from '../enums'\n\n// no regex for the HashContent in here. It applies at runtime of a normalization/serialization process.\nexport type HashContent = string\n\nexport type Hash = readonly [\n // order matters: it must reflect [key, value] of HashDictionary -\n // this way a HashDictionary can be constructed from multiple Hash objects.\n /* algorithm: */ HashAlgorithm,\n /* content: */ HashContent,\n // cannot use named tuple syntax ala `[a: T1, b: T2]` as it causes errors when downstream-projects compile with older versions of TypeScript\n]\n\nexport class HashDictionary extends Map<Hash[0], Hash[1]> implements Sortable<Hash> {\n static #compareItems ([a1, c1]: Hash, [a2, c2]: Hash): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return a1.localeCompare(a2) ||\n c1.localeCompare(c2)\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n\n sorted (): Hash[] {\n return Array.from(this.entries()).sort(HashDictionary.#compareItems)\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './attachment'\nexport * from './bom'\nexport * from './bomLink'\nexport * from './bomRef'\nexport * from './component'\nexport * from './externalReference'\nexport * from './hash'\nexport * from './license'\nexport * from './lifecycle'\nexport * from './metadata'\nexport * from './organizationalContact'\nexport * from './organizationalEntity'\nexport * from './property'\nexport * from './swid'\nexport * from './tool'\nexport * as Vulnerability from './vulnerability'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Sortable } from '../_helpers/sortable'\nimport type { LicenseAcknowledgement } from '../enums'\nimport type { SpdxId } from '../spdx'\nimport type { Attachment } from './attachment'\n\n/**\n * (SPDX) License Expression.\n *\n * No validation is done internally.\n * You may validate with {@link SPDX.isValidSpdxLicenseExpression | SPDX.isValidSpdxLicenseExpression()}.\n * You may assert valid objects with {@link Factories.LicenseFactory.makeExpression | Factories.LicenseFactory.makeExpression()}.\n */\nexport class LicenseExpression {\n /** @see {@link expression} */\n #expression!: string\n acknowledgement?: LicenseAcknowledgement\n\n /**\n * @throws {@link RangeError} if `expression` is empty string\n */\n constructor (expression: LicenseExpression['expression']) {\n this.expression = expression\n }\n\n get expression (): string {\n return this.#expression\n }\n\n /**\n * @throws {@link RangeError} if `value` is empty string\n */\n set expression (value: string) {\n if (value === '') {\n throw new RangeError('value is empty string')\n }\n this.#expression = value\n }\n\n compare (other: LicenseExpression): number {\n return this.#expression.localeCompare(other.#expression)\n }\n}\n\nclass DisjunctiveLicenseBase {\n acknowledgement?: LicenseAcknowledgement\n text?: Attachment\n #url?: URL | string\n\n constructor (op: OptionalDisjunctiveLicenseProperties = {}) {\n this.acknowledgement = op.acknowledgement\n this.text = op.text\n this.url = op.url\n }\n\n get url (): URL | string | undefined {\n return this.#url\n }\n\n set url (value: URL | string | undefined) {\n this.#url = value === ''\n ? undefined\n : value\n }\n}\n\ninterface OptionalDisjunctiveLicenseProperties {\n acknowledgement?: DisjunctiveLicenseBase['acknowledgement']\n text?: DisjunctiveLicenseBase['text']\n url?: DisjunctiveLicenseBase['url']\n}\n\nexport interface OptionalNamedLicenseProperties extends OptionalDisjunctiveLicenseProperties {}\n\nexport class NamedLicense extends DisjunctiveLicenseBase {\n name: string\n\n constructor (name: string, op: OptionalNamedLicenseProperties = {}) {\n super(op)\n this.name = name\n }\n\n compare (other: NamedLicense): number {\n return this.name.localeCompare(other.name)\n }\n}\n\nexport interface OptionalSpdxLicenseProperties extends OptionalDisjunctiveLicenseProperties {}\n\n/**\n * Disjunctive license with (SPDX-)ID - aka SpdxLicense.\n *\n * No validation is done internally.\n * You may validate with {@link SPDX.isSupportedSpdxId | SPDX.isSupportedSpdxId()}.\n * You may assert valid objects with {@link Factories.LicenseFactory.makeSpdxLicense | Factories.LicenseFactory.makeSpdxLicense()}.\n */\nexport class SpdxLicense extends DisjunctiveLicenseBase {\n /** @see {@link id} */\n #id!: SpdxId\n\n /**\n * @throws {@link RangeError} if `id` is empy string\n */\n constructor (id: SpdxId, op: OptionalSpdxLicenseProperties = {}) {\n super(op)\n this.id = id\n }\n\n get id (): SpdxId {\n return this.#id\n }\n\n /**\n * @throws {@link RangeError} if `value` is empy string\n */\n set id (value: SpdxId) {\n if (value === '') {\n throw new RangeError('value is empty string')\n }\n this.#id = value\n }\n\n compare (other: SpdxLicense): number {\n return this.#id.localeCompare(other.#id)\n }\n}\n\nexport type DisjunctiveLicense = NamedLicense | SpdxLicense\nexport type License = DisjunctiveLicense | LicenseExpression\n\nexport class LicenseRepository extends Set<License> implements Sortable<License> {\n static #compareItems (a: License, b: License): number {\n if (a.constructor === b.constructor) {\n // @ts-expect-error -- classes are from same type -> they are comparable\n return a.compare(b)\n }\n return a.constructor.name.localeCompare(b.constructor.name)\n }\n\n sorted (): License[] {\n return Array.from(this).sort(LicenseRepository.#compareItems)\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable, Sortable } from '../_helpers/sortable'\nimport type { LifecyclePhase } from '../enums'\n\nexport interface OptionalNamedLifecycleProperties {\n description?: NamedLifecycle['description']\n}\n\nexport class NamedLifecycle implements Comparable<NamedLifecycle> {\n name: string\n description?: string\n\n constructor (name: string, op: OptionalNamedLifecycleProperties = {}) {\n this.name = name\n this.description = op.description\n }\n\n compare (other: NamedLifecycle): number {\n return this.name.localeCompare(other.name)\n }\n}\n\nexport type Lifecycle = LifecyclePhase | NamedLifecycle\n\nexport class LifecycleRepository extends Set<Lifecycle> implements Sortable<Lifecycle> {\n static #compareItems (a: Lifecycle, b: Lifecycle): number {\n if (a.constructor === b.constructor) {\n return a instanceof NamedLifecycle\n ? a.compare(b as NamedLifecycle)\n : (a as string).localeCompare(b as string)\n }\n return a.constructor.name.localeCompare(b.constructor.name)\n }\n\n sorted (): Lifecycle[] {\n return Array.from(this).sort(LifecycleRepository.#compareItems)\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Component } from './component'\nimport { LicenseRepository } from './license'\nimport { LifecycleRepository } from './lifecycle'\nimport { OrganizationalContactRepository } from './organizationalContact'\nimport type { OrganizationalEntity } from './organizationalEntity'\nimport { PropertyRepository } from './property'\nimport { ToolRepository } from './tool'\n\nexport interface OptionalMetadataProperties {\n timestamp?: Metadata['timestamp']\n lifecycles?: Metadata['lifecycles']\n tools?: Metadata['tools']\n authors?: Metadata['authors']\n component?: Metadata['component']\n manufacture?: Metadata['manufacture']\n supplier?: Metadata['supplier']\n licenses?: Metadata['licenses']\n properties?: Metadata['properties']\n}\n\nexport class Metadata {\n timestamp?: Date\n lifecycles: LifecycleRepository\n tools: ToolRepository\n authors: OrganizationalContactRepository\n component?: Component\n manufacture?: OrganizationalEntity\n supplier?: OrganizationalEntity\n licenses: LicenseRepository\n properties: PropertyRepository\n\n constructor (op: OptionalMetadataProperties = {}) {\n this.timestamp = op.timestamp\n this.lifecycles = op.lifecycles ?? new LifecycleRepository()\n this.tools = op.tools ?? new ToolRepository()\n this.authors = op.authors ?? new OrganizationalContactRepository()\n this.component = op.component\n this.manufacture = op.manufacture\n this.supplier = op.supplier\n this.licenses = op.licenses ?? new LicenseRepository()\n this.properties = op.properties ?? new PropertyRepository()\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../_helpers/sortable'\nimport { SortableComparables } from '../_helpers/sortable'\n\nexport interface OptionalOrganizationalContactProperties {\n name?: OrganizationalContact['name']\n email?: OrganizationalContact['email']\n phone?: OrganizationalContact['phone']\n}\n\nexport class OrganizationalContact implements Comparable<OrganizationalContact> {\n name?: string\n email?: string\n phone?: string\n\n constructor (op: OptionalOrganizationalContactProperties = {}) {\n this.name = op.name\n this.email = op.email\n this.phone = op.phone\n }\n\n compare (other: OrganizationalContact): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.name ?? '').localeCompare(other.name ?? '') ||\n (this.email ?? '').localeCompare(other.email ?? '') ||\n (this.phone ?? '').localeCompare(other.phone ?? '')\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class OrganizationalContactRepository extends SortableComparables<OrganizationalContact> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../_helpers/sortable'\nimport { SortableComparables, SortableStringables } from '../_helpers/sortable'\nimport { OrganizationalContactRepository } from './organizationalContact'\n\nexport interface OptionalOrganizationalEntityProperties {\n name?: OrganizationalEntity['name']\n url?: OrganizationalEntity['url']\n contact?: OrganizationalEntity['contact']\n}\n\nexport class OrganizationalEntity implements Comparable<OrganizationalEntity> {\n name?: string\n url: Set<URL | string>\n contact: OrganizationalContactRepository\n\n constructor (op: OptionalOrganizationalEntityProperties = {}) {\n this.name = op.name\n this.url = op.url ?? new Set()\n this.contact = op.contact ?? new OrganizationalContactRepository()\n }\n\n compare (other: OrganizationalEntity): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.name ?? '').localeCompare(other.name ?? '') ||\n this.contact.compare(other.contact) ||\n (new SortableStringables(this.url)).compare(new SortableStringables(other.url))\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class OrganizationalEntityRepository extends SortableComparables<OrganizationalEntity> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../_helpers/sortable'\nimport { SortableComparables } from '../_helpers/sortable'\n\n/**\n * @see [CycloneDX Property Taxonomy](https://github.com/CycloneDX/cyclonedx-property-taxonomy)\n */\nexport class Property implements Comparable<Property> {\n name: string\n value: string\n\n constructor (name: Property['name'], value: Property['value']) {\n this.name = name\n this.value = value\n }\n\n compare (other: Property): number {\n /* eslint-disable-next-line @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return this.name.localeCompare(other.name) ||\n this.value.localeCompare(other.value)\n }\n}\n\nexport class PropertyRepository extends SortableComparables<Property> {\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { NonNegativeInteger } from '../types'\nimport { isNonNegativeInteger } from '../types'\nimport type { Attachment } from './attachment'\n\nexport interface OptionalSWIDProperties {\n version?: SWID['version']\n patch?: SWID['patch']\n text?: SWID['text']\n url?: SWID['url']\n tagVersion?: SWID['tagVersion']\n}\n\n/**\n * @see {@link https://csrc.nist.gov/projects/Software-Identification-SWID | SWID spec}\n */\nexport class SWID {\n tagId: string\n name: string\n version?: string\n patch?: boolean\n text?: Attachment\n url?: URL | string\n\n /** @see {@link tagVersion} */\n #tagVersion?: NonNegativeInteger\n\n /**\n * @throws {@link TypeError} if `op.tagVersion` is neither {@link NonNegativeInteger} nor `undefined`\n */\n constructor (tagId: SWID['tagId'], name: SWID['name'], op: OptionalSWIDProperties = {}) {\n this.tagId = tagId\n this.name = name\n this.version = op.version\n this.patch = op.patch\n this.text = op.text\n this.url = op.url\n this.tagVersion = op.tagVersion\n }\n\n get tagVersion (): NonNegativeInteger | undefined {\n return this.#tagVersion\n }\n\n /**\n * @throws {@link TypeError} if value is neither {@link NonNegativeInteger} nor `undefined`\n */\n set tagVersion (value: NonNegativeInteger | undefined) {\n if (value !== undefined && !isNonNegativeInteger(value)) {\n throw new TypeError('Not NonNegativeInteger nor undefined')\n }\n this.#tagVersion = value\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../_helpers/sortable'\nimport { SortableComparables } from '../_helpers/sortable'\nimport { ExternalReferenceRepository } from './externalReference'\nimport { HashDictionary } from './hash'\n\nexport interface OptionalToolProperties {\n vendor?: Tool['vendor']\n name?: Tool['name']\n version?: Tool['version']\n hashes?: Tool['hashes']\n externalReferences?: Tool['externalReferences']\n}\n\nexport class Tool implements Comparable<Tool> {\n vendor?: string\n name?: string\n version?: string\n hashes: HashDictionary\n externalReferences: ExternalReferenceRepository\n\n constructor (op: OptionalToolProperties = {}) {\n this.vendor = op.vendor\n this.name = op.name\n this.version = op.version\n this.hashes = op.hashes ?? new HashDictionary()\n this.externalReferences = op.externalReferences ?? new ExternalReferenceRepository()\n }\n\n compare (other: Tool): number {\n // The purpose of this method is not to test for equality, but have deterministic comparability.\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.vendor ?? '').localeCompare(other.vendor ?? '') ||\n (this.name ?? '').localeCompare(other.name ?? '') ||\n (this.version ?? '').localeCompare(other.version ?? '')\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class ToolRepository extends SortableComparables<Tool> {\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../../_helpers/sortable'\nimport { SortableComparables } from '../../_helpers/sortable'\n\nexport interface OptionalAdvisoryProperties {\n title?: Advisory['title']\n}\n\nexport class Advisory implements Comparable<Advisory> {\n title?: string\n url: string | URL\n\n constructor (url: string | URL, op: OptionalAdvisoryProperties = {}) {\n this.url = url\n this.title = op.title\n }\n\n compare (other: Advisory): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return this.url.toString().localeCompare(other.url.toString()) ||\n (this.title ?? '').localeCompare(other.title ?? '')\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class AdvisoryRepository extends SortableComparables<Advisory> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../../_helpers/sortable'\nimport { SortableComparables } from '../../_helpers/sortable'\nimport type { AffectStatus } from '../../enums/vulnerability'\nimport type { BomLinkElement } from '../bomLink'\nimport type { BomRef } from '../bomRef'\n\nexport interface OptionalAffectProperties {\n versions?: Affect['versions']\n}\n\nexport class Affect implements Comparable<Affect> {\n ref: BomRef | BomLinkElement\n versions: AffectedVersionRepository\n\n constructor (ref: Affect['ref'], op: OptionalAffectProperties = {}) {\n this.ref = ref\n this.versions = op.versions ?? new AffectedVersionRepository()\n }\n\n compare (other: Affect): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return this.ref.compare(other.ref) ||\n this.versions.compare(other.versions)\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class AffectRepository extends SortableComparables<Affect> {\n}\n\nexport interface OptionalAffectedVersionProperties {\n status?: AffectedVersion['status']\n}\n\nexport class AffectedSingleVersion implements Comparable<AffectedSingleVersion> {\n version: string\n status?: AffectStatus\n\n constructor (version: string, op: OptionalAffectedVersionProperties = {}) {\n this.version = version\n this.status = op.status\n }\n\n compare (other: AffectedSingleVersion): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.version).localeCompare(other.version) ||\n (this.status ?? '').localeCompare(other.status ?? '')\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class AffectedVersionRange implements Comparable<AffectedVersionRange> {\n range: string\n status?: AffectStatus\n\n constructor (range: string, op: OptionalAffectedVersionProperties = {}) {\n this.range = range\n this.status = op.status\n }\n\n compare (other: AffectedVersionRange): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.range).localeCompare(other.range) ||\n (this.status ?? '').localeCompare(other.status ?? '')\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport type AffectedVersion = AffectedSingleVersion | AffectedVersionRange\n\nexport class AffectedVersionRepository extends SortableComparables<AffectedVersion> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { AnalysisJustification, AnalysisState } from '../../enums/vulnerability'\nimport { AnalysisResponseRepository } from '../../enums/vulnerability'\n\nexport interface OptionalAnalysisProperties {\n state?: Analysis['state']\n justification?: Analysis['justification']\n response?: Analysis['response']\n detail?: Analysis['detail']\n}\n\nexport class Analysis {\n state?: AnalysisState\n justification?: AnalysisJustification\n response: AnalysisResponseRepository\n detail?: string\n\n constructor (op: OptionalAnalysisProperties = {}) {\n this.state = op.state\n this.justification = op.justification\n this.response = op.response ?? new AnalysisResponseRepository()\n this.detail = op.detail\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { OrganizationalContactRepository } from '../organizationalContact'\nimport { OrganizationalEntityRepository } from '../organizationalEntity'\n\nexport interface OptionalCreditsProperties {\n organizations?: Credits['organizations']\n individuals?: Credits['individuals']\n}\n\nexport class Credits {\n organizations: OrganizationalEntityRepository\n individuals: OrganizationalContactRepository\n\n constructor (op: OptionalCreditsProperties = {}) {\n this.organizations = op.organizations ?? new OrganizationalEntityRepository()\n this.individuals = op.individuals ?? new OrganizationalContactRepository()\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './advisory'\nexport * from './affect'\nexport * from './analysis'\nexport * from './credits'\nexport * from './rating'\nexport * from './reference'\nexport * from './source'\nexport * from './vulnerability'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../../_helpers/sortable'\nimport { SortableComparables } from '../../_helpers/sortable'\nimport type { RatingMethod, Severity } from '../../enums/vulnerability'\nimport type { Source } from './source'\n\nexport interface OptionalRatingProperties {\n source?: Rating['source']\n score?: Rating['score']\n severity?: Rating['severity']\n method?: Rating['method']\n vector?: Rating['vector']\n justification?: Rating['justification']\n}\n\nexport class Rating implements Comparable<Rating> {\n source?: Source\n score?: number\n severity?: Severity\n method?: RatingMethod\n vector?: string\n justification?: string\n\n constructor (op: OptionalRatingProperties = {}) {\n this.source = op.source\n this.score = op.score\n this.severity = op.severity\n this.method = op.method\n this.vector = op.vector\n this.justification = op.justification\n }\n\n compare (other: Rating): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return ((this.score ?? 0) - (other.score ?? 0)) ||\n (this.vector ?? '').localeCompare(other.vector ?? '') ||\n (this.justification ?? '').localeCompare(other.justification ?? '') ||\n (this.severity ?? '').localeCompare(other.severity ?? '') ||\n (this.method ?? '').localeCompare(other.method ?? '') ||\n (this.source && other.source ? this.source.compare(other.source) : 0)\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class RatingRepository extends SortableComparables<Rating> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../../_helpers/sortable'\nimport { SortableComparables } from '../../_helpers/sortable'\nimport type { Source } from './source'\n\n/**\n * @privateRemarks\n * The model is built based on the JSON spec, which has all properties mandatory.\n * In contrast to the XML spec, which has them optional.\n * see https://github.com/CycloneDX/specification/issues/154\n */\nexport class Reference implements Comparable<Reference> {\n /**\n * @example values\n * - `CVE-2021-39182`\n * - `GHSA-35m5-8cvj-8783`\n * - `SNYK-PYTHON-ENROCRYPT-1912876`\n */\n id: string\n source: Source\n\n constructor (id: string, source: Source) {\n this.id = id\n this.source = source\n }\n\n compare (other: Reference): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return this.id.localeCompare(other.id) ||\n this.source.compare(other.source)\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class ReferenceRepository extends SortableComparables<Reference> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../../_helpers/sortable'\n\nexport interface OptionalSourceProperties {\n name?: Source['name']\n url?: Source['url']\n}\n\nexport class Source implements Comparable<Source> {\n name?: string\n url?: URL | string\n\n constructor (op: OptionalSourceProperties = {}) {\n this.name = op.name\n this.url = op.url\n }\n\n compare (other: Source): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.url?.toString() ?? '').localeCompare(other.url?.toString() ?? '') ||\n (this.name ?? '').localeCompare(other.name ?? '')\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../../_helpers/sortable'\nimport { SortableComparables } from '../../_helpers/sortable'\nimport { CweRepository } from '../../types'\nimport { BomRef } from '../bomRef'\nimport { PropertyRepository } from '../property'\nimport { ToolRepository } from '../tool'\nimport { AdvisoryRepository } from './advisory'\nimport { AffectRepository } from './affect'\nimport type { Analysis } from './analysis'\nimport type { Credits } from './credits'\nimport { RatingRepository } from './rating'\nimport { ReferenceRepository } from './reference'\nimport type { Source } from './source'\n\nexport interface OptionalVulnerabilityProperties {\n bomRef?: BomRef['value']\n id?: Vulnerability['id']\n source?: Vulnerability['source']\n references?: Vulnerability['references']\n ratings?: Vulnerability['ratings']\n cwes?: Vulnerability['cwes']\n description?: Vulnerability['description']\n detail?: Vulnerability['detail']\n recommendation?: Vulnerability['recommendation']\n advisories?: Vulnerability['advisories']\n created?: Vulnerability['created']\n published?: Vulnerability['published']\n updated?: Vulnerability['updated']\n credits?: Vulnerability['credits']\n tools?: Vulnerability['tools']\n analysis?: Vulnerability['analysis']\n affects?: Vulnerability['affects']\n properties?: Vulnerability['properties']\n}\n\nexport class Vulnerability implements Comparable<Vulnerability> {\n /** @see bomRef */\n readonly #bomRef: BomRef\n id?: string\n source?: Source\n references: ReferenceRepository\n ratings: RatingRepository\n cwes: CweRepository\n description?: string\n detail?: string\n recommendation?: string\n advisories: AdvisoryRepository\n created?: Date\n published?: Date\n updated?: Date\n credits?: Credits\n tools: ToolRepository\n analysis?: Analysis\n affects: AffectRepository\n properties: PropertyRepository\n\n constructor (op: OptionalVulnerabilityProperties = {}) {\n this.#bomRef = new BomRef(op.bomRef)\n this.id = op.id\n this.source = op.source\n this.references = op.references ?? new ReferenceRepository()\n this.ratings = op.ratings ?? new RatingRepository()\n this.cwes = op.cwes ?? new CweRepository()\n this.description = op.description\n this.detail = op.detail\n this.recommendation = op.recommendation\n this.advisories = op.advisories ?? new AdvisoryRepository()\n this.created = op.created\n this.published = op.published\n this.updated = op.updated\n this.credits = op.credits\n this.tools = op.tools ?? new ToolRepository()\n this.analysis = op.analysis\n this.affects = op.affects ?? new AffectRepository()\n this.properties = op.properties ?? new PropertyRepository()\n }\n\n get bomRef (): BomRef {\n return this.#bomRef\n }\n\n compare (other: Vulnerability): number {\n const bomRefCompare = this.bomRef.compare(other.bomRef)\n if (bomRefCompare !== 0) {\n return bomRefCompare\n }\n\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.id ?? '').localeCompare(other.id ?? '') ||\n (this.created?.getTime() ?? 0) - (other.created?.getTime() ?? 0) ||\n (this.published?.getTime() ?? 0) - (other.published?.getTime() ?? 0) ||\n (this.updated?.getTime() ?? 0) - (other.updated?.getTime() ?? 0) ||\n this.ratings.compare(other.ratings) ||\n this.cwes.compare(other.cwes) ||\n (this.description ?? '').localeCompare(other.description ?? '') ||\n (this.detail ?? '').localeCompare(other.detail ?? '') ||\n (this.recommendation ?? '').localeCompare(other.recommendation ?? '') ||\n (this.source && other.source ? this.source.compare(other.source) : 0) ||\n this.properties.compare(other.properties)\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class VulnerabilityRepository extends SortableComparables<Vulnerability> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { treeIteratorSymbol } from '../_helpers/tree'\nimport type { Bom, BomRef } from '../models'\nimport { BomRefDiscriminator } from './bomRefDiscriminator'\nimport type { NormalizerOptions, Serializer, SerializerOptions } from './types'\n\nexport abstract class BaseSerializer<NormalizedBom> implements Serializer {\n * #getAllBomRefs (bom: Bom): Generator<BomRef> {\n // region from components\n if (bom.metadata.component !== undefined) {\n yield bom.metadata.component.bomRef\n for (const { bomRef } of bom.metadata.component.components[treeIteratorSymbol]()) {\n yield bomRef\n }\n }\n for (const { bomRef } of bom.components[treeIteratorSymbol]()) {\n yield bomRef\n }\n // endregion from components\n\n // region from vulnerabilities\n for (const { bomRef } of bom.vulnerabilities) {\n yield bomRef\n }\n // endregion from vulnerabilities\n }\n\n /**\n * @throws {@link Error}\n */\n #normalize (bom: Bom, options?: NormalizerOptions): NormalizedBom {\n const bomRefDiscriminator = new BomRefDiscriminator(this.#getAllBomRefs(bom))\n bomRefDiscriminator.discriminate()\n // This IS NOT the place to put meaning to the BomRef values. This would be out of scope.\n // This IS the place to make BomRef values (temporary) unique in their own document scope.\n try {\n return this._normalize(bom, options)\n } finally {\n bomRefDiscriminator.reset()\n }\n }\n\n /**\n * @readonly\n * @throws {@link Error}\n */\n public serialize (bom: Bom, options?: SerializerOptions & NormalizerOptions): string {\n return this._serialize(\n this.#normalize(bom, options),\n options\n )\n }\n\n /**\n * @throws {@link Error}\n */\n protected abstract _normalize (bom: Bom, options?: NormalizerOptions): NormalizedBom\n\n /**\n * @throws {@link Error}\n */\n protected abstract _serialize (normalizedBom: NormalizedBom, options?: SerializerOptions): string\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { BomRef } from '../models'\n\nexport class BomRefDiscriminator {\n readonly #originalValues: ReadonlyArray<readonly [BomRef, string | undefined]>\n\n readonly #prefix: string\n\n constructor (bomRefs: Iterable<BomRef>, prefix: string = 'BomRef') {\n this.#originalValues = Array.from(bomRefs, r => [r, r.value])\n this.#prefix = prefix\n }\n\n get prefix (): string {\n return this.#prefix\n }\n\n /** Iterate over the {@link BomRef}s. */\n * [Symbol.iterator] (): IterableIterator<BomRef> {\n for (const [bomRef] of this.#originalValues) {\n yield bomRef\n }\n }\n\n discriminate (): void {\n const knownRefValues = new Set<string>([''])\n for (const [bomRef] of this.#originalValues) {\n let value = bomRef.value\n if (value === undefined || knownRefValues.has(value)) {\n value = this.#makeUniqueId()\n bomRef.value = value\n }\n knownRefValues.add(value)\n }\n }\n\n reset (): void {\n for (const [bomRef, originalValue] of this.#originalValues) {\n bomRef.value = originalValue\n }\n }\n\n /**\n * generate a string in the format:\n * `${this.prefix}.<random-characters>.<random-characters>`\n */\n #makeUniqueId (): string {\n return `${\n this.#prefix\n }${\n Math.random().toString(32).substring(1)\n }${\n Math.random().toString(32).substring(1)\n }`\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n// !!! not everything is public, yet\n\nexport * from './bomRefDiscriminator'\nexport * as Types from './types'\n\n// region base\n\nexport * from './baseSerializer'\n// export * from './baseDeserializer' // @TODO\n\n// endregion base\n\n// region JSON\n\nexport * as JSON from './json'\nexport * from './jsonSerializer'\n// export * from './jsonDeserializer' // @TODO\n\n// endregion JSON\n\n// region XML\n\nexport * as XML from './xml'\nexport * from './xmlBaseSerializer'\n// export * from './xmlBaseDeserializer' // @TODO\n\n// endregion XML\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './index.common'\n\n// region web-specifics\n\nexport * from './xmlSerializer.web'\n// export * from './xmlDeserializer.web' // @TODO\n\n// endregion web-specifics\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * as Normalize from './normalize'\nexport * as Types from './types'\n// export * as Denormalize from './denormalize' // @TODO\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { isNotUndefined } from '../../_helpers/notUndefined'\nimport type { SortableIterable } from '../../_helpers/sortable'\nimport type { Stringable } from '../../_helpers/stringable'\nimport { treeIteratorSymbol } from '../../_helpers/tree'\nimport { escapeUri } from '../../_helpers/uri'\nimport * as Models from '../../models'\nimport { isSupportedSpdxId } from '../../spdx'\nimport { Version as SpecVersion } from '../../spec'\nimport type { _SpecProtocol as Spec } from '../../spec/_protocol'\nimport type { NormalizerOptions } from '../types'\nimport type { Normalized } from './types'\nimport { JsonSchema } from './types'\n\nexport class Factory {\n readonly #spec: Spec\n\n constructor (spec: Factory['spec']) {\n this.#spec = spec\n }\n\n get spec (): Spec {\n return this.#spec\n }\n\n makeForBom (): BomNormalizer {\n return new BomNormalizer(this)\n }\n\n makeForMetadata (): MetadataNormalizer {\n return new MetadataNormalizer(this)\n }\n\n makeForComponent (): ComponentNormalizer {\n return new ComponentNormalizer(this)\n }\n\n makeForComponentEvidence (): ComponentEvidenceNormalizer {\n return new ComponentEvidenceNormalizer(this)\n }\n\n makeForLifecycle (): LifecycleNormalizer {\n return new LifecycleNormalizer(this)\n }\n\n makeForTool (): ToolNormalizer {\n return new ToolNormalizer(this)\n }\n\n makeForOrganizationalContact (): OrganizationalContactNormalizer {\n return new OrganizationalContactNormalizer(this)\n }\n\n makeForOrganizationalEntity (): OrganizationalEntityNormalizer {\n return new OrganizationalEntityNormalizer(this)\n }\n\n makeForHash (): HashNormalizer {\n return new HashNormalizer(this)\n }\n\n makeForLicense (): LicenseNormalizer {\n return new LicenseNormalizer(this)\n }\n\n makeForSWID (): SWIDNormalizer {\n return new SWIDNormalizer(this)\n }\n\n makeForExternalReference (): ExternalReferenceNormalizer {\n return new ExternalReferenceNormalizer(this)\n }\n\n makeForAttachment (): AttachmentNormalizer {\n return new AttachmentNormalizer(this)\n }\n\n makeForProperty (): PropertyNormalizer {\n return new PropertyNormalizer(this)\n }\n\n makeForDependencyGraph (): DependencyGraphNormalizer {\n return new DependencyGraphNormalizer(this)\n }\n\n makeForVulnerability (): VulnerabilityNormalizer {\n return new VulnerabilityNormalizer(this)\n }\n\n makeForVulnerabilitySource (): VulnerabilitySourceNormalizer {\n return new VulnerabilitySourceNormalizer(this)\n }\n\n makeForVulnerabilityReference (): VulnerabilityReferenceNormalizer {\n return new VulnerabilityReferenceNormalizer(this)\n }\n\n makeForVulnerabilityRating (): VulnerabilityRatingNormalizer {\n return new VulnerabilityRatingNormalizer(this)\n }\n\n makeForVulnerabilityAdvisory (): VulnerabilityAdvisoryNormalizer {\n return new VulnerabilityAdvisoryNormalizer(this)\n }\n\n makeForVulnerabilityCredits (): VulnerabilityCreditsNormalizer {\n return new VulnerabilityCreditsNormalizer(this)\n }\n\n makeForVulnerabilityAffect (): VulnerabilityAffectNormalizer {\n return new VulnerabilityAffectNormalizer(this)\n }\n\n makeForVulnerabilityAffectedVersion (): VulnerabilityAffectedVersionNormalizer {\n return new VulnerabilityAffectedVersionNormalizer(this)\n }\n\n makeForVulnerabilityAnalysis (): VulnerabilityAnalysisNormalizer {\n return new VulnerabilityAnalysisNormalizer(this)\n }\n}\n\nconst schemaUrl: ReadonlyMap<SpecVersion, string> = new Map([\n [SpecVersion.v1dot6, 'http://cyclonedx.org/schema/bom-1.6.schema.json'],\n [SpecVersion.v1dot5, 'http://cyclonedx.org/schema/bom-1.5.schema.json'],\n [SpecVersion.v1dot4, 'http://cyclonedx.org/schema/bom-1.4.schema.json'],\n [SpecVersion.v1dot3, 'http://cyclonedx.org/schema/bom-1.3a.schema.json'],\n [SpecVersion.v1dot2, 'http://cyclonedx.org/schema/bom-1.2b.schema.json']\n])\n\ninterface JsonNormalizer<TModel, TNormalized> {\n normalize: (data: TModel, options: NormalizerOptions) => TNormalized | undefined\n\n normalizeIterable?: (data: SortableIterable<TModel>, options: NormalizerOptions) => TNormalized[]\n\n}\n\nabstract class BaseJsonNormalizer<TModel, TNormalized = object> implements JsonNormalizer<TModel, TNormalized> {\n protected readonly _factory: Factory\n\n constructor (factory: Factory) {\n this._factory = factory\n }\n\n get factory (): Factory {\n return this._factory\n }\n\n abstract normalize (data: TModel, options: NormalizerOptions): TNormalized | undefined\n}\n\n/* eslint-disable @typescript-eslint/prefer-nullish-coalescing, @typescript-eslint/strict-boolean-expressions --\n * since empty strings need to be treated as undefined/null\n */\n\nexport class BomNormalizer extends BaseJsonNormalizer<Models.Bom> {\n normalize (data: Models.Bom, options: NormalizerOptions): Normalized.Bom {\n return {\n $schema: schemaUrl.get(this._factory.spec.version),\n bomFormat: 'CycloneDX',\n specVersion: this._factory.spec.version,\n version: data.version,\n serialNumber: this.#isEligibleSerialNumber(data.serialNumber)\n ? data.serialNumber\n : undefined,\n metadata: this._factory.makeForMetadata().normalize(data.metadata, options),\n components: data.components.size > 0\n ? this._factory.makeForComponent().normalizeIterable(data.components, options)\n // spec < 1.4 requires `component` to be array\n : [],\n dependencies: this._factory.spec.supportsDependencyGraph\n ? this._factory.makeForDependencyGraph().normalize(data, options)\n : undefined,\n vulnerabilities: this._factory.spec.supportsVulnerabilities && data.vulnerabilities.size > 0\n ? this._factory.makeForVulnerability().normalizeIterable(data.vulnerabilities, options)\n : undefined\n }\n }\n\n #isEligibleSerialNumber (v: string | undefined): boolean {\n return v !== undefined &&\n // see https://github.com/CycloneDX/specification/blob/ef71717ae0ecb564c0b4c9536d6e9e57e35f2e69/schema/bom-1.4.schema.json#L39\n /^urn:uuid:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.test(v)\n }\n}\n\nexport class MetadataNormalizer extends BaseJsonNormalizer<Models.Metadata> {\n normalize (data: Models.Metadata, options: NormalizerOptions): Normalized.Metadata {\n const orgEntityNormalizer = this._factory.makeForOrganizationalEntity()\n return {\n timestamp: data.timestamp?.toISOString(),\n lifecycles: this._factory.spec.supportsMetadataLifecycles && data.lifecycles.size > 0\n ? this._factory.makeForLifecycle().normalizeIterable(data.lifecycles, options)\n : undefined,\n tools: data.tools.size > 0\n ? this._factory.makeForTool().normalizeIterable(data.tools, options)\n : undefined,\n authors: data.authors.size > 0\n ? this._factory.makeForOrganizationalContact().normalizeIterable(data.authors, options)\n : undefined,\n component: data.component === undefined\n ? undefined\n : this._factory.makeForComponent().normalize(data.component, options),\n manufacture: data.manufacture === undefined\n ? undefined\n : orgEntityNormalizer.normalize(data.manufacture, options),\n supplier: data.supplier === undefined\n ? undefined\n : orgEntityNormalizer.normalize(data.supplier, options),\n licenses: this._factory.spec.supportsMetadataLicenses && data.licenses.size > 0\n ? this._factory.makeForLicense().normalizeIterable(data.licenses, options)\n : undefined,\n properties: this._factory.spec.supportsMetadataProperties && data.properties.size > 0\n ? this._factory.makeForProperty().normalizeIterable(data.properties, options)\n : undefined\n }\n }\n}\n\nexport class LifecycleNormalizer extends BaseJsonNormalizer<Models.Lifecycle> {\n normalize (data: Models.Lifecycle, options: NormalizerOptions): Normalized.Lifecycle {\n return data instanceof Models.NamedLifecycle\n ? { name: data.name, description: data.description }\n : { phase: data }\n }\n\n normalizeIterable (data: SortableIterable<Models.Lifecycle>, options: NormalizerOptions): Normalized.Lifecycle[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(lc => this.normalize(lc, options))\n }\n}\n\nexport class ToolNormalizer extends BaseJsonNormalizer<Models.Tool> {\n normalize (data: Models.Tool, options: NormalizerOptions): Normalized.Tool {\n return {\n vendor: data.vendor || undefined,\n name: data.name || undefined,\n version: data.version || undefined,\n hashes: data.hashes.size > 0\n ? this._factory.makeForHash().normalizeIterable(data.hashes, options)\n : undefined,\n externalReferences: this._factory.spec.supportsToolReferences && data.externalReferences.size > 0\n ? this._factory.makeForExternalReference().normalizeIterable(data.externalReferences, options)\n : undefined\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Tool>, options: NormalizerOptions): Normalized.Tool[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(t => this.normalize(t, options))\n }\n}\n\nexport class HashNormalizer extends BaseJsonNormalizer<Models.Hash> {\n normalize ([algorithm, content]: Models.Hash, options: NormalizerOptions): Normalized.Hash | undefined {\n const spec = this._factory.spec\n return spec.supportsHashAlgorithm(algorithm) && spec.supportsHashValue(content)\n ? {\n alg: algorithm,\n content\n }\n : undefined\n }\n\n normalizeIterable (data: SortableIterable<Models.Hash>, options: NormalizerOptions): Normalized.Hash[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n h => this.normalize(h, options)\n ).filter(isNotUndefined)\n }\n}\n\nexport class OrganizationalContactNormalizer extends BaseJsonNormalizer<Models.OrganizationalContact> {\n normalize (data: Models.OrganizationalContact, options: NormalizerOptions): Normalized.OrganizationalContact {\n return {\n name: data.name || undefined,\n email: JsonSchema.isIdnEmail(data.email)\n ? data.email\n : undefined,\n phone: data.phone || undefined\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.OrganizationalContact>, options: NormalizerOptions): Normalized.OrganizationalContact[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(oc => this.normalize(oc, options))\n }\n}\n\nexport class OrganizationalEntityNormalizer extends BaseJsonNormalizer<Models.OrganizationalEntity> {\n normalize (data: Models.OrganizationalEntity, options: NormalizerOptions): Normalized.OrganizationalEntity {\n const urls = normalizeStringableIter(\n Array.from(data.url, (s) => escapeUri(s.toString())),\n options\n ).filter(JsonSchema.isIriReference)\n return {\n name: data.name || undefined,\n url: urls.length > 0\n ? urls\n : undefined,\n contact: data.contact.size > 0\n ? this._factory.makeForOrganizationalContact().normalizeIterable(data.contact, options)\n : undefined\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.OrganizationalEntity>, options: NormalizerOptions): Normalized.OrganizationalEntity[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(oe => this.normalize(oe, options))\n }\n}\n\nexport class ComponentNormalizer extends BaseJsonNormalizer<Models.Component> {\n normalize (data: Models.Component, options: NormalizerOptions): Normalized.Component | undefined {\n const spec = this._factory.spec\n if (!spec.supportsComponentType(data.type)) {\n return undefined\n }\n const version: string = data.version ?? ''\n return {\n type: data.type,\n name: data.name,\n group: data.group || undefined,\n version: version.length > 0 || spec.requiresComponentVersion\n ? version\n : undefined,\n 'bom-ref': data.bomRef.value || undefined,\n supplier: data.supplier === undefined\n ? undefined\n : this._factory.makeForOrganizationalEntity().normalize(data.supplier, options),\n author: data.author || undefined,\n publisher: data.publisher || undefined,\n description: data.description || undefined,\n scope: data.scope,\n hashes: data.hashes.size > 0\n ? this._factory.makeForHash().normalizeIterable(data.hashes, options)\n : undefined,\n licenses: data.licenses.size > 0\n ? this._factory.makeForLicense().normalizeIterable(data.licenses, options)\n : undefined,\n copyright: data.copyright?.toString() || undefined,\n cpe: data.cpe || undefined,\n purl: data.purl?.toString(),\n swid: data.swid === undefined\n ? undefined\n : this._factory.makeForSWID().normalize(data.swid, options),\n externalReferences: data.externalReferences.size > 0\n ? this._factory.makeForExternalReference().normalizeIterable(data.externalReferences, options)\n : undefined,\n properties: spec.supportsProperties(data) && data.properties.size > 0\n ? this._factory.makeForProperty().normalizeIterable(data.properties, options)\n : undefined,\n components: data.components.size > 0\n ? this.normalizeIterable(data.components, options)\n : undefined,\n evidence: spec.supportsComponentEvidence && data.evidence !== undefined\n ? this._factory.makeForComponentEvidence().normalize(data.evidence, options)\n : undefined\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Component>, options: NormalizerOptions): Normalized.Component[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n c => this.normalize(c, options)\n ).filter(isNotUndefined)\n }\n}\n\nexport class ComponentEvidenceNormalizer extends BaseJsonNormalizer<Models.ComponentEvidence> {\n normalize (data: Models.ComponentEvidence, options: NormalizerOptions): Normalized.ComponentEvidence {\n return {\n licenses: data.licenses.size > 0\n ? this._factory.makeForLicense().normalizeIterable(data.licenses, options)\n : undefined,\n copyright: data.copyright.size > 0\n ? (\n options.sortLists\n ? data.copyright.sorted().map(ComponentEvidenceNormalizer.#normalizeCopyright)\n : Array.from(data.copyright, ComponentEvidenceNormalizer.#normalizeCopyright)\n )\n : undefined\n }\n }\n\n static #normalizeCopyright (c: Stringable): Normalized.Copyright {\n return { text: c.toString() }\n }\n}\n\nexport class LicenseNormalizer extends BaseJsonNormalizer<Models.License> {\n normalize (data: Models.License, options: NormalizerOptions): Normalized.License {\n switch (true) {\n case data instanceof Models.NamedLicense:\n return this.#normalizeNamedLicense(data, options)\n case data instanceof Models.SpdxLicense:\n return isSupportedSpdxId(data.id)\n ? this.#normalizeSpdxLicense(data, options)\n : this.#normalizeNamedLicense(new Models.NamedLicense(\n // prevent information loss -> convert to broader type\n data.id,\n { url: data.url }\n ), options)\n case data instanceof Models.LicenseExpression:\n return this.#normalizeLicenseExpression(data)\n /* c8 ignore start */\n default:\n // this case is expected to never happen - and therefore is undocumented\n throw new TypeError('Unexpected LicenseChoice')\n /* c8 ignore end */\n }\n }\n\n #normalizeNamedLicense (data: Models.NamedLicense, options: NormalizerOptions): Normalized.NamedLicense {\n const url = escapeUri(data.url?.toString())\n return {\n license: {\n name: data.name,\n acknowledgement: this._factory.spec.supportsLicenseAcknowledgement\n ? data.acknowledgement\n : undefined,\n text: data.text === undefined\n ? undefined\n : this._factory.makeForAttachment().normalize(data.text, options),\n url: JsonSchema.isIriReference(url)\n ? url\n : undefined\n }\n }\n }\n\n #normalizeSpdxLicense (data: Models.SpdxLicense, options: NormalizerOptions): Normalized.SpdxLicense {\n const url = escapeUri(data.url?.toString())\n return {\n license: {\n id: data.id,\n acknowledgement: this._factory.spec.supportsLicenseAcknowledgement\n ? data.acknowledgement\n : undefined,\n text: data.text === undefined\n ? undefined\n : this._factory.makeForAttachment().normalize(data.text, options),\n url: JsonSchema.isIriReference(url)\n ? url\n : undefined\n }\n }\n }\n\n #normalizeLicenseExpression (data: Models.LicenseExpression): Normalized.LicenseExpression {\n return {\n expression: data.expression,\n acknowledgement: this._factory.spec.supportsLicenseAcknowledgement\n ? data.acknowledgement\n : undefined\n }\n }\n\n /**\n * If there is any {@link Models.LicenseExpression | LicenseExpression} in the set, then this is the only item that is normalized.\n */\n normalizeIterable (data: SortableIterable<Models.License>, options: NormalizerOptions): Normalized.License[] {\n const licenses = options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n\n if (licenses.length > 1) {\n const expressions = licenses.filter(l => l instanceof Models.LicenseExpression) as Models.LicenseExpression[]\n if (expressions.length > 0) {\n // could have thrown {@link RangeError} when there is more than one only {@link Models.LicenseExpression | LicenseExpression}.\n // but let's be graceful and just normalize to the most relevant choice: any expression\n return [this.#normalizeLicenseExpression(expressions[0])]\n }\n }\n\n return licenses.map(l => this.normalize(l, options))\n }\n}\n\nexport class SWIDNormalizer extends BaseJsonNormalizer<Models.SWID> {\n normalize (data: Models.SWID, options: NormalizerOptions): Normalized.SWID {\n const url = escapeUri(data.url?.toString())\n return {\n tagId: data.tagId,\n name: data.name,\n version: data.version || undefined,\n tagVersion: data.tagVersion,\n patch: data.patch,\n text: data.text === undefined\n ? undefined\n : this._factory.makeForAttachment().normalize(data.text, options),\n url: JsonSchema.isIriReference(url)\n ? url\n : undefined\n }\n }\n}\n\nexport class ExternalReferenceNormalizer extends BaseJsonNormalizer<Models.ExternalReference> {\n normalize (data: Models.ExternalReference, options: NormalizerOptions): Normalized.ExternalReference | undefined {\n return this._factory.spec.supportsExternalReferenceType(data.type)\n ? {\n url: escapeUri(data.url.toString()),\n type: data.type,\n hashes: this._factory.spec.supportsExternalReferenceHashes && data.hashes.size > 0\n ? this._factory.makeForHash().normalizeIterable(data.hashes, options)\n : undefined,\n comment: data.comment || undefined\n }\n : undefined\n }\n\n normalizeIterable (data: SortableIterable<Models.ExternalReference>, options: NormalizerOptions): Normalized.ExternalReference[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n r => this.normalize(r, options)\n ).filter(isNotUndefined)\n }\n}\n\nexport class AttachmentNormalizer extends BaseJsonNormalizer<Models.Attachment> {\n normalize (data: Models.Attachment, options: NormalizerOptions): Normalized.Attachment {\n return {\n content: data.content.toString(),\n contentType: data.contentType || undefined,\n encoding: data.encoding\n }\n }\n}\n\nexport class PropertyNormalizer extends BaseJsonNormalizer<Models.Property> {\n normalize (data: Models.Property, options: NormalizerOptions): Normalized.Property {\n return {\n name: data.name,\n value: data.value\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Property>, options: NormalizerOptions): Normalized.Property[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(p => this.normalize(p, options))\n }\n}\n\nexport class DependencyGraphNormalizer extends BaseJsonNormalizer<Models.Bom> {\n normalize (data: Models.Bom, options: NormalizerOptions): Normalized.Dependency[] | undefined {\n const allRefs = new Map<Models.BomRef, Models.BomRefRepository>()\n if (data.metadata.component !== undefined) {\n allRefs.set(data.metadata.component.bomRef, data.metadata.component.dependencies)\n for (const component of data.metadata.component.components[treeIteratorSymbol]()) {\n allRefs.set(component.bomRef, component.dependencies)\n }\n }\n for (const component of data.components[treeIteratorSymbol]()) {\n allRefs.set(component.bomRef, component.dependencies)\n }\n\n const normalized: Normalized.Dependency[] = []\n for (const [ref, deps] of allRefs) {\n const dep = this.#normalizeDependency(ref, deps, allRefs, options)\n if (isNotUndefined(dep)) {\n normalized.push(dep)\n }\n }\n\n if (options.sortLists ?? false) {\n normalized.sort(({ ref: a }, { ref: b }) => a.localeCompare(b))\n }\n\n return normalized\n }\n\n #normalizeDependency (\n ref: Models.BomRef,\n deps: Models.BomRefRepository,\n allRefs: Map<Models.BomRef, Models.BomRefRepository>,\n options: NormalizerOptions\n ): Normalized.Dependency | undefined {\n const bomRef = ref.toString()\n if (bomRef.length === 0) {\n // no value -> cannot render\n return undefined\n }\n\n const dependsOn: string[] = normalizeStringableIter(\n Array.from(deps).filter(d => allRefs.has(d) && d !== ref),\n options\n ).filter(d => d.length > 0)\n\n return {\n ref: bomRef,\n dependsOn: dependsOn.length > 0\n ? dependsOn\n : undefined\n }\n }\n}\n\nexport class VulnerabilityNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Vulnerability> {\n normalize (data: Models.Vulnerability.Vulnerability, options: NormalizerOptions): Normalized.Vulnerability {\n return {\n 'bom-ref': data.bomRef.value || undefined,\n id: data.id || undefined,\n source: data.source === undefined\n ? undefined\n : this._factory.makeForVulnerabilitySource().normalize(data.source, options),\n references: data.references.size > 0\n ? this._factory.makeForVulnerabilityReference().normalizeIterable(data.references, options)\n : undefined,\n ratings: data.ratings.size > 0\n ? this._factory.makeForVulnerabilityRating().normalizeIterable(data.ratings, options)\n : undefined,\n cwes: data.cwes.size > 0\n ? (\n options.sortLists ?? false\n ? data.cwes.sorted()\n : Array.from(data.cwes)\n )\n : undefined,\n description: data.description,\n detail: data.detail,\n recommendation: data.recommendation,\n advisories: data.advisories.size > 0\n ? this._factory.makeForVulnerabilityAdvisory().normalizeIterable(data.advisories, options)\n : undefined,\n created: data.created?.toISOString(),\n published: data.published?.toISOString(),\n updated: data.updated?.toISOString(),\n credits: data.credits === undefined\n ? undefined\n : this._factory.makeForVulnerabilityCredits().normalize(data.credits, options),\n tools: data.tools.size > 0\n ? this._factory.makeForTool().normalizeIterable(data.tools, options)\n : undefined,\n analysis: data.analysis === undefined\n ? undefined\n : this._factory.makeForVulnerabilityAnalysis().normalize(data.analysis, options),\n affects: data.affects.size > 0\n ? this._factory.makeForVulnerabilityAffect().normalizeIterable(data.affects, options)\n : undefined,\n properties: data.properties.size > 0\n ? this._factory.makeForProperty().normalizeIterable(data.properties, options)\n : undefined\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Vulnerability>, options: NormalizerOptions): Normalized.Vulnerability[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(v => this.normalize(v, options))\n }\n}\n\nexport class VulnerabilitySourceNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Source> {\n normalize (data: Models.Vulnerability.Source, options: NormalizerOptions): Normalized.Vulnerability.Source {\n return {\n name: data.name,\n url: data.url?.toString()\n }\n }\n}\n\nexport class VulnerabilityReferenceNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Reference> {\n normalize (data: Models.Vulnerability.Reference, options: NormalizerOptions): Normalized.Vulnerability.Reference {\n return {\n id: data.id,\n source: this._factory.makeForVulnerabilitySource().normalize(data.source, options)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Reference>, options: NormalizerOptions): Normalized.Vulnerability.Reference[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(r => this.normalize(r, options))\n }\n}\n\nexport class VulnerabilityRatingNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Rating> {\n normalize (data: Models.Vulnerability.Rating, options: NormalizerOptions): Normalized.Vulnerability.Rating {\n return {\n source: data.source === undefined\n ? undefined\n : this._factory.makeForVulnerabilitySource().normalize(data.source, options),\n score: data.score,\n severity: data.severity,\n method: this._factory.spec.supportsVulnerabilityRatingMethod(data.method)\n ? data.method\n : undefined,\n vector: data.vector,\n justification: data.justification\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Rating>, options: NormalizerOptions): Normalized.Vulnerability.Rating[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(r => this.normalize(r, options))\n }\n}\n\nexport class VulnerabilityAdvisoryNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Advisory> {\n normalize (data: Models.Vulnerability.Advisory, options: NormalizerOptions): Normalized.Vulnerability.Advisory | undefined {\n const url = escapeUri(data.url.toString())\n if (!JsonSchema.isIriReference(url)) {\n // invalid value -> cannot render\n return undefined\n }\n return {\n title: data.title,\n url\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Advisory>, options: NormalizerOptions): Normalized.Vulnerability.Advisory[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n a => this.normalize(a, options)\n ).filter(isNotUndefined)\n }\n}\n\nexport class VulnerabilityCreditsNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Credits> {\n normalize (data: Models.Vulnerability.Credits, options: NormalizerOptions): Normalized.Vulnerability.Credits {\n return {\n organizations: data.organizations.size > 0\n ? this._factory.makeForOrganizationalEntity().normalizeIterable(data.organizations, options)\n : undefined,\n individuals: data.individuals.size > 0\n ? this._factory.makeForOrganizationalContact().normalizeIterable(data.individuals, options)\n : undefined\n }\n }\n}\n\nexport class VulnerabilityAffectNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Affect> {\n normalize (data: Models.Vulnerability.Affect, options: NormalizerOptions): Normalized.Vulnerability.Affect {\n return {\n ref: data.ref.toString(),\n versions: data.versions.size > 0\n ? this._factory.makeForVulnerabilityAffectedVersion().normalizeIterable(data.versions, options)\n : undefined\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Affect>, options: NormalizerOptions): Normalized.Vulnerability.Affect[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(a => this.normalize(a, options))\n }\n}\n\nexport class VulnerabilityAffectedVersionNormalizer extends BaseJsonNormalizer<Models.Vulnerability.AffectedVersion> {\n normalize (data: Models.Vulnerability.AffectedVersion, options: NormalizerOptions): Normalized.Vulnerability.AffectedVersion | undefined {\n switch (true) {\n case data instanceof Models.Vulnerability.AffectedSingleVersion:\n return this.#normalizeAffectedSingleVersion(data)\n case data instanceof Models.Vulnerability.AffectedVersionRange:\n return this.#normalizeAffectedVersionRange(data)\n /* c8 ignore start */\n default:\n // this case is expected to never happen - and therefore is undocumented\n throw new TypeError('Unexpected Vulnerability AffectedVersion')\n /* c8 ignore end */\n }\n }\n\n #normalizeAffectedSingleVersion (data: Models.Vulnerability.AffectedSingleVersion): Normalized.Vulnerability.AffectedSingleVersion | undefined {\n return data.version.length < 1\n // invalid value -> cannot render\n ? undefined\n : {\n version: data.version.substring(0, 1024),\n status: data.status\n }\n }\n\n #normalizeAffectedVersionRange (data: Models.Vulnerability.AffectedVersionRange): Normalized.Vulnerability.AffectedVersionRange | undefined {\n return data.range.length < 1\n // invalid value -> cannot render\n ? undefined\n : {\n range: data.range.substring(0, 1024),\n status: data.status\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.AffectedVersion>, options: NormalizerOptions): Normalized.Vulnerability.AffectedVersion[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n av => this.normalize(av, options)\n ).filter(isNotUndefined)\n }\n}\n\nexport class VulnerabilityAnalysisNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Analysis> {\n normalize (data: Models.Vulnerability.Analysis, options: NormalizerOptions): Normalized.Vulnerability.Analysis {\n return {\n state: data.state,\n justification: data.justification,\n response: data.response.size > 0\n ? (\n options.sortLists ?? false\n ? data.response.sorted()\n : Array.from(data.response)\n )\n : undefined,\n detail: data.detail\n }\n }\n}\n\n/* eslint-enable @typescript-eslint/prefer-nullish-coalescing, @typescript-eslint/strict-boolean-expressions */\n\nfunction normalizeStringableIter (data: Iterable<Stringable>, options: NormalizerOptions): string[] {\n const r = Array.from(data, d => d.toString())\n if (options.sortLists ?? false) {\n r.sort((a, b) => a.localeCompare(b))\n }\n return r\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type * as Enums from '../../enums'\nimport type { HashContent } from '../../models'\nimport type { SpdxId } from '../../spdx'\nimport type { CPE, CWE, Integer } from '../../types'\n\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport namespace JsonSchema {\n\n /**\n * @see {@link isIriReference}\n */\n export type IriReference = string\n /**\n * Test whether format is JSON::iri-reference - best-effort.\n *\n * @see {@link https://datatracker.ietf.org/doc/html/rfc3987 | RFC 3987}\n *\n * @TODO add more validation according to spec\n */\n export function isIriReference (value: IriReference | any): value is IriReference {\n // There is just no working implementation for format \"iri-reference\": see https://github.com/luzlab/ajv-formats-draft2019/issues/22\n return typeof value === 'string' &&\n value.length > 0\n }\n\n /**\n * @see {@link isIdnEmail}\n */\n export type IdnEmail = string\n /**\n * Test whether format is JSON::idn-email - best-effort.\n *\n * @see {@link https://datatracker.ietf.org/doc/html/rfc6531 | RFC 6531}\n *\n * @TODO add more validation according to spec\n */\n export function isIdnEmail (value: IdnEmail | any): value is IdnEmail {\n return typeof value === 'string' &&\n value.length > 0\n }\n\n export type DateTime = string\n\n}\n\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport namespace Normalized {\n\n export type RefType = string\n export type RefLinkType = RefType\n\n export type BomLinkDocumentType = string\n export type BomLinkElementType = string\n export type BomLink = BomLinkDocumentType | BomLinkElementType\n\n export interface Bom {\n $schema?: string\n bomFormat: 'CycloneDX'\n specVersion: string\n version: Integer\n serialNumber?: string\n metadata?: Metadata\n components?: Component[]\n externalReferences?: ExternalReference[]\n dependencies?: Dependency[]\n vulnerabilities?: Vulnerability[]\n }\n\n export interface Metadata {\n timestamp?: JsonSchema.DateTime\n lifecycles?: Lifecycle[]\n tools?: Tool[]\n authors?: OrganizationalContact[]\n component?: Component\n manufacture?: OrganizationalEntity\n supplier?: OrganizationalEntity\n licenses?: License[]\n properties?: Property[]\n }\n\n export interface LifecyclePhase {\n phase: Enums.LifecyclePhase\n }\n\n export interface NamedLifecycle {\n name: string\n description?: string\n }\n\n export type Lifecycle = LifecyclePhase | NamedLifecycle\n\n export interface Tool {\n vendor?: string\n name?: string\n version?: string\n hashes?: Hash[]\n externalReferences?: ExternalReference[]\n }\n\n export interface OrganizationalContact {\n name?: string\n email?: JsonSchema.IdnEmail\n phone?: string\n }\n\n export interface OrganizationalEntity {\n name?: string\n url?: JsonSchema.IriReference[]\n contact?: OrganizationalContact[]\n }\n\n export interface Hash {\n alg: Enums.HashAlgorithm\n content: HashContent\n }\n\n export interface Component {\n type: Enums.ComponentType\n name: string\n 'mime-type'?: string\n 'bom-ref'?: RefType\n supplier?: OrganizationalEntity\n author?: string\n publisher?: string\n group?: string\n version?: string\n description?: string\n scope?: Enums.ComponentScope\n hashes?: Hash[]\n licenses?: License[]\n copyright?: string\n cpe?: CPE\n purl?: string\n swid?: SWID\n modified?: boolean\n externalReferences?: ExternalReference[]\n components?: Component[]\n evidence?: ComponentEvidence\n properties?: Property[]\n }\n\n export interface ComponentEvidence {\n licenses?: License[]\n copyright?: Copyright[]\n }\n\n export interface Copyright {\n text: string\n }\n\n export interface NamedLicense {\n license: {\n name: string\n acknowledgement?: Enums.LicenseAcknowledgement\n text?: Attachment\n url?: string\n }\n }\n\n export interface SpdxLicense {\n license: {\n /* see http://cyclonedx.org/schema/spdx */\n id: SpdxId\n acknowledgement?: Enums.LicenseAcknowledgement\n text?: Attachment\n url?: string\n }\n }\n\n export interface LicenseExpression {\n expression: string\n acknowledgement?: Enums.LicenseAcknowledgement\n }\n\n export type License = NamedLicense | SpdxLicense | LicenseExpression\n\n export interface SWID {\n tagId: string\n name: string\n version?: string\n tagVersion?: Integer\n patch?: boolean\n text?: Attachment\n url?: JsonSchema.IriReference\n }\n\n export interface ExternalReference {\n url: JsonSchema.IriReference | BomLink\n type: Enums.ExternalReferenceType\n hashes?: Hash[]\n comment?: string\n }\n\n export interface Attachment {\n content?: string\n contentType?: string\n encoding?: Enums.AttachmentEncoding\n }\n\n export interface Property {\n name?: string\n value?: string\n }\n\n export interface Dependency {\n ref: RefLinkType\n dependsOn?: RefLinkType[]\n }\n\n export interface Vulnerability {\n 'bom-ref'?: RefType\n id?: string\n source?: Vulnerability.Source\n references?: Vulnerability.Reference[]\n ratings?: Vulnerability.Rating[]\n cwes?: CWE[]\n description?: string\n detail?: string\n recommendation?: string\n advisories?: Vulnerability.Advisory[]\n created?: JsonSchema.DateTime\n published?: JsonSchema.DateTime\n updated?: JsonSchema.DateTime\n credits?: Vulnerability.Credits\n tools?: Tool[]\n analysis?: Vulnerability.Analysis\n affects?: Vulnerability.Affect[]\n properties?: Property[]\n }\n\n // eslint-disable-next-line @typescript-eslint/no-namespace\n export namespace Vulnerability {\n export interface Source {\n name?: string\n url?: string\n }\n\n export interface Reference {\n id: string\n source: Source\n }\n\n export interface Rating {\n source?: Source\n score?: number\n severity?: Enums.Vulnerability.Severity\n method?: Enums.Vulnerability.RatingMethod\n vector?: string\n justification?: string\n }\n\n export interface Advisory {\n title?: string\n url: JsonSchema.IriReference\n }\n\n export interface Credits {\n organizations?: OrganizationalEntity[]\n individuals?: OrganizationalContact[]\n }\n\n export interface Analysis {\n state?: Enums.Vulnerability.AnalysisState\n justification?: Enums.Vulnerability.AnalysisJustification\n response?: Enums.Vulnerability.AnalysisResponse[]\n detail?: string\n }\n\n export interface Affect {\n ref: RefLinkType | BomLinkElementType\n versions?: AffectedVersion[]\n }\n\n export interface AffectedSingleVersion {\n version: string\n status?: Enums.Vulnerability.AffectStatus\n }\n\n export interface AffectedVersionRange {\n range: string\n status?: Enums.Vulnerability.AffectStatus\n }\n\n export type AffectedVersion = AffectedSingleVersion | AffectedVersionRange\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Bom } from '../models'\nimport { Format, UnsupportedFormatError } from '../spec'\nimport { BaseSerializer } from './baseSerializer'\nimport type { Factory as NormalizerFactory } from './json/normalize'\nimport type { Normalized } from './json/types'\nimport type { NormalizerOptions, SerializerOptions } from './types'\n\n/**\n * Multi purpose Json serializer.\n */\nexport class JsonSerializer extends BaseSerializer<Normalized.Bom> {\n readonly #normalizerFactory: NormalizerFactory\n\n /**\n * @throws {@link UnsupportedFormatError} if `normalizerFactory.spec` does not support {@link Format.JSON}.\n */\n constructor (normalizerFactory: JsonSerializer['normalizerFactory']) {\n if (!normalizerFactory.spec.supportsFormat(Format.JSON)) {\n throw new UnsupportedFormatError('Spec does not support JSON format.')\n }\n\n super()\n this.#normalizerFactory = normalizerFactory\n }\n\n get normalizerFactory (): NormalizerFactory {\n return this.#normalizerFactory\n }\n\n protected _normalize (\n bom: Bom,\n options: NormalizerOptions = {}\n ): Normalized.Bom {\n return this.#normalizerFactory.makeForBom()\n .normalize(bom, options)\n }\n\n protected _serialize (\n bom: Normalized.Bom,\n { space }: SerializerOptions = {}\n ): string {\n return JSON.stringify(bom, null, space)\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Bom } from '../models'\n\nexport interface NormalizerOptions {\n /**\n * Whether to sort lists in normalization results. Sorted lists make the output reproducible.\n */\n sortLists?: boolean\n}\n\nexport interface SerializerOptions {\n /**\n * Add indention in the serialization result. Indention increases readability for humans.\n */\n space?: string | number\n}\n\nexport interface Serializer {\n /**\n * @throws {@link Error}\n */\n serialize: (bom: Bom, options?: SerializerOptions & NormalizerOptions) => string\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * as Normalize from './normalize'\nexport * as Types from './types'\n// export * as Denormalize from './denormalize' // @TODO\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { isNotUndefined } from '../../_helpers/notUndefined'\nimport type { SortableIterable } from '../../_helpers/sortable'\nimport type { Stringable } from '../../_helpers/stringable'\nimport { treeIteratorSymbol } from '../../_helpers/tree'\nimport { escapeUri } from '../../_helpers/uri'\nimport * as Models from '../../models'\nimport { isSupportedSpdxId } from '../../spdx'\nimport { Version as SpecVersion } from '../../spec'\nimport type { _SpecProtocol as Spec } from '../../spec/_protocol'\nimport type { NormalizerOptions } from '../types'\nimport type { SimpleXml } from './types'\nimport { XmlSchema } from './types'\n\nexport class Factory {\n readonly #spec: Spec\n\n constructor (spec: Factory['spec']) {\n this.#spec = spec\n }\n\n get spec (): Spec {\n return this.#spec\n }\n\n makeForBom (): BomNormalizer {\n return new BomNormalizer(this)\n }\n\n makeForMetadata (): MetadataNormalizer {\n return new MetadataNormalizer(this)\n }\n\n makeForLifecycle (): LifecycleNormalizer {\n return new LifecycleNormalizer(this)\n }\n\n makeForComponent (): ComponentNormalizer {\n return new ComponentNormalizer(this)\n }\n\n makeForComponentEvidence (): ComponentEvidenceNormalizer {\n return new ComponentEvidenceNormalizer(this)\n }\n\n makeForTool (): ToolNormalizer {\n return new ToolNormalizer(this)\n }\n\n makeForOrganizationalContact (): OrganizationalContactNormalizer {\n return new OrganizationalContactNormalizer(this)\n }\n\n makeForOrganizationalEntity (): OrganizationalEntityNormalizer {\n return new OrganizationalEntityNormalizer(this)\n }\n\n makeForHash (): HashNormalizer {\n return new HashNormalizer(this)\n }\n\n makeForLicense (): LicenseNormalizer {\n return new LicenseNormalizer(this)\n }\n\n makeForSWID (): SWIDNormalizer {\n return new SWIDNormalizer(this)\n }\n\n makeForExternalReference (): ExternalReferenceNormalizer {\n return new ExternalReferenceNormalizer(this)\n }\n\n makeForAttachment (): AttachmentNormalizer {\n return new AttachmentNormalizer(this)\n }\n\n makeForProperty (): PropertyNormalizer {\n return new PropertyNormalizer(this)\n }\n\n makeForDependencyGraph (): DependencyGraphNormalizer {\n return new DependencyGraphNormalizer(this)\n }\n\n makeForVulnerability (): VulnerabilityNormalizer {\n return new VulnerabilityNormalizer(this)\n }\n\n makeForVulnerabilitySource (): VulnerabilitySourceNormalizer {\n return new VulnerabilitySourceNormalizer(this)\n }\n\n makeForVulnerabilityReference (): VulnerabilityReferenceNormalizer {\n return new VulnerabilityReferenceNormalizer(this)\n }\n\n makeForVulnerabilityRating (): VulnerabilityRatingNormalizer {\n return new VulnerabilityRatingNormalizer(this)\n }\n\n makeForVulnerabilityAdvisory (): VulnerabilityAdvisoryNormalizer {\n return new VulnerabilityAdvisoryNormalizer(this)\n }\n\n makeForVulnerabilityCredits (): VulnerabilityCreditsNormalizer {\n return new VulnerabilityCreditsNormalizer(this)\n }\n\n makeForVulnerabilityAffect (): VulnerabilityAffectNormalizer {\n return new VulnerabilityAffectNormalizer(this)\n }\n\n makeForVulnerabilityAffectedVersion (): VulnerabilityAffectedVersionNormalizer {\n return new VulnerabilityAffectedVersionNormalizer(this)\n }\n\n makeForVulnerabilityAnalysis (): VulnerabilityAnalysisNormalizer {\n return new VulnerabilityAnalysisNormalizer(this)\n }\n}\n\nconst xmlNamespace: ReadonlyMap<SpecVersion, string> = new Map([\n [SpecVersion.v1dot6, 'http://cyclonedx.org/schema/bom/1.6'],\n [SpecVersion.v1dot5, 'http://cyclonedx.org/schema/bom/1.5'],\n [SpecVersion.v1dot4, 'http://cyclonedx.org/schema/bom/1.4'],\n [SpecVersion.v1dot3, 'http://cyclonedx.org/schema/bom/1.3'],\n [SpecVersion.v1dot2, 'http://cyclonedx.org/schema/bom/1.2'],\n [SpecVersion.v1dot1, 'http://cyclonedx.org/schema/bom/1.1'],\n [SpecVersion.v1dot0, 'http://cyclonedx.org/schema/bom/1.0']\n])\n\ninterface XmlNormalizer<TModel, TNormalized> {\n normalize: (data: TModel, options: NormalizerOptions, elementName?: string) => TNormalized | undefined\n\n normalizeIterable?: (data: SortableIterable<TModel>, options: NormalizerOptions, elementName: string) => TNormalized[]\n}\n\nabstract class BaseXmlNormalizer<TModel, TNormalized = SimpleXml.Element> implements XmlNormalizer<TModel, TNormalized> {\n protected readonly _factory: Factory\n\n constructor (factory: Factory) {\n this._factory = factory\n }\n\n get factory (): Factory {\n return this._factory\n }\n\n /**\n * @param elementName - element name. XML defines structures; the element's name is defined on usage of a structure.\n */\n abstract normalize (data: TModel, options: NormalizerOptions, elementName?: string): TNormalized | undefined\n}\n\n/* eslint-disable @typescript-eslint/prefer-nullish-coalescing, @typescript-eslint/strict-boolean-expressions --\n * since empty strings need to be treated as undefined/null\n */\n\nexport class BomNormalizer extends BaseXmlNormalizer<Models.Bom> {\n normalize (data: Models.Bom, options: NormalizerOptions): SimpleXml.Element {\n const components: SimpleXml.Element = {\n // spec < 1.4 always requires a 'components' element\n type: 'element',\n name: 'components',\n children: data.components.size > 0\n ? this._factory.makeForComponent().normalizeIterable(data.components, options, 'component')\n : undefined\n }\n const vulnerabilities: SimpleXml.Element | undefined = this._factory.spec.supportsVulnerabilities && data.vulnerabilities.size > 0\n ? {\n type: 'element',\n name: 'vulnerabilities',\n children: this._factory.makeForVulnerability().normalizeIterable(data.vulnerabilities, options, 'vulnerability')\n }\n : undefined\n return {\n type: 'element',\n // the element's name is hardcoded in the XSD\n name: 'bom',\n namespace: xmlNamespace.get(this._factory.spec.version),\n attributes: {\n version: data.version,\n serialNumber: this.#isEligibleSerialNumber(data.serialNumber)\n ? data.serialNumber\n : undefined\n },\n children: [\n data.metadata\n ? this._factory.makeForMetadata().normalize(data.metadata, options, 'metadata')\n : undefined,\n components,\n this._factory.spec.supportsDependencyGraph\n ? this._factory.makeForDependencyGraph().normalize(data, options, 'dependencies')\n : undefined,\n vulnerabilities\n ].filter(isNotUndefined)\n }\n }\n\n #isEligibleSerialNumber (v: string | undefined): boolean {\n return v !== undefined &&\n // see https://github.com/CycloneDX/specification/blob/ef71717ae0ecb564c0b4c9536d6e9e57e35f2e69/schema/bom-1.4.xsd#L699\n /^urn:uuid:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$|^\\{[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\\}$/.test(v)\n }\n}\n\nexport class MetadataNormalizer extends BaseXmlNormalizer<Models.Metadata> {\n normalize (data: Models.Metadata, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const orgEntityNormalizer = this._factory.makeForOrganizationalEntity()\n const lifecycles: SimpleXml.Element | undefined = this._factory.spec.supportsMetadataLifecycles && data.lifecycles.size > 0\n ? {\n type: 'element',\n name: 'lifecycles',\n children: this._factory.makeForLifecycle().normalizeIterable(data.lifecycles, options, 'lifecycle')\n }\n : undefined\n const tools: SimpleXml.Element | undefined = data.tools.size > 0\n ? {\n type: 'element',\n name: 'tools',\n children: this._factory.makeForTool().normalizeIterable(data.tools, options, 'tool')\n }\n : undefined\n const authors: SimpleXml.Element | undefined = data.authors.size > 0\n ? {\n type: 'element',\n name: 'authors',\n children: this._factory.makeForOrganizationalContact().normalizeIterable(data.authors, options, 'author')\n }\n : undefined\n const licenses: SimpleXml.Element | undefined = this._factory.spec.supportsMetadataLicenses && data.licenses.size > 0\n ? {\n type: 'element',\n name: 'licenses',\n children: this._factory.makeForLicense().normalizeIterable(data.licenses, options)\n }\n : undefined\n const properties: SimpleXml.Element | undefined = this._factory.spec.supportsMetadataProperties && data.properties.size > 0\n ? {\n type: 'element',\n name: 'properties',\n children: this._factory.makeForProperty().normalizeIterable(data.properties, options, 'property')\n }\n : undefined\n return {\n type: 'element',\n name: elementName,\n children: [\n makeOptionalDateTimeElement(data.timestamp, 'timestamp'),\n lifecycles,\n tools,\n authors,\n data.component === undefined\n ? undefined\n : this._factory.makeForComponent().normalize(data.component, options, 'component'),\n data.manufacture === undefined\n ? undefined\n : orgEntityNormalizer.normalize(data.manufacture, options, 'manufacture'),\n data.supplier === undefined\n ? undefined\n : orgEntityNormalizer.normalize(data.supplier, options, 'supplier'),\n licenses,\n properties\n ].filter(isNotUndefined)\n }\n }\n}\n\nexport class LifecycleNormalizer extends BaseXmlNormalizer<Models.Lifecycle> {\n normalize (data: Models.Lifecycle, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n return data instanceof Models.NamedLifecycle\n ? {\n type: 'element',\n name: elementName,\n children: [\n makeTextElement(data.name, 'name'),\n makeOptionalTextElement(data.description, 'description')\n ].filter(isNotUndefined)\n }\n : {\n type: 'element',\n name: elementName,\n children: [\n makeTextElement(data, 'phase')\n ]\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Lifecycle>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(t => this.normalize(t, options, elementName))\n }\n}\n\nexport class ToolNormalizer extends BaseXmlNormalizer<Models.Tool> {\n normalize (data: Models.Tool, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const hashes: SimpleXml.Element | undefined = data.hashes.size > 0\n ? {\n type: 'element',\n name: 'hashes',\n children: this._factory.makeForHash().normalizeIterable(data.hashes, options, 'hash')\n }\n : undefined\n const externalReferences: SimpleXml.Element | undefined =\n this._factory.spec.supportsToolReferences && data.externalReferences.size > 0\n ? {\n type: 'element',\n name: 'externalReferences',\n children: this._factory.makeForExternalReference().normalizeIterable(data.externalReferences, options, 'reference')\n }\n : undefined\n return {\n type: 'element',\n name: elementName,\n children: [\n makeOptionalTextElement(data.vendor, 'vendor'),\n makeOptionalTextElement(data.name, 'name'),\n makeOptionalTextElement(data.version, 'version'),\n hashes,\n externalReferences\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Tool>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(t => this.normalize(t, options, elementName))\n }\n}\n\nexport class HashNormalizer extends BaseXmlNormalizer<Models.Hash> {\n normalize ([algorithm, content]: Models.Hash, options: NormalizerOptions, elementName: string): SimpleXml.Element | undefined {\n const spec = this._factory.spec\n return spec.supportsHashAlgorithm(algorithm) && spec.supportsHashValue(content)\n ? {\n type: 'element',\n name: elementName,\n attributes: { alg: algorithm },\n children: content\n }\n : undefined\n }\n\n normalizeIterable (data: SortableIterable<Models.Hash>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n h => this.normalize(h, options, elementName)\n ).filter(isNotUndefined)\n }\n}\n\nexport class OrganizationalContactNormalizer extends BaseXmlNormalizer<Models.OrganizationalContact> {\n normalize (data: Models.OrganizationalContact, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n children: [\n makeOptionalTextElement(data.name, 'name'),\n makeOptionalTextElement(data.email, 'email'),\n makeOptionalTextElement(data.phone, 'phone')\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.OrganizationalContact>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(oc => this.normalize(oc, options, elementName))\n }\n}\n\nexport class OrganizationalEntityNormalizer extends BaseXmlNormalizer<Models.OrganizationalEntity> {\n normalize (data: Models.OrganizationalEntity, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n children: [\n makeOptionalTextElement(data.name, 'name'),\n ...makeTextElementIter(Array.from(\n data.url, (s): string => escapeUri(s.toString())\n ), options, 'url'\n ).filter(({ children: u }) => XmlSchema.isAnyURI(u)),\n ...this._factory.makeForOrganizationalContact().normalizeIterable(data.contact, options, 'contact')\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.OrganizationalEntity>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(oe => this.normalize(oe, options, elementName))\n }\n}\n\nexport class ComponentNormalizer extends BaseXmlNormalizer<Models.Component> {\n normalize (data: Models.Component, options: NormalizerOptions, elementName: string): SimpleXml.Element | undefined {\n const spec = this._factory.spec\n if (!spec.supportsComponentType(data.type)) {\n return undefined\n }\n const supplier: SimpleXml.Element | undefined = data.supplier === undefined\n ? undefined\n : this._factory.makeForOrganizationalEntity().normalize(data.supplier, options, 'supplier')\n const version: SimpleXml.Element | undefined = (\n spec.requiresComponentVersion\n ? makeTextElement\n : makeOptionalTextElement\n )(\n data.version ?? '',\n 'version'\n )\n const hashes: SimpleXml.Element | undefined = data.hashes.size > 0\n ? {\n type: 'element',\n name: 'hashes',\n children: this._factory.makeForHash().normalizeIterable(data.hashes, options, 'hash')\n }\n : undefined\n const licenses: SimpleXml.Element | undefined = data.licenses.size > 0\n ? {\n type: 'element',\n name: 'licenses',\n children: this._factory.makeForLicense().normalizeIterable(data.licenses, options)\n }\n : undefined\n const swid: SimpleXml.Element | undefined = data.swid === undefined\n ? undefined\n : this._factory.makeForSWID().normalize(data.swid, options, 'swid')\n const extRefs: SimpleXml.Element | undefined = data.externalReferences.size > 0\n ? {\n type: 'element',\n name: 'externalReferences',\n children: this._factory.makeForExternalReference().normalizeIterable(data.externalReferences, options, 'reference')\n }\n : undefined\n const properties: SimpleXml.Element | undefined = spec.supportsProperties(data) && data.properties.size > 0\n ? {\n type: 'element',\n name: 'properties',\n children: this._factory.makeForProperty().normalizeIterable(data.properties, options, 'property')\n }\n : undefined\n const components: SimpleXml.Element | undefined = data.components.size > 0\n ? {\n type: 'element',\n name: 'components',\n children: this.normalizeIterable(data.components, options, 'component')\n }\n : undefined\n const evidence: SimpleXml.Element | undefined = spec.supportsComponentEvidence && data.evidence !== undefined\n ? this._factory.makeForComponentEvidence().normalize(data.evidence, options, 'evidence')\n : undefined\n return {\n type: 'element',\n name: elementName,\n attributes: {\n type: data.type,\n 'bom-ref': data.bomRef.value\n },\n children: [\n supplier,\n makeOptionalTextElement(data.author, 'author'),\n makeOptionalTextElement(data.publisher, 'publisher'),\n makeOptionalTextElement(data.group, 'group'),\n makeTextElement(data.name, 'name'),\n version,\n makeOptionalTextElement(data.description, 'description'),\n makeOptionalTextElement(data.scope, 'scope'),\n hashes,\n licenses,\n makeOptionalTextElement(data.copyright, 'copyright'),\n makeOptionalTextElement(data.cpe, 'cpe'),\n makeOptionalTextElement(data.purl, 'purl'),\n swid,\n extRefs,\n properties,\n components,\n evidence\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Component>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n c => this.normalize(c, options, elementName)\n ).filter(isNotUndefined)\n }\n}\n\nexport class ComponentEvidenceNormalizer extends BaseXmlNormalizer<Models.ComponentEvidence> {\n normalize (data: Models.ComponentEvidence, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const licenses: SimpleXml.Element | undefined = data.licenses.size > 0\n ? {\n type: 'element',\n name: 'licenses',\n children: this._factory.makeForLicense().normalizeIterable(data.licenses, options)\n }\n : undefined\n const copyright: SimpleXml.Element | undefined = data.copyright.size > 0\n ? {\n type: 'element',\n name: 'copyright',\n children: makeTextElementIter(data.copyright, options, 'text')\n }\n : undefined\n return {\n type: 'element',\n name: elementName,\n children: [\n licenses,\n copyright\n ].filter(isNotUndefined)\n }\n }\n}\n\nexport class LicenseNormalizer extends BaseXmlNormalizer<Models.License> {\n normalize (data: Models.License, options: NormalizerOptions): SimpleXml.Element {\n switch (true) {\n case data instanceof Models.NamedLicense:\n return this.#normalizeNamedLicense(data, options)\n case data instanceof Models.SpdxLicense:\n return isSupportedSpdxId(data.id)\n ? this.#normalizeSpdxLicense(data, options)\n : this.#normalizeNamedLicense(new Models.NamedLicense(\n // prevent information loss -> convert to broader type\n data.id,\n { url: data.url }\n ), options)\n case data instanceof Models.LicenseExpression:\n return this.#normalizeLicenseExpression(data)\n /* c8 ignore start */\n default:\n // this case is expected to never happen - and therefore is undocumented\n throw new TypeError('Unexpected LicenseChoice')\n /* c8 ignore end */\n }\n }\n\n #normalizeNamedLicense (data: Models.NamedLicense, options: NormalizerOptions): SimpleXml.Element {\n const url = escapeUri(data.url?.toString())\n return {\n type: 'element',\n name: 'license',\n attributes: {\n acknowledgement: this._factory.spec.supportsLicenseAcknowledgement\n ? data.acknowledgement\n : undefined\n },\n children: [\n makeTextElement(data.name, 'name'),\n data.text === undefined\n ? undefined\n : this._factory.makeForAttachment().normalize(data.text, options, 'text'),\n XmlSchema.isAnyURI(url)\n ? makeTextElement(url, 'url')\n : undefined\n ].filter(isNotUndefined)\n }\n }\n\n #normalizeSpdxLicense (data: Models.SpdxLicense, options: NormalizerOptions): SimpleXml.Element {\n const url = escapeUri(data.url?.toString())\n return {\n type: 'element',\n name: 'license',\n attributes: {\n acknowledgement: this._factory.spec.supportsLicenseAcknowledgement\n ? data.acknowledgement\n : undefined\n },\n children: [\n makeTextElement(data.id, 'id'),\n data.text === undefined\n ? undefined\n : this._factory.makeForAttachment().normalize(data.text, options, 'text'),\n XmlSchema.isAnyURI(url)\n ? makeTextElement(url, 'url')\n : undefined\n ].filter(isNotUndefined)\n }\n }\n\n #normalizeLicenseExpression (data: Models.LicenseExpression): SimpleXml.Element {\n const elem = makeTextElement(data.expression, 'expression')\n elem.attributes = {\n acknowledgement: this._factory.spec.supportsLicenseAcknowledgement\n ? data.acknowledgement\n : undefined\n }\n return elem\n }\n\n /**\n * If there is any {@link Models.LicenseExpression | LicenseExpression} in the set, then this is the only item that is normalized.\n */\n normalizeIterable (data: SortableIterable<Models.License>, options: NormalizerOptions): SimpleXml.Element[] {\n const licenses = options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n\n if (licenses.length > 1) {\n const expressions = licenses.filter(l => l instanceof Models.LicenseExpression) as Models.LicenseExpression[]\n if (expressions.length > 0) {\n // could have thrown {@link RangeError} when there is more than one only {@link Models.LicenseExpression | LicenseExpression}.\n // but let's be graceful and just normalize to the most relevant choice: any expression\n return [this.#normalizeLicenseExpression(expressions[0])]\n }\n }\n\n return licenses.map(l => this.normalize(l, options))\n }\n}\n\nexport class SWIDNormalizer extends BaseXmlNormalizer<Models.SWID> {\n normalize (data: Models.SWID, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const url = escapeUri(data.url?.toString())\n return {\n type: 'element',\n name: elementName,\n attributes: {\n tagId: data.tagId,\n name: data.name,\n version: data.version || undefined,\n tagVersion: data.tagVersion,\n patch: data.patch === undefined\n ? undefined\n : (data.patch ? 'true' : 'false')\n },\n children: [\n data.text === undefined\n ? undefined\n : this._factory.makeForAttachment().normalize(data.text, options, 'text'),\n XmlSchema.isAnyURI(url)\n ? makeTextElement(url, 'url')\n : undefined\n ].filter(isNotUndefined)\n }\n }\n}\n\nexport class ExternalReferenceNormalizer extends BaseXmlNormalizer<Models.ExternalReference> {\n normalize (data: Models.ExternalReference, options: NormalizerOptions, elementName: string): SimpleXml.Element | undefined {\n const url = escapeUri(data.url.toString())\n const hashes: SimpleXml.Element | undefined = this._factory.spec.supportsExternalReferenceHashes && data.hashes.size > 0\n ? {\n type: 'element',\n name: 'hashes',\n children: this._factory.makeForHash().normalizeIterable(data.hashes, options, 'hash')\n }\n : undefined\n return this._factory.spec.supportsExternalReferenceType(data.type) &&\n XmlSchema.isAnyURI(url)\n ? {\n type: 'element',\n name: elementName,\n attributes: {\n type: data.type\n },\n children: [\n makeTextElement(url, 'url'),\n makeOptionalTextElement(data.comment, 'comment'),\n hashes\n ].filter(isNotUndefined)\n }\n : undefined\n }\n\n normalizeIterable (data: SortableIterable<Models.ExternalReference>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n r => this.normalize(r, options, elementName)\n ).filter(isNotUndefined)\n }\n}\n\nexport class AttachmentNormalizer extends BaseXmlNormalizer<Models.Attachment> {\n normalize (data: Models.Attachment, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n attributes: {\n 'content-type': data.contentType || undefined,\n encoding: data.encoding || undefined\n },\n children: data.content.toString()\n }\n }\n}\n\nexport class PropertyNormalizer extends BaseXmlNormalizer<Models.Property> {\n normalize (data: Models.Property, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n attributes: {\n name: data.name\n },\n children: data.value\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Property>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(p => this.normalize(p, options, elementName))\n }\n}\n\nexport class DependencyGraphNormalizer extends BaseXmlNormalizer<Models.Bom> {\n normalize (data: Models.Bom, options: NormalizerOptions, elementName: string): SimpleXml.Element | undefined {\n const allRefs = new Map<Models.BomRef, Models.BomRefRepository>()\n if (data.metadata.component !== undefined) {\n allRefs.set(data.metadata.component.bomRef, data.metadata.component.dependencies)\n for (const component of data.metadata.component.components[treeIteratorSymbol]()) {\n allRefs.set(component.bomRef, component.dependencies)\n }\n }\n for (const component of data.components[treeIteratorSymbol]()) {\n allRefs.set(component.bomRef, component.dependencies)\n }\n\n const normalized: Array<(SimpleXml.Element & { attributes: { ref: string } })> = []\n for (const [ref, deps] of allRefs) {\n const dep = this.#normalizeDependency(ref, deps, allRefs, options)\n if (isNotUndefined(dep)) {\n normalized.push(dep)\n }\n }\n\n if (options.sortLists ?? false) {\n normalized.sort(\n ({ attributes: { ref: a } }, { attributes: { ref: b } }) => a.localeCompare(b))\n }\n\n return {\n type: 'element',\n name: elementName,\n children: normalized\n }\n }\n\n #normalizeDependency (\n ref: Models.BomRef,\n deps: Models.BomRefRepository,\n allRefs: Map<Models.BomRef, Models.BomRefRepository>,\n options: NormalizerOptions\n ): undefined | (SimpleXml.Element & { attributes: { ref: string } }) {\n const bomRef = ref.toString()\n if (bomRef.length === 0) {\n // no value -> cannot render\n return undefined\n }\n\n const dependsOn: string[] = Array.from(deps).filter(d => allRefs.has(d) && d !== ref)\n .map(d => d.toString()).filter(d => d.length > 0)\n if (options.sortLists ?? false) {\n dependsOn.sort((a, b) => a.localeCompare(b))\n }\n\n return {\n type: 'element',\n name: 'dependency',\n attributes: { ref: bomRef },\n children: dependsOn.map(d => ({\n type: 'element',\n name: 'dependency',\n attributes: { ref: d }\n }))\n }\n }\n}\n\nexport class VulnerabilityNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Vulnerability> {\n normalize (data: Models.Vulnerability.Vulnerability, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const references: SimpleXml.Element | undefined = data.references.size > 0\n ? {\n type: 'element',\n name: 'references',\n children: this._factory.makeForVulnerabilityReference().normalizeIterable(data.references, options, 'reference')\n }\n : undefined\n const ratings: SimpleXml.Element | undefined = data.ratings.size > 0\n ? {\n type: 'element',\n name: 'ratings',\n children: this._factory.makeForVulnerabilityRating().normalizeIterable(data.ratings, options, 'rating')\n }\n : undefined\n const cwes: SimpleXml.Element | undefined = data.cwes.size > 0\n ? {\n type: 'element',\n name: 'cwes',\n children: (\n options.sortLists\n ? data.cwes.sorted()\n : Array.from(data.cwes)\n ).map(cwe => makeTextElement(cwe, 'cwe'))\n }\n : undefined\n const advisories: SimpleXml.Element | undefined = data.advisories.size > 0\n ? {\n type: 'element',\n name: 'advisories',\n children: this._factory.makeForVulnerabilityAdvisory().normalizeIterable(data.advisories, options, 'advisory')\n }\n : undefined\n const tools: SimpleXml.Element | undefined = data.tools.size > 0\n ? {\n type: 'element',\n name: 'tools',\n children: this._factory.makeForTool().normalizeIterable(data.tools, options, 'tool')\n }\n : undefined\n const affects: SimpleXml.Element | undefined = data.affects.size > 0\n ? {\n type: 'element',\n name: 'affects',\n children: this._factory.makeForVulnerabilityAffect().normalizeIterable(data.affects, options, 'target')\n }\n : undefined\n const properties: SimpleXml.Element | undefined = data.properties.size > 0\n ? {\n type: 'element',\n name: 'properties',\n children: this._factory.makeForProperty().normalizeIterable(data.properties, options, 'property')\n }\n : undefined\n return {\n type: 'element',\n name: elementName,\n attributes: { 'bom-ref': data.bomRef.value || undefined },\n children: [\n makeOptionalTextElement(data.id, 'id'),\n data.source === undefined\n ? undefined\n : this._factory.makeForVulnerabilitySource().normalize(data.source, options, 'source'),\n references,\n ratings,\n cwes,\n makeOptionalTextElement(data.description, 'description'),\n makeOptionalTextElement(data.detail, 'detail'),\n makeOptionalTextElement(data.recommendation, 'recommendation'),\n advisories,\n makeOptionalDateTimeElement(data.created, 'created'),\n makeOptionalDateTimeElement(data.created, 'published'),\n makeOptionalDateTimeElement(data.created, 'updated'),\n data.credits === undefined\n ? undefined\n : this._factory.makeForVulnerabilityCredits().normalize(data.credits, options, 'credits'),\n tools,\n data.analysis === undefined\n ? undefined\n : this._factory.makeForVulnerabilityAnalysis().normalize(data.analysis, options, 'analysis'),\n affects,\n properties\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Vulnerability>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(v => this.normalize(v, options, elementName))\n }\n}\n\nexport class VulnerabilitySourceNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Source> {\n normalize (data: Models.Vulnerability.Source, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const url = escapeUri(data.url?.toString())\n return {\n type: 'element',\n name: elementName,\n children: [\n makeOptionalTextElement(data.name, 'name'),\n XmlSchema.isAnyURI(url)\n ? makeTextElement(url, 'url')\n : undefined\n ].filter(isNotUndefined)\n }\n }\n}\n\nexport class VulnerabilityReferenceNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Reference> {\n normalize (data: Models.Vulnerability.Reference, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n children: [\n makeTextElement(data.id, 'id'),\n this._factory.makeForVulnerabilitySource().normalize(data.source, options, 'source')\n ]\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Reference>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(r => this.normalize(r, options, elementName))\n }\n}\n\nexport class VulnerabilityRatingNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Rating> {\n normalize (data: Models.Vulnerability.Rating, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n children: [\n data.source === undefined\n ? undefined\n : this._factory.makeForVulnerabilitySource().normalize(data.source, options, 'source'),\n makeOptionalTextElement(data.score, 'score'),\n makeOptionalTextElement(data.severity, 'severity'),\n this._factory.spec.supportsVulnerabilityRatingMethod(data.method)\n ? makeOptionalTextElement(data.method, 'method')\n : undefined,\n makeOptionalTextElement(data.vector, 'vector'),\n makeOptionalTextElement(data.justification, 'justification')\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Rating>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(r => this.normalize(r, options, elementName))\n }\n}\n\nexport class VulnerabilityAdvisoryNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Advisory> {\n normalize (data: Models.Vulnerability.Advisory, options: NormalizerOptions, elementName: string): SimpleXml.Element | undefined {\n const url = escapeUri(data.url.toString())\n if (!XmlSchema.isAnyURI(url)) {\n // invalid value -> cannot render\n return undefined\n }\n return {\n type: 'element',\n name: elementName,\n children: [\n makeOptionalTextElement(data.title, 'title'),\n makeTextElement(url, 'url')\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Advisory>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n a => this.normalize(a, options, elementName)\n ).filter(isNotUndefined)\n }\n}\n\nexport class VulnerabilityCreditsNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Credits> {\n normalize (data: Models.Vulnerability.Credits, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const organizations: SimpleXml.Element | undefined = data.organizations.size > 0\n ? {\n type: 'element',\n name: 'organizations',\n children: this._factory.makeForOrganizationalEntity().normalizeIterable(data.organizations, options, 'organization')\n }\n : undefined\n const individuals: SimpleXml.Element | undefined = data.individuals.size > 0\n ? {\n type: 'element',\n name: 'individuals',\n children: this._factory.makeForOrganizationalContact().normalizeIterable(data.individuals, options, 'individual')\n }\n : undefined\n return {\n type: 'element',\n name: elementName,\n children: [\n organizations,\n individuals\n ].filter(isNotUndefined)\n }\n }\n}\n\nexport class VulnerabilityAnalysisNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Analysis> {\n normalize (data: Models.Vulnerability.Analysis, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const responses: SimpleXml.Element | undefined = data.response.size > 0\n ? {\n type: 'element',\n name: 'responses',\n children: (\n options.sortLists ?? false\n ? data.response.sorted()\n : Array.from(data.response)\n ).map(ar => makeTextElement(ar, 'response'))\n }\n : undefined\n return {\n type: 'element',\n name: elementName,\n children: [\n makeOptionalTextElement(data.state, 'state'),\n makeOptionalTextElement(data.justification, 'justification'),\n responses,\n makeOptionalTextElement(data.detail, 'detail')\n ].filter(isNotUndefined)\n }\n }\n}\n\nexport class VulnerabilityAffectNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Affect> {\n normalize (data: Models.Vulnerability.Affect, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const versions: SimpleXml.Element | undefined = data.versions.size > 0\n ? {\n type: 'element',\n name: 'versions',\n children: this._factory.makeForVulnerabilityAffectedVersion().normalizeIterable(data.versions, options, 'version')\n }\n : undefined\n return {\n type: 'element',\n name: elementName,\n children: [\n makeTextElement(data.ref, 'ref'),\n versions\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Affect>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(a => this.normalize(a, options, elementName))\n }\n}\n\nexport class VulnerabilityAffectedVersionNormalizer extends BaseXmlNormalizer<Models.Vulnerability.AffectedVersion> {\n normalize (data: Models.Vulnerability.AffectedVersion, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n switch (true) {\n case data instanceof Models.Vulnerability.AffectedSingleVersion:\n return this.#normalizeAffectedSingleVersion(data, elementName)\n case data instanceof Models.Vulnerability.AffectedVersionRange:\n return this.#normalizeAffectedVersionRange(data, elementName)\n /* c8 ignore start */\n default:\n // this case is expected to never happen - and therefore is undocumented\n throw new TypeError('Unexpected Vulnerability AffectedVersion')\n /* c8 ignore end */\n }\n }\n\n #normalizeAffectedSingleVersion (data: Models.Vulnerability.AffectedSingleVersion, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n children: [\n makeTextElement(data.version, 'version'),\n makeOptionalTextElement(data.status, 'status')\n ].filter(isNotUndefined)\n }\n }\n\n #normalizeAffectedVersionRange (data: Models.Vulnerability.AffectedVersionRange, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n children: [\n makeTextElement(data.range, 'range'),\n makeOptionalTextElement(data.status, 'status')\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.AffectedVersion>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(av => this.normalize(av, options, elementName))\n }\n}\n\n/* eslint-enable @typescript-eslint/prefer-nullish-coalescing, @typescript-eslint/strict-boolean-expressions */\n\ntype StrictTextElement = SimpleXml.TextElement & { children: string }\n\nfunction makeOptionalTextElement (data: null | undefined | Stringable, elementName: string): undefined | StrictTextElement {\n const s = data?.toString() ?? ''\n return s.length > 0\n ? makeTextElement(s, elementName)\n : undefined\n}\n\nfunction makeTextElement (data: Stringable, elementName: string): StrictTextElement {\n return {\n type: 'element',\n name: elementName,\n children: data.toString()\n }\n}\n\nfunction makeTextElementIter (data: Iterable<Stringable>, options: NormalizerOptions, elementName: string): StrictTextElement[] {\n const r: StrictTextElement[] = Array.from(data, d => makeTextElement(d, elementName))\n if (options.sortLists ?? false) {\n r.sort(({ children: a }, { children: b }) => a.localeCompare(b))\n }\n return r\n}\n\nfunction makeOptionalDateTimeElement (data: null | undefined | Date, elementName: string): undefined | StrictTextElement {\n const d = data?.toISOString()\n return d === undefined\n ? undefined\n : makeTextElement(d, elementName)\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport namespace XmlSchema {\n\n const _AnyUriSchemePattern = /^[a-z][a-z0-9+\\-.]*$/i\n\n /**\n * @see {@link isAnyURI}\n */\n export type AnyURI = string\n\n /**\n * Test whether format is XML::anyURI - best-effort.\n *\n * @see {@link http://www.w3.org/TR/xmlschema-2/#anyURI | anyURI spec}\n * @see {@link https://www.w3.org/2011/04/XMLSchema/TypeLibrary-URI-RFC3986.xsd | RFC 3986}\n * @see {@link https://www.w3.org/2011/04/XMLSchema/TypeLibrary-IRI-RFC3987.xsd | RFC 3987}\n *\n * @TODO add more validation according to spec\n */\n export function isAnyURI (value: AnyURI | any): value is AnyURI {\n if (typeof value !== 'string') {\n // not a string\n return false\n }\n if (value.length === 0) {\n // empty string\n return false\n }\n\n const fragmentPos = value.indexOf('#')\n let beforeFragment: string\n if (fragmentPos >= 0) {\n if (value.includes('#', fragmentPos + 1)) {\n // has a second fragment marker\n return false\n }\n beforeFragment = value.slice(undefined, fragmentPos)\n } else {\n beforeFragment = value\n }\n\n const schemePos = beforeFragment.indexOf(':')\n if (schemePos >= 0) {\n if (!_AnyUriSchemePattern.test(beforeFragment.slice(undefined, schemePos))) {\n // invalid schema\n return false\n }\n }\n\n return true\n }\n\n}\n\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport namespace SimpleXml {\n\n /**\n * Attribute's name.\n *\n * Must be alphanumeric.\n * Must start with alpha.\n * Must not contain whitespace characters.\n * Should not be literal \"xmlns\".\n */\n export type AttributeName = string\n\n /**\n * Element's name.\n *\n * Must be alphanumeric.\n * Must start with alpha.\n * Must not contain whitespace characters.\n */\n export type ElementName = string\n\n /**\n * Textual representation.\n *\n * Be aware that low-/high-bytes could be represented as numbers.\n * They might need to be converted on serialization.\n */\n export type Text = string | number\n\n /**\n * Unset representation.\n *\n * Do NOT allow null here, as it is context-aware sometimes an empty string or unset,\n * in a space where context is unknown.\n */\n export type Unset = undefined\n\n export type ElementAttributes = Record<AttributeName, Text | Unset>\n\n export type ElementChildren = Iterable<Comment | Element> | Text | Unset\n\n /**\n * Element node.\n */\n export interface Element {\n type: 'element'\n name: ElementName\n namespace?: string | URL\n attributes?: ElementAttributes\n children?: ElementChildren\n }\n\n /**\n * Element node with textual content\n */\n export interface TextElement extends Element {\n children: Text\n }\n\n /**\n * Comment node.\n */\n export interface Comment {\n type: 'comment'\n text?: Text\n }\n\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Bom } from '../models'\nimport { Format, UnsupportedFormatError } from '../spec'\nimport { BaseSerializer } from './baseSerializer'\nimport type { NormalizerOptions } from './types'\nimport type { Factory as NormalizerFactory } from './xml/normalize'\nimport type { SimpleXml } from './xml/types'\n\n/**\n * Base XML serializer.\n */\nexport abstract class XmlBaseSerializer extends BaseSerializer<SimpleXml.Element> {\n readonly #normalizerFactory: NormalizerFactory\n\n /**\n * @throws {@link UnsupportedFormatError} if `normalizerFactory.spec` does not support {@link Format.XML}.\n */\n constructor (normalizerFactory: XmlBaseSerializer['normalizerFactory']) {\n if (!normalizerFactory.spec.supportsFormat(Format.XML)) {\n throw new UnsupportedFormatError('Spec does not support XML format.')\n }\n\n super()\n this.#normalizerFactory = normalizerFactory\n }\n\n get normalizerFactory (): NormalizerFactory {\n return this.#normalizerFactory\n }\n\n protected _normalize (\n bom: Bom,\n options: NormalizerOptions = {}\n ): SimpleXml.Element {\n return this.#normalizerFactory.makeForBom()\n .normalize(bom, options)\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { isNotUndefined } from '../_helpers/notUndefined'\nimport type { SerializerOptions } from './types'\nimport type { SimpleXml } from './xml/types'\nimport { XmlBaseSerializer } from './xmlBaseSerializer'\n\n/**\n * XML serializer for web browsers.\n */\nexport class XmlSerializer extends XmlBaseSerializer {\n protected _serialize (\n normalizedBom: SimpleXml.Element,\n { space }: SerializerOptions = {}\n ): string {\n const doc = this.#buildXmlDocument(normalizedBom)\n // @TODO: add indention based on `space`\n return (new XMLSerializer()).serializeToString(doc)\n }\n\n #buildXmlDocument (\n rootElement: SimpleXml.Element\n ): XMLDocument {\n const namespace = null\n const doc = document.implementation.createDocument(namespace, null)\n doc.appendChild(this.#buildElement(rootElement, doc, namespace))\n return doc\n }\n\n #getNS (element: SimpleXml.Element): string | null {\n const ns = (element.namespace ?? element.attributes?.xmlns)?.toString() ?? ''\n return ns.length > 0\n ? ns\n : null\n }\n\n #buildElement (element: SimpleXml.Element, doc: XMLDocument, parentNS: string | null): Element {\n const ns = this.#getNS(element) ?? parentNS\n const node: Element = doc.createElementNS(ns, element.name)\n if (isNotUndefined(element.attributes)) {\n this.#setAttributes(node, element.attributes)\n }\n if (isNotUndefined(element.children)) {\n this.#addChildren(node, element.children, ns)\n }\n return node\n }\n\n #setAttributes (node: Element, attributes: SimpleXml.ElementAttributes): void {\n for (const [name, value] of Object.entries(attributes)) {\n if (isNotUndefined(value) && name !== 'xmlns') {\n // reminder: cannot change a namespace(xmlns) after the fact.\n node.setAttribute(name, `${value}`)\n }\n }\n }\n\n #addChildren (node: Element, children: SimpleXml.ElementChildren, parentNS: string | null = null): void {\n if (children === undefined) {\n return\n }\n\n if (typeof children === 'string' || typeof children === 'number') {\n node.textContent = children.toString()\n return\n }\n\n const doc = node.ownerDocument\n for (const child of children) {\n if (child.type === 'element') {\n node.appendChild(this.#buildElement(child, doc, parentNS))\n }\n // comments are not implemented, yet\n }\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport * as spdxExpressionParse from 'spdx-expression-parse'\n\n/* @ts-expect-error: TS6059 -- this works as long as the file/path is available in dist-package. */\nimport { enum as _spdxSpecEnum } from '../res/schema/spdx.SNAPSHOT.schema.json' with { type: 'json' }\n\n/**\n * One of the known SPDX licence identifiers.\n *\n * @see {@link http://cyclonedx.org/schema/spdx | SPDX schema}\n * @see {@link isSupportedSpdxId}\n * @see {@link fixupSpdxId}\n */\nexport type SpdxId = string\n\nconst spdxIds: ReadonlySet<SpdxId> = new Set(_spdxSpecEnum)\n\nconst spdxLowerToActual: Readonly<Record<string, SpdxId>> = Object.freeze(Object.fromEntries(\n _spdxSpecEnum.map(spdxId => [spdxId.toLowerCase(), spdxId])\n))\n\nexport function isSupportedSpdxId (value: SpdxId | any): value is SpdxId {\n /* eslint-disable-next-line @typescript-eslint/no-unsafe-argument */\n return spdxIds.has(value)\n}\n\n/** Try to convert a `string`-like to a valid/known {@link SpdxId}. */\nexport function fixupSpdxId (value: string | any): SpdxId | undefined {\n return typeof value === 'string' && value.length > 0\n ? spdxLowerToActual[value.toLowerCase()]\n : undefined\n}\n\nexport function isValidSpdxLicenseExpression (value: string | any): boolean {\n if (typeof value !== 'string') {\n return false\n }\n try {\n spdxExpressionParse(value)\n } catch (err) {\n return false\n }\n return true\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { ComponentType, ExternalReferenceType, HashAlgorithm, Vulnerability } from '../enums'\nimport type { HashContent } from '../models'\nimport type { Format, Version } from './enums'\n\n/**\n * This interface is not intended to be public API.\n * This interface may be affected by breaking changes without notice.\n *\n * See the public exported constants, like {@link Spec.Spec1dot4}, that provide objects implementing this interface.\n * See also {@link Spec.SpecVersionDict} for implementations.\n */\nexport interface _SpecProtocol {\n version: Version\n supportsFormat: (f: Format | any) => boolean\n supportsComponentType: (ct: ComponentType | any) => boolean\n supportsHashAlgorithm: (ha: HashAlgorithm | any) => boolean\n supportsHashValue: (hv: HashContent | any) => boolean\n supportsExternalReferenceType: (ert: ExternalReferenceType | any) => boolean\n supportsDependencyGraph: boolean\n supportsToolReferences: boolean\n requiresComponentVersion: boolean\n supportsProperties: (model: any) => boolean\n supportsVulnerabilities: boolean\n supportsVulnerabilityRatingMethod: (rm: Vulnerability.RatingMethod | any) => boolean\n supportsComponentEvidence: boolean\n supportsMetadataLifecycles: boolean\n supportsMetadataLicenses: boolean\n supportsMetadataProperties: boolean\n supportsExternalReferenceHashes: boolean\n supportsLicenseAcknowledgement: boolean\n}\n\n/**\n * This class was never intended to be public API,\n *\n * This is a helper to get the exact spec-versions implemented according to {@link _SpecProtocol | Specification}.\n *\n * @internal as this class may be affected by breaking changes without notice\n */\nexport class _Spec implements _SpecProtocol {\n readonly #version: Version\n readonly #formats: ReadonlySet<Format>\n readonly #componentTypes: ReadonlySet<ComponentType>\n readonly #hashAlgorithms: ReadonlySet<HashAlgorithm>\n readonly #hashValuePattern: RegExp\n readonly #externalReferenceTypes: ReadonlySet<ExternalReferenceType>\n readonly #vulnerabilityRatingMethods: ReadonlySet<Vulnerability.RatingMethod>\n readonly #supportsDependencyGraph: boolean\n readonly #supportsToolReferences: boolean\n readonly #requiresComponentVersion: boolean\n readonly #supportsProperties: boolean\n readonly #supportsVulnerabilities: boolean\n readonly #supportsComponentEvidence: boolean\n readonly #supportsMetadataLifecycles: boolean\n readonly #supportsMetadataLicenses: boolean\n readonly #supportsMetadataProperties: boolean\n readonly #supportsExternalReferenceHashes: boolean\n readonly #supportsLicenseAcknowledgement: boolean\n\n constructor (\n version: Version,\n formats: Iterable<Format>,\n componentTypes: Iterable<ComponentType>,\n hashAlgorithms: Iterable<HashAlgorithm>,\n hashValuePattern: RegExp,\n externalReferenceTypes: Iterable<ExternalReferenceType>,\n supportsDependencyGraph: boolean,\n supportsToolReferences: boolean,\n requiresComponentVersion: boolean,\n supportsProperties: boolean,\n supportsVulnerabilities: boolean,\n vulnerabilityRatingMethods: Iterable<Vulnerability.RatingMethod>,\n supportsComponentEvidence: boolean,\n supportsMetadataLifecycles: boolean,\n supportsMetadataLicenses: boolean,\n supportsMetadataProperties: boolean,\n supportsExternalReferenceHashes: boolean,\n supportsLicenseAcknowledgement: boolean\n ) {\n this.#version = version\n this.#formats = new Set(formats)\n this.#componentTypes = new Set(componentTypes)\n this.#hashAlgorithms = new Set(hashAlgorithms)\n this.#hashValuePattern = hashValuePattern\n this.#externalReferenceTypes = new Set(externalReferenceTypes)\n this.#supportsDependencyGraph = supportsDependencyGraph\n this.#supportsToolReferences = supportsToolReferences\n this.#requiresComponentVersion = requiresComponentVersion\n this.#supportsProperties = supportsProperties\n this.#supportsVulnerabilities = supportsVulnerabilities\n this.#vulnerabilityRatingMethods = new Set(vulnerabilityRatingMethods)\n this.#supportsComponentEvidence = supportsComponentEvidence\n this.#supportsMetadataLifecycles = supportsMetadataLifecycles\n this.#supportsMetadataLicenses = supportsMetadataLicenses\n this.#supportsMetadataProperties = supportsMetadataProperties\n this.#supportsExternalReferenceHashes = supportsExternalReferenceHashes\n this.#supportsLicenseAcknowledgement = supportsLicenseAcknowledgement\n }\n\n get version (): Version {\n return this.#version\n }\n\n supportsFormat (f: Format | any): boolean {\n /* eslint-disable-next-line @typescript-eslint/no-unsafe-argument */\n return this.#formats.has(f)\n }\n\n supportsComponentType (ct: ComponentType | any): boolean {\n /* eslint-disable-next-line @typescript-eslint/no-unsafe-argument */\n return this.#componentTypes.has(ct)\n }\n\n supportsHashAlgorithm (ha: HashAlgorithm | any): boolean {\n /* eslint-disable-next-line @typescript-eslint/no-unsafe-argument */\n return this.#hashAlgorithms.has(ha)\n }\n\n supportsHashValue (hv: HashContent | any): boolean {\n return typeof hv === 'string' &&\n this.#hashValuePattern.test(hv)\n }\n\n supportsExternalReferenceType (ert: ExternalReferenceType | any): boolean {\n /* eslint-disable-next-line @typescript-eslint/no-unsafe-argument */\n return this.#externalReferenceTypes.has(ert)\n }\n\n get supportsDependencyGraph (): boolean {\n return this.#supportsDependencyGraph\n }\n\n get supportsToolReferences (): boolean {\n return this.#supportsToolReferences\n }\n\n get requiresComponentVersion (): boolean {\n return this.#requiresComponentVersion\n }\n\n supportsProperties (): boolean {\n // currently a global allow/deny -- might work based on input, in the future\n return this.#supportsProperties\n }\n\n get supportsVulnerabilities (): boolean {\n return this.#supportsVulnerabilities\n }\n\n supportsVulnerabilityRatingMethod (rm: Vulnerability.RatingMethod | any): boolean {\n /* eslint-disable-next-line @typescript-eslint/no-unsafe-argument */\n return this.#vulnerabilityRatingMethods.has(rm)\n }\n\n get supportsComponentEvidence (): boolean {\n return this.#supportsComponentEvidence\n }\n\n get supportsMetadataLifecycles (): boolean {\n return this.#supportsMetadataLifecycles\n }\n\n get supportsMetadataLicenses (): boolean {\n return this.#supportsMetadataLicenses\n }\n\n get supportsMetadataProperties (): boolean {\n return this.#supportsMetadataProperties\n }\n\n get supportsExternalReferenceHashes (): boolean {\n return this.#supportsExternalReferenceHashes\n }\n\n get supportsLicenseAcknowledgement (): boolean {\n return this.#supportsLicenseAcknowledgement\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { ComponentType, ExternalReferenceType, HashAlgorithm, Vulnerability } from '../enums'\nimport type { _SpecProtocol } from './_protocol'\nimport { _Spec } from './_protocol'\nimport { Format, Version } from './enums'\n\n/** Specification v1.2 */\nexport const Spec1dot2: Readonly<_SpecProtocol> = Object.freeze(new _Spec(\n Version.v1dot2,\n [\n Format.XML,\n Format.JSON\n ],\n [\n ComponentType.Application,\n ComponentType.Framework,\n ComponentType.Library,\n ComponentType.Container,\n ComponentType.OperatingSystem,\n ComponentType.Device,\n ComponentType.Firmware,\n ComponentType.File\n ],\n [\n HashAlgorithm.MD5,\n HashAlgorithm['SHA-1'],\n HashAlgorithm['SHA-256'],\n HashAlgorithm['SHA-384'],\n HashAlgorithm['SHA-512'],\n HashAlgorithm['SHA3-256'],\n HashAlgorithm['SHA3-384'],\n HashAlgorithm['SHA3-512'],\n HashAlgorithm['BLAKE2b-256'],\n HashAlgorithm['BLAKE2b-384'],\n HashAlgorithm['BLAKE2b-512'],\n HashAlgorithm.BLAKE3\n ],\n /^([a-fA-F0-9]{32})$|^([a-fA-F0-9]{40})$|^([a-fA-F0-9]{64})$|^([a-fA-F0-9]{96})$|^([a-fA-F0-9]{128})$/,\n [\n ExternalReferenceType.VCS,\n ExternalReferenceType.IssueTracker,\n ExternalReferenceType.Website,\n ExternalReferenceType.Advisories,\n ExternalReferenceType.BOM,\n ExternalReferenceType.MailingList,\n ExternalReferenceType.Social,\n ExternalReferenceType.Chat,\n ExternalReferenceType.Documentation,\n ExternalReferenceType.Support,\n ExternalReferenceType.Distribution,\n ExternalReferenceType.License,\n ExternalReferenceType.BuildMeta,\n ExternalReferenceType.BuildSystem,\n ExternalReferenceType.Other\n ],\n true,\n false,\n true,\n false,\n false,\n [],\n false,\n false,\n false,\n false,\n false,\n false\n))\n\n/** Specification v1.3 */\nexport const Spec1dot3: Readonly<_SpecProtocol> = Object.freeze(new _Spec(\n Version.v1dot3,\n [\n Format.XML,\n Format.JSON\n ],\n [\n ComponentType.Application,\n ComponentType.Framework,\n ComponentType.Library,\n ComponentType.Container,\n ComponentType.OperatingSystem,\n ComponentType.Device,\n ComponentType.Firmware,\n ComponentType.File\n ],\n [\n HashAlgorithm.MD5,\n HashAlgorithm['SHA-1'],\n HashAlgorithm['SHA-256'],\n HashAlgorithm['SHA-384'],\n HashAlgorithm['SHA-512'],\n HashAlgorithm['SHA3-256'],\n HashAlgorithm['SHA3-384'],\n HashAlgorithm['SHA3-512'],\n HashAlgorithm['BLAKE2b-256'],\n HashAlgorithm['BLAKE2b-384'],\n HashAlgorithm['BLAKE2b-512'],\n HashAlgorithm.BLAKE3\n ],\n /^([a-fA-F0-9]{32})$|^([a-fA-F0-9]{40})$|^([a-fA-F0-9]{64})$|^([a-fA-F0-9]{96})$|^([a-fA-F0-9]{128})$/,\n [\n ExternalReferenceType.VCS,\n ExternalReferenceType.IssueTracker,\n ExternalReferenceType.Website,\n ExternalReferenceType.Advisories,\n ExternalReferenceType.BOM,\n ExternalReferenceType.MailingList,\n ExternalReferenceType.Social,\n ExternalReferenceType.Chat,\n ExternalReferenceType.Documentation,\n ExternalReferenceType.Support,\n ExternalReferenceType.Distribution,\n ExternalReferenceType.License,\n ExternalReferenceType.BuildMeta,\n ExternalReferenceType.BuildSystem,\n ExternalReferenceType.Other\n ],\n true,\n false,\n true,\n true,\n false,\n [],\n true,\n false,\n true,\n true,\n true,\n false\n))\n\n/** Specification v1.4 */\nexport const Spec1dot4: Readonly<_SpecProtocol> = Object.freeze(new _Spec(\n Version.v1dot4,\n [\n Format.XML,\n Format.JSON\n ],\n [\n ComponentType.Application,\n ComponentType.Framework,\n ComponentType.Library,\n ComponentType.Container,\n ComponentType.OperatingSystem,\n ComponentType.Device,\n ComponentType.Firmware,\n ComponentType.File\n ],\n [\n HashAlgorithm.MD5,\n HashAlgorithm['SHA-1'],\n HashAlgorithm['SHA-256'],\n HashAlgorithm['SHA-384'],\n HashAlgorithm['SHA-512'],\n HashAlgorithm['SHA3-256'],\n HashAlgorithm['SHA3-384'],\n HashAlgorithm['SHA3-512'],\n HashAlgorithm['BLAKE2b-256'],\n HashAlgorithm['BLAKE2b-384'],\n HashAlgorithm['BLAKE2b-512'],\n HashAlgorithm.BLAKE3\n ],\n /^([a-fA-F0-9]{32})$|^([a-fA-F0-9]{40})$|^([a-fA-F0-9]{64})$|^([a-fA-F0-9]{96})$|^([a-fA-F0-9]{128})$/,\n [\n ExternalReferenceType.VCS,\n ExternalReferenceType.IssueTracker,\n ExternalReferenceType.Website,\n ExternalReferenceType.Advisories,\n ExternalReferenceType.BOM,\n ExternalReferenceType.MailingList,\n ExternalReferenceType.Social,\n ExternalReferenceType.Chat,\n ExternalReferenceType.Documentation,\n ExternalReferenceType.Support,\n ExternalReferenceType.Distribution,\n ExternalReferenceType.License,\n ExternalReferenceType.BuildMeta,\n ExternalReferenceType.BuildSystem,\n ExternalReferenceType.ReleaseNotes,\n ExternalReferenceType.Other\n ],\n true,\n true,\n false,\n true,\n true,\n [\n Vulnerability.RatingMethod.CVSSv2,\n Vulnerability.RatingMethod.CVSSv3,\n Vulnerability.RatingMethod.CVSSv31,\n Vulnerability.RatingMethod.OWASP,\n Vulnerability.RatingMethod.Other\n ],\n true,\n false,\n true,\n true,\n true,\n false\n))\n\n/** Specification v1.5 */\nexport const Spec1dot5: Readonly<_SpecProtocol> = Object.freeze(new _Spec(\n Version.v1dot5,\n [\n Format.XML,\n Format.JSON\n ],\n [\n ComponentType.Application,\n ComponentType.Framework,\n ComponentType.Library,\n ComponentType.Container,\n ComponentType.Platform,\n ComponentType.OperatingSystem,\n ComponentType.Device,\n ComponentType.DeviceDriver,\n ComponentType.Firmware,\n ComponentType.File,\n ComponentType.MachineLearningModel,\n ComponentType.Data\n ],\n [\n HashAlgorithm.MD5,\n HashAlgorithm['SHA-1'],\n HashAlgorithm['SHA-256'],\n HashAlgorithm['SHA-384'],\n HashAlgorithm['SHA-512'],\n HashAlgorithm['SHA3-256'],\n HashAlgorithm['SHA3-384'],\n HashAlgorithm['SHA3-512'],\n HashAlgorithm['BLAKE2b-256'],\n HashAlgorithm['BLAKE2b-384'],\n HashAlgorithm['BLAKE2b-512'],\n HashAlgorithm.BLAKE3\n ],\n /^([a-fA-F0-9]{32})$|^([a-fA-F0-9]{40})$|^([a-fA-F0-9]{64})$|^([a-fA-F0-9]{96})$|^([a-fA-F0-9]{128})$/,\n [\n ExternalReferenceType.VCS,\n ExternalReferenceType.IssueTracker,\n ExternalReferenceType.Website,\n ExternalReferenceType.Advisories,\n ExternalReferenceType.BOM,\n ExternalReferenceType.MailingList,\n ExternalReferenceType.Social,\n ExternalReferenceType.Chat,\n ExternalReferenceType.Documentation,\n ExternalReferenceType.Support,\n ExternalReferenceType.Distribution,\n ExternalReferenceType.DistributionIntake,\n ExternalReferenceType.License,\n ExternalReferenceType.BuildMeta,\n ExternalReferenceType.BuildSystem,\n ExternalReferenceType.ReleaseNotes,\n ExternalReferenceType.SecurityContact,\n ExternalReferenceType.ModelCard,\n ExternalReferenceType.Log,\n ExternalReferenceType.Configuration,\n ExternalReferenceType.Evidence,\n ExternalReferenceType.Formulation,\n ExternalReferenceType.Attestation,\n ExternalReferenceType.ThreatModel,\n ExternalReferenceType.AdversaryModel,\n ExternalReferenceType.RiskAssessment,\n ExternalReferenceType.VulnerabilityAssertion,\n ExternalReferenceType.ExploitabilityStatement,\n ExternalReferenceType.PentestReport,\n ExternalReferenceType.StaticAnalysisReport,\n ExternalReferenceType.DynamicAnalysisReport,\n ExternalReferenceType.RuntimeAnalysisReport,\n ExternalReferenceType.ComponentAnalysisReport,\n ExternalReferenceType.MaturityReport,\n ExternalReferenceType.CertificationReport,\n ExternalReferenceType.CodifiedInfrastructure,\n ExternalReferenceType.QualityMetrics,\n ExternalReferenceType.POAM,\n ExternalReferenceType.Other\n ],\n true,\n true,\n false,\n true,\n true,\n [\n Vulnerability.RatingMethod.CVSSv2,\n Vulnerability.RatingMethod.CVSSv3,\n Vulnerability.RatingMethod.CVSSv31,\n Vulnerability.RatingMethod.CVSSv4,\n Vulnerability.RatingMethod.OWASP,\n Vulnerability.RatingMethod.SSVC,\n Vulnerability.RatingMethod.Other\n ],\n true,\n true,\n true,\n true,\n true,\n false\n))\n\n/** Specification v1.6 */\nexport const Spec1dot6: Readonly<_SpecProtocol> = Object.freeze(new _Spec(\n Version.v1dot6,\n [\n Format.XML,\n Format.JSON\n ],\n [\n ComponentType.Application,\n ComponentType.Framework,\n ComponentType.Library,\n ComponentType.Container,\n ComponentType.Platform,\n ComponentType.OperatingSystem,\n ComponentType.Device,\n ComponentType.DeviceDriver,\n ComponentType.Firmware,\n ComponentType.File,\n ComponentType.MachineLearningModel,\n ComponentType.Data,\n ComponentType.CryptographicAsset\n ],\n [\n HashAlgorithm.MD5,\n HashAlgorithm['SHA-1'],\n HashAlgorithm['SHA-256'],\n HashAlgorithm['SHA-384'],\n HashAlgorithm['SHA-512'],\n HashAlgorithm['SHA3-256'],\n HashAlgorithm['SHA3-384'],\n HashAlgorithm['SHA3-512'],\n HashAlgorithm['BLAKE2b-256'],\n HashAlgorithm['BLAKE2b-384'],\n HashAlgorithm['BLAKE2b-512'],\n HashAlgorithm.BLAKE3\n ],\n /^([a-fA-F0-9]{32})$|^([a-fA-F0-9]{40})$|^([a-fA-F0-9]{64})$|^([a-fA-F0-9]{96})$|^([a-fA-F0-9]{128})$/,\n [\n ExternalReferenceType.VCS,\n ExternalReferenceType.IssueTracker,\n ExternalReferenceType.Website,\n ExternalReferenceType.Advisories,\n ExternalReferenceType.BOM,\n ExternalReferenceType.MailingList,\n ExternalReferenceType.Social,\n ExternalReferenceType.Chat,\n ExternalReferenceType.Documentation,\n ExternalReferenceType.Support,\n ExternalReferenceType.SourceDistribution,\n ExternalReferenceType.Distribution,\n ExternalReferenceType.DistributionIntake,\n ExternalReferenceType.License,\n ExternalReferenceType.BuildMeta,\n ExternalReferenceType.BuildSystem,\n ExternalReferenceType.ReleaseNotes,\n ExternalReferenceType.SecurityContact,\n ExternalReferenceType.ModelCard,\n ExternalReferenceType.Log,\n ExternalReferenceType.Configuration,\n ExternalReferenceType.Evidence,\n ExternalReferenceType.Formulation,\n ExternalReferenceType.Attestation,\n ExternalReferenceType.ThreatModel,\n ExternalReferenceType.AdversaryModel,\n ExternalReferenceType.RiskAssessment,\n ExternalReferenceType.VulnerabilityAssertion,\n ExternalReferenceType.ExploitabilityStatement,\n ExternalReferenceType.PentestReport,\n ExternalReferenceType.StaticAnalysisReport,\n ExternalReferenceType.DynamicAnalysisReport,\n ExternalReferenceType.RuntimeAnalysisReport,\n ExternalReferenceType.ComponentAnalysisReport,\n ExternalReferenceType.MaturityReport,\n ExternalReferenceType.CertificationReport,\n ExternalReferenceType.CodifiedInfrastructure,\n ExternalReferenceType.QualityMetrics,\n ExternalReferenceType.POAM,\n ExternalReferenceType.ElectronicSignature,\n ExternalReferenceType.DigitalSignature,\n ExternalReferenceType.RFC9116,\n ExternalReferenceType.Other\n ],\n true,\n true,\n false,\n true,\n true,\n [\n Vulnerability.RatingMethod.CVSSv2,\n Vulnerability.RatingMethod.CVSSv3,\n Vulnerability.RatingMethod.CVSSv31,\n Vulnerability.RatingMethod.CVSSv4,\n Vulnerability.RatingMethod.OWASP,\n Vulnerability.RatingMethod.SSVC,\n Vulnerability.RatingMethod.Other\n ],\n true,\n true,\n true,\n true,\n true,\n true\n))\n\nexport const SpecVersionDict: Readonly<Partial<Record<Version, Readonly<_SpecProtocol>>>> = Object.freeze({\n [Version.v1dot6]: Spec1dot6,\n [Version.v1dot5]: Spec1dot5,\n [Version.v1dot4]: Spec1dot4,\n [Version.v1dot3]: Spec1dot3,\n [Version.v1dot2]: Spec1dot2\n // <= v1.1 is not implemented\n})\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum Version {\n v1dot6 = '1.6',\n v1dot5 = '1.5',\n v1dot4 = '1.4',\n v1dot3 = '1.3',\n v1dot2 = '1.2',\n v1dot1 = '1.1',\n v1dot0 = '1.0',\n}\n\nexport enum Format {\n XML = 'xml',\n JSON = 'json',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './consts'\nexport * from './enums'\n\nexport class UnsupportedFormatError extends Error {\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * Specifies a well-formed CPE name that conforms to the CPE 2.2 or 2.3 specification.\n * See the [official specification](https://nvd.nist.gov/products/cpe).\n *\n * @see {@link isCPE}\n */\nexport type CPE = string\n\n/* eslint-disable-next-line no-useless-escape -- value directly from XML, revert special-chars(like `&` -> `&`), and surrounded with `^` and `$` */\nconst cpePattern = /^([c][pP][eE]:\\/[AHOaho]?(:[A-Za-z0-9\\._\\-~%]*){0,6})$|^(cpe:2\\.3:[aho\\*\\-](:(((\\?*|\\*?)([a-zA-Z0-9\\-\\._]|(\\\\[\\\\\\*\\?!\"#$$%&'\\(\\)\\+,\\/:;<=>@\\[\\]\\^`\\{\\|}~]))+(\\?*|\\*?))|[\\*\\-])){5}(:(([a-zA-Z]{2,3}(-([a-zA-Z]{2}|[0-9]{3}))?)|[\\*\\-]))(:(((\\?*|\\*?)([a-zA-Z0-9\\-\\._]|(\\\\[\\\\\\*\\?!\"#$$%&'\\(\\)\\+,\\/:;<=>@\\[\\]\\^`\\{\\|}~]))+(\\?*|\\*?))|[\\*\\-])){4})$/\n\nexport function isCPE (value: any): value is CPE {\n return typeof value === 'string' &&\n cpePattern.test(value)\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { SortableNumbers } from '../_helpers/sortable'\nimport type { PositiveInteger } from './integer'\nimport { isPositiveInteger } from './integer'\n\n/**\n * Integer representation of a Common Weaknesses Enumerations (CWE).\n *\n * @example\n * value `399` might represent `https://cwe.mitre.org/data/definitions/399.html`.\n *\n * @see {@link isCWE}\n */\nexport type CWE = PositiveInteger\n\nexport function isCWE (value: any): value is CWE {\n return isPositiveInteger(value)\n}\n\nexport class CweRepository extends SortableNumbers<CWE> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './cpe'\nexport * from './cwe'\nexport * from './integer'\nexport * from './mimeType'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * Integer\n *\n * @see {@link isInteger}\n */\nexport type Integer = number | NonNegativeInteger\n\nexport function isInteger (value: any): value is Integer {\n return Number.isInteger(value)\n}\n\n/**\n * Integer greater than or equal to `0`\n *\n * @see {@link isNonNegativeInteger}\n */\nexport type NonNegativeInteger = number | PositiveInteger\n\nexport function isNonNegativeInteger (value: any): value is NonNegativeInteger {\n return isInteger(value) &&\n value >= 0\n}\n\n/**\n * Integer greater `0`\n *\n * @see {@link isPositiveInteger}\n */\nexport type PositiveInteger = number\n\nexport function isPositiveInteger (value: any): value is PositiveInteger {\n return isInteger(value) &&\n value > 0\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * @see {@link isMimeType}\n */\nexport type MimeType = string\n\n/* regular expression was taken from the CycloneDX schema definitions. */\nconst mimeTypePattern = /^[-+a-z0-9.]+\\/[-+a-z0-9.]+$/\n\nexport function isMimeType (value: any): value is MimeType {\n return typeof value === 'string' &&\n mimeTypePattern.test(value)\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * Generate valid random SerialNumbers for {@link Models.Bom.serialNumber | Models.Bom.serialNumber}.\n */\nexport function randomSerialNumber (): string {\n const b = [\n Math.round(Math.random() * 0xFFFF),\n Math.round(Math.random() * 0xFFFF),\n Math.round(Math.random() * 0xFFFF),\n // UUID version 4\n Math.round(Math.random() * 0x0FFF) | 0x4000,\n // UUID version 4 variant 1\n Math.round(Math.random() * 0x3FFF) | 0x8000,\n Math.round(Math.random() * 0xFFFF),\n Math.round(Math.random() * 0xFFFF),\n Math.round(Math.random() * 0xFFFF)\n ].map(n => n.toString(16).padStart(4, '0'))\n return `urn:uuid:${b[0]}${b[1]}-${b[2]}-${b[3]}-${b[4]}-${b[5]}${b[6]}${b[7]}`\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\nexport * as BomUtility from './bomUtility'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Version } from '../spec'\n\nexport class NotImplementedError extends Error {\n constructor (version: Version) {\n super(`not implemented for CycloneDX version: ${version}`)\n }\n}\n\nexport class MissingOptionalDependencyError extends Error {\n readonly cause: any | undefined\n\n constructor (message: string, cause?: any) {\n super(message)\n this.cause = cause\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './errors'\nexport * as Types from './types'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './index.common'\n\n// region web-specifics\n\n// there is no JSON validator for the web, yet\n// there is no XML validator for the web, yet\n\n// endregion web-specifics\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * Details and information describing a validation error.\n */\nexport type ValidationError = NonNullable<any>\n\nexport interface Validator {\n /**\n * Promise completes with one of the following:\n * - `null`, when data was valid\n * - {@link ValidationError | something} representing the error details, when data was invalid\n *\n * Promise rejects with one of the following:\n * - {@link Validation.NotImplementedError | NotImplementedError}, when there is no validator available\n * - {@link Validation.MissingOptionalDependencyError | MissingOptionalDependencyError}, when a required dependency was not installed\n */\n validate: (data: string) => Promise<null | ValidationError>\n}\n","module.exports = require(\"packageurl-js\");","module.exports = require(\"spdx-expression-parse\");","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","","// startup\n// Load entry module and return exports\n// This entry module is referenced by other modules so it can't be inlined\nvar __webpack_exports__ = __webpack_require__(\"./src/index.web.ts\");\n",""],"names":[],"sourceRoot":""}
|
|
1
|
+
{"version":3,"file":"lib.dev.js","mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD,O;;;;;;;;;;;ACVA;;;;;;;;;;;;;;;;;EAiBE;;;AAIF,SAAgB,cAAc,CAAK,KAAoB;IACrD,OAAO,KAAK,KAAK,SAAS;AAC5B,CAAC;AAFD,wCAEC;;;;;;;;;;;;ACvBD;;;;;;;;;;;;;;;;;EAiBE;;;AAUF,IAAkB,wBAIjB;AAJD,WAAkB,wBAAwB;IACxC,wDAA4B;IAC5B,8CAAkB;IAClB,iDAAqB;AACvB,CAAC,EAJiB,wBAAwB,wCAAxB,wBAAwB,QAIzC;;;;;;;;;;;;AC/BD;;;;;;;;;;;;;;;;;EAiBE;;;AAkBW,4BAAoB,GAAG,MAAM,CAAC,2BAA2B,CAAC;AAIvE,MAAsB,WAAmB,SAAQ,GAAU;IASzD,MAAM;QACJ,OAAO,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,4BAAoB,CAAC,CAAC;IAC1D,CAAC;IAKD,OAAO,CAAE,KAAsB;QAC7B,MAAM,WAAW,GAAG,KAAK,CAAC,MAAM,EAAE;QAClC,MAAM,UAAU,GAAG,IAAI,CAAC,MAAM,EAAE;QAEhC,IAAI,UAAU,CAAC,MAAM,KAAK,WAAW,CAAC,MAAM,EAAE,CAAC;YAC7C,OAAO,UAAU,CAAC,MAAM,GAAG,WAAW,CAAC,MAAM;QAC/C,CAAC;QAGD,KAAK,IA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xB,gFAAgC;;;;;;;;;;;;ACpBhC;;;;;;;;;;;;;;;;;EAiBE;;;;;;;;;;;;;;;;AAEF,qGAA8B;;;;;;;;;;;;ACnB9B;;;;;;;;;;;;;;;;;EAiBE;;;;;;;;;;;;ACjBF;;;;;;;;;;ACAA;;;;;;;;;;;;;;;;UCAA;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;;;UEtBA;UACA;UACA;UACA","sources":["webpack://CycloneDX_library/webpack/universalModuleDefinition","webpack://CycloneDX_library/./src/_helpers/notUndefined.ts","webpack://CycloneDX_library/./src/_helpers/packageUrl.ts","webpack://CycloneDX_library/./src/_helpers/sortable.ts","webpack://CycloneDX_library/./src/_helpers/tree.ts","webpack://CycloneDX_library/./src/_helpers/uri.ts","webpack://CycloneDX_library/./src/enums/attachmentEncoding.ts","webpack://CycloneDX_library/./src/enums/componentScope.ts","webpack://CycloneDX_library/./src/enums/componentType.ts","webpack://CycloneDX_library/./src/enums/externalReferenceType.ts","webpack://CycloneDX_library/./src/enums/hashAlogorithm.ts","webpack://CycloneDX_library/./src/enums/index.ts","webpack://CycloneDX_library/./src/enums/licenseAcknowledgement.ts","webpack://CycloneDX_library/./src/enums/lifecyclePhase.ts","webpack://CycloneDX_library/./src/enums/vulnerability/affectStatus.ts","webpack://CycloneDX_library/./src/enums/vulnerability/analysisJustification.ts","webpack://CycloneDX_library/./src/enums/vulnerability/analysisResponse.ts","webpack://CycloneDX_library/./src/enums/vulnerability/analysisState.ts","webpack://CycloneDX_library/./src/enums/vulnerability/index.ts","webpack://CycloneDX_library/./src/enums/vulnerability/ratingMethod.ts","webpack://CycloneDX_library/./src/enums/vulnerability/severity.ts","webpack://CycloneDX_library/./src/factories/index.common.ts","webpack://CycloneDX_library/./src/factories/index.web.ts","webpack://CycloneDX_library/./src/factories/license.ts","webpack://CycloneDX_library/./src/factories/packageUrl.ts","webpack://CycloneDX_library/./src/index.common.ts","webpack://CycloneDX_library/./src/index.web.ts","webpack://CycloneDX_library/./src/models/attachment.ts","webpack://CycloneDX_library/./src/models/bom.ts","webpack://CycloneDX_library/./src/models/bomLink.ts","webpack://CycloneDX_library/./src/models/bomRef.ts","webpack://CycloneDX_library/./src/models/component.ts","webpack://CycloneDX_library/./src/models/externalReference.ts","webpack://CycloneDX_library/./src/models/hash.ts","webpack://CycloneDX_library/./src/models/index.ts","webpack://CycloneDX_library/./src/models/license.ts","webpack://CycloneDX_library/./src/models/lifecycle.ts","webpack://CycloneDX_library/./src/models/metadata.ts","webpack://CycloneDX_library/./src/models/organizationalContact.ts","webpack://CycloneDX_library/./src/models/organizationalEntity.ts","webpack://CycloneDX_library/./src/models/property.ts","webpack://CycloneDX_library/./src/models/swid.ts","webpack://CycloneDX_library/./src/models/tool.ts","webpack://CycloneDX_library/./src/models/vulnerability/advisory.ts","webpack://CycloneDX_library/./src/models/vulnerability/affect.ts","webpack://CycloneDX_library/./src/models/vulnerability/analysis.ts","webpack://CycloneDX_library/./src/models/vulnerability/credits.ts","webpack://CycloneDX_library/./src/models/vulnerability/index.ts","webpack://CycloneDX_library/./src/models/vulnerability/rating.ts","webpack://CycloneDX_library/./src/models/vulnerability/reference.ts","webpack://CycloneDX_library/./src/models/vulnerability/source.ts","webpack://CycloneDX_library/./src/models/vulnerability/vulnerability.ts","webpack://CycloneDX_library/./src/serialize/baseSerializer.ts","webpack://CycloneDX_library/./src/serialize/bomRefDiscriminator.ts","webpack://CycloneDX_library/./src/serialize/index.common.ts","webpack://CycloneDX_library/./src/serialize/index.web.ts","webpack://CycloneDX_library/./src/serialize/json/index.ts","webpack://CycloneDX_library/./src/serialize/json/normalize.ts","webpack://CycloneDX_library/./src/serialize/json/types.ts","webpack://CycloneDX_library/./src/serialize/jsonSerializer.ts","webpack://CycloneDX_library/./src/serialize/types.ts","webpack://CycloneDX_library/./src/serialize/xml/index.ts","webpack://CycloneDX_library/./src/serialize/xml/normalize.ts","webpack://CycloneDX_library/./src/serialize/xml/types.ts","webpack://CycloneDX_library/./src/serialize/xmlBaseSerializer.ts","webpack://CycloneDX_library/./src/serialize/xmlSerializer.web.ts","webpack://CycloneDX_library/./src/spdx.ts","webpack://CycloneDX_library/./src/spec/_protocol.ts","webpack://CycloneDX_library/./src/spec/consts.ts","webpack://CycloneDX_library/./src/spec/enums.ts","webpack://CycloneDX_library/./src/spec/errors.ts","webpack://CycloneDX_library/./src/spec/index.ts","webpack://CycloneDX_library/./src/types/cpe.ts","webpack://CycloneDX_library/./src/types/cwe.ts","webpack://CycloneDX_library/./src/types/index.ts","webpack://CycloneDX_library/./src/types/integer.ts","webpack://CycloneDX_library/./src/types/mimeType.ts","webpack://CycloneDX_library/./src/utils/bomUtility.ts","webpack://CycloneDX_library/./src/utils/index.ts","webpack://CycloneDX_library/./src/validation/errors.ts","webpack://CycloneDX_library/./src/validation/index.common.ts","webpack://CycloneDX_library/./src/validation/index.web.ts","webpack://CycloneDX_library/./src/validation/types.ts","webpack://CycloneDX_library/external commonjs \"packageurl-js\"","webpack://CycloneDX_library/external commonjs \"spdx-expression-parse\"","webpack://CycloneDX_library/webpack/bootstrap","webpack://CycloneDX_library/webpack/before-startup","webpack://CycloneDX_library/webpack/startup","webpack://CycloneDX_library/webpack/after-startup"],"sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"CycloneDX_library\"] = factory();\n\telse\n\t\troot[\"CycloneDX_library\"] = factory();\n})(self, () => {\nreturn ","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport type NotUndefined<T> = T extends undefined ? never : T\n\nexport function isNotUndefined<T> (value: T | undefined): value is NotUndefined<T> {\n return value !== undefined\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * Known PURL qualifier names.\n * To be used until {@link https://github.com/package-url/packageurl-js/pull/34 | PackageURL PR#34} gets merged and released,\n * and {@link https://github.com/package-url/packageurl-js/issues/35 | PackageURL Issue#35} gets sorted out.\n *\n * For the list/spec of the well-known keys,\n * see {@link https://github.com/package-url/purl-spec/blob/master/PURL-SPECIFICATION.rst#known-qualifiers-keyvalue-pairs | known qualifiers key/value-pairs}\n */\nexport const enum PackageUrlQualifierNames {\n DownloadURL = 'download_url',\n VcsUrl = 'vcs_url',\n Checksum = 'checksum',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Stringable } from './stringable'\n\nexport interface Sortable<TItem> {\n sorted: () => TItem[]\n}\n\nexport interface Comparable<TOther> {\n /**\n * Compare one object with another.\n *\n * The purpose of this method is not to test for equality, but have deterministic comparability.\n * As long as this method is deterministic, there is no need for a proper ordering in any result/downstream.\n */\n compare: (other: TOther) => number\n}\n\nexport const compareObjectsSymbol = Symbol('internal compare function')\n\nexport type SortableIterable<TItem> = Iterable<TItem> & Sortable<TItem>\n\nexport abstract class SortableSet<TItem> extends Set<TItem> implements SortableIterable<TItem>, Comparable<Sortable<TItem>> {\n /**\n * Comparator function to apply to two items.\n */\n protected abstract [compareObjectsSymbol] (a: TItem, b: TItem): number\n\n /**\n * Get a sorted array of all items in the collection..\n */\n sorted (): TItem[] {\n return Array.from(this).sort(this[compareObjectsSymbol])\n }\n\n /**\n * Comparator function to apply to two objects of the collection..\n */\n compare (other: Sortable<TItem>): number {\n const sortedOther = other.sorted()\n const sortedSelf = this.sorted()\n\n if (sortedSelf.length !== sortedOther.length) {\n return sortedSelf.length - sortedOther.length\n }\n\n // it was asserted, that both lists have equal length -> zip-like compare\n for (let i = sortedSelf.length - 1; i >= 0; --i) {\n const iCompared = this[compareObjectsSymbol](sortedSelf[i], sortedOther[i])\n if (iCompared !== 0) {\n return iCompared\n }\n }\n\n return 0\n }\n}\n\nexport class SortableComparables<TItem extends Comparable<any>> extends SortableSet<TItem> {\n protected [compareObjectsSymbol] (a: TItem, b: TItem): number {\n if (a.constructor === b.constructor) {\n return a.compare(b)\n }\n return a.constructor.name.localeCompare(b.constructor.name)\n }\n}\n\nexport class SortableStringables<TItem extends Stringable = Stringable> extends SortableSet<TItem> {\n protected [compareObjectsSymbol] (a: TItem, b: TItem): number {\n return a.toString().localeCompare(b.toString())\n }\n}\n\nexport class SortableNumbers<TItem extends number = number> extends SortableSet<TItem> {\n protected [compareObjectsSymbol] (a: TItem, b: TItem): number {\n return a - b\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport const treeIteratorSymbol = Symbol('iterator of a tree/nesting-like structure')\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nconst escapeMap: Readonly<Record<string, string>> = Object.freeze({\n ' ': '%20',\n '[': '%5B',\n ']': '%5D',\n '<': '%3C',\n '>': '%3E',\n '{': '%7B',\n '}': '%7D'\n})\n\n/**\n * Make a string valid to\n * - XML::anyURI spec.\n * - JSON::iri-reference spec.\n *\n * BEST EFFORT IMPLEMENTATION\n *\n * @see http://www.w3.org/TR/xmlschema-2/#anyURI\n * @see http://www.datypic.com/sc/xsd/t-xsd_anyURI.html\n * @see https://datatracker.ietf.org/doc/html/rfc2396\n * @see https://datatracker.ietf.org/doc/html/rfc3987\n */\nexport function escapeUri<T extends (string | undefined)> (value: T): T {\n if (value === undefined) {\n return value\n }\n for (const [s, r] of Object.entries(escapeMap)) {\n /* @ts-expect-error -- TS does not properly detect that value is to be forced as string, here */\n value = value.replace(s, r)\n }\n return value\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum AttachmentEncoding {\n Base64 = 'base64',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum ComponentScope {\n Required = 'required',\n Optional = 'optional',\n Excluded = 'excluded',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum ComponentType {\n Application = 'application',\n Framework = 'framework',\n Library = 'library',\n Container = 'container',\n Platform = 'platform',\n OperatingSystem = 'operating-system',\n Device = 'device',\n DeviceDriver = 'device-driver',\n Firmware = 'firmware',\n File = 'file',\n MachineLearningModel = 'machine-learning-model',\n Data = 'data',\n CryptographicAsset = 'cryptographic-asset',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum ExternalReferenceType {\n VCS = 'vcs',\n IssueTracker = 'issue-tracker',\n Website = 'website',\n Advisories = 'advisories',\n BOM = 'bom',\n MailingList = 'mailing-list',\n Social = 'social',\n Chat = 'chat',\n Documentation = 'documentation',\n Support = 'support',\n SourceDistribution = 'source-distribution',\n Distribution = 'distribution',\n DistributionIntake = 'distribution-intake',\n License = 'license',\n BuildMeta = 'build-meta',\n BuildSystem = 'build-system',\n ReleaseNotes = 'release-notes',\n SecurityContact = 'security-contact',\n ModelCard = 'model-card',\n Log = 'log',\n Configuration = 'configuration',\n Evidence = 'evidence',\n Formulation = 'formulation',\n Attestation = 'attestation',\n ThreatModel = 'threat-model',\n AdversaryModel = 'adversary-model',\n RiskAssessment = 'risk-assessment',\n VulnerabilityAssertion = 'vulnerability-assertion',\n ExploitabilityStatement = 'exploitability-statement',\n PentestReport = 'pentest-report',\n StaticAnalysisReport = 'static-analysis-report',\n DynamicAnalysisReport = 'dynamic-analysis-report',\n RuntimeAnalysisReport = 'runtime-analysis-report',\n ComponentAnalysisReport = 'component-analysis-report',\n MaturityReport = 'maturity-report',\n CertificationReport = 'certification-report',\n CodifiedInfrastructure = 'codified-infrastructure',\n QualityMetrics = 'quality-metrics',\n POAM = 'poam',\n ElectronicSignature = 'electronic-signature',\n DigitalSignature = 'digital-signature',\n RFC9116 = 'rfc-9116',\n\n // --\n\n Other = 'other',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum HashAlgorithm {\n MD5 = 'MD5',\n 'SHA-1' = 'SHA-1',\n 'SHA-256' = 'SHA-256',\n 'SHA-384' = 'SHA-384',\n 'SHA-512' = 'SHA-512',\n 'SHA3-256' = 'SHA3-256',\n 'SHA3-384' = 'SHA3-384',\n 'SHA3-512' = 'SHA3-512',\n 'BLAKE2b-256' = 'BLAKE2b-256',\n 'BLAKE2b-384' = 'BLAKE2b-384',\n 'BLAKE2b-512' = 'BLAKE2b-512',\n BLAKE3 = 'BLAKE3',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './attachmentEncoding'\nexport * from './componentScope'\nexport * from './componentType'\nexport * from './externalReferenceType'\nexport * from './hashAlogorithm'\nexport * from './licenseAcknowledgement'\nexport * from './lifecyclePhase'\nexport * as Vulnerability from './vulnerability'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum LicenseAcknowledgement {\n Declared = 'declared',\n Concluded = 'concluded',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum LifecyclePhase {\n Design = 'design',\n PreBuild = 'pre-build',\n Build = 'build',\n PostBuild = 'post-build',\n Operations = 'operations',\n Discovery = 'discovery',\n Decommission = 'decommission',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum AffectStatus {\n Affected = 'affected',\n Unaffected = 'unaffected',\n Unknown = 'unknown',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum AnalysisJustification {\n CodeNotPresent = 'code_not_present',\n CodeNotReachable = 'code_not_reachable',\n RequiresConfiguration = 'requires_configuration',\n RequiresDependency = 'requires_dependency',\n RequiresEnvironment = 'requires_environment',\n ProtectedByCompiler = 'protected_by_compiler',\n ProtectedAtRuntime = 'protected_at_runtime',\n ProtectedAtPerimeter = 'protected_at_perimeter',\n ProtectedByMitigatingControl = 'protected_by_mitigating_control',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { SortableStringables } from '../../_helpers/sortable'\n\nexport enum AnalysisResponse {\n CanNotFix = 'can_not_fix',\n WillNotFix = 'will_not_fix',\n Update = 'update',\n Rollback = 'rollback',\n WorkaroundAvailable = 'workaround_available',\n}\n\nexport class AnalysisResponseRepository extends SortableStringables<AnalysisResponse> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum AnalysisState {\n Resolved = 'resolved',\n ResolvedWithPedigree = 'resolved_with_pedigree',\n Exploitable = 'exploitable',\n InTriage = 'in_triage',\n FalsePositive = 'false_positive',\n NotAffected = 'not_affected',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './affectStatus'\nexport * from './analysisJustification'\nexport * from './analysisResponse'\nexport * from './analysisState'\nexport * from './ratingMethod'\nexport * from './severity'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * Specifies the severity or risk scoring methodology or standard used.\n */\nexport enum RatingMethod {\n /** CVSSv2 - [Common Vulnerability Scoring System v2](https://www.first.org/cvss/v2/) */\n CVSSv2 = 'CVSSv2',\n /** CVSSv3 - [Common Vulnerability Scoring System v3](https://www.first.org/cvss/v3-0/) */\n CVSSv3 = 'CVSSv3',\n /** CVSSv31 - [Common Vulnerability Scoring System v3.1](https://www.first.org/cvss/v3-1/) */\n CVSSv31 = 'CVSSv31',\n /** CVSSv4 - [Common Vulnerability Scoring System v4](https://www.first.org/cvss/v4-0/) */\n CVSSv4 = 'CVSSv4',\n /** OWASP - [OWASP Risk Rating Methodology](https://owasp.org/www-community/OWASP_Risk_Rating_Methodology) */\n OWASP = 'OWASP',\n /** SSVC - [Stakeholder Specific Vulnerability Categorization](https://github.com/CERTCC/SSVC) (all versions) */\n SSVC = 'SSVC',\n\n // --\n\n /** any other */\n Other = 'other',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * Textual representation of the severity of the vulnerability adopted by the analysis method.\n * If the analysis method uses values other than what is provided, the user is expected to translate appropriately.\n */\nexport enum Severity {\n Critical = 'critical',\n High = 'high',\n Medium = 'medium',\n Low = 'low',\n Info = 'info',\n None = 'none',\n Unknown = 'unknown',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n// not everything is public, yet\n\nexport * from './license'\nexport * from './packageUrl'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './index.common'\n\n// region web-specifics\n\n// ... nothing yet\n\n// endregion web-specifics\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { DisjunctiveLicense, License } from '../models/license'\nimport { LicenseExpression, NamedLicense, SpdxLicense } from '../models/license'\nimport { fixupSpdxId, isValidSpdxLicenseExpression } from '../spdx'\n\nexport class LicenseFactory {\n makeFromString (value: string): License {\n try {\n return this.makeSpdxLicense(value)\n } catch {\n /* pass */\n }\n\n try {\n return this.makeExpression(value)\n } catch {\n /* pass */\n }\n\n return this.makeNamedLicense(value)\n }\n\n /**\n * @throws {@link RangeError} if expression is not eligible\n */\n makeExpression (value: string | any): LicenseExpression {\n const expression = String(value)\n if (isValidSpdxLicenseExpression(expression)) {\n return new LicenseExpression(expression)\n }\n throw new RangeError('Invalid SPDX license expression')\n }\n\n makeDisjunctive (value: string): DisjunctiveLicense {\n try {\n return this.makeSpdxLicense(value)\n } catch {\n return this.makeNamedLicense(value)\n }\n }\n\n /**\n * @throws {@link RangeError} if value is not supported SPDX id\n */\n makeSpdxLicense (value: string | any): SpdxLicense {\n const fixed = fixupSpdxId(String(value))\n if (undefined === fixed) {\n throw new RangeError('Unsupported SPDX license ID')\n }\n\n return new SpdxLicense(fixed)\n }\n\n makeNamedLicense (value: string | any): NamedLicense {\n return new NamedLicense(String(value))\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { PackageURL } from 'packageurl-js'\n\nimport { PackageUrlQualifierNames } from '../_helpers/packageUrl'\nimport { ExternalReferenceType } from '../enums/externalReferenceType'\nimport type { Component } from '../models/component'\n\nexport class PackageUrlFactory {\n readonly #type: PackageURL['type']\n\n constructor (type: PackageUrlFactory['type']) {\n this.#type = type\n }\n\n get type (): PackageURL['type'] {\n return this.#type\n }\n\n makeFromComponent (component: Component, sort: boolean = false): PackageURL | undefined {\n const qualifiers: PackageURL['qualifiers'] = {}\n let subpath: PackageURL['subpath']\n\n // sorting to allow reproducibility: use the last instance for a `extRef.type`, if multiples exist\n const extRefs = sort\n ? component.externalReferences.sorted()\n : component.externalReferences\n for (const extRef of extRefs) {\n const url = extRef.url.toString()\n if (url.length <= 0) {\n continue\n }\n // No further need for validation.\n // According to https://github.com/package-url/purl-spec/blob/master/PURL-TYPES.rst\n // there is no formal requirement to a `..._url`.\n // Everything is possible: URL-encoded, not encoded, with schema, without schema\n switch (extRef.type) {\n case ExternalReferenceType.VCS:\n [qualifiers[PackageUrlQualifierNames.VcsUrl], subpath] = url.split('#', 2)\n break\n case ExternalReferenceType.Distribution:\n qualifiers[PackageUrlQualifierNames.DownloadURL] = url\n break\n }\n }\n\n const hashes = component.hashes\n if (hashes.size > 0) {\n qualifiers[PackageUrlQualifierNames.Checksum] = Array.from(\n sort\n ? hashes.sorted()\n : hashes,\n ([hashAlgo, hashCont]) => `${hashAlgo.toLowerCase()}:${hashCont.toLowerCase()}`\n ).join(',')\n }\n\n try {\n // Do not beautify the parameters here, because that is in the domain of PackageURL and its representation.\n // No need to convert an empty \"subpath\" string to `undefined` and such.\n return new PackageURL(\n this.#type,\n component.group,\n component.name,\n component.version,\n qualifiers,\n subpath\n )\n } catch {\n return undefined\n }\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * as Enums from './enums'\nexport * as Models from './models'\nexport * as SPDX from './spdx'\nexport * as Spec from './spec'\nexport * as Types from './types'\nexport * as Utils from './utils'\n// do not export the _helpers, they are for internal use only\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './index.common'\n\n// region web-specifics\n\nexport * as Factories from './factories/index.web'\nexport * as Serialize from './serialize/index.web'\nexport * as Validation from './validation/index.web'\n\n// endregion web-specifics\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Stringable } from '../_helpers/stringable'\nimport type { AttachmentEncoding } from '../enums/attachmentEncoding'\n\nexport interface OptionalAttachmentProperties {\n contentType?: Attachment['contentType']\n encoding?: Attachment['encoding']\n}\n\nexport class Attachment {\n contentType?: string\n content: Stringable\n encoding?: AttachmentEncoding\n\n constructor (content: Attachment['content'], op: OptionalAttachmentProperties = {}) {\n this.contentType = op.contentType\n this.content = content\n this.encoding = op.encoding\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { PositiveInteger } from '../types/integer'\nimport { isPositiveInteger } from '../types/integer'\nimport { ComponentRepository } from './component'\nimport { Metadata } from './metadata'\nimport { VulnerabilityRepository } from './vulnerability/vulnerability'\n\nexport interface OptionalBomProperties {\n metadata?: Bom['metadata']\n components?: Bom['components']\n version?: Bom['version']\n vulnerabilities?: Bom['vulnerabilities']\n serialNumber?: Bom['serialNumber']\n}\n\nexport class Bom {\n metadata: Metadata\n components: ComponentRepository\n vulnerabilities: VulnerabilityRepository\n\n /** @see {@link version} */\n #version: PositiveInteger = 1\n\n /** @see {@link serialNumber} */\n #serialNumber?: string\n\n // Property `bomFormat` is not part of model, it is runtime information.\n // Property `specVersion` is not part of model, it is runtime information.\n\n // Property `dependencies` is not part of this model, but part of `Component` and other models.\n // The dependency graph can be normalized on render-time, no need to store it in the bom model.\n\n /**\n * @throws {@link TypeError} if `op.version` is neither {@link PositiveInteger} nor `undefined`\n */\n constructor (op: OptionalBomProperties = {}) {\n this.metadata = op.metadata ?? new Metadata()\n this.components = op.components ?? new ComponentRepository()\n this.version = op.version ?? this.version\n this.vulnerabilities = op.vulnerabilities ?? new VulnerabilityRepository()\n this.serialNumber = op.serialNumber\n }\n\n get version (): PositiveInteger {\n return this.#version\n }\n\n /**\n * @throws {@link TypeError} if value is not {@link PositiveInteger}\n */\n set version (value: PositiveInteger) {\n if (!isPositiveInteger(value)) {\n throw new TypeError('Not PositiveInteger')\n }\n this.#version = value\n }\n\n get serialNumber (): string | undefined {\n return this.#serialNumber\n }\n\n set serialNumber (value: string | undefined) {\n this.#serialNumber = value === ''\n ? undefined\n : value\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../_helpers/sortable'\nimport type { Stringable } from '../_helpers/stringable'\n\nabstract class BomLinkBase implements Stringable, Comparable<Stringable> {\n /* @ts-expect-error TS2564 */\n #value: string\n\n /** @internal */\n protected abstract _isValid (value: any): boolean\n\n /**\n * @throws {@link RangeError} if value is invalid\n */\n constructor (value: string) {\n this.value = value\n }\n\n /**\n * @throws {@link RangeError} if value is invalid\n */\n set value (value: string) {\n if (!this._isValid(value)) {\n throw new RangeError('invalid value')\n }\n this.#value = value\n }\n\n get value (): string {\n return this.#value\n }\n\n compare (other: Stringable): number {\n return this.toString().localeCompare(other.toString())\n }\n\n toString (): string {\n return this.value\n }\n}\n\n/**\n * Descriptor for another BOM document.\n *\n * See [the docs](https://cyclonedx.org/capabilities/bomlink/)\n */\nexport class BomLinkDocument extends BomLinkBase {\n /* regular expressions were taken from the CycloneDX schema definitions. */\n static readonly #pattern = /^urn:cdx:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\\/[1-9][0-9]*$/\n\n /**\n * Whether the `value` is a valid descriptor for another BOM document.\n */\n static isValid (value: any): boolean {\n return typeof value === 'string' &&\n this.#pattern.test(value)\n }\n\n /** @internal */\n protected _isValid (value: any): boolean {\n return BomLinkDocument.isValid(value)\n }\n}\n\n/**\n * Descriptor for an element in a BOM document.\n *\n * See [the docs](https://cyclonedx.org/capabilities/bomlink/)\n */\nexport class BomLinkElement extends BomLinkBase {\n /* regular expressions were taken from the CycloneDX schema definitions. */\n static readonly #pattern = /^urn:cdx:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\\/[1-9][0-9]*#.+$/\n\n /**\n * Whether the `value` is a valid descriptor for an element in a BOM document.\n */\n static isValid (value: any): boolean {\n return typeof value === 'string' &&\n this.#pattern.test(value)\n }\n\n /** @internal */\n protected _isValid (value: any): boolean {\n return BomLinkElement.isValid(value)\n }\n}\n\n/**\n * Either {@link BomLinkDocument} or {@link BomLinkElement}.\n *\n * See [the docs](https://cyclonedx.org/capabilities/bomlink/)\n */\nexport type BomLink = BomLinkDocument | BomLinkElement\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../_helpers/sortable'\nimport type { Stringable } from '../_helpers/stringable'\n\n/**\n * Proxy for the BomRef.\n * This way a `BomRef` gets unique by the in-memory-address of the object.\n */\nexport class BomRef implements Stringable, Comparable<Stringable> {\n value?: string\n\n constructor (value?: BomRef['value']) {\n this.value = value\n }\n\n compare (other: Stringable): number {\n return this.toString().localeCompare(other.toString())\n }\n\n toString (): string {\n return this.value ?? ''\n }\n}\n\nexport class BomRefRepository extends Set<BomRef> {\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { PackageURL } from 'packageurl-js'\n\nimport type { Comparable } from '../_helpers/sortable'\nimport { SortableComparables, SortableStringables } from '../_helpers/sortable'\nimport type { Stringable } from '../_helpers/stringable'\nimport { treeIteratorSymbol } from '../_helpers/tree'\nimport type { ComponentScope, ComponentType } from '../enums'\nimport type { CPE } from '../types/cpe'\nimport { isCPE } from '../types/cpe'\nimport { BomRef, BomRefRepository } from './bomRef'\nimport { ExternalReferenceRepository } from './externalReference'\nimport { HashDictionary } from './hash'\nimport { LicenseRepository } from './license'\nimport type { OrganizationalEntity } from './organizationalEntity'\nimport { PropertyRepository } from './property'\nimport type { SWID } from './swid'\n\nexport interface OptionalComponentProperties {\n bomRef?: BomRef['value']\n author?: Component['author']\n copyright?: Component['copyright']\n description?: Component['description']\n externalReferences?: Component['externalReferences']\n group?: Component['group']\n hashes?: Component['hashes']\n licenses?: Component['licenses']\n publisher?: Component['publisher']\n purl?: Component['purl']\n scope?: Component['scope']\n supplier?: Component['supplier']\n swid?: Component['swid']\n version?: Component['version']\n dependencies?: Component['dependencies']\n components?: Component['components']\n cpe?: Component['cpe']\n properties?: Component['properties']\n evidence?: Component['evidence']\n}\n\nexport class Component implements Comparable<Component> {\n type: ComponentType\n name: string\n author?: string\n copyright?: Stringable\n description?: string\n externalReferences: ExternalReferenceRepository\n group?: string\n hashes: HashDictionary\n licenses: LicenseRepository\n publisher?: string\n purl?: PackageURL\n scope?: ComponentScope\n supplier?: OrganizationalEntity\n swid?: SWID\n version?: string\n dependencies: BomRefRepository\n components: ComponentRepository\n properties: PropertyRepository\n evidence?: ComponentEvidence\n\n /** @see {@link bomRef} */\n readonly #bomRef: BomRef\n\n /** @see {@link cpe} */\n #cpe?: CPE\n\n /**\n * @throws {@link TypeError} if `op.cpe` is neither {@link CPE} nor `undefined`\n */\n constructor (type: Component['type'], name: Component['name'], op: OptionalComponentProperties = {}) {\n this.#bomRef = new BomRef(op.bomRef)\n this.type = type\n this.name = name\n this.supplier = op.supplier\n this.author = op.author\n this.copyright = op.copyright\n this.externalReferences = op.externalReferences ?? new ExternalReferenceRepository()\n this.group = op.group\n this.hashes = op.hashes ?? new HashDictionary()\n this.licenses = op.licenses ?? new LicenseRepository()\n this.publisher = op.publisher\n this.purl = op.purl\n this.scope = op.scope\n this.swid = op.swid\n this.version = op.version\n this.description = op.description\n this.dependencies = op.dependencies ?? new BomRefRepository()\n this.components = op.components ?? new ComponentRepository()\n this.cpe = op.cpe\n this.properties = op.properties ?? new PropertyRepository()\n this.evidence = op.evidence\n }\n\n get bomRef (): BomRef {\n return this.#bomRef\n }\n\n get cpe (): CPE | undefined {\n return this.#cpe\n }\n\n /**\n * @throws {@link TypeError} if value is neither {@link CPE} nor `undefined`\n */\n set cpe (value: CPE | undefined) {\n if (value !== undefined && !isCPE(value)) {\n throw new TypeError('Not CPE nor undefined')\n }\n this.#cpe = value\n }\n\n compare (other: Component): number {\n // The purpose of this method is not to test for equality, but have deterministic comparability.\n const bomRefCompare = this.bomRef.compare(other.bomRef)\n if (bomRefCompare !== 0) {\n return bomRefCompare\n }\n if (this.purl !== undefined && other.purl !== undefined) {\n return this.purl.toString().localeCompare(other.purl.toString())\n }\n if (this.#cpe !== undefined && other.#cpe !== undefined) {\n return this.#cpe.localeCompare(other.#cpe)\n }\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.group ?? '').localeCompare(other.group ?? '') ||\n this.name.localeCompare(other.name) ||\n (this.version ?? '').localeCompare(other.version ?? '')\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class ComponentRepository extends SortableComparables<Component> {\n * [treeIteratorSymbol] (): Generator<Component> {\n for (const component of this) {\n yield component\n yield * component.components[treeIteratorSymbol]()\n }\n }\n}\n\nexport interface OptionalComponentEvidenceProperties {\n licenses?: ComponentEvidence['licenses']\n copyright?: ComponentEvidence['copyright']\n}\n\nexport class ComponentEvidence {\n licenses: LicenseRepository\n copyright: SortableStringables\n\n constructor (op: OptionalComponentEvidenceProperties = {}) {\n this.licenses = op.licenses ?? new LicenseRepository()\n this.copyright = op.copyright ?? new SortableStringables()\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../_helpers/sortable'\nimport { SortableComparables } from '../_helpers/sortable'\nimport type { ExternalReferenceType } from '../enums/externalReferenceType'\nimport type { BomLink } from './bomLink'\nimport { HashDictionary } from './hash'\n\nexport interface OptionalExternalReferenceProperties {\n hashes?: ExternalReference['hashes']\n comment?: ExternalReference['comment']\n}\n\nexport class ExternalReference implements Comparable<ExternalReference> {\n url: URL | BomLink | string\n type: ExternalReferenceType\n hashes: HashDictionary\n comment?: string\n\n constructor (url: ExternalReference['url'], type: ExternalReference['type'], op: OptionalExternalReferenceProperties = {}) {\n this.url = url\n this.type = type\n this.hashes = op.hashes ?? new HashDictionary()\n this.comment = op.comment\n }\n\n compare (other: ExternalReference): number {\n // The purpose of this method is not to test for equality, but have deterministic comparability.\n /* eslint-disable-next-line @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return this.type.localeCompare(other.type) ||\n this.url.toString().localeCompare(other.url.toString())\n }\n}\n\nexport class ExternalReferenceRepository extends SortableComparables<ExternalReference> {\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Sortable } from '../_helpers/sortable'\nimport type { HashAlgorithm } from '../enums/hashAlogorithm'\n\n// no regex for the HashContent in here. It applies at runtime of a normalization/serialization process.\nexport type HashContent = string\n\nexport type Hash = readonly [\n // order matters: it must reflect [key, value] of HashDictionary -\n // this way a HashDictionary can be constructed from multiple Hash objects.\n /* algorithm: */ HashAlgorithm,\n /* content: */ HashContent,\n // cannot use named tuple syntax ala `[a: T1, b: T2]` as it causes errors when downstream-projects compile with older versions of TypeScript\n]\n\nexport class HashDictionary extends Map<Hash[0], Hash[1]> implements Sortable<Hash> {\n static #compareItems ([a1, c1]: Hash, [a2, c2]: Hash): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return a1.localeCompare(a2) ||\n c1.localeCompare(c2)\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n\n sorted (): Hash[] {\n return Array.from(this.entries()).sort(HashDictionary.#compareItems)\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './attachment'\nexport * from './bom'\nexport * from './bomLink'\nexport * from './bomRef'\nexport * from './component'\nexport * from './externalReference'\nexport * from './hash'\nexport * from './license'\nexport * from './lifecycle'\nexport * from './metadata'\nexport * from './organizationalContact'\nexport * from './organizationalEntity'\nexport * from './property'\nexport * from './swid'\nexport * from './tool'\nexport * as Vulnerability from './vulnerability'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Sortable } from '../_helpers/sortable'\nimport type { LicenseAcknowledgement } from '../enums/licenseAcknowledgement'\nimport type { SpdxId } from '../spdx'\nimport type { Attachment } from './attachment'\n\n/**\n * (SPDX) License Expression.\n *\n * No validation is done internally.\n * You may validate with {@link SPDX.isValidSpdxLicenseExpression | SPDX.isValidSpdxLicenseExpression()}.\n * You may assert valid objects with {@link Factories.LicenseFactory.makeExpression | Factories.LicenseFactory.makeExpression()}.\n */\nexport class LicenseExpression {\n /** @see {@link expression} */\n #expression!: string\n acknowledgement?: LicenseAcknowledgement\n\n /**\n * @throws {@link RangeError} if `expression` is empty string\n */\n constructor (expression: LicenseExpression['expression']) {\n this.expression = expression\n }\n\n get expression (): string {\n return this.#expression\n }\n\n /**\n * @throws {@link RangeError} if `value` is empty string\n */\n set expression (value: string) {\n if (value === '') {\n throw new RangeError('value is empty string')\n }\n this.#expression = value\n }\n\n compare (other: LicenseExpression): number {\n return this.#expression.localeCompare(other.#expression)\n }\n}\n\nclass DisjunctiveLicenseBase {\n acknowledgement?: LicenseAcknowledgement\n text?: Attachment\n #url?: URL | string\n\n constructor (op: OptionalDisjunctiveLicenseProperties = {}) {\n this.acknowledgement = op.acknowledgement\n this.text = op.text\n this.url = op.url\n }\n\n get url (): URL | string | undefined {\n return this.#url\n }\n\n set url (value: URL | string | undefined) {\n this.#url = value === ''\n ? undefined\n : value\n }\n}\n\ninterface OptionalDisjunctiveLicenseProperties {\n acknowledgement?: DisjunctiveLicenseBase['acknowledgement']\n text?: DisjunctiveLicenseBase['text']\n url?: DisjunctiveLicenseBase['url']\n}\n\nexport interface OptionalNamedLicenseProperties extends OptionalDisjunctiveLicenseProperties {}\n\nexport class NamedLicense extends DisjunctiveLicenseBase {\n name: string\n\n constructor (name: string, op: OptionalNamedLicenseProperties = {}) {\n super(op)\n this.name = name\n }\n\n compare (other: NamedLicense): number {\n return this.name.localeCompare(other.name)\n }\n}\n\nexport interface OptionalSpdxLicenseProperties extends OptionalDisjunctiveLicenseProperties {}\n\n/**\n * Disjunctive license with (SPDX-)ID - aka SpdxLicense.\n *\n * No validation is done internally.\n * You may validate with {@link SPDX.isSupportedSpdxId | SPDX.isSupportedSpdxId()}.\n * You may assert valid objects with {@link Factories.LicenseFactory.makeSpdxLicense | Factories.LicenseFactory.makeSpdxLicense()}.\n */\nexport class SpdxLicense extends DisjunctiveLicenseBase {\n /** @see {@link id} */\n #id!: SpdxId\n\n /**\n * @throws {@link RangeError} if `id` is empy string\n */\n constructor (id: SpdxId, op: OptionalSpdxLicenseProperties = {}) {\n super(op)\n this.id = id\n }\n\n get id (): SpdxId {\n return this.#id\n }\n\n /**\n * @throws {@link RangeError} if `value` is empy string\n */\n set id (value: SpdxId) {\n if (value === '') {\n throw new RangeError('value is empty string')\n }\n this.#id = value\n }\n\n compare (other: SpdxLicense): number {\n return this.#id.localeCompare(other.#id)\n }\n}\n\nexport type DisjunctiveLicense = NamedLicense | SpdxLicense\nexport type License = DisjunctiveLicense | LicenseExpression\n\nexport class LicenseRepository extends Set<License> implements Sortable<License> {\n static #compareItems (a: License, b: License): number {\n if (a.constructor === b.constructor) {\n // @ts-expect-error -- classes are from same type -> they are comparable\n return a.compare(b)\n }\n return a.constructor.name.localeCompare(b.constructor.name)\n }\n\n sorted (): License[] {\n return Array.from(this).sort(LicenseRepository.#compareItems)\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable, Sortable } from '../_helpers/sortable'\nimport type { LifecyclePhase } from '../enums/lifecyclePhase'\n\nexport interface OptionalNamedLifecycleProperties {\n description?: NamedLifecycle['description']\n}\n\nexport class NamedLifecycle implements Comparable<NamedLifecycle> {\n name: string\n description?: string\n\n constructor (name: string, op: OptionalNamedLifecycleProperties = {}) {\n this.name = name\n this.description = op.description\n }\n\n compare (other: NamedLifecycle): number {\n return this.name.localeCompare(other.name)\n }\n}\n\nexport type Lifecycle = LifecyclePhase | NamedLifecycle\n\nexport class LifecycleRepository extends Set<Lifecycle> implements Sortable<Lifecycle> {\n static #compareItems (a: Lifecycle, b: Lifecycle): number {\n if (a.constructor === b.constructor) {\n return a instanceof NamedLifecycle\n ? a.compare(b as NamedLifecycle)\n : (a as string).localeCompare(b as string)\n }\n return a.constructor.name.localeCompare(b.constructor.name)\n }\n\n sorted (): Lifecycle[] {\n return Array.from(this).sort(LifecycleRepository.#compareItems)\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Component } from './component'\nimport { LicenseRepository } from './license'\nimport { LifecycleRepository } from './lifecycle'\nimport { OrganizationalContactRepository } from './organizationalContact'\nimport type { OrganizationalEntity } from './organizationalEntity'\nimport { PropertyRepository } from './property'\nimport { ToolRepository } from './tool'\n\nexport interface OptionalMetadataProperties {\n timestamp?: Metadata['timestamp']\n lifecycles?: Metadata['lifecycles']\n tools?: Metadata['tools']\n authors?: Metadata['authors']\n component?: Metadata['component']\n manufacture?: Metadata['manufacture']\n supplier?: Metadata['supplier']\n licenses?: Metadata['licenses']\n properties?: Metadata['properties']\n}\n\nexport class Metadata {\n timestamp?: Date\n lifecycles: LifecycleRepository\n tools: ToolRepository\n authors: OrganizationalContactRepository\n component?: Component\n manufacture?: OrganizationalEntity\n supplier?: OrganizationalEntity\n licenses: LicenseRepository\n properties: PropertyRepository\n\n constructor (op: OptionalMetadataProperties = {}) {\n this.timestamp = op.timestamp\n this.lifecycles = op.lifecycles ?? new LifecycleRepository()\n this.tools = op.tools ?? new ToolRepository()\n this.authors = op.authors ?? new OrganizationalContactRepository()\n this.component = op.component\n this.manufacture = op.manufacture\n this.supplier = op.supplier\n this.licenses = op.licenses ?? new LicenseRepository()\n this.properties = op.properties ?? new PropertyRepository()\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../_helpers/sortable'\nimport { SortableComparables } from '../_helpers/sortable'\n\nexport interface OptionalOrganizationalContactProperties {\n name?: OrganizationalContact['name']\n email?: OrganizationalContact['email']\n phone?: OrganizationalContact['phone']\n}\n\nexport class OrganizationalContact implements Comparable<OrganizationalContact> {\n name?: string\n email?: string\n phone?: string\n\n constructor (op: OptionalOrganizationalContactProperties = {}) {\n this.name = op.name\n this.email = op.email\n this.phone = op.phone\n }\n\n compare (other: OrganizationalContact): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.name ?? '').localeCompare(other.name ?? '') ||\n (this.email ?? '').localeCompare(other.email ?? '') ||\n (this.phone ?? '').localeCompare(other.phone ?? '')\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class OrganizationalContactRepository extends SortableComparables<OrganizationalContact> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../_helpers/sortable'\nimport { SortableComparables, SortableStringables } from '../_helpers/sortable'\nimport { OrganizationalContactRepository } from './organizationalContact'\n\nexport interface OptionalOrganizationalEntityProperties {\n name?: OrganizationalEntity['name']\n url?: OrganizationalEntity['url']\n contact?: OrganizationalEntity['contact']\n}\n\nexport class OrganizationalEntity implements Comparable<OrganizationalEntity> {\n name?: string\n url: Set<URL | string>\n contact: OrganizationalContactRepository\n\n constructor (op: OptionalOrganizationalEntityProperties = {}) {\n this.name = op.name\n this.url = op.url ?? new Set()\n this.contact = op.contact ?? new OrganizationalContactRepository()\n }\n\n compare (other: OrganizationalEntity): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.name ?? '').localeCompare(other.name ?? '') ||\n this.contact.compare(other.contact) ||\n (new SortableStringables(this.url)).compare(new SortableStringables(other.url))\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class OrganizationalEntityRepository extends SortableComparables<OrganizationalEntity> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../_helpers/sortable'\nimport { SortableComparables } from '../_helpers/sortable'\n\n/**\n * @see [CycloneDX Property Taxonomy](https://github.com/CycloneDX/cyclonedx-property-taxonomy)\n */\nexport class Property implements Comparable<Property> {\n name: string\n value: string\n\n constructor (name: Property['name'], value: Property['value']) {\n this.name = name\n this.value = value\n }\n\n compare (other: Property): number {\n /* eslint-disable-next-line @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return this.name.localeCompare(other.name) ||\n this.value.localeCompare(other.value)\n }\n}\n\nexport class PropertyRepository extends SortableComparables<Property> {\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { NonNegativeInteger } from '../types/integer'\nimport { isNonNegativeInteger } from '../types/integer'\nimport type { Attachment } from './attachment'\n\nexport interface OptionalSWIDProperties {\n version?: SWID['version']\n patch?: SWID['patch']\n text?: SWID['text']\n url?: SWID['url']\n tagVersion?: SWID['tagVersion']\n}\n\n/**\n * @see {@link https://csrc.nist.gov/projects/Software-Identification-SWID | SWID spec}\n */\nexport class SWID {\n tagId: string\n name: string\n version?: string\n patch?: boolean\n text?: Attachment\n url?: URL | string\n\n /** @see {@link tagVersion} */\n #tagVersion?: NonNegativeInteger\n\n /**\n * @throws {@link TypeError} if `op.tagVersion` is neither {@link NonNegativeInteger} nor `undefined`\n */\n constructor (tagId: SWID['tagId'], name: SWID['name'], op: OptionalSWIDProperties = {}) {\n this.tagId = tagId\n this.name = name\n this.version = op.version\n this.patch = op.patch\n this.text = op.text\n this.url = op.url\n this.tagVersion = op.tagVersion\n }\n\n get tagVersion (): NonNegativeInteger | undefined {\n return this.#tagVersion\n }\n\n /**\n * @throws {@link TypeError} if value is neither {@link NonNegativeInteger} nor `undefined`\n */\n set tagVersion (value: NonNegativeInteger | undefined) {\n if (value !== undefined && !isNonNegativeInteger(value)) {\n throw new TypeError('Not NonNegativeInteger nor undefined')\n }\n this.#tagVersion = value\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../_helpers/sortable'\nimport { SortableComparables } from '../_helpers/sortable'\nimport { ExternalReferenceRepository } from './externalReference'\nimport { HashDictionary } from './hash'\n\nexport interface OptionalToolProperties {\n vendor?: Tool['vendor']\n name?: Tool['name']\n version?: Tool['version']\n hashes?: Tool['hashes']\n externalReferences?: Tool['externalReferences']\n}\n\nexport class Tool implements Comparable<Tool> {\n vendor?: string\n name?: string\n version?: string\n hashes: HashDictionary\n externalReferences: ExternalReferenceRepository\n\n constructor (op: OptionalToolProperties = {}) {\n this.vendor = op.vendor\n this.name = op.name\n this.version = op.version\n this.hashes = op.hashes ?? new HashDictionary()\n this.externalReferences = op.externalReferences ?? new ExternalReferenceRepository()\n }\n\n compare (other: Tool): number {\n // The purpose of this method is not to test for equality, but have deterministic comparability.\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.vendor ?? '').localeCompare(other.vendor ?? '') ||\n (this.name ?? '').localeCompare(other.name ?? '') ||\n (this.version ?? '').localeCompare(other.version ?? '')\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class ToolRepository extends SortableComparables<Tool> {\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../../_helpers/sortable'\nimport { SortableComparables } from '../../_helpers/sortable'\n\nexport interface OptionalAdvisoryProperties {\n title?: Advisory['title']\n}\n\nexport class Advisory implements Comparable<Advisory> {\n title?: string\n url: string | URL\n\n constructor (url: string | URL, op: OptionalAdvisoryProperties = {}) {\n this.url = url\n this.title = op.title\n }\n\n compare (other: Advisory): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return this.url.toString().localeCompare(other.url.toString()) ||\n (this.title ?? '').localeCompare(other.title ?? '')\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class AdvisoryRepository extends SortableComparables<Advisory> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../../_helpers/sortable'\nimport { SortableComparables } from '../../_helpers/sortable'\nimport type { AffectStatus } from '../../enums/vulnerability'\nimport type { BomLinkElement } from '../bomLink'\nimport type { BomRef } from '../bomRef'\n\nexport interface OptionalAffectProperties {\n versions?: Affect['versions']\n}\n\nexport class Affect implements Comparable<Affect> {\n ref: BomRef | BomLinkElement\n versions: AffectedVersionRepository\n\n constructor (ref: Affect['ref'], op: OptionalAffectProperties = {}) {\n this.ref = ref\n this.versions = op.versions ?? new AffectedVersionRepository()\n }\n\n compare (other: Affect): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return this.ref.compare(other.ref) ||\n this.versions.compare(other.versions)\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class AffectRepository extends SortableComparables<Affect> {\n}\n\nexport interface OptionalAffectedVersionProperties {\n status?: AffectedVersion['status']\n}\n\nexport class AffectedSingleVersion implements Comparable<AffectedSingleVersion> {\n version: string\n status?: AffectStatus\n\n constructor (version: string, op: OptionalAffectedVersionProperties = {}) {\n this.version = version\n this.status = op.status\n }\n\n compare (other: AffectedSingleVersion): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.version).localeCompare(other.version) ||\n (this.status ?? '').localeCompare(other.status ?? '')\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class AffectedVersionRange implements Comparable<AffectedVersionRange> {\n range: string\n status?: AffectStatus\n\n constructor (range: string, op: OptionalAffectedVersionProperties = {}) {\n this.range = range\n this.status = op.status\n }\n\n compare (other: AffectedVersionRange): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.range).localeCompare(other.range) ||\n (this.status ?? '').localeCompare(other.status ?? '')\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport type AffectedVersion = AffectedSingleVersion | AffectedVersionRange\n\nexport class AffectedVersionRepository extends SortableComparables<AffectedVersion> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { AnalysisJustification, AnalysisState } from '../../enums/vulnerability'\nimport { AnalysisResponseRepository } from '../../enums/vulnerability/analysisResponse'\n\nexport interface OptionalAnalysisProperties {\n state?: Analysis['state']\n justification?: Analysis['justification']\n response?: Analysis['response']\n detail?: Analysis['detail']\n}\n\nexport class Analysis {\n state?: AnalysisState\n justification?: AnalysisJustification\n response: AnalysisResponseRepository\n detail?: string\n\n constructor (op: OptionalAnalysisProperties = {}) {\n this.state = op.state\n this.justification = op.justification\n this.response = op.response ?? new AnalysisResponseRepository()\n this.detail = op.detail\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { OrganizationalContactRepository } from '../organizationalContact'\nimport { OrganizationalEntityRepository } from '../organizationalEntity'\n\nexport interface OptionalCreditsProperties {\n organizations?: Credits['organizations']\n individuals?: Credits['individuals']\n}\n\nexport class Credits {\n organizations: OrganizationalEntityRepository\n individuals: OrganizationalContactRepository\n\n constructor (op: OptionalCreditsProperties = {}) {\n this.organizations = op.organizations ?? new OrganizationalEntityRepository()\n this.individuals = op.individuals ?? new OrganizationalContactRepository()\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './advisory'\nexport * from './affect'\nexport * from './analysis'\nexport * from './credits'\nexport * from './rating'\nexport * from './reference'\nexport * from './source'\nexport * from './vulnerability'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../../_helpers/sortable'\nimport { SortableComparables } from '../../_helpers/sortable'\nimport type { RatingMethod, Severity } from '../../enums/vulnerability'\nimport type { Source } from './source'\n\nexport interface OptionalRatingProperties {\n source?: Rating['source']\n score?: Rating['score']\n severity?: Rating['severity']\n method?: Rating['method']\n vector?: Rating['vector']\n justification?: Rating['justification']\n}\n\nexport class Rating implements Comparable<Rating> {\n source?: Source\n score?: number\n severity?: Severity\n method?: RatingMethod\n vector?: string\n justification?: string\n\n constructor (op: OptionalRatingProperties = {}) {\n this.source = op.source\n this.score = op.score\n this.severity = op.severity\n this.method = op.method\n this.vector = op.vector\n this.justification = op.justification\n }\n\n compare (other: Rating): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return ((this.score ?? 0) - (other.score ?? 0)) ||\n (this.vector ?? '').localeCompare(other.vector ?? '') ||\n (this.justification ?? '').localeCompare(other.justification ?? '') ||\n (this.severity ?? '').localeCompare(other.severity ?? '') ||\n (this.method ?? '').localeCompare(other.method ?? '') ||\n (this.source && other.source ? this.source.compare(other.source) : 0)\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class RatingRepository extends SortableComparables<Rating> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../../_helpers/sortable'\nimport { SortableComparables } from '../../_helpers/sortable'\nimport type { Source } from './source'\n\n/**\n * @privateRemarks\n * The model is built based on the JSON spec, which has all properties mandatory.\n * In contrast to the XML spec, which has them optional.\n * see https://github.com/CycloneDX/specification/issues/154\n */\nexport class Reference implements Comparable<Reference> {\n /**\n * @example values\n * - `CVE-2021-39182`\n * - `GHSA-35m5-8cvj-8783`\n * - `SNYK-PYTHON-ENROCRYPT-1912876`\n */\n id: string\n source: Source\n\n constructor (id: string, source: Source) {\n this.id = id\n this.source = source\n }\n\n compare (other: Reference): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return this.id.localeCompare(other.id) ||\n this.source.compare(other.source)\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class ReferenceRepository extends SortableComparables<Reference> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../../_helpers/sortable'\n\nexport interface OptionalSourceProperties {\n name?: Source['name']\n url?: Source['url']\n}\n\nexport class Source implements Comparable<Source> {\n name?: string\n url?: URL | string\n\n constructor (op: OptionalSourceProperties = {}) {\n this.name = op.name\n this.url = op.url\n }\n\n compare (other: Source): number {\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.url?.toString() ?? '').localeCompare(other.url?.toString() ?? '') ||\n (this.name ?? '').localeCompare(other.name ?? '')\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Comparable } from '../../_helpers/sortable'\nimport { SortableComparables } from '../../_helpers/sortable'\nimport { CweRepository } from '../../types/cwe'\nimport { BomRef } from '../bomRef'\nimport { PropertyRepository } from '../property'\nimport { ToolRepository } from '../tool'\nimport { AdvisoryRepository } from './advisory'\nimport { AffectRepository } from './affect'\nimport type { Analysis } from './analysis'\nimport type { Credits } from './credits'\nimport { RatingRepository } from './rating'\nimport { ReferenceRepository } from './reference'\nimport type { Source } from './source'\n\nexport interface OptionalVulnerabilityProperties {\n bomRef?: BomRef['value']\n id?: Vulnerability['id']\n source?: Vulnerability['source']\n references?: Vulnerability['references']\n ratings?: Vulnerability['ratings']\n cwes?: Vulnerability['cwes']\n description?: Vulnerability['description']\n detail?: Vulnerability['detail']\n recommendation?: Vulnerability['recommendation']\n advisories?: Vulnerability['advisories']\n created?: Vulnerability['created']\n published?: Vulnerability['published']\n updated?: Vulnerability['updated']\n credits?: Vulnerability['credits']\n tools?: Vulnerability['tools']\n analysis?: Vulnerability['analysis']\n affects?: Vulnerability['affects']\n properties?: Vulnerability['properties']\n}\n\nexport class Vulnerability implements Comparable<Vulnerability> {\n /** @see bomRef */\n readonly #bomRef: BomRef\n id?: string\n source?: Source\n references: ReferenceRepository\n ratings: RatingRepository\n cwes: CweRepository\n description?: string\n detail?: string\n recommendation?: string\n advisories: AdvisoryRepository\n created?: Date\n published?: Date\n updated?: Date\n credits?: Credits\n tools: ToolRepository\n analysis?: Analysis\n affects: AffectRepository\n properties: PropertyRepository\n\n constructor (op: OptionalVulnerabilityProperties = {}) {\n this.#bomRef = new BomRef(op.bomRef)\n this.id = op.id\n this.source = op.source\n this.references = op.references ?? new ReferenceRepository()\n this.ratings = op.ratings ?? new RatingRepository()\n this.cwes = op.cwes ?? new CweRepository()\n this.description = op.description\n this.detail = op.detail\n this.recommendation = op.recommendation\n this.advisories = op.advisories ?? new AdvisoryRepository()\n this.created = op.created\n this.published = op.published\n this.updated = op.updated\n this.credits = op.credits\n this.tools = op.tools ?? new ToolRepository()\n this.analysis = op.analysis\n this.affects = op.affects ?? new AffectRepository()\n this.properties = op.properties ?? new PropertyRepository()\n }\n\n get bomRef (): BomRef {\n return this.#bomRef\n }\n\n compare (other: Vulnerability): number {\n const bomRefCompare = this.bomRef.compare(other.bomRef)\n if (bomRefCompare !== 0) {\n return bomRefCompare\n }\n\n /* eslint-disable @typescript-eslint/strict-boolean-expressions -- run compares in weighted order */\n return (this.id ?? '').localeCompare(other.id ?? '') ||\n (this.created?.getTime() ?? 0) - (other.created?.getTime() ?? 0) ||\n (this.published?.getTime() ?? 0) - (other.published?.getTime() ?? 0) ||\n (this.updated?.getTime() ?? 0) - (other.updated?.getTime() ?? 0) ||\n this.ratings.compare(other.ratings) ||\n this.cwes.compare(other.cwes) ||\n (this.description ?? '').localeCompare(other.description ?? '') ||\n (this.detail ?? '').localeCompare(other.detail ?? '') ||\n (this.recommendation ?? '').localeCompare(other.recommendation ?? '') ||\n (this.source && other.source ? this.source.compare(other.source) : 0) ||\n this.properties.compare(other.properties)\n /* eslint-enable @typescript-eslint/strict-boolean-expressions */\n }\n}\n\nexport class VulnerabilityRepository extends SortableComparables<Vulnerability> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { treeIteratorSymbol } from '../_helpers/tree'\nimport type { Bom, BomRef } from '../models'\nimport { BomRefDiscriminator } from './bomRefDiscriminator'\nimport type { NormalizerOptions, Serializer, SerializerOptions } from './types'\n\nexport abstract class BaseSerializer<NormalizedBom> implements Serializer {\n * #getAllBomRefs (bom: Bom): Generator<BomRef> {\n // region from components\n if (bom.metadata.component !== undefined) {\n yield bom.metadata.component.bomRef\n for (const { bomRef } of bom.metadata.component.components[treeIteratorSymbol]()) {\n yield bomRef\n }\n }\n for (const { bomRef } of bom.components[treeIteratorSymbol]()) {\n yield bomRef\n }\n // endregion from components\n\n // region from vulnerabilities\n for (const { bomRef } of bom.vulnerabilities) {\n yield bomRef\n }\n // endregion from vulnerabilities\n }\n\n /**\n * @throws {@link Error}\n */\n #normalize (bom: Bom, options?: NormalizerOptions): NormalizedBom {\n const bomRefDiscriminator = new BomRefDiscriminator(this.#getAllBomRefs(bom))\n bomRefDiscriminator.discriminate()\n // This IS NOT the place to put meaning to the BomRef values. This would be out of scope.\n // This IS the place to make BomRef values (temporary) unique in their own document scope.\n try {\n return this._normalize(bom, options)\n } finally {\n bomRefDiscriminator.reset()\n }\n }\n\n /**\n * @readonly\n * @throws {@link Error}\n */\n public serialize (bom: Bom, options?: SerializerOptions & NormalizerOptions): string {\n return this._serialize(\n this.#normalize(bom, options),\n options\n )\n }\n\n /**\n * @throws {@link Error}\n */\n protected abstract _normalize (bom: Bom, options?: NormalizerOptions): NormalizedBom\n\n /**\n * @throws {@link Error}\n */\n protected abstract _serialize (normalizedBom: NormalizedBom, options?: SerializerOptions): string\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { BomRef } from '../models'\n\nexport class BomRefDiscriminator {\n readonly #originalValues: ReadonlyArray<readonly [BomRef, string | undefined]>\n\n readonly #prefix: string\n\n constructor (bomRefs: Iterable<BomRef>, prefix: string = 'BomRef') {\n this.#originalValues = Array.from(bomRefs, r => [r, r.value])\n this.#prefix = prefix\n }\n\n get prefix (): string {\n return this.#prefix\n }\n\n /** Iterate over the {@link BomRef}s. */\n * [Symbol.iterator] (): IterableIterator<BomRef> {\n for (const [bomRef] of this.#originalValues) {\n yield bomRef\n }\n }\n\n discriminate (): void {\n const knownRefValues = new Set<string>([''])\n for (const [bomRef] of this.#originalValues) {\n let value = bomRef.value\n if (value === undefined || knownRefValues.has(value)) {\n value = this.#makeUniqueId()\n bomRef.value = value\n }\n knownRefValues.add(value)\n }\n }\n\n reset (): void {\n for (const [bomRef, originalValue] of this.#originalValues) {\n bomRef.value = originalValue\n }\n }\n\n /**\n * generate a string in the format:\n * `${this.prefix}.<random-characters>.<random-characters>`\n */\n #makeUniqueId (): string {\n return `${\n this.#prefix\n }${\n Math.random().toString(32).substring(1)\n }${\n Math.random().toString(32).substring(1)\n }`\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n// !!! not everything is public, yet\n\nexport * from './bomRefDiscriminator'\nexport * as Types from './types'\n\n// region base\n\nexport * from './baseSerializer'\n// export * from './baseDeserializer' // @TODO\n\n// endregion base\n\n// region JSON\n\nexport * as JSON from './json'\nexport * from './jsonSerializer'\n// export * from './jsonDeserializer' // @TODO\n\n// endregion JSON\n\n// region XML\n\nexport * as XML from './xml'\nexport * from './xmlBaseSerializer'\n// export * from './xmlBaseDeserializer' // @TODO\n\n// endregion XML\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './index.common'\n\n// region web-specifics\n\nexport * from './xmlSerializer.web'\n// export * from './xmlDeserializer.web' // @TODO\n\n// endregion web-specifics\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * as Normalize from './normalize'\nexport * as Types from './types'\n// export * as Denormalize from './denormalize' // @TODO\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { isNotUndefined } from '../../_helpers/notUndefined'\nimport type { SortableIterable } from '../../_helpers/sortable'\nimport type { Stringable } from '../../_helpers/stringable'\nimport { treeIteratorSymbol } from '../../_helpers/tree'\nimport { escapeUri } from '../../_helpers/uri'\nimport type * as Models from '../../models'\nimport { LicenseExpression, NamedLicense, SpdxLicense } from '../../models/license'\nimport { NamedLifecycle } from '../../models/lifecycle'\nimport { AffectedSingleVersion, AffectedVersionRange } from '../../models/vulnerability/affect'\nimport { isSupportedSpdxId } from '../../spdx'\nimport type { _SpecProtocol as Spec } from '../../spec/_protocol'\nimport { Version as SpecVersion } from '../../spec/enums'\nimport type { NormalizerOptions } from '../types'\nimport type { Normalized } from './types'\nimport { JsonSchema } from './types'\n\nexport class Factory {\n readonly #spec: Spec\n\n constructor (spec: Factory['spec']) {\n this.#spec = spec\n }\n\n get spec (): Spec {\n return this.#spec\n }\n\n makeForBom (): BomNormalizer {\n return new BomNormalizer(this)\n }\n\n makeForMetadata (): MetadataNormalizer {\n return new MetadataNormalizer(this)\n }\n\n makeForComponent (): ComponentNormalizer {\n return new ComponentNormalizer(this)\n }\n\n makeForComponentEvidence (): ComponentEvidenceNormalizer {\n return new ComponentEvidenceNormalizer(this)\n }\n\n makeForLifecycle (): LifecycleNormalizer {\n return new LifecycleNormalizer(this)\n }\n\n makeForTool (): ToolNormalizer {\n return new ToolNormalizer(this)\n }\n\n makeForOrganizationalContact (): OrganizationalContactNormalizer {\n return new OrganizationalContactNormalizer(this)\n }\n\n makeForOrganizationalEntity (): OrganizationalEntityNormalizer {\n return new OrganizationalEntityNormalizer(this)\n }\n\n makeForHash (): HashNormalizer {\n return new HashNormalizer(this)\n }\n\n makeForLicense (): LicenseNormalizer {\n return new LicenseNormalizer(this)\n }\n\n makeForSWID (): SWIDNormalizer {\n return new SWIDNormalizer(this)\n }\n\n makeForExternalReference (): ExternalReferenceNormalizer {\n return new ExternalReferenceNormalizer(this)\n }\n\n makeForAttachment (): AttachmentNormalizer {\n return new AttachmentNormalizer(this)\n }\n\n makeForProperty (): PropertyNormalizer {\n return new PropertyNormalizer(this)\n }\n\n makeForDependencyGraph (): DependencyGraphNormalizer {\n return new DependencyGraphNormalizer(this)\n }\n\n makeForVulnerability (): VulnerabilityNormalizer {\n return new VulnerabilityNormalizer(this)\n }\n\n makeForVulnerabilitySource (): VulnerabilitySourceNormalizer {\n return new VulnerabilitySourceNormalizer(this)\n }\n\n makeForVulnerabilityReference (): VulnerabilityReferenceNormalizer {\n return new VulnerabilityReferenceNormalizer(this)\n }\n\n makeForVulnerabilityRating (): VulnerabilityRatingNormalizer {\n return new VulnerabilityRatingNormalizer(this)\n }\n\n makeForVulnerabilityAdvisory (): VulnerabilityAdvisoryNormalizer {\n return new VulnerabilityAdvisoryNormalizer(this)\n }\n\n makeForVulnerabilityCredits (): VulnerabilityCreditsNormalizer {\n return new VulnerabilityCreditsNormalizer(this)\n }\n\n makeForVulnerabilityAffect (): VulnerabilityAffectNormalizer {\n return new VulnerabilityAffectNormalizer(this)\n }\n\n makeForVulnerabilityAffectedVersion (): VulnerabilityAffectedVersionNormalizer {\n return new VulnerabilityAffectedVersionNormalizer(this)\n }\n\n makeForVulnerabilityAnalysis (): VulnerabilityAnalysisNormalizer {\n return new VulnerabilityAnalysisNormalizer(this)\n }\n}\n\nconst schemaUrl: ReadonlyMap<SpecVersion, string> = new Map([\n [SpecVersion.v1dot6, 'http://cyclonedx.org/schema/bom-1.6.schema.json'],\n [SpecVersion.v1dot5, 'http://cyclonedx.org/schema/bom-1.5.schema.json'],\n [SpecVersion.v1dot4, 'http://cyclonedx.org/schema/bom-1.4.schema.json'],\n [SpecVersion.v1dot3, 'http://cyclonedx.org/schema/bom-1.3a.schema.json'],\n [SpecVersion.v1dot2, 'http://cyclonedx.org/schema/bom-1.2b.schema.json']\n])\n\ninterface JsonNormalizer<TModel, TNormalized> {\n normalize: (data: TModel, options: NormalizerOptions) => TNormalized | undefined\n\n normalizeIterable?: (data: SortableIterable<TModel>, options: NormalizerOptions) => TNormalized[]\n\n}\n\nabstract class BaseJsonNormalizer<TModel, TNormalized = object> implements JsonNormalizer<TModel, TNormalized> {\n protected readonly _factory: Factory\n\n constructor (factory: Factory) {\n this._factory = factory\n }\n\n get factory (): Factory {\n return this._factory\n }\n\n abstract normalize (data: TModel, options: NormalizerOptions): TNormalized | undefined\n}\n\n/* eslint-disable @typescript-eslint/prefer-nullish-coalescing, @typescript-eslint/strict-boolean-expressions --\n * since empty strings need to be treated as undefined/null\n */\n\nexport class BomNormalizer extends BaseJsonNormalizer<Models.Bom> {\n normalize (data: Models.Bom, options: NormalizerOptions): Normalized.Bom {\n return {\n $schema: schemaUrl.get(this._factory.spec.version),\n bomFormat: 'CycloneDX',\n specVersion: this._factory.spec.version,\n version: data.version,\n serialNumber: this.#isEligibleSerialNumber(data.serialNumber)\n ? data.serialNumber\n : undefined,\n metadata: this._factory.makeForMetadata().normalize(data.metadata, options),\n components: data.components.size > 0\n ? this._factory.makeForComponent().normalizeIterable(data.components, options)\n // spec < 1.4 requires `component` to be array\n : [],\n dependencies: this._factory.spec.supportsDependencyGraph\n ? this._factory.makeForDependencyGraph().normalize(data, options)\n : undefined,\n vulnerabilities: this._factory.spec.supportsVulnerabilities && data.vulnerabilities.size > 0\n ? this._factory.makeForVulnerability().normalizeIterable(data.vulnerabilities, options)\n : undefined\n }\n }\n\n #isEligibleSerialNumber (v: string | undefined): boolean {\n return v !== undefined &&\n // see https://github.com/CycloneDX/specification/blob/ef71717ae0ecb564c0b4c9536d6e9e57e35f2e69/schema/bom-1.4.schema.json#L39\n /^urn:uuid:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.test(v)\n }\n}\n\nexport class MetadataNormalizer extends BaseJsonNormalizer<Models.Metadata> {\n normalize (data: Models.Metadata, options: NormalizerOptions): Normalized.Metadata {\n const orgEntityNormalizer = this._factory.makeForOrganizationalEntity()\n return {\n timestamp: data.timestamp?.toISOString(),\n lifecycles: this._factory.spec.supportsMetadataLifecycles && data.lifecycles.size > 0\n ? this._factory.makeForLifecycle().normalizeIterable(data.lifecycles, options)\n : undefined,\n tools: data.tools.size > 0\n ? this._factory.makeForTool().normalizeIterable(data.tools, options)\n : undefined,\n authors: data.authors.size > 0\n ? this._factory.makeForOrganizationalContact().normalizeIterable(data.authors, options)\n : undefined,\n component: data.component === undefined\n ? undefined\n : this._factory.makeForComponent().normalize(data.component, options),\n manufacture: data.manufacture === undefined\n ? undefined\n : orgEntityNormalizer.normalize(data.manufacture, options),\n supplier: data.supplier === undefined\n ? undefined\n : orgEntityNormalizer.normalize(data.supplier, options),\n licenses: this._factory.spec.supportsMetadataLicenses && data.licenses.size > 0\n ? this._factory.makeForLicense().normalizeIterable(data.licenses, options)\n : undefined,\n properties: this._factory.spec.supportsMetadataProperties && data.properties.size > 0\n ? this._factory.makeForProperty().normalizeIterable(data.properties, options)\n : undefined\n }\n }\n}\n\nexport class LifecycleNormalizer extends BaseJsonNormalizer<Models.Lifecycle> {\n normalize (data: Models.Lifecycle, options: NormalizerOptions): Normalized.Lifecycle {\n return data instanceof NamedLifecycle\n ? { name: data.name, description: data.description }\n : { phase: data }\n }\n\n normalizeIterable (data: SortableIterable<Models.Lifecycle>, options: NormalizerOptions): Normalized.Lifecycle[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(lc => this.normalize(lc, options))\n }\n}\n\nexport class ToolNormalizer extends BaseJsonNormalizer<Models.Tool> {\n normalize (data: Models.Tool, options: NormalizerOptions): Normalized.Tool {\n return {\n vendor: data.vendor || undefined,\n name: data.name || undefined,\n version: data.version || undefined,\n hashes: data.hashes.size > 0\n ? this._factory.makeForHash().normalizeIterable(data.hashes, options)\n : undefined,\n externalReferences: this._factory.spec.supportsToolReferences && data.externalReferences.size > 0\n ? this._factory.makeForExternalReference().normalizeIterable(data.externalReferences, options)\n : undefined\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Tool>, options: NormalizerOptions): Normalized.Tool[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(t => this.normalize(t, options))\n }\n}\n\nexport class HashNormalizer extends BaseJsonNormalizer<Models.Hash> {\n normalize ([algorithm, content]: Models.Hash, options: NormalizerOptions): Normalized.Hash | undefined {\n const spec = this._factory.spec\n return spec.supportsHashAlgorithm(algorithm) && spec.supportsHashValue(content)\n ? {\n alg: algorithm,\n content\n }\n : undefined\n }\n\n normalizeIterable (data: SortableIterable<Models.Hash>, options: NormalizerOptions): Normalized.Hash[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n h => this.normalize(h, options)\n ).filter(isNotUndefined)\n }\n}\n\nexport class OrganizationalContactNormalizer extends BaseJsonNormalizer<Models.OrganizationalContact> {\n normalize (data: Models.OrganizationalContact, options: NormalizerOptions): Normalized.OrganizationalContact {\n return {\n name: data.name || undefined,\n email: JsonSchema.isIdnEmail(data.email)\n ? data.email\n : undefined,\n phone: data.phone || undefined\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.OrganizationalContact>, options: NormalizerOptions): Normalized.OrganizationalContact[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(oc => this.normalize(oc, options))\n }\n}\n\nexport class OrganizationalEntityNormalizer extends BaseJsonNormalizer<Models.OrganizationalEntity> {\n normalize (data: Models.OrganizationalEntity, options: NormalizerOptions): Normalized.OrganizationalEntity {\n const urls = normalizeStringableIter(\n Array.from(data.url, (s) => escapeUri(s.toString())),\n options\n ).filter(JsonSchema.isIriReference)\n return {\n name: data.name || undefined,\n url: urls.length > 0\n ? urls\n : undefined,\n contact: data.contact.size > 0\n ? this._factory.makeForOrganizationalContact().normalizeIterable(data.contact, options)\n : undefined\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.OrganizationalEntity>, options: NormalizerOptions): Normalized.OrganizationalEntity[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(oe => this.normalize(oe, options))\n }\n}\n\nexport class ComponentNormalizer extends BaseJsonNormalizer<Models.Component> {\n normalize (data: Models.Component, options: NormalizerOptions): Normalized.Component | undefined {\n const spec = this._factory.spec\n if (!spec.supportsComponentType(data.type)) {\n return undefined\n }\n const version: string = data.version ?? ''\n return {\n type: data.type,\n name: data.name,\n group: data.group || undefined,\n version: version.length > 0 || spec.requiresComponentVersion\n ? version\n : undefined,\n 'bom-ref': data.bomRef.value || undefined,\n supplier: data.supplier === undefined\n ? undefined\n : this._factory.makeForOrganizationalEntity().normalize(data.supplier, options),\n author: data.author || undefined,\n publisher: data.publisher || undefined,\n description: data.description || undefined,\n scope: data.scope,\n hashes: data.hashes.size > 0\n ? this._factory.makeForHash().normalizeIterable(data.hashes, options)\n : undefined,\n licenses: data.licenses.size > 0\n ? this._factory.makeForLicense().normalizeIterable(data.licenses, options)\n : undefined,\n copyright: data.copyright?.toString() || undefined,\n cpe: data.cpe || undefined,\n purl: data.purl?.toString(),\n swid: data.swid === undefined\n ? undefined\n : this._factory.makeForSWID().normalize(data.swid, options),\n externalReferences: data.externalReferences.size > 0\n ? this._factory.makeForExternalReference().normalizeIterable(data.externalReferences, options)\n : undefined,\n properties: spec.supportsProperties(data) && data.properties.size > 0\n ? this._factory.makeForProperty().normalizeIterable(data.properties, options)\n : undefined,\n components: data.components.size > 0\n ? this.normalizeIterable(data.components, options)\n : undefined,\n evidence: spec.supportsComponentEvidence && data.evidence !== undefined\n ? this._factory.makeForComponentEvidence().normalize(data.evidence, options)\n : undefined\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Component>, options: NormalizerOptions): Normalized.Component[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n c => this.normalize(c, options)\n ).filter(isNotUndefined)\n }\n}\n\nexport class ComponentEvidenceNormalizer extends BaseJsonNormalizer<Models.ComponentEvidence> {\n normalize (data: Models.ComponentEvidence, options: NormalizerOptions): Normalized.ComponentEvidence {\n return {\n licenses: data.licenses.size > 0\n ? this._factory.makeForLicense().normalizeIterable(data.licenses, options)\n : undefined,\n copyright: data.copyright.size > 0\n ? (\n options.sortLists\n ? data.copyright.sorted().map(ComponentEvidenceNormalizer.#normalizeCopyright)\n : Array.from(data.copyright, ComponentEvidenceNormalizer.#normalizeCopyright)\n )\n : undefined\n }\n }\n\n static #normalizeCopyright (c: Stringable): Normalized.Copyright {\n return { text: c.toString() }\n }\n}\n\nexport class LicenseNormalizer extends BaseJsonNormalizer<Models.License> {\n normalize (data: Models.License, options: NormalizerOptions): Normalized.License {\n switch (true) {\n case data instanceof NamedLicense:\n return this.#normalizeNamedLicense(data, options)\n case data instanceof SpdxLicense:\n return isSupportedSpdxId(data.id)\n ? this.#normalizeSpdxLicense(data, options)\n : this.#normalizeNamedLicense(new NamedLicense(\n // prevent information loss -> convert to broader type\n data.id,\n { url: data.url }\n ), options)\n case data instanceof LicenseExpression:\n return this.#normalizeLicenseExpression(data)\n /* c8 ignore start */\n default:\n // this case is expected to never happen - and therefore is undocumented\n throw new TypeError('Unexpected LicenseChoice')\n /* c8 ignore end */\n }\n }\n\n #normalizeNamedLicense (data: Models.NamedLicense, options: NormalizerOptions): Normalized.NamedLicense {\n const url = escapeUri(data.url?.toString())\n return {\n license: {\n name: data.name,\n acknowledgement: this._factory.spec.supportsLicenseAcknowledgement\n ? data.acknowledgement\n : undefined,\n text: data.text === undefined\n ? undefined\n : this._factory.makeForAttachment().normalize(data.text, options),\n url: JsonSchema.isIriReference(url)\n ? url\n : undefined\n }\n }\n }\n\n #normalizeSpdxLicense (data: Models.SpdxLicense, options: NormalizerOptions): Normalized.SpdxLicense {\n const url = escapeUri(data.url?.toString())\n return {\n license: {\n id: data.id,\n acknowledgement: this._factory.spec.supportsLicenseAcknowledgement\n ? data.acknowledgement\n : undefined,\n text: data.text === undefined\n ? undefined\n : this._factory.makeForAttachment().normalize(data.text, options),\n url: JsonSchema.isIriReference(url)\n ? url\n : undefined\n }\n }\n }\n\n #normalizeLicenseExpression (data: Models.LicenseExpression): Normalized.LicenseExpression {\n return {\n expression: data.expression,\n acknowledgement: this._factory.spec.supportsLicenseAcknowledgement\n ? data.acknowledgement\n : undefined\n }\n }\n\n /**\n * If there is any {@link Models.LicenseExpression | LicenseExpression} in the set, then this is the only item that is normalized.\n */\n normalizeIterable (data: SortableIterable<Models.License>, options: NormalizerOptions): Normalized.License[] {\n const licenses = options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n\n if (licenses.length > 1) {\n const expressions = licenses.filter(l => l instanceof LicenseExpression) as Models.LicenseExpression[]\n if (expressions.length > 0) {\n // could have thrown {@link RangeError} when there is more than one only {@link Models.LicenseExpression | LicenseExpression}.\n // but let's be graceful and just normalize to the most relevant choice: any expression\n return [this.#normalizeLicenseExpression(expressions[0])]\n }\n }\n\n return licenses.map(l => this.normalize(l, options))\n }\n}\n\nexport class SWIDNormalizer extends BaseJsonNormalizer<Models.SWID> {\n normalize (data: Models.SWID, options: NormalizerOptions): Normalized.SWID {\n const url = escapeUri(data.url?.toString())\n return {\n tagId: data.tagId,\n name: data.name,\n version: data.version || undefined,\n tagVersion: data.tagVersion,\n patch: data.patch,\n text: data.text === undefined\n ? undefined\n : this._factory.makeForAttachment().normalize(data.text, options),\n url: JsonSchema.isIriReference(url)\n ? url\n : undefined\n }\n }\n}\n\nexport class ExternalReferenceNormalizer extends BaseJsonNormalizer<Models.ExternalReference> {\n normalize (data: Models.ExternalReference, options: NormalizerOptions): Normalized.ExternalReference | undefined {\n return this._factory.spec.supportsExternalReferenceType(data.type)\n ? {\n url: escapeUri(data.url.toString()),\n type: data.type,\n hashes: this._factory.spec.supportsExternalReferenceHashes && data.hashes.size > 0\n ? this._factory.makeForHash().normalizeIterable(data.hashes, options)\n : undefined,\n comment: data.comment || undefined\n }\n : undefined\n }\n\n normalizeIterable (data: SortableIterable<Models.ExternalReference>, options: NormalizerOptions): Normalized.ExternalReference[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n r => this.normalize(r, options)\n ).filter(isNotUndefined)\n }\n}\n\nexport class AttachmentNormalizer extends BaseJsonNormalizer<Models.Attachment> {\n normalize (data: Models.Attachment, options: NormalizerOptions): Normalized.Attachment {\n return {\n content: data.content.toString(),\n contentType: data.contentType || undefined,\n encoding: data.encoding\n }\n }\n}\n\nexport class PropertyNormalizer extends BaseJsonNormalizer<Models.Property> {\n normalize (data: Models.Property, options: NormalizerOptions): Normalized.Property {\n return {\n name: data.name,\n value: data.value\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Property>, options: NormalizerOptions): Normalized.Property[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(p => this.normalize(p, options))\n }\n}\n\nexport class DependencyGraphNormalizer extends BaseJsonNormalizer<Models.Bom> {\n normalize (data: Models.Bom, options: NormalizerOptions): Normalized.Dependency[] | undefined {\n const allRefs = new Map<Models.BomRef, Models.BomRefRepository>()\n if (data.metadata.component !== undefined) {\n allRefs.set(data.metadata.component.bomRef, data.metadata.component.dependencies)\n for (const component of data.metadata.component.components[treeIteratorSymbol]()) {\n allRefs.set(component.bomRef, component.dependencies)\n }\n }\n for (const component of data.components[treeIteratorSymbol]()) {\n allRefs.set(component.bomRef, component.dependencies)\n }\n\n const normalized: Normalized.Dependency[] = []\n for (const [ref, deps] of allRefs) {\n const dep = this.#normalizeDependency(ref, deps, allRefs, options)\n if (isNotUndefined(dep)) {\n normalized.push(dep)\n }\n }\n\n if (options.sortLists ?? false) {\n normalized.sort(({ ref: a }, { ref: b }) => a.localeCompare(b))\n }\n\n return normalized\n }\n\n #normalizeDependency (\n ref: Models.BomRef,\n deps: Models.BomRefRepository,\n allRefs: Map<Models.BomRef, Models.BomRefRepository>,\n options: NormalizerOptions\n ): Normalized.Dependency | undefined {\n const bomRef = ref.toString()\n if (bomRef.length === 0) {\n // no value -> cannot render\n return undefined\n }\n\n const dependsOn: string[] = normalizeStringableIter(\n Array.from(deps).filter(d => allRefs.has(d) && d !== ref),\n options\n ).filter(d => d.length > 0)\n\n return {\n ref: bomRef,\n dependsOn: dependsOn.length > 0\n ? dependsOn\n : undefined\n }\n }\n}\n\nexport class VulnerabilityNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Vulnerability> {\n normalize (data: Models.Vulnerability.Vulnerability, options: NormalizerOptions): Normalized.Vulnerability {\n return {\n 'bom-ref': data.bomRef.value || undefined,\n id: data.id || undefined,\n source: data.source === undefined\n ? undefined\n : this._factory.makeForVulnerabilitySource().normalize(data.source, options),\n references: data.references.size > 0\n ? this._factory.makeForVulnerabilityReference().normalizeIterable(data.references, options)\n : undefined,\n ratings: data.ratings.size > 0\n ? this._factory.makeForVulnerabilityRating().normalizeIterable(data.ratings, options)\n : undefined,\n cwes: data.cwes.size > 0\n ? (\n options.sortLists ?? false\n ? data.cwes.sorted()\n : Array.from(data.cwes)\n )\n : undefined,\n description: data.description,\n detail: data.detail,\n recommendation: data.recommendation,\n advisories: data.advisories.size > 0\n ? this._factory.makeForVulnerabilityAdvisory().normalizeIterable(data.advisories, options)\n : undefined,\n created: data.created?.toISOString(),\n published: data.published?.toISOString(),\n updated: data.updated?.toISOString(),\n credits: data.credits === undefined\n ? undefined\n : this._factory.makeForVulnerabilityCredits().normalize(data.credits, options),\n tools: data.tools.size > 0\n ? this._factory.makeForTool().normalizeIterable(data.tools, options)\n : undefined,\n analysis: data.analysis === undefined\n ? undefined\n : this._factory.makeForVulnerabilityAnalysis().normalize(data.analysis, options),\n affects: data.affects.size > 0\n ? this._factory.makeForVulnerabilityAffect().normalizeIterable(data.affects, options)\n : undefined,\n properties: data.properties.size > 0\n ? this._factory.makeForProperty().normalizeIterable(data.properties, options)\n : undefined\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Vulnerability>, options: NormalizerOptions): Normalized.Vulnerability[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(v => this.normalize(v, options))\n }\n}\n\nexport class VulnerabilitySourceNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Source> {\n normalize (data: Models.Vulnerability.Source, options: NormalizerOptions): Normalized.Vulnerability.Source {\n return {\n name: data.name,\n url: data.url?.toString()\n }\n }\n}\n\nexport class VulnerabilityReferenceNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Reference> {\n normalize (data: Models.Vulnerability.Reference, options: NormalizerOptions): Normalized.Vulnerability.Reference {\n return {\n id: data.id,\n source: this._factory.makeForVulnerabilitySource().normalize(data.source, options)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Reference>, options: NormalizerOptions): Normalized.Vulnerability.Reference[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(r => this.normalize(r, options))\n }\n}\n\nexport class VulnerabilityRatingNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Rating> {\n normalize (data: Models.Vulnerability.Rating, options: NormalizerOptions): Normalized.Vulnerability.Rating {\n return {\n source: data.source === undefined\n ? undefined\n : this._factory.makeForVulnerabilitySource().normalize(data.source, options),\n score: data.score,\n severity: data.severity,\n method: this._factory.spec.supportsVulnerabilityRatingMethod(data.method)\n ? data.method\n : undefined,\n vector: data.vector,\n justification: data.justification\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Rating>, options: NormalizerOptions): Normalized.Vulnerability.Rating[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(r => this.normalize(r, options))\n }\n}\n\nexport class VulnerabilityAdvisoryNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Advisory> {\n normalize (data: Models.Vulnerability.Advisory, options: NormalizerOptions): Normalized.Vulnerability.Advisory | undefined {\n const url = escapeUri(data.url.toString())\n if (!JsonSchema.isIriReference(url)) {\n // invalid value -> cannot render\n return undefined\n }\n return {\n title: data.title,\n url\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Advisory>, options: NormalizerOptions): Normalized.Vulnerability.Advisory[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n a => this.normalize(a, options)\n ).filter(isNotUndefined)\n }\n}\n\nexport class VulnerabilityCreditsNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Credits> {\n normalize (data: Models.Vulnerability.Credits, options: NormalizerOptions): Normalized.Vulnerability.Credits {\n return {\n organizations: data.organizations.size > 0\n ? this._factory.makeForOrganizationalEntity().normalizeIterable(data.organizations, options)\n : undefined,\n individuals: data.individuals.size > 0\n ? this._factory.makeForOrganizationalContact().normalizeIterable(data.individuals, options)\n : undefined\n }\n }\n}\n\nexport class VulnerabilityAffectNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Affect> {\n normalize (data: Models.Vulnerability.Affect, options: NormalizerOptions): Normalized.Vulnerability.Affect {\n return {\n ref: data.ref.toString(),\n versions: data.versions.size > 0\n ? this._factory.makeForVulnerabilityAffectedVersion().normalizeIterable(data.versions, options)\n : undefined\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Affect>, options: NormalizerOptions): Normalized.Vulnerability.Affect[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(a => this.normalize(a, options))\n }\n}\n\nexport class VulnerabilityAffectedVersionNormalizer extends BaseJsonNormalizer<Models.Vulnerability.AffectedVersion> {\n normalize (data: Models.Vulnerability.AffectedVersion, options: NormalizerOptions): Normalized.Vulnerability.AffectedVersion | undefined {\n switch (true) {\n case data instanceof AffectedSingleVersion:\n return this.#normalizeAffectedSingleVersion(data)\n case data instanceof AffectedVersionRange:\n return this.#normalizeAffectedVersionRange(data)\n /* c8 ignore start */\n default:\n // this case is expected to never happen - and therefore is undocumented\n throw new TypeError('Unexpected Vulnerability AffectedVersion')\n /* c8 ignore end */\n }\n }\n\n #normalizeAffectedSingleVersion (data: Models.Vulnerability.AffectedSingleVersion): Normalized.Vulnerability.AffectedSingleVersion | undefined {\n return data.version.length < 1\n // invalid value -> cannot render\n ? undefined\n : {\n version: data.version.substring(0, 1024),\n status: data.status\n }\n }\n\n #normalizeAffectedVersionRange (data: Models.Vulnerability.AffectedVersionRange): Normalized.Vulnerability.AffectedVersionRange | undefined {\n return data.range.length < 1\n // invalid value -> cannot render\n ? undefined\n : {\n range: data.range.substring(0, 1024),\n status: data.status\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.AffectedVersion>, options: NormalizerOptions): Normalized.Vulnerability.AffectedVersion[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n av => this.normalize(av, options)\n ).filter(isNotUndefined)\n }\n}\n\nexport class VulnerabilityAnalysisNormalizer extends BaseJsonNormalizer<Models.Vulnerability.Analysis> {\n normalize (data: Models.Vulnerability.Analysis, options: NormalizerOptions): Normalized.Vulnerability.Analysis {\n return {\n state: data.state,\n justification: data.justification,\n response: data.response.size > 0\n ? (\n options.sortLists ?? false\n ? data.response.sorted()\n : Array.from(data.response)\n )\n : undefined,\n detail: data.detail\n }\n }\n}\n\n/* eslint-enable @typescript-eslint/prefer-nullish-coalescing, @typescript-eslint/strict-boolean-expressions */\n\nfunction normalizeStringableIter (data: Iterable<Stringable>, options: NormalizerOptions): string[] {\n const r = Array.from(data, d => d.toString())\n if (options.sortLists ?? false) {\n r.sort((a, b) => a.localeCompare(b))\n }\n return r\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type * as Enums from '../../enums'\nimport type { HashContent } from '../../models'\nimport type { SpdxId } from '../../spdx'\nimport type { CPE, CWE, Integer } from '../../types'\n\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport namespace JsonSchema {\n\n /**\n * @see {@link isIriReference}\n */\n export type IriReference = string\n /**\n * Test whether format is JSON::iri-reference - best-effort.\n *\n * @see {@link https://datatracker.ietf.org/doc/html/rfc3987 | RFC 3987}\n *\n * @TODO add more validation according to spec\n */\n export function isIriReference (value: IriReference | any): value is IriReference {\n // There is just no working implementation for format \"iri-reference\": see https://github.com/luzlab/ajv-formats-draft2019/issues/22\n return typeof value === 'string' &&\n value.length > 0\n }\n\n /**\n * @see {@link isIdnEmail}\n */\n export type IdnEmail = string\n /**\n * Test whether format is JSON::idn-email - best-effort.\n *\n * @see {@link https://datatracker.ietf.org/doc/html/rfc6531 | RFC 6531}\n *\n * @TODO add more validation according to spec\n */\n export function isIdnEmail (value: IdnEmail | any): value is IdnEmail {\n return typeof value === 'string' &&\n value.length > 0\n }\n\n export type DateTime = string\n\n}\n\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport namespace Normalized {\n\n export type RefType = string\n export type RefLinkType = RefType\n\n export type BomLinkDocumentType = string\n export type BomLinkElementType = string\n export type BomLink = BomLinkDocumentType | BomLinkElementType\n\n export interface Bom {\n $schema?: string\n bomFormat: 'CycloneDX'\n specVersion: string\n version: Integer\n serialNumber?: string\n metadata?: Metadata\n components?: Component[]\n externalReferences?: ExternalReference[]\n dependencies?: Dependency[]\n vulnerabilities?: Vulnerability[]\n }\n\n export interface Metadata {\n timestamp?: JsonSchema.DateTime\n lifecycles?: Lifecycle[]\n tools?: Tool[]\n authors?: OrganizationalContact[]\n component?: Component\n manufacture?: OrganizationalEntity\n supplier?: OrganizationalEntity\n licenses?: License[]\n properties?: Property[]\n }\n\n export interface LifecyclePhase {\n phase: Enums.LifecyclePhase\n }\n\n export interface NamedLifecycle {\n name: string\n description?: string\n }\n\n export type Lifecycle = LifecyclePhase | NamedLifecycle\n\n export interface Tool {\n vendor?: string\n name?: string\n version?: string\n hashes?: Hash[]\n externalReferences?: ExternalReference[]\n }\n\n export interface OrganizationalContact {\n name?: string\n email?: JsonSchema.IdnEmail\n phone?: string\n }\n\n export interface OrganizationalEntity {\n name?: string\n url?: JsonSchema.IriReference[]\n contact?: OrganizationalContact[]\n }\n\n export interface Hash {\n alg: Enums.HashAlgorithm\n content: HashContent\n }\n\n export interface Component {\n type: Enums.ComponentType\n name: string\n 'mime-type'?: string\n 'bom-ref'?: RefType\n supplier?: OrganizationalEntity\n author?: string\n publisher?: string\n group?: string\n version?: string\n description?: string\n scope?: Enums.ComponentScope\n hashes?: Hash[]\n licenses?: License[]\n copyright?: string\n cpe?: CPE\n purl?: string\n swid?: SWID\n modified?: boolean\n externalReferences?: ExternalReference[]\n components?: Component[]\n evidence?: ComponentEvidence\n properties?: Property[]\n }\n\n export interface ComponentEvidence {\n licenses?: License[]\n copyright?: Copyright[]\n }\n\n export interface Copyright {\n text: string\n }\n\n export interface NamedLicense {\n license: {\n name: string\n acknowledgement?: Enums.LicenseAcknowledgement\n text?: Attachment\n url?: string\n }\n }\n\n export interface SpdxLicense {\n license: {\n /* see http://cyclonedx.org/schema/spdx */\n id: SpdxId\n acknowledgement?: Enums.LicenseAcknowledgement\n text?: Attachment\n url?: string\n }\n }\n\n export interface LicenseExpression {\n expression: string\n acknowledgement?: Enums.LicenseAcknowledgement\n }\n\n export type License = NamedLicense | SpdxLicense | LicenseExpression\n\n export interface SWID {\n tagId: string\n name: string\n version?: string\n tagVersion?: Integer\n patch?: boolean\n text?: Attachment\n url?: JsonSchema.IriReference\n }\n\n export interface ExternalReference {\n url: JsonSchema.IriReference | BomLink\n type: Enums.ExternalReferenceType\n hashes?: Hash[]\n comment?: string\n }\n\n export interface Attachment {\n content?: string\n contentType?: string\n encoding?: Enums.AttachmentEncoding\n }\n\n export interface Property {\n name?: string\n value?: string\n }\n\n export interface Dependency {\n ref: RefLinkType\n dependsOn?: RefLinkType[]\n }\n\n export interface Vulnerability {\n 'bom-ref'?: RefType\n id?: string\n source?: Vulnerability.Source\n references?: Vulnerability.Reference[]\n ratings?: Vulnerability.Rating[]\n cwes?: CWE[]\n description?: string\n detail?: string\n recommendation?: string\n advisories?: Vulnerability.Advisory[]\n created?: JsonSchema.DateTime\n published?: JsonSchema.DateTime\n updated?: JsonSchema.DateTime\n credits?: Vulnerability.Credits\n tools?: Tool[]\n analysis?: Vulnerability.Analysis\n affects?: Vulnerability.Affect[]\n properties?: Property[]\n }\n\n // eslint-disable-next-line @typescript-eslint/no-namespace\n export namespace Vulnerability {\n export interface Source {\n name?: string\n url?: string\n }\n\n export interface Reference {\n id: string\n source: Source\n }\n\n export interface Rating {\n source?: Source\n score?: number\n severity?: Enums.Vulnerability.Severity\n method?: Enums.Vulnerability.RatingMethod\n vector?: string\n justification?: string\n }\n\n export interface Advisory {\n title?: string\n url: JsonSchema.IriReference\n }\n\n export interface Credits {\n organizations?: OrganizationalEntity[]\n individuals?: OrganizationalContact[]\n }\n\n export interface Analysis {\n state?: Enums.Vulnerability.AnalysisState\n justification?: Enums.Vulnerability.AnalysisJustification\n response?: Enums.Vulnerability.AnalysisResponse[]\n detail?: string\n }\n\n export interface Affect {\n ref: RefLinkType | BomLinkElementType\n versions?: AffectedVersion[]\n }\n\n export interface AffectedSingleVersion {\n version: string\n status?: Enums.Vulnerability.AffectStatus\n }\n\n export interface AffectedVersionRange {\n range: string\n status?: Enums.Vulnerability.AffectStatus\n }\n\n export type AffectedVersion = AffectedSingleVersion | AffectedVersionRange\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Bom } from '../models/bom'\nimport { Format } from '../spec/enums'\nimport { UnsupportedFormatError } from '../spec/errors'\nimport { BaseSerializer } from './baseSerializer'\nimport type { Factory as NormalizerFactory } from './json/normalize'\nimport type { Normalized } from './json/types'\nimport type { NormalizerOptions, SerializerOptions } from './types'\n\n/**\n * Multi purpose Json serializer.\n */\nexport class JsonSerializer extends BaseSerializer<Normalized.Bom> {\n readonly #normalizerFactory: NormalizerFactory\n\n /**\n * @throws {@link UnsupportedFormatError} if `normalizerFactory.spec` does not support {@link Format.JSON}.\n */\n constructor (normalizerFactory: JsonSerializer['normalizerFactory']) {\n if (!normalizerFactory.spec.supportsFormat(Format.JSON)) {\n throw new UnsupportedFormatError('Spec does not support JSON format.')\n }\n\n super()\n this.#normalizerFactory = normalizerFactory\n }\n\n get normalizerFactory (): NormalizerFactory {\n return this.#normalizerFactory\n }\n\n protected _normalize (\n bom: Bom,\n options: NormalizerOptions = {}\n ): Normalized.Bom {\n return this.#normalizerFactory.makeForBom()\n .normalize(bom, options)\n }\n\n protected _serialize (\n bom: Normalized.Bom,\n { space }: SerializerOptions = {}\n ): string {\n return JSON.stringify(bom, null, space)\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Bom } from '../models'\n\nexport interface NormalizerOptions {\n /**\n * Whether to sort lists in normalization results. Sorted lists make the output reproducible.\n */\n sortLists?: boolean\n}\n\nexport interface SerializerOptions {\n /**\n * Add indention in the serialization result. Indention increases readability for humans.\n */\n space?: string | number\n}\n\nexport interface Serializer {\n /**\n * @throws {@link Error}\n */\n serialize: (bom: Bom, options?: SerializerOptions & NormalizerOptions) => string\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * as Normalize from './normalize'\nexport * as Types from './types'\n// export * as Denormalize from './denormalize' // @TODO\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { isNotUndefined } from '../../_helpers/notUndefined'\nimport type { SortableIterable } from '../../_helpers/sortable'\nimport type { Stringable } from '../../_helpers/stringable'\nimport { treeIteratorSymbol } from '../../_helpers/tree'\nimport { escapeUri } from '../../_helpers/uri'\nimport type * as Models from '../../models'\nimport { LicenseExpression, NamedLicense, SpdxLicense } from '../../models/license'\nimport { NamedLifecycle } from '../../models/lifecycle'\nimport { AffectedSingleVersion, AffectedVersionRange } from '../../models/vulnerability/affect'\nimport { isSupportedSpdxId } from '../../spdx'\nimport type { _SpecProtocol as Spec } from '../../spec/_protocol'\nimport { Version as SpecVersion } from '../../spec/enums'\nimport type { NormalizerOptions } from '../types'\nimport type { SimpleXml } from './types'\nimport { XmlSchema } from './types'\n\nexport class Factory {\n readonly #spec: Spec\n\n constructor (spec: Factory['spec']) {\n this.#spec = spec\n }\n\n get spec (): Spec {\n return this.#spec\n }\n\n makeForBom (): BomNormalizer {\n return new BomNormalizer(this)\n }\n\n makeForMetadata (): MetadataNormalizer {\n return new MetadataNormalizer(this)\n }\n\n makeForLifecycle (): LifecycleNormalizer {\n return new LifecycleNormalizer(this)\n }\n\n makeForComponent (): ComponentNormalizer {\n return new ComponentNormalizer(this)\n }\n\n makeForComponentEvidence (): ComponentEvidenceNormalizer {\n return new ComponentEvidenceNormalizer(this)\n }\n\n makeForTool (): ToolNormalizer {\n return new ToolNormalizer(this)\n }\n\n makeForOrganizationalContact (): OrganizationalContactNormalizer {\n return new OrganizationalContactNormalizer(this)\n }\n\n makeForOrganizationalEntity (): OrganizationalEntityNormalizer {\n return new OrganizationalEntityNormalizer(this)\n }\n\n makeForHash (): HashNormalizer {\n return new HashNormalizer(this)\n }\n\n makeForLicense (): LicenseNormalizer {\n return new LicenseNormalizer(this)\n }\n\n makeForSWID (): SWIDNormalizer {\n return new SWIDNormalizer(this)\n }\n\n makeForExternalReference (): ExternalReferenceNormalizer {\n return new ExternalReferenceNormalizer(this)\n }\n\n makeForAttachment (): AttachmentNormalizer {\n return new AttachmentNormalizer(this)\n }\n\n makeForProperty (): PropertyNormalizer {\n return new PropertyNormalizer(this)\n }\n\n makeForDependencyGraph (): DependencyGraphNormalizer {\n return new DependencyGraphNormalizer(this)\n }\n\n makeForVulnerability (): VulnerabilityNormalizer {\n return new VulnerabilityNormalizer(this)\n }\n\n makeForVulnerabilitySource (): VulnerabilitySourceNormalizer {\n return new VulnerabilitySourceNormalizer(this)\n }\n\n makeForVulnerabilityReference (): VulnerabilityReferenceNormalizer {\n return new VulnerabilityReferenceNormalizer(this)\n }\n\n makeForVulnerabilityRating (): VulnerabilityRatingNormalizer {\n return new VulnerabilityRatingNormalizer(this)\n }\n\n makeForVulnerabilityAdvisory (): VulnerabilityAdvisoryNormalizer {\n return new VulnerabilityAdvisoryNormalizer(this)\n }\n\n makeForVulnerabilityCredits (): VulnerabilityCreditsNormalizer {\n return new VulnerabilityCreditsNormalizer(this)\n }\n\n makeForVulnerabilityAffect (): VulnerabilityAffectNormalizer {\n return new VulnerabilityAffectNormalizer(this)\n }\n\n makeForVulnerabilityAffectedVersion (): VulnerabilityAffectedVersionNormalizer {\n return new VulnerabilityAffectedVersionNormalizer(this)\n }\n\n makeForVulnerabilityAnalysis (): VulnerabilityAnalysisNormalizer {\n return new VulnerabilityAnalysisNormalizer(this)\n }\n}\n\nconst xmlNamespace: ReadonlyMap<SpecVersion, string> = new Map([\n [SpecVersion.v1dot6, 'http://cyclonedx.org/schema/bom/1.6'],\n [SpecVersion.v1dot5, 'http://cyclonedx.org/schema/bom/1.5'],\n [SpecVersion.v1dot4, 'http://cyclonedx.org/schema/bom/1.4'],\n [SpecVersion.v1dot3, 'http://cyclonedx.org/schema/bom/1.3'],\n [SpecVersion.v1dot2, 'http://cyclonedx.org/schema/bom/1.2'],\n [SpecVersion.v1dot1, 'http://cyclonedx.org/schema/bom/1.1'],\n [SpecVersion.v1dot0, 'http://cyclonedx.org/schema/bom/1.0']\n])\n\ninterface XmlNormalizer<TModel, TNormalized> {\n normalize: (data: TModel, options: NormalizerOptions, elementName?: string) => TNormalized | undefined\n\n normalizeIterable?: (data: SortableIterable<TModel>, options: NormalizerOptions, elementName: string) => TNormalized[]\n}\n\nabstract class BaseXmlNormalizer<TModel, TNormalized = SimpleXml.Element> implements XmlNormalizer<TModel, TNormalized> {\n protected readonly _factory: Factory\n\n constructor (factory: Factory) {\n this._factory = factory\n }\n\n get factory (): Factory {\n return this._factory\n }\n\n /**\n * @param elementName - element name. XML defines structures; the element's name is defined on usage of a structure.\n */\n abstract normalize (data: TModel, options: NormalizerOptions, elementName?: string): TNormalized | undefined\n}\n\n/* eslint-disable @typescript-eslint/prefer-nullish-coalescing, @typescript-eslint/strict-boolean-expressions --\n * since empty strings need to be treated as undefined/null\n */\n\nexport class BomNormalizer extends BaseXmlNormalizer<Models.Bom> {\n normalize (data: Models.Bom, options: NormalizerOptions): SimpleXml.Element {\n const components: SimpleXml.Element = {\n // spec < 1.4 always requires a 'components' element\n type: 'element',\n name: 'components',\n children: data.components.size > 0\n ? this._factory.makeForComponent().normalizeIterable(data.components, options, 'component')\n : undefined\n }\n const vulnerabilities: SimpleXml.Element | undefined = this._factory.spec.supportsVulnerabilities && data.vulnerabilities.size > 0\n ? {\n type: 'element',\n name: 'vulnerabilities',\n children: this._factory.makeForVulnerability().normalizeIterable(data.vulnerabilities, options, 'vulnerability')\n }\n : undefined\n return {\n type: 'element',\n // the element's name is hardcoded in the XSD\n name: 'bom',\n namespace: xmlNamespace.get(this._factory.spec.version),\n attributes: {\n version: data.version,\n serialNumber: this.#isEligibleSerialNumber(data.serialNumber)\n ? data.serialNumber\n : undefined\n },\n children: [\n data.metadata\n ? this._factory.makeForMetadata().normalize(data.metadata, options, 'metadata')\n : undefined,\n components,\n this._factory.spec.supportsDependencyGraph\n ? this._factory.makeForDependencyGraph().normalize(data, options, 'dependencies')\n : undefined,\n vulnerabilities\n ].filter(isNotUndefined)\n }\n }\n\n #isEligibleSerialNumber (v: string | undefined): boolean {\n return v !== undefined &&\n // see https://github.com/CycloneDX/specification/blob/ef71717ae0ecb564c0b4c9536d6e9e57e35f2e69/schema/bom-1.4.xsd#L699\n /^urn:uuid:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$|^\\{[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\\}$/.test(v)\n }\n}\n\nexport class MetadataNormalizer extends BaseXmlNormalizer<Models.Metadata> {\n normalize (data: Models.Metadata, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const orgEntityNormalizer = this._factory.makeForOrganizationalEntity()\n const lifecycles: SimpleXml.Element | undefined = this._factory.spec.supportsMetadataLifecycles && data.lifecycles.size > 0\n ? {\n type: 'element',\n name: 'lifecycles',\n children: this._factory.makeForLifecycle().normalizeIterable(data.lifecycles, options, 'lifecycle')\n }\n : undefined\n const tools: SimpleXml.Element | undefined = data.tools.size > 0\n ? {\n type: 'element',\n name: 'tools',\n children: this._factory.makeForTool().normalizeIterable(data.tools, options, 'tool')\n }\n : undefined\n const authors: SimpleXml.Element | undefined = data.authors.size > 0\n ? {\n type: 'element',\n name: 'authors',\n children: this._factory.makeForOrganizationalContact().normalizeIterable(data.authors, options, 'author')\n }\n : undefined\n const licenses: SimpleXml.Element | undefined = this._factory.spec.supportsMetadataLicenses && data.licenses.size > 0\n ? {\n type: 'element',\n name: 'licenses',\n children: this._factory.makeForLicense().normalizeIterable(data.licenses, options)\n }\n : undefined\n const properties: SimpleXml.Element | undefined = this._factory.spec.supportsMetadataProperties && data.properties.size > 0\n ? {\n type: 'element',\n name: 'properties',\n children: this._factory.makeForProperty().normalizeIterable(data.properties, options, 'property')\n }\n : undefined\n return {\n type: 'element',\n name: elementName,\n children: [\n makeOptionalDateTimeElement(data.timestamp, 'timestamp'),\n lifecycles,\n tools,\n authors,\n data.component === undefined\n ? undefined\n : this._factory.makeForComponent().normalize(data.component, options, 'component'),\n data.manufacture === undefined\n ? undefined\n : orgEntityNormalizer.normalize(data.manufacture, options, 'manufacture'),\n data.supplier === undefined\n ? undefined\n : orgEntityNormalizer.normalize(data.supplier, options, 'supplier'),\n licenses,\n properties\n ].filter(isNotUndefined)\n }\n }\n}\n\nexport class LifecycleNormalizer extends BaseXmlNormalizer<Models.Lifecycle> {\n normalize (data: Models.Lifecycle, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n return data instanceof NamedLifecycle\n ? {\n type: 'element',\n name: elementName,\n children: [\n makeTextElement(data.name, 'name'),\n makeOptionalTextElement(data.description, 'description')\n ].filter(isNotUndefined)\n }\n : {\n type: 'element',\n name: elementName,\n children: [\n makeTextElement(data, 'phase')\n ]\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Lifecycle>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(t => this.normalize(t, options, elementName))\n }\n}\n\nexport class ToolNormalizer extends BaseXmlNormalizer<Models.Tool> {\n normalize (data: Models.Tool, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const hashes: SimpleXml.Element | undefined = data.hashes.size > 0\n ? {\n type: 'element',\n name: 'hashes',\n children: this._factory.makeForHash().normalizeIterable(data.hashes, options, 'hash')\n }\n : undefined\n const externalReferences: SimpleXml.Element | undefined =\n this._factory.spec.supportsToolReferences && data.externalReferences.size > 0\n ? {\n type: 'element',\n name: 'externalReferences',\n children: this._factory.makeForExternalReference().normalizeIterable(data.externalReferences, options, 'reference')\n }\n : undefined\n return {\n type: 'element',\n name: elementName,\n children: [\n makeOptionalTextElement(data.vendor, 'vendor'),\n makeOptionalTextElement(data.name, 'name'),\n makeOptionalTextElement(data.version, 'version'),\n hashes,\n externalReferences\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Tool>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(t => this.normalize(t, options, elementName))\n }\n}\n\nexport class HashNormalizer extends BaseXmlNormalizer<Models.Hash> {\n normalize ([algorithm, content]: Models.Hash, options: NormalizerOptions, elementName: string): SimpleXml.Element | undefined {\n const spec = this._factory.spec\n return spec.supportsHashAlgorithm(algorithm) && spec.supportsHashValue(content)\n ? {\n type: 'element',\n name: elementName,\n attributes: { alg: algorithm },\n children: content\n }\n : undefined\n }\n\n normalizeIterable (data: SortableIterable<Models.Hash>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n h => this.normalize(h, options, elementName)\n ).filter(isNotUndefined)\n }\n}\n\nexport class OrganizationalContactNormalizer extends BaseXmlNormalizer<Models.OrganizationalContact> {\n normalize (data: Models.OrganizationalContact, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n children: [\n makeOptionalTextElement(data.name, 'name'),\n makeOptionalTextElement(data.email, 'email'),\n makeOptionalTextElement(data.phone, 'phone')\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.OrganizationalContact>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(oc => this.normalize(oc, options, elementName))\n }\n}\n\nexport class OrganizationalEntityNormalizer extends BaseXmlNormalizer<Models.OrganizationalEntity> {\n normalize (data: Models.OrganizationalEntity, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n children: [\n makeOptionalTextElement(data.name, 'name'),\n ...makeTextElementIter(Array.from(\n data.url, (s): string => escapeUri(s.toString())\n ), options, 'url'\n ).filter(({ children: u }) => XmlSchema.isAnyURI(u)),\n ...this._factory.makeForOrganizationalContact().normalizeIterable(data.contact, options, 'contact')\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.OrganizationalEntity>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(oe => this.normalize(oe, options, elementName))\n }\n}\n\nexport class ComponentNormalizer extends BaseXmlNormalizer<Models.Component> {\n normalize (data: Models.Component, options: NormalizerOptions, elementName: string): SimpleXml.Element | undefined {\n const spec = this._factory.spec\n if (!spec.supportsComponentType(data.type)) {\n return undefined\n }\n const supplier: SimpleXml.Element | undefined = data.supplier === undefined\n ? undefined\n : this._factory.makeForOrganizationalEntity().normalize(data.supplier, options, 'supplier')\n const version: SimpleXml.Element | undefined = (\n spec.requiresComponentVersion\n ? makeTextElement\n : makeOptionalTextElement\n )(\n data.version ?? '',\n 'version'\n )\n const hashes: SimpleXml.Element | undefined = data.hashes.size > 0\n ? {\n type: 'element',\n name: 'hashes',\n children: this._factory.makeForHash().normalizeIterable(data.hashes, options, 'hash')\n }\n : undefined\n const licenses: SimpleXml.Element | undefined = data.licenses.size > 0\n ? {\n type: 'element',\n name: 'licenses',\n children: this._factory.makeForLicense().normalizeIterable(data.licenses, options)\n }\n : undefined\n const swid: SimpleXml.Element | undefined = data.swid === undefined\n ? undefined\n : this._factory.makeForSWID().normalize(data.swid, options, 'swid')\n const extRefs: SimpleXml.Element | undefined = data.externalReferences.size > 0\n ? {\n type: 'element',\n name: 'externalReferences',\n children: this._factory.makeForExternalReference().normalizeIterable(data.externalReferences, options, 'reference')\n }\n : undefined\n const properties: SimpleXml.Element | undefined = spec.supportsProperties(data) && data.properties.size > 0\n ? {\n type: 'element',\n name: 'properties',\n children: this._factory.makeForProperty().normalizeIterable(data.properties, options, 'property')\n }\n : undefined\n const components: SimpleXml.Element | undefined = data.components.size > 0\n ? {\n type: 'element',\n name: 'components',\n children: this.normalizeIterable(data.components, options, 'component')\n }\n : undefined\n const evidence: SimpleXml.Element | undefined = spec.supportsComponentEvidence && data.evidence !== undefined\n ? this._factory.makeForComponentEvidence().normalize(data.evidence, options, 'evidence')\n : undefined\n return {\n type: 'element',\n name: elementName,\n attributes: {\n type: data.type,\n 'bom-ref': data.bomRef.value\n },\n children: [\n supplier,\n makeOptionalTextElement(data.author, 'author'),\n makeOptionalTextElement(data.publisher, 'publisher'),\n makeOptionalTextElement(data.group, 'group'),\n makeTextElement(data.name, 'name'),\n version,\n makeOptionalTextElement(data.description, 'description'),\n makeOptionalTextElement(data.scope, 'scope'),\n hashes,\n licenses,\n makeOptionalTextElement(data.copyright, 'copyright'),\n makeOptionalTextElement(data.cpe, 'cpe'),\n makeOptionalTextElement(data.purl, 'purl'),\n swid,\n extRefs,\n properties,\n components,\n evidence\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Component>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n c => this.normalize(c, options, elementName)\n ).filter(isNotUndefined)\n }\n}\n\nexport class ComponentEvidenceNormalizer extends BaseXmlNormalizer<Models.ComponentEvidence> {\n normalize (data: Models.ComponentEvidence, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const licenses: SimpleXml.Element | undefined = data.licenses.size > 0\n ? {\n type: 'element',\n name: 'licenses',\n children: this._factory.makeForLicense().normalizeIterable(data.licenses, options)\n }\n : undefined\n const copyright: SimpleXml.Element | undefined = data.copyright.size > 0\n ? {\n type: 'element',\n name: 'copyright',\n children: makeTextElementIter(data.copyright, options, 'text')\n }\n : undefined\n return {\n type: 'element',\n name: elementName,\n children: [\n licenses,\n copyright\n ].filter(isNotUndefined)\n }\n }\n}\n\nexport class LicenseNormalizer extends BaseXmlNormalizer<Models.License> {\n normalize (data: Models.License, options: NormalizerOptions): SimpleXml.Element {\n switch (true) {\n case data instanceof NamedLicense:\n return this.#normalizeNamedLicense(data, options)\n case data instanceof SpdxLicense:\n return isSupportedSpdxId(data.id)\n ? this.#normalizeSpdxLicense(data, options)\n : this.#normalizeNamedLicense(new NamedLicense(\n // prevent information loss -> convert to broader type\n data.id,\n { url: data.url }\n ), options)\n case data instanceof LicenseExpression:\n return this.#normalizeLicenseExpression(data)\n /* c8 ignore start */\n default:\n // this case is expected to never happen - and therefore is undocumented\n throw new TypeError('Unexpected LicenseChoice')\n /* c8 ignore end */\n }\n }\n\n #normalizeNamedLicense (data: Models.NamedLicense, options: NormalizerOptions): SimpleXml.Element {\n const url = escapeUri(data.url?.toString())\n return {\n type: 'element',\n name: 'license',\n attributes: {\n acknowledgement: this._factory.spec.supportsLicenseAcknowledgement\n ? data.acknowledgement\n : undefined\n },\n children: [\n makeTextElement(data.name, 'name'),\n data.text === undefined\n ? undefined\n : this._factory.makeForAttachment().normalize(data.text, options, 'text'),\n XmlSchema.isAnyURI(url)\n ? makeTextElement(url, 'url')\n : undefined\n ].filter(isNotUndefined)\n }\n }\n\n #normalizeSpdxLicense (data: Models.SpdxLicense, options: NormalizerOptions): SimpleXml.Element {\n const url = escapeUri(data.url?.toString())\n return {\n type: 'element',\n name: 'license',\n attributes: {\n acknowledgement: this._factory.spec.supportsLicenseAcknowledgement\n ? data.acknowledgement\n : undefined\n },\n children: [\n makeTextElement(data.id, 'id'),\n data.text === undefined\n ? undefined\n : this._factory.makeForAttachment().normalize(data.text, options, 'text'),\n XmlSchema.isAnyURI(url)\n ? makeTextElement(url, 'url')\n : undefined\n ].filter(isNotUndefined)\n }\n }\n\n #normalizeLicenseExpression (data: Models.LicenseExpression): SimpleXml.Element {\n const elem = makeTextElement(data.expression, 'expression')\n elem.attributes = {\n acknowledgement: this._factory.spec.supportsLicenseAcknowledgement\n ? data.acknowledgement\n : undefined\n }\n return elem\n }\n\n /**\n * If there is any {@link Models.LicenseExpression | LicenseExpression} in the set, then this is the only item that is normalized.\n */\n normalizeIterable (data: SortableIterable<Models.License>, options: NormalizerOptions): SimpleXml.Element[] {\n const licenses = options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n\n if (licenses.length > 1) {\n const expressions = licenses.filter(l => l instanceof LicenseExpression) as Models.LicenseExpression[]\n if (expressions.length > 0) {\n // could have thrown {@link RangeError} when there is more than one only {@link Models.LicenseExpression | LicenseExpression}.\n // but let's be graceful and just normalize to the most relevant choice: any expression\n return [this.#normalizeLicenseExpression(expressions[0])]\n }\n }\n\n return licenses.map(l => this.normalize(l, options))\n }\n}\n\nexport class SWIDNormalizer extends BaseXmlNormalizer<Models.SWID> {\n normalize (data: Models.SWID, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const url = escapeUri(data.url?.toString())\n return {\n type: 'element',\n name: elementName,\n attributes: {\n tagId: data.tagId,\n name: data.name,\n version: data.version || undefined,\n tagVersion: data.tagVersion,\n patch: data.patch === undefined\n ? undefined\n : (data.patch ? 'true' : 'false')\n },\n children: [\n data.text === undefined\n ? undefined\n : this._factory.makeForAttachment().normalize(data.text, options, 'text'),\n XmlSchema.isAnyURI(url)\n ? makeTextElement(url, 'url')\n : undefined\n ].filter(isNotUndefined)\n }\n }\n}\n\nexport class ExternalReferenceNormalizer extends BaseXmlNormalizer<Models.ExternalReference> {\n normalize (data: Models.ExternalReference, options: NormalizerOptions, elementName: string): SimpleXml.Element | undefined {\n const url = escapeUri(data.url.toString())\n const hashes: SimpleXml.Element | undefined = this._factory.spec.supportsExternalReferenceHashes && data.hashes.size > 0\n ? {\n type: 'element',\n name: 'hashes',\n children: this._factory.makeForHash().normalizeIterable(data.hashes, options, 'hash')\n }\n : undefined\n return this._factory.spec.supportsExternalReferenceType(data.type) &&\n XmlSchema.isAnyURI(url)\n ? {\n type: 'element',\n name: elementName,\n attributes: {\n type: data.type\n },\n children: [\n makeTextElement(url, 'url'),\n makeOptionalTextElement(data.comment, 'comment'),\n hashes\n ].filter(isNotUndefined)\n }\n : undefined\n }\n\n normalizeIterable (data: SortableIterable<Models.ExternalReference>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n r => this.normalize(r, options, elementName)\n ).filter(isNotUndefined)\n }\n}\n\nexport class AttachmentNormalizer extends BaseXmlNormalizer<Models.Attachment> {\n normalize (data: Models.Attachment, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n attributes: {\n 'content-type': data.contentType || undefined,\n encoding: data.encoding || undefined\n },\n children: data.content.toString()\n }\n }\n}\n\nexport class PropertyNormalizer extends BaseXmlNormalizer<Models.Property> {\n normalize (data: Models.Property, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n attributes: {\n name: data.name\n },\n children: data.value\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Property>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(p => this.normalize(p, options, elementName))\n }\n}\n\nexport class DependencyGraphNormalizer extends BaseXmlNormalizer<Models.Bom> {\n normalize (data: Models.Bom, options: NormalizerOptions, elementName: string): SimpleXml.Element | undefined {\n const allRefs = new Map<Models.BomRef, Models.BomRefRepository>()\n if (data.metadata.component !== undefined) {\n allRefs.set(data.metadata.component.bomRef, data.metadata.component.dependencies)\n for (const component of data.metadata.component.components[treeIteratorSymbol]()) {\n allRefs.set(component.bomRef, component.dependencies)\n }\n }\n for (const component of data.components[treeIteratorSymbol]()) {\n allRefs.set(component.bomRef, component.dependencies)\n }\n\n const normalized: Array<(SimpleXml.Element & { attributes: { ref: string } })> = []\n for (const [ref, deps] of allRefs) {\n const dep = this.#normalizeDependency(ref, deps, allRefs, options)\n if (isNotUndefined(dep)) {\n normalized.push(dep)\n }\n }\n\n if (options.sortLists ?? false) {\n normalized.sort(\n ({ attributes: { ref: a } }, { attributes: { ref: b } }) => a.localeCompare(b))\n }\n\n return {\n type: 'element',\n name: elementName,\n children: normalized\n }\n }\n\n #normalizeDependency (\n ref: Models.BomRef,\n deps: Models.BomRefRepository,\n allRefs: Map<Models.BomRef, Models.BomRefRepository>,\n options: NormalizerOptions\n ): undefined | (SimpleXml.Element & { attributes: { ref: string } }) {\n const bomRef = ref.toString()\n if (bomRef.length === 0) {\n // no value -> cannot render\n return undefined\n }\n\n const dependsOn: string[] = Array.from(deps).filter(d => allRefs.has(d) && d !== ref)\n .map(d => d.toString()).filter(d => d.length > 0)\n if (options.sortLists ?? false) {\n dependsOn.sort((a, b) => a.localeCompare(b))\n }\n\n return {\n type: 'element',\n name: 'dependency',\n attributes: { ref: bomRef },\n children: dependsOn.map(d => ({\n type: 'element',\n name: 'dependency',\n attributes: { ref: d }\n }))\n }\n }\n}\n\nexport class VulnerabilityNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Vulnerability> {\n normalize (data: Models.Vulnerability.Vulnerability, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const references: SimpleXml.Element | undefined = data.references.size > 0\n ? {\n type: 'element',\n name: 'references',\n children: this._factory.makeForVulnerabilityReference().normalizeIterable(data.references, options, 'reference')\n }\n : undefined\n const ratings: SimpleXml.Element | undefined = data.ratings.size > 0\n ? {\n type: 'element',\n name: 'ratings',\n children: this._factory.makeForVulnerabilityRating().normalizeIterable(data.ratings, options, 'rating')\n }\n : undefined\n const cwes: SimpleXml.Element | undefined = data.cwes.size > 0\n ? {\n type: 'element',\n name: 'cwes',\n children: (\n options.sortLists\n ? data.cwes.sorted()\n : Array.from(data.cwes)\n ).map(cwe => makeTextElement(cwe, 'cwe'))\n }\n : undefined\n const advisories: SimpleXml.Element | undefined = data.advisories.size > 0\n ? {\n type: 'element',\n name: 'advisories',\n children: this._factory.makeForVulnerabilityAdvisory().normalizeIterable(data.advisories, options, 'advisory')\n }\n : undefined\n const tools: SimpleXml.Element | undefined = data.tools.size > 0\n ? {\n type: 'element',\n name: 'tools',\n children: this._factory.makeForTool().normalizeIterable(data.tools, options, 'tool')\n }\n : undefined\n const affects: SimpleXml.Element | undefined = data.affects.size > 0\n ? {\n type: 'element',\n name: 'affects',\n children: this._factory.makeForVulnerabilityAffect().normalizeIterable(data.affects, options, 'target')\n }\n : undefined\n const properties: SimpleXml.Element | undefined = data.properties.size > 0\n ? {\n type: 'element',\n name: 'properties',\n children: this._factory.makeForProperty().normalizeIterable(data.properties, options, 'property')\n }\n : undefined\n return {\n type: 'element',\n name: elementName,\n attributes: { 'bom-ref': data.bomRef.value || undefined },\n children: [\n makeOptionalTextElement(data.id, 'id'),\n data.source === undefined\n ? undefined\n : this._factory.makeForVulnerabilitySource().normalize(data.source, options, 'source'),\n references,\n ratings,\n cwes,\n makeOptionalTextElement(data.description, 'description'),\n makeOptionalTextElement(data.detail, 'detail'),\n makeOptionalTextElement(data.recommendation, 'recommendation'),\n advisories,\n makeOptionalDateTimeElement(data.created, 'created'),\n makeOptionalDateTimeElement(data.created, 'published'),\n makeOptionalDateTimeElement(data.created, 'updated'),\n data.credits === undefined\n ? undefined\n : this._factory.makeForVulnerabilityCredits().normalize(data.credits, options, 'credits'),\n tools,\n data.analysis === undefined\n ? undefined\n : this._factory.makeForVulnerabilityAnalysis().normalize(data.analysis, options, 'analysis'),\n affects,\n properties\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Vulnerability>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(v => this.normalize(v, options, elementName))\n }\n}\n\nexport class VulnerabilitySourceNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Source> {\n normalize (data: Models.Vulnerability.Source, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const url = escapeUri(data.url?.toString())\n return {\n type: 'element',\n name: elementName,\n children: [\n makeOptionalTextElement(data.name, 'name'),\n XmlSchema.isAnyURI(url)\n ? makeTextElement(url, 'url')\n : undefined\n ].filter(isNotUndefined)\n }\n }\n}\n\nexport class VulnerabilityReferenceNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Reference> {\n normalize (data: Models.Vulnerability.Reference, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n children: [\n makeTextElement(data.id, 'id'),\n this._factory.makeForVulnerabilitySource().normalize(data.source, options, 'source')\n ]\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Reference>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(r => this.normalize(r, options, elementName))\n }\n}\n\nexport class VulnerabilityRatingNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Rating> {\n normalize (data: Models.Vulnerability.Rating, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n children: [\n data.source === undefined\n ? undefined\n : this._factory.makeForVulnerabilitySource().normalize(data.source, options, 'source'),\n makeOptionalTextElement(data.score, 'score'),\n makeOptionalTextElement(data.severity, 'severity'),\n this._factory.spec.supportsVulnerabilityRatingMethod(data.method)\n ? makeOptionalTextElement(data.method, 'method')\n : undefined,\n makeOptionalTextElement(data.vector, 'vector'),\n makeOptionalTextElement(data.justification, 'justification')\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Rating>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(r => this.normalize(r, options, elementName))\n }\n}\n\nexport class VulnerabilityAdvisoryNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Advisory> {\n normalize (data: Models.Vulnerability.Advisory, options: NormalizerOptions, elementName: string): SimpleXml.Element | undefined {\n const url = escapeUri(data.url.toString())\n if (!XmlSchema.isAnyURI(url)) {\n // invalid value -> cannot render\n return undefined\n }\n return {\n type: 'element',\n name: elementName,\n children: [\n makeOptionalTextElement(data.title, 'title'),\n makeTextElement(url, 'url')\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Advisory>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(\n a => this.normalize(a, options, elementName)\n ).filter(isNotUndefined)\n }\n}\n\nexport class VulnerabilityCreditsNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Credits> {\n normalize (data: Models.Vulnerability.Credits, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const organizations: SimpleXml.Element | undefined = data.organizations.size > 0\n ? {\n type: 'element',\n name: 'organizations',\n children: this._factory.makeForOrganizationalEntity().normalizeIterable(data.organizations, options, 'organization')\n }\n : undefined\n const individuals: SimpleXml.Element | undefined = data.individuals.size > 0\n ? {\n type: 'element',\n name: 'individuals',\n children: this._factory.makeForOrganizationalContact().normalizeIterable(data.individuals, options, 'individual')\n }\n : undefined\n return {\n type: 'element',\n name: elementName,\n children: [\n organizations,\n individuals\n ].filter(isNotUndefined)\n }\n }\n}\n\nexport class VulnerabilityAnalysisNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Analysis> {\n normalize (data: Models.Vulnerability.Analysis, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const responses: SimpleXml.Element | undefined = data.response.size > 0\n ? {\n type: 'element',\n name: 'responses',\n children: (\n options.sortLists ?? false\n ? data.response.sorted()\n : Array.from(data.response)\n ).map(ar => makeTextElement(ar, 'response'))\n }\n : undefined\n return {\n type: 'element',\n name: elementName,\n children: [\n makeOptionalTextElement(data.state, 'state'),\n makeOptionalTextElement(data.justification, 'justification'),\n responses,\n makeOptionalTextElement(data.detail, 'detail')\n ].filter(isNotUndefined)\n }\n }\n}\n\nexport class VulnerabilityAffectNormalizer extends BaseXmlNormalizer<Models.Vulnerability.Affect> {\n normalize (data: Models.Vulnerability.Affect, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n const versions: SimpleXml.Element | undefined = data.versions.size > 0\n ? {\n type: 'element',\n name: 'versions',\n children: this._factory.makeForVulnerabilityAffectedVersion().normalizeIterable(data.versions, options, 'version')\n }\n : undefined\n return {\n type: 'element',\n name: elementName,\n children: [\n makeTextElement(data.ref, 'ref'),\n versions\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.Affect>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(a => this.normalize(a, options, elementName))\n }\n}\n\nexport class VulnerabilityAffectedVersionNormalizer extends BaseXmlNormalizer<Models.Vulnerability.AffectedVersion> {\n normalize (data: Models.Vulnerability.AffectedVersion, options: NormalizerOptions, elementName: string): SimpleXml.Element {\n switch (true) {\n case data instanceof AffectedSingleVersion:\n return this.#normalizeAffectedSingleVersion(data, elementName)\n case data instanceof AffectedVersionRange:\n return this.#normalizeAffectedVersionRange(data, elementName)\n /* c8 ignore start */\n default:\n // this case is expected to never happen - and therefore is undocumented\n throw new TypeError('Unexpected Vulnerability AffectedVersion')\n /* c8 ignore end */\n }\n }\n\n #normalizeAffectedSingleVersion (data: Models.Vulnerability.AffectedSingleVersion, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n children: [\n makeTextElement(data.version, 'version'),\n makeOptionalTextElement(data.status, 'status')\n ].filter(isNotUndefined)\n }\n }\n\n #normalizeAffectedVersionRange (data: Models.Vulnerability.AffectedVersionRange, elementName: string): SimpleXml.Element {\n return {\n type: 'element',\n name: elementName,\n children: [\n makeTextElement(data.range, 'range'),\n makeOptionalTextElement(data.status, 'status')\n ].filter(isNotUndefined)\n }\n }\n\n normalizeIterable (data: SortableIterable<Models.Vulnerability.AffectedVersion>, options: NormalizerOptions, elementName: string): SimpleXml.Element[] {\n return (\n options.sortLists ?? false\n ? data.sorted()\n : Array.from(data)\n ).map(av => this.normalize(av, options, elementName))\n }\n}\n\n/* eslint-enable @typescript-eslint/prefer-nullish-coalescing, @typescript-eslint/strict-boolean-expressions */\n\ntype StrictTextElement = SimpleXml.TextElement & { children: string }\n\nfunction makeOptionalTextElement (data: null | undefined | Stringable, elementName: string): undefined | StrictTextElement {\n const s = data?.toString() ?? ''\n return s.length > 0\n ? makeTextElement(s, elementName)\n : undefined\n}\n\nfunction makeTextElement (data: Stringable, elementName: string): StrictTextElement {\n return {\n type: 'element',\n name: elementName,\n children: data.toString()\n }\n}\n\nfunction makeTextElementIter (data: Iterable<Stringable>, options: NormalizerOptions, elementName: string): StrictTextElement[] {\n const r: StrictTextElement[] = Array.from(data, d => makeTextElement(d, elementName))\n if (options.sortLists ?? false) {\n r.sort(({ children: a }, { children: b }) => a.localeCompare(b))\n }\n return r\n}\n\nfunction makeOptionalDateTimeElement (data: null | undefined | Date, elementName: string): undefined | StrictTextElement {\n const d = data?.toISOString()\n return d === undefined\n ? undefined\n : makeTextElement(d, elementName)\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport namespace XmlSchema {\n\n const _AnyUriSchemePattern = /^[a-z][a-z0-9+\\-.]*$/i\n\n /**\n * @see {@link isAnyURI}\n */\n export type AnyURI = string\n\n /**\n * Test whether format is XML::anyURI - best-effort.\n *\n * @see {@link http://www.w3.org/TR/xmlschema-2/#anyURI | anyURI spec}\n * @see {@link https://www.w3.org/2011/04/XMLSchema/TypeLibrary-URI-RFC3986.xsd | RFC 3986}\n * @see {@link https://www.w3.org/2011/04/XMLSchema/TypeLibrary-IRI-RFC3987.xsd | RFC 3987}\n *\n * @TODO add more validation according to spec\n */\n export function isAnyURI (value: AnyURI | any): value is AnyURI {\n if (typeof value !== 'string') {\n // not a string\n return false\n }\n if (value.length === 0) {\n // empty string\n return false\n }\n\n const fragmentPos = value.indexOf('#')\n let beforeFragment: string\n if (fragmentPos >= 0) {\n if (value.includes('#', fragmentPos + 1)) {\n // has a second fragment marker\n return false\n }\n beforeFragment = value.slice(undefined, fragmentPos)\n } else {\n beforeFragment = value\n }\n\n const schemePos = beforeFragment.indexOf(':')\n if (schemePos >= 0) {\n if (!_AnyUriSchemePattern.test(beforeFragment.slice(undefined, schemePos))) {\n // invalid schema\n return false\n }\n }\n\n return true\n }\n\n}\n\n// eslint-disable-next-line @typescript-eslint/no-namespace\nexport namespace SimpleXml {\n\n /**\n * Attribute's name.\n *\n * Must be alphanumeric.\n * Must start with alpha.\n * Must not contain whitespace characters.\n * Should not be literal \"xmlns\".\n */\n export type AttributeName = string\n\n /**\n * Element's name.\n *\n * Must be alphanumeric.\n * Must start with alpha.\n * Must not contain whitespace characters.\n */\n export type ElementName = string\n\n /**\n * Textual representation.\n *\n * Be aware that low-/high-bytes could be represented as numbers.\n * They might need to be converted on serialization.\n */\n export type Text = string | number\n\n /**\n * Unset representation.\n *\n * Do NOT allow null here, as it is context-aware sometimes an empty string or unset,\n * in a space where context is unknown.\n */\n export type Unset = undefined\n\n export type ElementAttributes = Record<AttributeName, Text | Unset>\n\n export type ElementChildren = Iterable<Comment | Element> | Text | Unset\n\n /**\n * Element node.\n */\n export interface Element {\n type: 'element'\n name: ElementName\n namespace?: string | URL\n attributes?: ElementAttributes\n children?: ElementChildren\n }\n\n /**\n * Element node with textual content\n */\n export interface TextElement extends Element {\n children: Text\n }\n\n /**\n * Comment node.\n */\n export interface Comment {\n type: 'comment'\n text?: Text\n }\n\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Bom } from '../models'\nimport { Format } from '../spec/enums'\nimport { UnsupportedFormatError } from '../spec/errors'\nimport { BaseSerializer } from './baseSerializer'\nimport type { NormalizerOptions } from './types'\nimport type { Factory as NormalizerFactory } from './xml/normalize'\nimport type { SimpleXml } from './xml/types'\n\n/**\n * Base XML serializer.\n */\nexport abstract class XmlBaseSerializer extends BaseSerializer<SimpleXml.Element> {\n readonly #normalizerFactory: NormalizerFactory\n\n /**\n * @throws {@link UnsupportedFormatError} if `normalizerFactory.spec` does not support {@link Format.XML}.\n */\n constructor (normalizerFactory: XmlBaseSerializer['normalizerFactory']) {\n if (!normalizerFactory.spec.supportsFormat(Format.XML)) {\n throw new UnsupportedFormatError('Spec does not support XML format.')\n }\n\n super()\n this.#normalizerFactory = normalizerFactory\n }\n\n get normalizerFactory (): NormalizerFactory {\n return this.#normalizerFactory\n }\n\n protected _normalize (\n bom: Bom,\n options: NormalizerOptions = {}\n ): SimpleXml.Element {\n return this.#normalizerFactory.makeForBom()\n .normalize(bom, options)\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { isNotUndefined } from '../_helpers/notUndefined'\nimport type { SerializerOptions } from './types'\nimport type { SimpleXml } from './xml/types'\nimport { XmlBaseSerializer } from './xmlBaseSerializer'\n\n/**\n * XML serializer for web browsers.\n */\nexport class XmlSerializer extends XmlBaseSerializer {\n protected _serialize (\n normalizedBom: SimpleXml.Element,\n { space }: SerializerOptions = {}\n ): string {\n const doc = this.#buildXmlDocument(normalizedBom)\n // @TODO: add indention based on `space`\n return (new XMLSerializer()).serializeToString(doc)\n }\n\n #buildXmlDocument (\n rootElement: SimpleXml.Element\n ): XMLDocument {\n const namespace = null\n const doc = document.implementation.createDocument(namespace, null)\n doc.appendChild(this.#buildElement(rootElement, doc, namespace))\n return doc\n }\n\n #getNS (element: SimpleXml.Element): string | null {\n const ns = (element.namespace ?? element.attributes?.xmlns)?.toString() ?? ''\n return ns.length > 0\n ? ns\n : null\n }\n\n #buildElement (element: SimpleXml.Element, doc: XMLDocument, parentNS: string | null): Element {\n const ns = this.#getNS(element) ?? parentNS\n const node: Element = doc.createElementNS(ns, element.name)\n if (isNotUndefined(element.attributes)) {\n this.#setAttributes(node, element.attributes)\n }\n if (isNotUndefined(element.children)) {\n this.#addChildren(node, element.children, ns)\n }\n return node\n }\n\n #setAttributes (node: Element, attributes: SimpleXml.ElementAttributes): void {\n for (const [name, value] of Object.entries(attributes)) {\n if (isNotUndefined(value) && name !== 'xmlns') {\n // reminder: cannot change a namespace(xmlns) after the fact.\n node.setAttribute(name, `${value}`)\n }\n }\n }\n\n #addChildren (node: Element, children: SimpleXml.ElementChildren, parentNS: string | null = null): void {\n if (children === undefined) {\n return\n }\n\n if (typeof children === 'string' || typeof children === 'number') {\n node.textContent = children.toString()\n return\n }\n\n const doc = node.ownerDocument\n for (const child of children) {\n if (child.type === 'element') {\n node.appendChild(this.#buildElement(child, doc, parentNS))\n }\n // comments are not implemented, yet\n }\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport * as spdxExpressionParse from 'spdx-expression-parse'\n\n/* @ts-expect-error: TS6059 -- this works as long as the file/path is available in dist-package. */\nimport { enum as _spdxSpecEnum } from '../res/schema/spdx.SNAPSHOT.schema.json' with { type: 'json' }\n\n/**\n * One of the known SPDX licence identifiers.\n *\n * @see {@link http://cyclonedx.org/schema/spdx | SPDX schema}\n * @see {@link isSupportedSpdxId}\n * @see {@link fixupSpdxId}\n */\nexport type SpdxId = string\n\nconst spdxIds: ReadonlySet<SpdxId> = new Set(_spdxSpecEnum)\n\nconst spdxLowerToActual: Readonly<Record<string, SpdxId>> = Object.freeze(Object.fromEntries(\n _spdxSpecEnum.map(spdxId => [spdxId.toLowerCase(), spdxId])\n))\n\nexport function isSupportedSpdxId (value: SpdxId | any): value is SpdxId {\n /* eslint-disable-next-line @typescript-eslint/no-unsafe-argument */\n return spdxIds.has(value)\n}\n\n/** Try to convert a `string`-like to a valid/known {@link SpdxId}. */\nexport function fixupSpdxId (value: string | any): SpdxId | undefined {\n return typeof value === 'string' && value.length > 0\n ? spdxLowerToActual[value.toLowerCase()]\n : undefined\n}\n\nexport function isValidSpdxLicenseExpression (value: string | any): boolean {\n if (typeof value !== 'string') {\n return false\n }\n try {\n spdxExpressionParse(value)\n } catch (err) {\n return false\n }\n return true\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { ComponentType, ExternalReferenceType, HashAlgorithm, Vulnerability } from '../enums'\nimport type { HashContent } from '../models'\nimport type { Format, Version } from './enums'\n\n/**\n * This interface is not intended to be public API.\n * This interface may be affected by breaking changes without notice.\n *\n * See the public exported constants, like {@link Spec.Spec1dot4}, that provide objects implementing this interface.\n * See also {@link Spec.SpecVersionDict} for implementations.\n */\nexport interface _SpecProtocol {\n version: Version\n supportsFormat: (f: Format | any) => boolean\n supportsComponentType: (ct: ComponentType | any) => boolean\n supportsHashAlgorithm: (ha: HashAlgorithm | any) => boolean\n supportsHashValue: (hv: HashContent | any) => boolean\n supportsExternalReferenceType: (ert: ExternalReferenceType | any) => boolean\n supportsDependencyGraph: boolean\n supportsToolReferences: boolean\n requiresComponentVersion: boolean\n supportsProperties: (model: any) => boolean\n supportsVulnerabilities: boolean\n supportsVulnerabilityRatingMethod: (rm: Vulnerability.RatingMethod | any) => boolean\n supportsComponentEvidence: boolean\n supportsMetadataLifecycles: boolean\n supportsMetadataLicenses: boolean\n supportsMetadataProperties: boolean\n supportsExternalReferenceHashes: boolean\n supportsLicenseAcknowledgement: boolean\n}\n\n/**\n * This class was never intended to be public API,\n *\n * This is a helper to get the exact spec-versions implemented according to {@link _SpecProtocol | Specification}.\n *\n * @internal as this class may be affected by breaking changes without notice\n */\nexport class _Spec implements _SpecProtocol {\n readonly #version: Version\n readonly #formats: ReadonlySet<Format>\n readonly #componentTypes: ReadonlySet<ComponentType>\n readonly #hashAlgorithms: ReadonlySet<HashAlgorithm>\n readonly #hashValuePattern: RegExp\n readonly #externalReferenceTypes: ReadonlySet<ExternalReferenceType>\n readonly #vulnerabilityRatingMethods: ReadonlySet<Vulnerability.RatingMethod>\n readonly #supportsDependencyGraph: boolean\n readonly #supportsToolReferences: boolean\n readonly #requiresComponentVersion: boolean\n readonly #supportsProperties: boolean\n readonly #supportsVulnerabilities: boolean\n readonly #supportsComponentEvidence: boolean\n readonly #supportsMetadataLifecycles: boolean\n readonly #supportsMetadataLicenses: boolean\n readonly #supportsMetadataProperties: boolean\n readonly #supportsExternalReferenceHashes: boolean\n readonly #supportsLicenseAcknowledgement: boolean\n\n constructor (\n version: Version,\n formats: Iterable<Format>,\n componentTypes: Iterable<ComponentType>,\n hashAlgorithms: Iterable<HashAlgorithm>,\n hashValuePattern: RegExp,\n externalReferenceTypes: Iterable<ExternalReferenceType>,\n supportsDependencyGraph: boolean,\n supportsToolReferences: boolean,\n requiresComponentVersion: boolean,\n supportsProperties: boolean,\n supportsVulnerabilities: boolean,\n vulnerabilityRatingMethods: Iterable<Vulnerability.RatingMethod>,\n supportsComponentEvidence: boolean,\n supportsMetadataLifecycles: boolean,\n supportsMetadataLicenses: boolean,\n supportsMetadataProperties: boolean,\n supportsExternalReferenceHashes: boolean,\n supportsLicenseAcknowledgement: boolean\n ) {\n this.#version = version\n this.#formats = new Set(formats)\n this.#componentTypes = new Set(componentTypes)\n this.#hashAlgorithms = new Set(hashAlgorithms)\n this.#hashValuePattern = hashValuePattern\n this.#externalReferenceTypes = new Set(externalReferenceTypes)\n this.#supportsDependencyGraph = supportsDependencyGraph\n this.#supportsToolReferences = supportsToolReferences\n this.#requiresComponentVersion = requiresComponentVersion\n this.#supportsProperties = supportsProperties\n this.#supportsVulnerabilities = supportsVulnerabilities\n this.#vulnerabilityRatingMethods = new Set(vulnerabilityRatingMethods)\n this.#supportsComponentEvidence = supportsComponentEvidence\n this.#supportsMetadataLifecycles = supportsMetadataLifecycles\n this.#supportsMetadataLicenses = supportsMetadataLicenses\n this.#supportsMetadataProperties = supportsMetadataProperties\n this.#supportsExternalReferenceHashes = supportsExternalReferenceHashes\n this.#supportsLicenseAcknowledgement = supportsLicenseAcknowledgement\n }\n\n get version (): Version {\n return this.#version\n }\n\n supportsFormat (f: Format | any): boolean {\n /* eslint-disable-next-line @typescript-eslint/no-unsafe-argument */\n return this.#formats.has(f)\n }\n\n supportsComponentType (ct: ComponentType | any): boolean {\n /* eslint-disable-next-line @typescript-eslint/no-unsafe-argument */\n return this.#componentTypes.has(ct)\n }\n\n supportsHashAlgorithm (ha: HashAlgorithm | any): boolean {\n /* eslint-disable-next-line @typescript-eslint/no-unsafe-argument */\n return this.#hashAlgorithms.has(ha)\n }\n\n supportsHashValue (hv: HashContent | any): boolean {\n return typeof hv === 'string' &&\n this.#hashValuePattern.test(hv)\n }\n\n supportsExternalReferenceType (ert: ExternalReferenceType | any): boolean {\n /* eslint-disable-next-line @typescript-eslint/no-unsafe-argument */\n return this.#externalReferenceTypes.has(ert)\n }\n\n get supportsDependencyGraph (): boolean {\n return this.#supportsDependencyGraph\n }\n\n get supportsToolReferences (): boolean {\n return this.#supportsToolReferences\n }\n\n get requiresComponentVersion (): boolean {\n return this.#requiresComponentVersion\n }\n\n supportsProperties (): boolean {\n // currently a global allow/deny -- might work based on input, in the future\n return this.#supportsProperties\n }\n\n get supportsVulnerabilities (): boolean {\n return this.#supportsVulnerabilities\n }\n\n supportsVulnerabilityRatingMethod (rm: Vulnerability.RatingMethod | any): boolean {\n /* eslint-disable-next-line @typescript-eslint/no-unsafe-argument */\n return this.#vulnerabilityRatingMethods.has(rm)\n }\n\n get supportsComponentEvidence (): boolean {\n return this.#supportsComponentEvidence\n }\n\n get supportsMetadataLifecycles (): boolean {\n return this.#supportsMetadataLifecycles\n }\n\n get supportsMetadataLicenses (): boolean {\n return this.#supportsMetadataLicenses\n }\n\n get supportsMetadataProperties (): boolean {\n return this.#supportsMetadataProperties\n }\n\n get supportsExternalReferenceHashes (): boolean {\n return this.#supportsExternalReferenceHashes\n }\n\n get supportsLicenseAcknowledgement (): boolean {\n return this.#supportsLicenseAcknowledgement\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { ComponentType } from '../enums/componentType'\nimport { ExternalReferenceType } from '../enums/externalReferenceType'\nimport { HashAlgorithm } from '../enums/hashAlogorithm'\nimport { RatingMethod as VulnerabilityRatingMethod } from '../enums/vulnerability/ratingMethod'\nimport type { _SpecProtocol } from './_protocol'\nimport { _Spec } from './_protocol'\nimport { Format, Version } from './enums'\n\n/** Specification v1.2 */\nexport const Spec1dot2: Readonly<_SpecProtocol> = Object.freeze(new _Spec(\n Version.v1dot2,\n [\n Format.XML,\n Format.JSON\n ],\n [\n ComponentType.Application,\n ComponentType.Framework,\n ComponentType.Library,\n ComponentType.Container,\n ComponentType.OperatingSystem,\n ComponentType.Device,\n ComponentType.Firmware,\n ComponentType.File\n ],\n [\n HashAlgorithm.MD5,\n HashAlgorithm['SHA-1'],\n HashAlgorithm['SHA-256'],\n HashAlgorithm['SHA-384'],\n HashAlgorithm['SHA-512'],\n HashAlgorithm['SHA3-256'],\n HashAlgorithm['SHA3-384'],\n HashAlgorithm['SHA3-512'],\n HashAlgorithm['BLAKE2b-256'],\n HashAlgorithm['BLAKE2b-384'],\n HashAlgorithm['BLAKE2b-512'],\n HashAlgorithm.BLAKE3\n ],\n /^([a-fA-F0-9]{32})$|^([a-fA-F0-9]{40})$|^([a-fA-F0-9]{64})$|^([a-fA-F0-9]{96})$|^([a-fA-F0-9]{128})$/,\n [\n ExternalReferenceType.VCS,\n ExternalReferenceType.IssueTracker,\n ExternalReferenceType.Website,\n ExternalReferenceType.Advisories,\n ExternalReferenceType.BOM,\n ExternalReferenceType.MailingList,\n ExternalReferenceType.Social,\n ExternalReferenceType.Chat,\n ExternalReferenceType.Documentation,\n ExternalReferenceType.Support,\n ExternalReferenceType.Distribution,\n ExternalReferenceType.License,\n ExternalReferenceType.BuildMeta,\n ExternalReferenceType.BuildSystem,\n ExternalReferenceType.Other\n ],\n true,\n false,\n true,\n false,\n false,\n [],\n false,\n false,\n false,\n false,\n false,\n false\n))\n\n/** Specification v1.3 */\nexport const Spec1dot3: Readonly<_SpecProtocol> = Object.freeze(new _Spec(\n Version.v1dot3,\n [\n Format.XML,\n Format.JSON\n ],\n [\n ComponentType.Application,\n ComponentType.Framework,\n ComponentType.Library,\n ComponentType.Container,\n ComponentType.OperatingSystem,\n ComponentType.Device,\n ComponentType.Firmware,\n ComponentType.File\n ],\n [\n HashAlgorithm.MD5,\n HashAlgorithm['SHA-1'],\n HashAlgorithm['SHA-256'],\n HashAlgorithm['SHA-384'],\n HashAlgorithm['SHA-512'],\n HashAlgorithm['SHA3-256'],\n HashAlgorithm['SHA3-384'],\n HashAlgorithm['SHA3-512'],\n HashAlgorithm['BLAKE2b-256'],\n HashAlgorithm['BLAKE2b-384'],\n HashAlgorithm['BLAKE2b-512'],\n HashAlgorithm.BLAKE3\n ],\n /^([a-fA-F0-9]{32})$|^([a-fA-F0-9]{40})$|^([a-fA-F0-9]{64})$|^([a-fA-F0-9]{96})$|^([a-fA-F0-9]{128})$/,\n [\n ExternalReferenceType.VCS,\n ExternalReferenceType.IssueTracker,\n ExternalReferenceType.Website,\n ExternalReferenceType.Advisories,\n ExternalReferenceType.BOM,\n ExternalReferenceType.MailingList,\n ExternalReferenceType.Social,\n ExternalReferenceType.Chat,\n ExternalReferenceType.Documentation,\n ExternalReferenceType.Support,\n ExternalReferenceType.Distribution,\n ExternalReferenceType.License,\n ExternalReferenceType.BuildMeta,\n ExternalReferenceType.BuildSystem,\n ExternalReferenceType.Other\n ],\n true,\n false,\n true,\n true,\n false,\n [],\n true,\n false,\n true,\n true,\n true,\n false\n))\n\n/** Specification v1.4 */\nexport const Spec1dot4: Readonly<_SpecProtocol> = Object.freeze(new _Spec(\n Version.v1dot4,\n [\n Format.XML,\n Format.JSON\n ],\n [\n ComponentType.Application,\n ComponentType.Framework,\n ComponentType.Library,\n ComponentType.Container,\n ComponentType.OperatingSystem,\n ComponentType.Device,\n ComponentType.Firmware,\n ComponentType.File\n ],\n [\n HashAlgorithm.MD5,\n HashAlgorithm['SHA-1'],\n HashAlgorithm['SHA-256'],\n HashAlgorithm['SHA-384'],\n HashAlgorithm['SHA-512'],\n HashAlgorithm['SHA3-256'],\n HashAlgorithm['SHA3-384'],\n HashAlgorithm['SHA3-512'],\n HashAlgorithm['BLAKE2b-256'],\n HashAlgorithm['BLAKE2b-384'],\n HashAlgorithm['BLAKE2b-512'],\n HashAlgorithm.BLAKE3\n ],\n /^([a-fA-F0-9]{32})$|^([a-fA-F0-9]{40})$|^([a-fA-F0-9]{64})$|^([a-fA-F0-9]{96})$|^([a-fA-F0-9]{128})$/,\n [\n ExternalReferenceType.VCS,\n ExternalReferenceType.IssueTracker,\n ExternalReferenceType.Website,\n ExternalReferenceType.Advisories,\n ExternalReferenceType.BOM,\n ExternalReferenceType.MailingList,\n ExternalReferenceType.Social,\n ExternalReferenceType.Chat,\n ExternalReferenceType.Documentation,\n ExternalReferenceType.Support,\n ExternalReferenceType.Distribution,\n ExternalReferenceType.License,\n ExternalReferenceType.BuildMeta,\n ExternalReferenceType.BuildSystem,\n ExternalReferenceType.ReleaseNotes,\n ExternalReferenceType.Other\n ],\n true,\n true,\n false,\n true,\n true,\n [\n VulnerabilityRatingMethod.CVSSv2,\n VulnerabilityRatingMethod.CVSSv3,\n VulnerabilityRatingMethod.CVSSv31,\n VulnerabilityRatingMethod.OWASP,\n VulnerabilityRatingMethod.Other\n ],\n true,\n false,\n true,\n true,\n true,\n false\n))\n\n/** Specification v1.5 */\nexport const Spec1dot5: Readonly<_SpecProtocol> = Object.freeze(new _Spec(\n Version.v1dot5,\n [\n Format.XML,\n Format.JSON\n ],\n [\n ComponentType.Application,\n ComponentType.Framework,\n ComponentType.Library,\n ComponentType.Container,\n ComponentType.Platform,\n ComponentType.OperatingSystem,\n ComponentType.Device,\n ComponentType.DeviceDriver,\n ComponentType.Firmware,\n ComponentType.File,\n ComponentType.MachineLearningModel,\n ComponentType.Data\n ],\n [\n HashAlgorithm.MD5,\n HashAlgorithm['SHA-1'],\n HashAlgorithm['SHA-256'],\n HashAlgorithm['SHA-384'],\n HashAlgorithm['SHA-512'],\n HashAlgorithm['SHA3-256'],\n HashAlgorithm['SHA3-384'],\n HashAlgorithm['SHA3-512'],\n HashAlgorithm['BLAKE2b-256'],\n HashAlgorithm['BLAKE2b-384'],\n HashAlgorithm['BLAKE2b-512'],\n HashAlgorithm.BLAKE3\n ],\n /^([a-fA-F0-9]{32})$|^([a-fA-F0-9]{40})$|^([a-fA-F0-9]{64})$|^([a-fA-F0-9]{96})$|^([a-fA-F0-9]{128})$/,\n [\n ExternalReferenceType.VCS,\n ExternalReferenceType.IssueTracker,\n ExternalReferenceType.Website,\n ExternalReferenceType.Advisories,\n ExternalReferenceType.BOM,\n ExternalReferenceType.MailingList,\n ExternalReferenceType.Social,\n ExternalReferenceType.Chat,\n ExternalReferenceType.Documentation,\n ExternalReferenceType.Support,\n ExternalReferenceType.Distribution,\n ExternalReferenceType.DistributionIntake,\n ExternalReferenceType.License,\n ExternalReferenceType.BuildMeta,\n ExternalReferenceType.BuildSystem,\n ExternalReferenceType.ReleaseNotes,\n ExternalReferenceType.SecurityContact,\n ExternalReferenceType.ModelCard,\n ExternalReferenceType.Log,\n ExternalReferenceType.Configuration,\n ExternalReferenceType.Evidence,\n ExternalReferenceType.Formulation,\n ExternalReferenceType.Attestation,\n ExternalReferenceType.ThreatModel,\n ExternalReferenceType.AdversaryModel,\n ExternalReferenceType.RiskAssessment,\n ExternalReferenceType.VulnerabilityAssertion,\n ExternalReferenceType.ExploitabilityStatement,\n ExternalReferenceType.PentestReport,\n ExternalReferenceType.StaticAnalysisReport,\n ExternalReferenceType.DynamicAnalysisReport,\n ExternalReferenceType.RuntimeAnalysisReport,\n ExternalReferenceType.ComponentAnalysisReport,\n ExternalReferenceType.MaturityReport,\n ExternalReferenceType.CertificationReport,\n ExternalReferenceType.CodifiedInfrastructure,\n ExternalReferenceType.QualityMetrics,\n ExternalReferenceType.POAM,\n ExternalReferenceType.Other\n ],\n true,\n true,\n false,\n true,\n true,\n [\n VulnerabilityRatingMethod.CVSSv2,\n VulnerabilityRatingMethod.CVSSv3,\n VulnerabilityRatingMethod.CVSSv31,\n VulnerabilityRatingMethod.CVSSv4,\n VulnerabilityRatingMethod.OWASP,\n VulnerabilityRatingMethod.SSVC,\n VulnerabilityRatingMethod.Other\n ],\n true,\n true,\n true,\n true,\n true,\n false\n))\n\n/** Specification v1.6 */\nexport const Spec1dot6: Readonly<_SpecProtocol> = Object.freeze(new _Spec(\n Version.v1dot6,\n [\n Format.XML,\n Format.JSON\n ],\n [\n ComponentType.Application,\n ComponentType.Framework,\n ComponentType.Library,\n ComponentType.Container,\n ComponentType.Platform,\n ComponentType.OperatingSystem,\n ComponentType.Device,\n ComponentType.DeviceDriver,\n ComponentType.Firmware,\n ComponentType.File,\n ComponentType.MachineLearningModel,\n ComponentType.Data,\n ComponentType.CryptographicAsset\n ],\n [\n HashAlgorithm.MD5,\n HashAlgorithm['SHA-1'],\n HashAlgorithm['SHA-256'],\n HashAlgorithm['SHA-384'],\n HashAlgorithm['SHA-512'],\n HashAlgorithm['SHA3-256'],\n HashAlgorithm['SHA3-384'],\n HashAlgorithm['SHA3-512'],\n HashAlgorithm['BLAKE2b-256'],\n HashAlgorithm['BLAKE2b-384'],\n HashAlgorithm['BLAKE2b-512'],\n HashAlgorithm.BLAKE3\n ],\n /^([a-fA-F0-9]{32})$|^([a-fA-F0-9]{40})$|^([a-fA-F0-9]{64})$|^([a-fA-F0-9]{96})$|^([a-fA-F0-9]{128})$/,\n [\n ExternalReferenceType.VCS,\n ExternalReferenceType.IssueTracker,\n ExternalReferenceType.Website,\n ExternalReferenceType.Advisories,\n ExternalReferenceType.BOM,\n ExternalReferenceType.MailingList,\n ExternalReferenceType.Social,\n ExternalReferenceType.Chat,\n ExternalReferenceType.Documentation,\n ExternalReferenceType.Support,\n ExternalReferenceType.SourceDistribution,\n ExternalReferenceType.Distribution,\n ExternalReferenceType.DistributionIntake,\n ExternalReferenceType.License,\n ExternalReferenceType.BuildMeta,\n ExternalReferenceType.BuildSystem,\n ExternalReferenceType.ReleaseNotes,\n ExternalReferenceType.SecurityContact,\n ExternalReferenceType.ModelCard,\n ExternalReferenceType.Log,\n ExternalReferenceType.Configuration,\n ExternalReferenceType.Evidence,\n ExternalReferenceType.Formulation,\n ExternalReferenceType.Attestation,\n ExternalReferenceType.ThreatModel,\n ExternalReferenceType.AdversaryModel,\n ExternalReferenceType.RiskAssessment,\n ExternalReferenceType.VulnerabilityAssertion,\n ExternalReferenceType.ExploitabilityStatement,\n ExternalReferenceType.PentestReport,\n ExternalReferenceType.StaticAnalysisReport,\n ExternalReferenceType.DynamicAnalysisReport,\n ExternalReferenceType.RuntimeAnalysisReport,\n ExternalReferenceType.ComponentAnalysisReport,\n ExternalReferenceType.MaturityReport,\n ExternalReferenceType.CertificationReport,\n ExternalReferenceType.CodifiedInfrastructure,\n ExternalReferenceType.QualityMetrics,\n ExternalReferenceType.POAM,\n ExternalReferenceType.ElectronicSignature,\n ExternalReferenceType.DigitalSignature,\n ExternalReferenceType.RFC9116,\n ExternalReferenceType.Other\n ],\n true,\n true,\n false,\n true,\n true,\n [\n VulnerabilityRatingMethod.CVSSv2,\n VulnerabilityRatingMethod.CVSSv3,\n VulnerabilityRatingMethod.CVSSv31,\n VulnerabilityRatingMethod.CVSSv4,\n VulnerabilityRatingMethod.OWASP,\n VulnerabilityRatingMethod.SSVC,\n VulnerabilityRatingMethod.Other\n ],\n true,\n true,\n true,\n true,\n true,\n true\n))\n\nexport const SpecVersionDict: Readonly<Partial<Record<Version, Readonly<_SpecProtocol>>>> = Object.freeze({\n [Version.v1dot6]: Spec1dot6,\n [Version.v1dot5]: Spec1dot5,\n [Version.v1dot4]: Spec1dot4,\n [Version.v1dot3]: Spec1dot3,\n [Version.v1dot2]: Spec1dot2\n // <= v1.1 is not implemented\n})\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport enum Version {\n v1dot6 = '1.6',\n v1dot5 = '1.5',\n v1dot4 = '1.4',\n v1dot3 = '1.3',\n v1dot2 = '1.2',\n v1dot1 = '1.1',\n v1dot0 = '1.0',\n}\n\nexport enum Format {\n XML = 'xml',\n JSON = 'json',\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport class UnsupportedFormatError extends Error {\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './consts'\nexport * from './enums'\nexport * from './errors'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * Specifies a well-formed CPE name that conforms to the CPE 2.2 or 2.3 specification.\n * See the [official specification](https://nvd.nist.gov/products/cpe).\n *\n * @see {@link isCPE}\n */\nexport type CPE = string\n\n/* eslint-disable-next-line no-useless-escape -- value directly from XML, revert special-chars(like `&` -> `&`), and surrounded with `^` and `$` */\nconst cpePattern = /^([c][pP][eE]:\\/[AHOaho]?(:[A-Za-z0-9\\._\\-~%]*){0,6})$|^(cpe:2\\.3:[aho\\*\\-](:(((\\?*|\\*?)([a-zA-Z0-9\\-\\._]|(\\\\[\\\\\\*\\?!\"#$$%&'\\(\\)\\+,\\/:;<=>@\\[\\]\\^`\\{\\|}~]))+(\\?*|\\*?))|[\\*\\-])){5}(:(([a-zA-Z]{2,3}(-([a-zA-Z]{2}|[0-9]{3}))?)|[\\*\\-]))(:(((\\?*|\\*?)([a-zA-Z0-9\\-\\._]|(\\\\[\\\\\\*\\?!\"#$$%&'\\(\\)\\+,\\/:;<=>@\\[\\]\\^`\\{\\|}~]))+(\\?*|\\*?))|[\\*\\-])){4})$/\n\nexport function isCPE (value: any): value is CPE {\n return typeof value === 'string' &&\n cpePattern.test(value)\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport { SortableNumbers } from '../_helpers/sortable'\nimport type { PositiveInteger } from './integer'\nimport { isPositiveInteger } from './integer'\n\n/**\n * Integer representation of a Common Weaknesses Enumerations (CWE).\n *\n * @example\n * value `399` might represent `https://cwe.mitre.org/data/definitions/399.html`.\n *\n * @see {@link isCWE}\n */\nexport type CWE = PositiveInteger\n\nexport function isCWE (value: any): value is CWE {\n return isPositiveInteger(value)\n}\n\nexport class CweRepository extends SortableNumbers<CWE> {}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './cpe'\nexport * from './cwe'\nexport * from './integer'\nexport * from './mimeType'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * Integer\n *\n * @see {@link isInteger}\n */\nexport type Integer = number | NonNegativeInteger\n\nexport function isInteger (value: any): value is Integer {\n return Number.isInteger(value)\n}\n\n/**\n * Integer greater than or equal to `0`\n *\n * @see {@link isNonNegativeInteger}\n */\nexport type NonNegativeInteger = number | PositiveInteger\n\nexport function isNonNegativeInteger (value: any): value is NonNegativeInteger {\n return isInteger(value) &&\n value >= 0\n}\n\n/**\n * Integer greater `0`\n *\n * @see {@link isPositiveInteger}\n */\nexport type PositiveInteger = number\n\nexport function isPositiveInteger (value: any): value is PositiveInteger {\n return isInteger(value) &&\n value > 0\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * @see {@link isMimeType}\n */\nexport type MimeType = string\n\n/* regular expression was taken from the CycloneDX schema definitions. */\nconst mimeTypePattern = /^[-+a-z0-9.]+\\/[-+a-z0-9.]+$/\n\nexport function isMimeType (value: any): value is MimeType {\n return typeof value === 'string' &&\n mimeTypePattern.test(value)\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * Generate valid random SerialNumbers for {@link Models.Bom.serialNumber | Models.Bom.serialNumber}.\n */\nexport function randomSerialNumber (): string {\n const b = [\n Math.round(Math.random() * 0xFFFF),\n Math.round(Math.random() * 0xFFFF),\n Math.round(Math.random() * 0xFFFF),\n // UUID version 4\n Math.round(Math.random() * 0x0FFF) | 0x4000,\n // UUID version 4 variant 1\n Math.round(Math.random() * 0x3FFF) | 0x8000,\n Math.round(Math.random() * 0xFFFF),\n Math.round(Math.random() * 0xFFFF),\n Math.round(Math.random() * 0xFFFF)\n ].map(n => n.toString(16).padStart(4, '0'))\n return `urn:uuid:${b[0]}${b[1]}-${b[2]}-${b[3]}-${b[4]}-${b[5]}${b[6]}${b[7]}`\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\nexport * as BomUtility from './bomUtility'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nimport type { Version } from '../spec'\n\nexport class NotImplementedError extends Error {\n constructor (version: Version) {\n super(`not implemented for CycloneDX version: ${version}`)\n }\n}\n\nexport class MissingOptionalDependencyError extends Error {\n readonly cause: any | undefined\n\n constructor (message: string, cause?: any) {\n super(message)\n this.cause = cause\n }\n}\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './errors'\nexport * as Types from './types'\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\nexport * from './index.common'\n\n// region web-specifics\n\n// there is no JSON validator for the web, yet\n// there is no XML validator for the web, yet\n\n// endregion web-specifics\n","/*!\nThis file is part of CycloneDX JavaScript Library.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\nSPDX-License-Identifier: Apache-2.0\nCopyright (c) OWASP Foundation. All Rights Reserved.\n*/\n\n/**\n * Details and information describing a validation error.\n */\nexport type ValidationError = NonNullable<any>\n\nexport interface Validator {\n /**\n * Promise completes with one of the following:\n * - `null`, when data was valid\n * - {@link ValidationError | something} representing the error details, when data was invalid\n *\n * Promise rejects with one of the following:\n * - {@link Validation.NotImplementedError | NotImplementedError}, when there is no validator available\n * - {@link Validation.MissingOptionalDependencyError | MissingOptionalDependencyError}, when a required dependency was not installed\n */\n validate: (data: string) => Promise<null | ValidationError>\n}\n","module.exports = require(\"packageurl-js\");","module.exports = require(\"spdx-expression-parse\");","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","","// startup\n// Load entry module and return exports\n// This entry module is referenced by other modules so it can't be inlined\nvar __webpack_exports__ = __webpack_require__(\"./src/index.web.ts\");\n",""],"names":[],"sourceRoot":""}
|