SBOM介绍

SBOM

软件物料清单 (SBOM) 是一种用于描述软件供应链中组件及其依赖关系的文件格式。SBOM 标准旨在提高软件供应链的安全性和透明度,并使组织更容易识别和修复安全漏洞。

SBOM 文件格式标准通常包含以下信息:

  • 软件组件的名称、版本和标识符

  • 软件组件的许可证

  • 软件组件的版权所有者

  • 软件组件的依赖关系

  • 软件组件的安全漏洞信息

目前存在多种SBOM文件格式标准,最常见的如下:

SPDX

SPDX 是 Linux 基金会开发的一种开放标准,用于以机器可读和人类可读的格式共享有关软件组件、许可证、版权和安全详细信息。SPDX 是目前最广泛使用的 SBOM 格式标准之一,并得到了许多政府和行业组织的支持。

官网

SPDX – Linux 基金会项目站点icon-default.png?t=N7T8https://spdx.dev/

SPDX3.0

介绍:在 SPDX 3.0 中捕获软件漏洞数据 – SPDXicon-default.png?t=N7T8https://spdx.dev/capturing-software-vulnerability-data-in-spdx-3-0/

配置文件

介绍:了解 SPDX 配置文件 – SPDXicon-default.png?t=N7T8https://spdx.dev/understanding-spdx-profiles/

SPDX格式规范

链接:Specifications – SPDXicon-default.png?t=N7T8https://spdx.dev/use/specifications/

文档链接:第 1 条:范围 - 规范 v2.3.0 (spdx.github.io)icon-default.png?t=N7T8https://spdx.github.io/spdx-spec/v2.3/scope/

标准和示例

spdx-schema2.3
{
  "SPDXID" : "SPDXRef-DOCUMENT",
  "spdxVersion" : "SPDX-2.3",
  "creationInfo" : {
    "comment" : "This package has been shipped in source and binary form.\nThe binaries were created with gcc 4.5.1 and expect to link to\ncompatible system run time libraries.",
    "created" : "2010-01-29T18:30:22Z",
    "creators" : [ "Tool: LicenseFind-1.0", "Organization: ExampleCodeInspect ()", "Person: Jane Doe ()" ],
    "licenseListVersion" : "3.17"
  },
  "name" : "SPDX-Tools-v2.0",
  "dataLicense" : "CC0-1.0",
  "comment" : "This document was created using SPDX 2.0 using licenses from the web site.",
  "externalDocumentRefs" : [ {
    "externalDocumentId" : "DocumentRef-spdx-tool-1.2",
    "checksum" : {
      "algorithm" : "SHA1",
      "checksumValue" : "d6a770ba38583ed4bb4525bd96e50461655d2759"
    },
    "spdxDocument" : "http://spdx.org/spdxdocs/spdx-tools-v1.2-3F2504E0-4F89-41D3-9A0C-0305E82C3301"
  } ],
  "hasExtractedLicensingInfos" : [ {
    "licenseId" : "LicenseRef-1",
    "extractedText" : "/*\n * (c) Copyright 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Hewlett-Packard Development Company, LP\n * All rights reserved.\n *\n * Redistribution and use in source and binary forms, with or without\n * modification, are permitted provided that the following conditions\n * are met:\n * 1. Redistributions of source code must retain the above copyright\n *    notice, this list of conditions and the following disclaimer.\n * 2. Redistributions in binary form must reproduce the above copyright\n *    notice, this list of conditions and the following disclaimer in the\n *    documentation and/or other materials provided with the distribution.\n * 3. The name of the author may not be used to endorse or promote products\n *    derived from this software without specific prior written permission.\n *\n * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR\n * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES\n * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.\n * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,\n * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT\n * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\n * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY\n * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF\n * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n*/"
  }, {
    "licenseId" : "LicenseRef-2",
    "extractedText" : "This package includes the GRDDL parser developed by Hewlett Packard under the following license:\n© Copyright 2007 Hewlett-Packard Development Company, LP\n\nRedistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: \n\nRedistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. \nRedistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. \nThe name of the author may not be used to endorse or promote products derived from this software without specific prior written permission. \nTHIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
  }, {
    "licenseId" : "LicenseRef-4",
    "extractedText" : "/*\n * (c) Copyright 2009 University of Bristol\n * All rights reserved.\n *\n * Redistribution and use in source and binary forms, with or without\n * modification, are permitted provided that the following conditions\n * are met:\n * 1. Redistributions of source code must retain the above copyright\n *    notice, this list of conditions and the following disclaimer.\n * 2. Redistributions in binary form must reproduce the above copyright\n *    notice, this list of conditions and the following disclaimer in the\n *    documentation and/or other materials provided with the distribution.\n * 3. The name of the author may not be used to endorse or promote products\n *    derived from this software without specific prior written permission.\n *\n * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR\n * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES\n * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.\n * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,\n * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT\n * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\n * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY\n * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF\n * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n*/"
  }, {
    "licenseId" : "LicenseRef-Beerware-4.2",
    "comment" : "The beerware license has a couple of other standard variants.",
    "extractedText" : "\"THE BEER-WARE LICENSE\" (Revision 42):\nphk@FreeBSD.ORG wrote this file. As long as you retain this notice you\ncan do whatever you want with this stuff. If we meet some day, and you think this stuff is worth it, you can buy me a beer in return Poul-Henning Kamp",
    "name" : "Beer-Ware License (Version 42)",
    "seeAlsos" : [ "http://people.freebsd.org/~phk/" ]
  }, {
    "licenseId" : "LicenseRef-3",
    "comment" : "This is tye CyperNeko License",
    "extractedText" : "The CyberNeko Software License, Version 1.0\n\n \n(C) Copyright 2002-2005, Andy Clark.  All rights reserved.\n \nRedistribution and use in source and binary forms, with or without\nmodification, are permitted provided that the following conditions\nare met:\n\n1. Redistributions of source code must retain the above copyright\n   notice, this list of conditions and the following disclaimer. \n\n2. Redistributions in binary form must reproduce the above copyright\n   notice, this list of conditions and the following disclaimer in\n   the documentation and/or other materials provided with the\n   distribution.\n\n3. The end-user documentation included with the redistribution,\n   if any, must include the following acknowledgment:  \n     \"This product includes software developed by Andy Clark.\"\n   Alternately, this acknowledgment may appear in the software itself,\n   if and wherever such third-party acknowledgments normally appear.\n\n4. The names \"CyberNeko\" and \"NekoHTML\" must not be used to endorse\n   or promote products derived from this software without prior \n   written permission. For written permission, please contact \n   andyc@cyberneko.net.\n\n5. Products derived from this software may not be called \"CyberNeko\",\n   nor may \"CyberNeko\" appear in their name, without prior written\n   permission of the author.\n\nTHIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED\nWARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES\nOF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\nDISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR OTHER CONTRIBUTORS\nBE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, \nOR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT \nOF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR \nBUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \nWHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE \nOR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, \nEVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.",
    "name" : "CyberNeko License",
    "seeAlsos" : [ "http://people.apache.org/~andyc/neko/LICENSE", "http://justasample.url.com" ]
  } ],
  "annotations" : [ {
    "annotationDate" : "2010-01-29T18:30:22Z",
    "annotationType" : "OTHER",
    "annotator" : "Person: Jane Doe ()",
    "comment" : "Document level annotation"
  }, {
    "annotationDate" : "2010-02-10T00:00:00Z",
    "annotationType" : "REVIEW",
    "annotator" : "Person: Joe Reviewer",
    "comment" : "This is just an example.  Some of the non-standard licenses look like they are actually BSD 3 clause licenses"
  }, {
    "annotationDate" : "2011-03-13T00:00:00Z",
    "annotationType" : "REVIEW",
    "annotator" : "Person: Suzanne Reviewer",
    "comment" : "Another example reviewer."
  } ],
  "documentDescribes" : [ "SPDXRef-File", "SPDXRef-Package" ],
  "documentNamespace" : "http://spdx.org/spdxdocs/spdx-example-444504E0-4F89-41D3-9A0C-0305E82C3301",
  "packages" : [ {
    "SPDXID" : "SPDXRef-Package",
    "annotations" : [ {
      "annotationDate" : "2011-01-29T18:30:22Z",
      "annotationType" : "OTHER",
      "annotator" : "Person: Package Commenter",
      "comment" : "Package level annotation"
    } ],
    "attributionTexts" : [ "The GNU C Library is free software.  See the file COPYING.LIB for copying conditions, and LICENSES for notices about a few contributions that require these additional notices to be distributed.  License copyright years may be listed using range notation, e.g., 1996-2015, indicating that every year in the range, inclusive, is a copyrightable year that would otherwise be listed individually." ],
    "builtDate" : "2011-01-29T18:30:22Z",
    "checksums" : [ {
      "algorithm" : "MD5",
      "checksumValue" : "624c1abb3664f4b35547e7c73864ad24"
    }, {
      "algorithm" : "SHA1",
      "checksumValue" : "85ed0817af83a24ad8da68c2b5094de69833983c"
    }, {
      "algorithm" : "SHA256",
      "checksumValue" : "11b6d3ee554eedf79299905a98f9b9a04e498210b59f15094c916c91d150efcd"
    }, {
      "algorithm" : "BLAKE2b-384",
      "checksumValue" : "aaabd89c926ab525c242e6621f2f5fa73aa4afe3d9e24aed727faaadd6af38b620bdb623dd2b4788b1c8086984af8706"
    } ],
    "copyrightText" : "Copyright 2008-2010 John Smith",
    "description" : "The GNU C Library defines functions that are specified by the ISO C standard, as well as additional features specific to POSIX and other derivatives of the Unix operating system, and extensions specific to GNU systems.",
    "downloadLocation" : "http://ftp.gnu.org/gnu/glibc/glibc-ports-2.15.tar.gz",
    "externalRefs" : [ {
      "referenceCategory" : "SECURITY",
      "referenceLocator" : "cpe:2.3:a:pivotal_software:spring_framework:4.1.0:*:*:*:*:*:*:*",
      "referenceType" : "cpe23Type"
    }, {
      "comment" : "This is the external ref for Acme",
      "referenceCategory" : "OTHER",
      "referenceLocator" : "acmecorp/acmenator/4.1.3-alpha",
      "referenceType" : "http://spdx.org/spdxdocs/spdx-example-444504E0-4F89-41D3-9A0C-0305E82C3301#LocationRef-acmeforge"
    } ],
    "filesAnalyzed" : true,
    "homepage" : "http://ftp.gnu.org/gnu/glibc",
    "licenseComments" : "The license for this project changed with the release of version x.y.  The version of the project included here post-dates the license change.",
    "licenseConcluded" : "(LGPL-2.0-only OR LicenseRef-3)",
    "licenseDeclared" : "(LGPL-2.0-only AND LicenseRef-3)",
    "licenseInfoFromFiles" : [ "GPL-2.0-only", "LicenseRef-2", "LicenseRef-1" ],
    "name" : "glibc",
    "originator" : "Organization: ExampleCodeInspect (contact@example.com)",
    "packageFileName" : "glibc-2.11.1.tar.gz",
    "packageVerificationCode" : {
      "packageVerificationCodeExcludedFiles" : [ "./package.spdx" ],
      "packageVerificationCodeValue" : "d6a770ba38583ed4bb4525bd96e50461655d2758"
    },
    "primaryPackagePurpose" : "SOURCE",
    "hasFiles" : [ "SPDXRef-Specification", "SPDXRef-Specification", "SPDXRef-CommonsLangSrc", "SPDXRef-Specification", "SPDXRef-CommonsLangSrc", "SPDXRef-JenaLib", "SPDXRef-Specification", "SPDXRef-CommonsLangSrc", "SPDXRef-JenaLib", "SPDXRef-DoapSource", "SPDXRef-Specification", "SPDXRef-CommonsLangSrc", "SPDXRef-JenaLib", "SPDXRef-DoapSource" ],
    "releaseDate" : "2012-01-29T18:30:22Z",
    "sourceInfo" : "uses glibc-2_11-branch from git://sourceware.org/git/glibc.git.",
    "summary" : "GNU C library.",
    "supplier" : "Person: Jane Doe (jane.doe@example.com)",
    "validUntilDate" : "2014-01-29T18:30:22Z",
    "versionInfo" : "2.11.1"
  }, {
    "SPDXID" : "SPDXRef-fromDoap-1",
    "copyrightText" : "NOASSERTION",
    "downloadLocation" : "NOASSERTION",
    "filesAnalyzed" : false,
    "homepage" : "http://commons.apache.org/proper/commons-lang/",
    "licenseConcluded" : "NOASSERTION",
    "licenseDeclared" : "NOASSERTION",
    "name" : "Apache Commons Lang"
  }, {
    "SPDXID" : "SPDXRef-fromDoap-0",
    "downloadLocation" : "https://search.maven.org/remotecontent?filepath=org/apache/jena/apache-jena/3.12.0/apache-jena-3.12.0.tar.gz",
    "externalRefs" : [ {
      "referenceCategory" : "PACKAGE-MANAGER",
      "referenceLocator" : "pkg:maven/org.apache.jena/apache-jena@3.12.0",
      "referenceType" : "purl"
    } ],
    "filesAnalyzed" : false,
    "homepage" : "http://www.openjena.org/",
    "name" : "Jena",
    "versionInfo" : "3.12.0"
  }, {
    "SPDXID" : "SPDXRef-Saxon",
    "checksums" : [ {
      "algorithm" : "SHA1",
      "checksumValue" : "85ed0817af83a24ad8da68c2b5094de69833983c"
    } ],
    "copyrightText" : "Copyright Saxonica Ltd",
    "description" : "The Saxon package is a collection of tools for processing XML documents.",
    "downloadLocation" : "https://sourceforge.net/projects/saxon/files/Saxon-B/8.8.0.7/saxonb8-8-0-7j.zip/download",
    "filesAnalyzed" : false,
    "homepage" : "http://saxon.sourceforge.net/",
    "licenseComments" : "Other versions available for a commercial license",
    "licenseConcluded" : "MPL-1.0",
    "licenseDeclared" : "MPL-1.0",
    "name" : "Saxon",
    "packageFileName" : "saxonB-8.8.zip",
    "versionInfo" : "8.8"
  } ],
  "files" : [ {
    "SPDXID" : "SPDXRef-DoapSource",
    "checksums" : [ {
      "algorithm" : "SHA1",
      "checksumValue" : "2fd4e1c67a2d28fced849ee1bb76e7391b93eb12"
    } ],
    "copyrightText" : "Copyright 2010, 2011 Source Auditor Inc.",
    "fileContributors" : [ "Protecode Inc.", "SPDX Technical Team Members", "Open Logic Inc.", "Source Auditor Inc.", "Black Duck Software In.c" ],
    "fileName" : "./src/org/spdx/parser/DOAPProject.java",
    "fileTypes" : [ "SOURCE" ],
    "licenseConcluded" : "Apache-2.0",
    "licenseInfoInFiles" : [ "Apache-2.0" ]
  }, {
    "SPDXID" : "SPDXRef-CommonsLangSrc",
    "checksums" : [ {
      "algorithm" : "SHA1",
      "checksumValue" : "c2b4e1c67a2d28fced849ee1bb76e7391b93f125"
    } ],
    "comment" : "This file is used by Jena",
    "copyrightText" : "Copyright 2001-2011 The Apache Software Foundation",
    "fileContributors" : [ "Apache Software Foundation" ],
    "fileName" : "./lib-source/commons-lang3-3.1-sources.jar",
    "fileTypes" : [ "ARCHIVE" ],
    "licenseConcluded" : "Apache-2.0",
    "licenseInfoInFiles" : [ "Apache-2.0" ],
    "noticeText" : "Apache Commons Lang\nCopyright 2001-2011 The Apache Software Foundation\n\nThis product includes software developed by\nThe Apache Software Foundation (http://www.apache.org/).\n\nThis product includes software from the Spring Framework,\nunder the Apache License 2.0 (see: StringUtils.containsWhitespace())"
  }, {
    "SPDXID" : "SPDXRef-JenaLib",
    "checksums" : [ {
      "algorithm" : "SHA1",
      "checksumValue" : "3ab4e1c67a2d28fced849ee1bb76e7391b93f125"
    } ],
    "comment" : "This file belongs to Jena",
    "copyrightText" : "(c) Copyright 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Hewlett-Packard Development Company, LP",
    "fileContributors" : [ "Apache Software Foundation", "Hewlett Packard Inc." ],
    "fileName" : "./lib-source/jena-2.6.3-sources.jar",
    "fileTypes" : [ "ARCHIVE" ],
    "licenseComments" : "This license is used by Jena",
    "licenseConcluded" : "LicenseRef-1",
    "licenseInfoInFiles" : [ "LicenseRef-1" ]
  }, {
    "SPDXID" : "SPDXRef-Specification",
    "checksums" : [ {
      "algorithm" : "SHA1",
      "checksumValue" : "fff4e1c67a2d28fced849ee1bb76e7391b93f125"
    } ],
    "comment" : "Specification Documentation",
    "fileName" : "./docs/myspec.pdf",
    "fileTypes" : [ "DOCUMENTATION" ]
  }, {
    "SPDXID" : "SPDXRef-File",
    "annotations" : [ {
      "annotationDate" : "2011-01-29T18:30:22Z",
      "annotationType" : "OTHER",
      "annotator" : "Person: File Commenter",
      "comment" : "File level annotation"
    } ],
    "checksums" : [ {
      "algorithm" : "SHA1",
      "checksumValue" : "d6a770ba38583ed4bb4525bd96e50461655d2758"
    }, {
      "algorithm" : "MD5",
      "checksumValue" : "624c1abb3664f4b35547e7c73864ad24"
    } ],
    "comment" : "The concluded license was taken from the package level that the file was included in.\nThis information was found in the COPYING.txt file in the xyz directory.",
    "copyrightText" : "Copyright 2008-2010 John Smith",
    "fileContributors" : [ "The Regents of the University of California", "Modified by Paul Mundt lethal@linux-sh.org", "IBM Corporation" ],
    "fileName" : "./package/foo.c",
    "fileTypes" : [ "SOURCE" ],
    "licenseComments" : "The concluded license was taken from the package level that the file was included in.",
    "licenseConcluded" : "(LGPL-2.0-only OR LicenseRef-2)",
    "licenseInfoInFiles" : [ "GPL-2.0-only", "LicenseRef-2" ],
    "noticeText" : "Copyright (c) 2001 Aaron Lehmann aaroni@vitelus.com\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: \nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE."
  } ],
  "snippets" : [ {
    "SPDXID" : "SPDXRef-Snippet",
    "comment" : "This snippet was identified as significant and highlighted in this Apache-2.0 file, when a commercial scanner identified it as being derived from file foo.c in package xyz which is licensed under GPL-2.0.",
    "copyrightText" : "Copyright 2008-2010 John Smith",
    "licenseComments" : "The concluded license was taken from package xyz, from which the snippet was copied into the current file. The concluded license information was found in the COPYING.txt file in package xyz.",
    "licenseConcluded" : "GPL-2.0-only",
    "licenseInfoInSnippets" : [ "GPL-2.0-only" ],
    "name" : "from linux kernel",
    "ranges" : [ {
      "endPointer" : {
        "offset" : 420,
        "reference" : "SPDXRef-DoapSource"
      },
      "startPointer" : {
        "offset" : 310,
        "reference" : "SPDXRef-DoapSource"
      }
    }, {
      "endPointer" : {
        "lineNumber" : 23,
        "reference" : "SPDXRef-DoapSource"
      },
      "startPointer" : {
        "lineNumber" : 5,
        "reference" : "SPDXRef-DoapSource"
      }
    } ],
    "snippetFromFile" : "SPDXRef-DoapSource"
  } ],
  "relationships" : [ {
    "spdxElementId" : "SPDXRef-DOCUMENT",
    "relationshipType" : "CONTAINS",
    "relatedSpdxElement" : "SPDXRef-Package"
  }, {
    "spdxElementId" : "SPDXRef-DOCUMENT",
    "relationshipType" : "COPY_OF",
    "relatedSpdxElement" : "DocumentRef-spdx-tool-1.2:SPDXRef-ToolsElement"
  }, {
    "spdxElementId" : "SPDXRef-Package",
    "relationshipType" : "DYNAMIC_LINK",
    "relatedSpdxElement" : "SPDXRef-Saxon"
  }, {
    "spdxElementId" : "SPDXRef-CommonsLangSrc",
    "relationshipType" : "GENERATED_FROM",
    "relatedSpdxElement" : "NOASSERTION"
  }, {
    "spdxElementId" : "SPDXRef-JenaLib",
    "relationshipType" : "CONTAINS",
    "relatedSpdxElement" : "SPDXRef-Package"
  }, {
    "spdxElementId" : "SPDXRef-Specification",
    "relationshipType" : "SPECIFICATION_FOR",
    "relatedSpdxElement" : "SPDXRef-fromDoap-0"
  }, {
    "spdxElementId" : "SPDXRef-File",
    "relationshipType" : "GENERATED_FROM",
    "relatedSpdxElement" : "SPDXRef-fromDoap-0"
  } ]
}
SPDXJSONExample-v2.3.spdx
{
  "$schema" : "https://json-schema.org/draft/2019-09/schema#",
  "$id" : "http://spdx.org/rdf/terms/2.3",
  "title" : "SPDX 2.3",
  "type" : "object",
  "properties" : {
    "$schema": {
      "type": "string",
      "description": "Reference the SPDX 2.3 JSON schema."
    },
    "SPDXID" : {
      "type" : "string",
      //在 SPDX 文档中唯一标识任何可能被其他元素引用的元素
      "description" : "Uniquely identify any element in an SPDX document which may be referenced by other elements."
    },
    //SPDX 文档中的注释
    "annotations" : {
      "description" : "Provide additional information about an SpdxElement.",
      "type" : "array",
      "items" : {
        "type" : "object",
        "properties" : {
          "annotationDate" : {
            "description" : "Identify when the comment was made. This is to be specified according to the combined date and time in the UTC format, as specified in the ISO 8601 standard.",
            "type" : "string"
          },
          "annotationType" : {
            "description" : "Type of the annotation.",
            "type" : "string",
            "enum" : [ "OTHER", "REVIEW" ]
          },
          "annotator" : {
            "description" : "This field identifies the person, organization, or tool that has commented on a file, package, snippet, or the entire document.",
            "type" : "string"
          },
          "comment" : {
            "type" : "string"
          }
        },
        "required" : [ "annotationDate", "annotationType", "annotator", "comment" ],
        "additionalProperties" : false,
        "description" : "An Annotation is a comment on an SpdxItem by an agent."
      }
    },
    "comment" : {
      "type" : "string"
    },
    "creationInfo" : {
      "type" : "object",
      "properties" : {
        "comment" : {
          "type" : "string"
        },
        "created" : {
          "description" : "Identify when the SPDX document was originally created. The date is to be specified according to combined date and time in UTC format as specified in ISO 8601 standard.",
          "type" : "string"
        },
        "creators" : {
          "description" : "Identify who (or what, in the case of a tool) created the SPDX document. If the SPDX document was created by an individual, indicate the person's name. If the SPDX document was created on behalf of a company or organization, indicate the entity name. If the SPDX document was created using a software tool, indicate the name and version for that tool. If multiple participants or tools were involved, use multiple instances of this field. Person name or organization name may be designated as “anonymous” if appropriate.",
          "minItems" : 1,
          "type" : "array",
          "items" : {
            "description" : "Identify who (or what, in the case of a tool) created the SPDX document. If the SPDX document was created by an individual, indicate the person's name. If the SPDX document was created on behalf of a company or organization, indicate the entity name. If the SPDX document was created using a software tool, indicate the name and version for that tool. If multiple participants or tools were involved, use multiple instances of this field. Person name or organization name may be designated as “anonymous” if appropriate.",
            "type" : "string"
          }
        },
        "licenseListVersion" : {
          "description" : "An optional field for creators of the SPDX file to provide the version of the SPDX License List used when the SPDX file was created.",
          "type" : "string"
        }
      },
      "required" : [ "created", "creators" ],
      "additionalProperties" : false,
      "description" : "One instance is required for each SPDX file produced. It provides the necessary information for forward and backward compatibility for processing tools."
    },
    "dataLicense" : {
      "description" : "License expression for dataLicense. See SPDX Annex D for the license expression syntax.  Compliance with the SPDX specification includes populating the SPDX fields therein with data related to such fields (\"SPDX-Metadata\"). The SPDX specification contains numerous fields where an SPDX document creator may provide relevant explanatory text in SPDX-Metadata. Without opining on the lawfulness of \"database rights\" (in jurisdictions where applicable), such explanatory text is copyrightable subject matter in most Berne Convention countries. By using the SPDX specification, or any portion hereof, you hereby agree that any copyright rights (as determined by your jurisdiction) in any SPDX-Metadata, including without limitation explanatory text, shall be subject to the terms of the Creative Commons CC0 1.0 Universal license. For SPDX-Metadata not containing any copyright rights, you hereby agree and acknowledge that the SPDX-Metadata is provided to you \"as-is\" and without any representations or warranties of any kind concerning the SPDX-Metadata, express, implied, statutory or otherwise, including without limitation warranties of title, merchantability, fitness for a particular purpose, non-infringement, or the absence of latent or other defects, accuracy, or the presence or absence of errors, whether or not discoverable, all to the greatest extent permissible under applicable law.",
      "type" : "string"
    },
    "externalDocumentRefs" : {
      "description" : "Identify any external SPDX documents referenced within this SPDX document.",
      "type" : "array",
      "items" : {
        "type" : "object",
        "properties" : {
          "checksum" : {
            "type" : "object",
            "properties" : {
              "algorithm" : {
                "description" : "Identifies the algorithm used to produce the subject Checksum. Currently, SHA-1 is the only supported algorithm. It is anticipated that other algorithms will be supported at a later time.",
                "type" : "string",
                "enum" : [ "SHA1", "BLAKE3", "SHA3-384", "SHA256", "SHA384", "BLAKE2b-512", "BLAKE2b-256", "SHA3-512", "MD2", "ADLER32", "MD4", "SHA3-256", "BLAKE2b-384", "SHA512", "MD6", "MD5", "SHA224" ]
              },
              "checksumValue" : {
                "description" : "The checksumValue property provides a lower case hexidecimal encoded digest value produced using a specific algorithm.",
                "type" : "string"
              }
            },
            "required" : [ "algorithm", "checksumValue" ],
            "additionalProperties" : false,
            "description" : "A Checksum is value that allows the contents of a file to be authenticated. Even small changes to the content of the file will change its checksum. This class allows the results of a variety of checksum and cryptographic message digest algorithms to be represented."
          },
          "externalDocumentId" : {
            "description" : "externalDocumentId is a string containing letters, numbers, ., - and/or + which uniquely identifies an external document within this document.",
            "type" : "string"
          },
          "spdxDocument" : {
            "description" : "SPDX ID for SpdxDocument.  A property containing an SPDX document.",
            "type" : "string"
          }
        },
        "required" : [ "checksum", "externalDocumentId", "spdxDocument" ],
        "additionalProperties" : false,
        "description" : "Information about an external SPDX document reference including the checksum. This allows for verification of the external references."
      }
    },
    "hasExtractedLicensingInfos" : {
      "description" : "Indicates that a particular ExtractedLicensingInfo was defined in the subject SpdxDocument.",
      "type" : "array",
      "items" : {
        "type" : "object",
        "properties" : {
          "comment" : {
            "type" : "string"
          },
          "crossRefs" : {
            "description" : "Cross Reference Detail for a license SeeAlso URL",
            "type" : "array",
            "items" : {
              "type" : "object",
              "properties" : {
                "isLive" : {
                  "description" : "Indicate a URL is still a live accessible location on the public internet",
                  "type" : "boolean"
                },
                "isValid" : {
                  "description" : "True if the URL is a valid well formed URL",
                  "type" : "boolean"
                },
                "isWayBackLink" : {
                  "description" : "True if the License SeeAlso URL points to a Wayback archive",
                  "type" : "boolean"
                },
                "match" : {
                  "description" : "Status of a License List SeeAlso URL reference if it refers to a website that matches the license text.",
                  "type" : "string"
                },
                "order" : {
                  "description" : "The ordinal order of this element within a list",
                  "type" : "integer"
                },
                "timestamp" : {
                  "description" : "Timestamp",
                  "type" : "string"
                },
                "url" : {
                  "description" : "URL Reference",
                  "type" : "string"
                }
              },
              "required" : [ "url" ],
              "additionalProperties" : false,
              "description" : "Cross reference details for the a URL reference"
            }
          },
          "extractedText" : {
            "description" : "Provide a copy of the actual text of the license reference extracted from the package, file or snippet that is associated with the License Identifier to aid in future analysis.",
            "type" : "string"
          },
          "licenseId" : {
            "description" : "A human readable short form license identifier for a license. The license ID is either on the standard license list or the form \"LicenseRef-[idString]\" where [idString] is a unique string containing letters, numbers, \".\" or \"-\".  When used within a license expression, the license ID can optionally include a reference to an external document in the form \"DocumentRef-[docrefIdString]:LicenseRef-[idString]\" where docRefIdString is an ID for an external document reference.",
            "type" : "string"
          },
          "name" : {
            "description" : "Identify name of this SpdxElement.",
            "type" : "string"
          },
          "seeAlsos" : {
            "type" : "array",
            "items" : {
              "type" : "string"
            }
          }
        },
        "required" : [ "extractedText", "licenseId" ],
        "additionalProperties" : false,
        "description" : "An ExtractedLicensingInfo represents a license or licensing notice that was found in a package, file or snippet. Any license text that is recognized as a license may be represented as a License rather than an ExtractedLicensingInfo."
      }
    },
    "name" : {
      "description" : "Identify name of this SpdxElement.",
      "type" : "string"
    },
    "revieweds" : {
      "description" : "Reviewed",
      "deprecated": true,
      "type" : "array",
      "items" : {
        "type" : "object",
        "properties" : {
          "comment" : {
            "type" : "string"
          },
          "reviewDate" : {
            "description" : "The date and time at which the SpdxDocument was reviewed. This value must be in UTC and have 'Z' as its timezone indicator.",
            "type" : "string"
          },
          "reviewer" : {
            "description" : "The name and, optionally, contact information of the person who performed the review. Values of this property must conform to the agent and tool syntax.  The reviewer property is deprecated in favor of Annotation with an annotationType review.",
            "type" : "string"
          }
        },
        "required" : [ "reviewDate" ],
        "additionalProperties" : false,
        "description" : "This class has been deprecated in favor of an Annotation with an Annotation type of review."
      }
    },
    "spdxVersion" : {
      "description" : "Provide a reference number that can be used to understand how to parse and interpret the rest of the file. It will enable both future changes to the specification and to support backward compatibility. The version number consists of a major and minor version indicator. The major field will be incremented when incompatible changes between versions are made (one or more sections are created, modified or deleted). The minor field will be incremented when backwards compatible changes are made.",
      "type" : "string"
    },
    "documentNamespace" : {
      "type" : "string",
      "description" : "The URI provides an unambiguous mechanism for other SPDX documents to reference SPDX elements within this SPDX document."
    },
    "documentDescribes" : {
      "description" : "DEPRECATED: use relationships instead of this field. Packages, files and/or Snippets described by this SPDX document",
      "deprecated": true,
      "$comment": "This field has been deprecated as it is a duplicate of using the SPDXRef-DOCUMENT DESCRIBES relationship",
      "type" : "array",
      "items" : {
        "type" : "string",
        "description" : "SPDX ID for each Package, File, or Snippet."
      }
    },
    "packages" : {
      "description" : "Packages referenced in the SPDX document",
      "type" : "array",
      "items" : {
        "type" : "object",
        "properties" : {
          "SPDXID" : {
            "type" : "string",
            "description" : "Uniquely identify any element in an SPDX document which may be referenced by other elements."
          },
          "annotations" : {
            "description" : "Provide additional information about an SpdxElement.",
            "type" : "array",
            "items" : {
              "type" : "object",
              "properties" : {
                "annotationDate" : {
                  "description" : "Identify when the comment was made. This is to be specified according to the combined date and time in the UTC format, as specified in the ISO 8601 standard.",
                  "type" : "string"
                },
                "annotationType" : {
                  "description" : "Type of the annotation.",
                  "type" : "string",
                  "enum" : [ "OTHER", "REVIEW" ]
                },
                "annotator" : {
                  "description" : "This field identifies the person, organization, or tool that has commented on a file, package, snippet, or the entire document.",
                  "type" : "string"
                },
                "comment" : {
                  "type" : "string"
                }
              },
              "required" : [ "annotationDate", "annotationType", "annotator", "comment" ],
              "additionalProperties" : false,
              "description" : "An Annotation is a comment on an SpdxItem by an agent."
            }
          },
          "attributionTexts" : {
            "description" : "This field provides a place for the SPDX data creator to record acknowledgements that may be required to be communicated in some contexts. This is not meant to include the actual complete license text (see licenseConculded and licenseDeclared), and may or may not include copyright notices (see also copyrightText). The SPDX data creator may use this field to record other acknowledgements, such as particular clauses from license texts, which may be necessary or desirable to reproduce.",
            "type" : "array",
            "items" : {
              "description" : "This field provides a place for the SPDX data creator to record acknowledgements that may be required to be communicated in some contexts. This is not meant to include the actual complete license text (see licenseConculded and licenseDeclared), and may or may not include copyright notices (see also copyrightText). The SPDX data creator may use this field to record other acknowledgements, such as particular clauses from license texts, which may be necessary or desirable to reproduce.",
              "type" : "string"
            }
          },
          "builtDate" : {
            "description" : "This field provides a place for recording the actual date the package was built.",
            "type" : "string"
          },
          "checksums" : {
            "description" : "The checksum property provides a mechanism that can be used to verify that the contents of a File or Package have not changed.",
            "type" : "array",
            "items" : {
              "type" : "object",
              "properties" : {
                "algorithm" : {
                  "description" : "Identifies the algorithm used to produce the subject Checksum. Currently, SHA-1 is the only supported algorithm. It is anticipated that other algorithms will be supported at a later time.",
                  "type" : "string",
                  "enum" : [ "SHA1", "BLAKE3", "SHA3-384", "SHA256", "SHA384", "BLAKE2b-512", "BLAKE2b-256", "SHA3-512", "MD2", "ADLER32", "MD4", "SHA3-256", "BLAKE2b-384", "SHA512", "MD6", "MD5", "SHA224" ]
                },
                "checksumValue" : {
                  "description" : "The checksumValue property provides a lower case hexidecimal encoded digest value produced using a specific algorithm.",
                  "type" : "string"
                }
              },
              "required" : [ "algorithm", "checksumValue" ],
              "additionalProperties" : false,
              "description" : "A Checksum is value that allows the contents of a file to be authenticated. Even small changes to the content of the file will change its checksum. This class allows the results of a variety of checksum and cryptographic message digest algorithms to be represented."
            }
          },
          "comment" : {
            "type" : "string"
          },
          "copyrightText" : {
            "description" : "The text of copyright declarations recited in the package, file or snippet.\n\nIf the copyrightText field is not present, it implies an equivalent meaning to NOASSERTION.",
            "type" : "string"
          },
          "description" : {
            "description" : "Provides a detailed description of the package.",
            "type" : "string"
          },
          "downloadLocation" : {
            "description" : "The URI at which this package is available for download. Private (i.e., not publicly reachable) URIs are acceptable as values of this property. The values http://spdx.org/rdf/terms#none and http://spdx.org/rdf/terms#noassertion may be used to specify that the package is not downloadable or that no attempt was made to determine its download location, respectively.",
            "type" : "string"
          },
          "externalRefs" : {
            "description" : "An External Reference allows a Package to reference an external source of additional information, metadata, enumerations, asset identifiers, or downloadable content believed to be relevant to the Package.",
            "type" : "array",
            "items" : {
              "type" : "object",
              "properties" : {
                "comment" : {
                  "type" : "string"
                },
                "referenceCategory" : {
                  "description" : "Category for the external reference",
                  "type" : "string",
                  "enum" : [ "OTHER", "PERSISTENT-ID", "PERSISTENT_ID", "SECURITY", "PACKAGE-MANAGER", "PACKAGE_MANAGER" ]
                },
                "referenceLocator" : {
                  "description" : "The unique string with no spaces necessary to access the package-specific information, metadata, or content within the target location. The format of the locator is subject to constraints defined by the <type>.",
                  "type" : "string"
                },
                "referenceType" : {
                  "description" : "Type of the external reference. These are defined in an appendix in the SPDX specification.",
                  "type" : "string"
                }
              },
              "required" : [ "referenceCategory", "referenceLocator", "referenceType" ],
              "additionalProperties" : false,
              "description" : "An External Reference allows a Package to reference an external source of additional information, metadata, enumerations, asset identifiers, or downloadable content believed to be relevant to the Package."
            }
          },
          "filesAnalyzed" : {
            "description" : "Indicates whether the file content of this package has been available for or subjected to analysis when creating the SPDX document. If false indicates packages that represent metadata or URI references to a project, product, artifact, distribution or a component. If set to false, the package must not contain any files.",
            "type" : "boolean"
          },
          "hasFiles" : {
            "description" : "DEPRECATED: use relationships instead of this field. Indicates that a particular file belongs to a package.",
            "deprecated": true,
            "$comment": "This field has been deprecated as it is a duplicate of using CONTAINS relationships from a package to files",
            "type" : "array",
            "items" : {
              "description" : "SPDX ID for File.  Indicates that a particular file belongs to a package.",
              "type" : "string"
            }
          },
          "homepage" : {
            "type" : "string"
          },
          "licenseComments" : {
            "description" : "The licenseComments property allows the preparer of the SPDX document to describe why the licensing in spdx:licenseConcluded was chosen.",
            "type" : "string"
          },
          "licenseConcluded" : {
            "description" : "License expression for licenseConcluded. See SPDX Annex D for the license expression syntax.  The licensing that the preparer of this SPDX document has concluded, based on the evidence, actually applies to the SPDX Item.\n\nIf the licenseConcluded field is not present for an SPDX Item, it implies an equivalent meaning to NOASSERTION.",
            "type" : "string"
          },
          "licenseDeclared" : {
            "description" : "License expression for licenseDeclared. See SPDX Annex D for the license expression syntax.  The licensing that the creators of the software in the package, or the packager, have declared. Declarations by the original software creator should be preferred, if they exist.",
            "type" : "string"
          },
          "licenseInfoFromFiles" : {
            "description" : "The licensing information that was discovered directly within the package. There will be an instance of this property for each distinct value of alllicenseInfoInFile properties of all files contained in the package.\n\nIf the licenseInfoFromFiles field is not present for a package and filesAnalyzed property for that same package is true or omitted, it implies an equivalent meaning to NOASSERTION.",
            "type" : "array",
            "items" : {
              "description" : "License expression for licenseInfoFromFiles. See SPDX Annex D for the license expression syntax.  The licensing information that was discovered directly within the package. There will be an instance of this property for each distinct value of alllicenseInfoInFile properties of all files contained in the package.\n\nIf the licenseInfoFromFiles field is not present for a package and filesAnalyzed property for that same package is true or omitted, it implies an equivalent meaning to NOASSERTION.",
              "type" : "string"
            }
          },
          "name" : {
            "description" : "Identify name of this SpdxElement.",
            "type" : "string"
          },
          "originator" : {
            "description" : "The name and, optionally, contact information of the person or organization that originally created the package. Values of this property must conform to the agent and tool syntax.",
            "type" : "string"
          },
          "packageFileName" : {
            "description" : "The base name of the package file name. For example, zlib-1.2.5.tar.gz.",
            "type" : "string"
          },
          "packageVerificationCode" : {
            "type" : "object",
            "properties" : {
              "packageVerificationCodeExcludedFiles" : {
                "description" : "A file that was excluded when calculating the package verification code. This is usually a file containing SPDX data regarding the package. If a package contains more than one SPDX file all SPDX files must be excluded from the package verification code. If this is not done it would be impossible to correctly calculate the verification codes in both files.",
                "type" : "array",
                "items" : {
                  "description" : "A file that was excluded when calculating the package verification code. This is usually a file containing SPDX data regarding the package. If a package contains more than one SPDX file all SPDX files must be excluded from the package verification code. If this is not done it would be impossible to correctly calculate the verification codes in both files.",
                  "type" : "string"
                }
              },
              "packageVerificationCodeValue" : {
                "description" : "The actual package verification code as a hex encoded value.",
                "type" : "string"
              }
            },
            "required" : [ "packageVerificationCodeValue" ],
            "additionalProperties" : false,
            "description" : "A manifest based verification code (the algorithm is defined in section 4.7 of the full specification) of the SPDX Item. This allows consumers of this data and/or database to determine if an SPDX item they have in hand is identical to the SPDX item from which the data was produced. This algorithm works even if the SPDX document is included in the SPDX item."
          },
          "primaryPackagePurpose" : {
            "description" : "This field provides information about the primary purpose of the identified package. Package Purpose is intrinsic to how the package is being used rather than the content of the package.",
            "type" : "string",
            "enum" : [ "OTHER", "INSTALL", "ARCHIVE", "FIRMWARE", "APPLICATION", "FRAMEWORK", "LIBRARY", "CONTAINER", "SOURCE", "DEVICE", "OPERATING_SYSTEM", "FILE" ]
          },
          "releaseDate" : {
            "description" : "This field provides a place for recording the date the package was released.",
            "type" : "string"
          },
          "sourceInfo" : {
            "description" : "Allows the producer(s) of the SPDX document to describe how the package was acquired and/or changed from the original source.",
            "type" : "string"
          },
          "summary" : {
            "description" : "Provides a short description of the package.",
            "type" : "string"
          },
          "supplier" : {
            "description" : "The name and, optionally, contact information of the person or organization who was the immediate supplier of this package to the recipient. The supplier may be different than originator when the software has been repackaged. Values of this property must conform to the agent and tool syntax.",
            "type" : "string"
          },
          "validUntilDate" : {
            "description" : "This field provides a place for recording the end of the support period for a package from the supplier.",
            "type" : "string"
          },
          "versionInfo" : {
            "description" : "Provides an indication of the version of the package that is described by this SpdxDocument.",
            "type" : "string"
          }
        },
        "required" : [ "SPDXID", "downloadLocation", "name" ],
        "additionalProperties" : false
      }
    },
    "files" : {
      "description" : "Files referenced in the SPDX document",
      "type" : "array",
      "items" : {
        "type" : "object",
        "properties" : {
          "SPDXID" : {
            "type" : "string",
            "description" : "Uniquely identify any element in an SPDX document which may be referenced by other elements."
          },
          "annotations" : {
            "description" : "Provide additional information about an SpdxElement.",
            "type" : "array",
            "items" : {
              "type" : "object",
              "properties" : {
                "annotationDate" : {
                  "description" : "Identify when the comment was made. This is to be specified according to the combined date and time in the UTC format, as specified in the ISO 8601 standard.",
                  "type" : "string"
                },
                "annotationType" : {
                  "description" : "Type of the annotation.",
                  "type" : "string",
                  "enum" : [ "OTHER", "REVIEW" ]
                },
                "annotator" : {
                  "description" : "This field identifies the person, organization, or tool that has commented on a file, package, snippet, or the entire document.",
                  "type" : "string"
                },
                "comment" : {
                  "type" : "string"
                }
              },
              "required" : [ "annotationDate", "annotationType", "annotator", "comment" ],
              "additionalProperties" : false,
              "description" : "An Annotation is a comment on an SpdxItem by an agent."
            }
          },
          "artifactOfs" : {
            "description" : "Indicates the project in which the SpdxElement originated. Tools must preserve doap:homepage and doap:name properties and the URI (if one is known) of doap:Project resources that are values of this property. All other properties of doap:Projects are not directly supported by SPDX and may be dropped when translating to or from some SPDX formats.",
            "type" : "array",
            "items" : {
              "type" : "object"
            }
          },
          "attributionTexts" : {
            "description" : "This field provides a place for the SPDX data creator to record acknowledgements that may be required to be communicated in some contexts. This is not meant to include the actual complete license text (see licenseConculded and licenseDeclared), and may or may not include copyright notices (see also copyrightText). The SPDX data creator may use this field to record other acknowledgements, such as particular clauses from license texts, which may be necessary or desirable to reproduce.",
            "type" : "array",
            "items" : {
              "description" : "This field provides a place for the SPDX data creator to record acknowledgements that may be required to be communicated in some contexts. This is not meant to include the actual complete license text (see licenseConculded and licenseDeclared), and may or may not include copyright notices (see also copyrightText). The SPDX data creator may use this field to record other acknowledgements, such as particular clauses from license texts, which may be necessary or desirable to reproduce.",
              "type" : "string"
            }
          },
          "checksums" : {
            "description" : "The checksum property provides a mechanism that can be used to verify that the contents of a File or Package have not changed.",
            "minItems" : 1,
            "type" : "array",
            "items" : {
              "type" : "object",
              "properties" : {
                "algorithm" : {
                  "description" : "Identifies the algorithm used to produce the subject Checksum. Currently, SHA-1 is the only supported algorithm. It is anticipated that other algorithms will be supported at a later time.",
                  "type" : "string",
                  "enum" : [ "SHA1", "BLAKE3", "SHA3-384", "SHA256", "SHA384", "BLAKE2b-512", "BLAKE2b-256", "SHA3-512", "MD2", "ADLER32", "MD4", "SHA3-256", "BLAKE2b-384", "SHA512", "MD6", "MD5", "SHA224" ]
                },
                "checksumValue" : {
                  "description" : "The checksumValue property provides a lower case hexidecimal encoded digest value produced using a specific algorithm.",
                  "type" : "string"
                }
              },
              "required" : [ "algorithm", "checksumValue" ],
              "additionalProperties" : false,
              "description" : "A Checksum is value that allows the contents of a file to be authenticated. Even small changes to the content of the file will change its checksum. This class allows the results of a variety of checksum and cryptographic message digest algorithms to be represented."
            }
          },
          "comment" : {
            "type" : "string"
          },
          "copyrightText" : {
            "description" : "The text of copyright declarations recited in the package, file or snippet.\n\nIf the copyrightText field is not present, it implies an equivalent meaning to NOASSERTION.",
            "type" : "string"
          },
          "fileContributors" : {
            "description" : "This field provides a place for the SPDX file creator to record file contributors. Contributors could include names of copyright holders and/or authors who may not be copyright holders yet contributed to the file content.",
            "type" : "array",
            "items" : {
              "description" : "This field provides a place for the SPDX file creator to record file contributors. Contributors could include names of copyright holders and/or authors who may not be copyright holders yet contributed to the file content.",
              "type" : "string"
            }
          },
          "fileDependencies" : {
            "description" : "This field is deprecated since SPDX 2.0 in favor of using Section 7 which provides more granularity about relationships.",
            "deprecated": true,
            "type" : "array",
            "items" : {
              "description" : "SPDX ID for File.  This field is deprecated since SPDX 2.0 in favor of using Section 7 which provides more granularity about relationships.",
              "type" : "string"
            }
          },
          "fileName" : {
            "description" : "The name of the file relative to the root of the package.",
            "type" : "string"
          },
          "fileTypes" : {
            "description" : "The type of the file.",
            "type" : "array",
            "items" : {
              "description" : "The type of the file.",
              "type" : "string",
              "enum" : [ "OTHER", "DOCUMENTATION", "IMAGE", "VIDEO", "ARCHIVE", "SPDX", "APPLICATION", "SOURCE", "BINARY", "TEXT", "AUDIO" ]
            }
          },
          "licenseComments" : {
            "description" : "The licenseComments property allows the preparer of the SPDX document to describe why the licensing in spdx:licenseConcluded was chosen.",
            "type" : "string"
          },
          "licenseConcluded" : {
            "description" : "License expression for licenseConcluded. See SPDX Annex D for the license expression syntax.  The licensing that the preparer of this SPDX document has concluded, based on the evidence, actually applies to the SPDX Item.\n\nIf the licenseConcluded field is not present for an SPDX Item, it implies an equivalent meaning to NOASSERTION.",
            "type" : "string"
          },
          "licenseInfoInFiles" : {
            "description" : "Licensing information that was discovered directly in the subject file. This is also considered a declared license for the file.\n\nIf the licenseInfoInFile field is not present for a file, it implies an equivalent meaning to NOASSERTION.",
            "type" : "array",
            "items" : {
              "description" : "License expression for licenseInfoInFile. See SPDX Annex D for the license expression syntax.  Licensing information that was discovered directly in the subject file. This is also considered a declared license for the file.\n\nIf the licenseInfoInFile field is not present for a file, it implies an equivalent meaning to NOASSERTION.",
              "type" : "string"
            }
          },
          "noticeText" : {
            "description" : "This field provides a place for the SPDX file creator to record potential legal notices found in the file. This may or may not include copyright statements.",
            "type" : "string"
          }
        },
        "required" : [ "SPDXID", "checksums", "fileName" ],
        "additionalProperties" : false
      }
    },
    //SPDX 文档中引用的片段
    "snippets" : {
      "description" : "Snippets referenced in the SPDX document",
      "type" : "array",
      "items" : {
        "type" : "object",
        "properties" : {
          "SPDXID" : {
            "type" : "string",
            "description" : "Uniquely identify any element in an SPDX document which may be referenced by other elements."
          },
          "annotations" : {
            "description" : "Provide additional information about an SpdxElement.",
            "type" : "array",
            "items" : {
              "type" : "object",
              "properties" : {
                "annotationDate" : {
                  "description" : "Identify when the comment was made. This is to be specified according to the combined date and time in the UTC format, as specified in the ISO 8601 standard.",
                  "type" : "string"
                },
                "annotationType" : {
                  "description" : "Type of the annotation.",
                  "type" : "string",
                  "enum" : [ "OTHER", "REVIEW" ]
                },
                "annotator" : {
                  "description" : "This field identifies the person, organization, or tool that has commented on a file, package, snippet, or the entire document.",
                  "type" : "string"
                },
                "comment" : {
                  "type" : "string"
                }
              },
              "required" : [ "annotationDate", "annotationType", "annotator", "comment" ],
              "additionalProperties" : false,
              "description" : "An Annotation is a comment on an SpdxItem by an agent."
            }
          },
          "attributionTexts" : {
            "description" : "This field provides a place for the SPDX data creator to record acknowledgements that may be required to be communicated in some contexts. This is not meant to include the actual complete license text (see licenseConculded and licenseDeclared), and may or may not include copyright notices (see also copyrightText). The SPDX data creator may use this field to record other acknowledgements, such as particular clauses from license texts, which may be necessary or desirable to reproduce.",
            "type" : "array",
            "items" : {
              "description" : "This field provides a place for the SPDX data creator to record acknowledgements that may be required to be communicated in some contexts. This is not meant to include the actual complete license text (see licenseConculded and licenseDeclared), and may or may not include copyright notices (see also copyrightText). The SPDX data creator may use this field to record other acknowledgements, such as particular clauses from license texts, which may be necessary or desirable to reproduce.",
              "type" : "string"
            }
          },
          "comment" : {
            "type" : "string"
          },
          "copyrightText" : {
            "description" : "The text of copyright declarations recited in the package, file or snippet.\n\nIf the copyrightText field is not present, it implies an equivalent meaning to NOASSERTION.",
            "type" : "string"
          },
          "licenseComments" : {
            "description" : "The licenseComments property allows the preparer of the SPDX document to describe why the licensing in spdx:licenseConcluded was chosen.",
            "type" : "string"
          },
          "licenseConcluded" : {
            "description" : "License expression for licenseConcluded. See SPDX Annex D for the license expression syntax.  The licensing that the preparer of this SPDX document has concluded, based on the evidence, actually applies to the SPDX Item.\n\nIf the licenseConcluded field is not present for an SPDX Item, it implies an equivalent meaning to NOASSERTION.",
            "type" : "string"
          },
          "licenseInfoInSnippets" : {
            "description" : "Licensing information that was discovered directly in the subject snippet. This is also considered a declared license for the snippet.\n\nIf the licenseInfoInSnippet field is not present for a snippet, it implies an equivalent meaning to NOASSERTION.",
            "type" : "array",
            "items" : {
              "description" : "License expression for licenseInfoInSnippet. See SPDX Annex D for the license expression syntax.  Licensing information that was discovered directly in the subject snippet. This is also considered a declared license for the snippet.\n\nIf the licenseInfoInSnippet field is not present for a snippet, it implies an equivalent meaning to NOASSERTION.",
              "type" : "string"
            }
          },
          "name" : {
            "description" : "Identify name of this SpdxElement.",
            "type" : "string"
          },
          "ranges" : {
            "description" : "This field defines the byte range in the original host file (in X.2) that the snippet information applies to",
            "minItems" : 1,
            "type" : "array",
            "items" : {
              "type" : "object",
              "properties" : {
                "endPointer" : {
                  "type" : "object",
                  "properties" : {
                    "reference" : {
                      "description" : "SPDX ID for File",
                      "type" : "string"
                    },
                    "offset" : {
                      "type" : "integer",
                      "description" : "Byte offset in the file"
                    },
                    "lineNumber" : {
                      "type" : "integer",
                      "description" : "line number offset in the file"
                    }
                  },
                  "required" : [ "reference" ],
                  "additionalProperties" : false
                },
                "startPointer" : {
                  "type" : "object",
                  "properties" : {
                    "reference" : {
                      "description" : "SPDX ID for File",
                      "type" : "string"
                    },
                    "offset" : {
                      "type" : "integer",
                      "description" : "Byte offset in the file"
                    },
                    "lineNumber" : {
                      "type" : "integer",
                      "description" : "line number offset in the file"
                    }
                  },
                  "required" : [ "reference" ],
                  "additionalProperties" : false
                }
              },
              "required" : [ "endPointer", "startPointer" ],
              "additionalProperties" : false
            }
          },
          "snippetFromFile" : {
            "description" : "SPDX ID for File.  File containing the SPDX element (e.g. the file contaning a snippet).",
            "type" : "string"
          }
        },
        "required" : [ "SPDXID", "name", "ranges", "snippetFromFile" ],
        "additionalProperties" : false
      }
    },
    "relationships" : {
      "description" : "Relationships referenced in the SPDX document",
      "type" : "array",
      "items" : {
        "type" : "object",
        "properties" : {
          "spdxElementId" : {
            "type" : "string",
            "description" : "Id to which the SPDX element is related"
          },
          "comment" : {
            "type" : "string"
          },
          "relatedSpdxElement" : {
            "description" : "SPDX ID for SpdxElement.  A related SpdxElement.",
            "type" : "string"
          },
          "relationshipType" : {
            "description" : "Describes the type of relationship between two SPDX elements.",
            "type" : "string",
            "enum" : [ "VARIANT_OF", "COPY_OF", "PATCH_FOR", "TEST_DEPENDENCY_OF", "CONTAINED_BY", "DATA_FILE_OF", "OPTIONAL_COMPONENT_OF", "ANCESTOR_OF", "GENERATES", "CONTAINS", "OPTIONAL_DEPENDENCY_OF", "FILE_ADDED", "REQUIREMENT_DESCRIPTION_FOR", "DEV_DEPENDENCY_OF", "DEPENDENCY_OF", "BUILD_DEPENDENCY_OF", "DESCRIBES", "PREREQUISITE_FOR", "HAS_PREREQUISITE", "PROVIDED_DEPENDENCY_OF", "DYNAMIC_LINK", "DESCRIBED_BY", "METAFILE_OF", "DEPENDENCY_MANIFEST_OF", "PATCH_APPLIED", "RUNTIME_DEPENDENCY_OF", "TEST_OF", "TEST_TOOL_OF", "DEPENDS_ON", "SPECIFICATION_FOR", "FILE_MODIFIED", "DISTRIBUTION_ARTIFACT", "AMENDS", "DOCUMENTATION_OF", "GENERATED_FROM", "STATIC_LINK", "OTHER", "BUILD_TOOL_OF", "TEST_CASE_OF", "PACKAGE_OF", "DESCENDANT_OF", "FILE_DELETED", "EXPANDED_FROM_ARCHIVE", "DEV_TOOL_OF", "EXAMPLE_OF" ]
          }
        },
        "required" : [ "spdxElementId", "relatedSpdxElement", "relationshipType" ],
        "additionalProperties" : false
      }
    }
  },
  "required" : [ "SPDXID", "creationInfo", "dataLicense", "name", "spdxVersion", "documentNamespace" ],
  "additionalProperties" : false
}

CycloneDX

CycloneDX 是由 OWASP (Open Web Application Security Project) 开发的一种开源标准,用于描述软件供应链中组件及其依赖关系。CycloneDX 类似于 SPDX,但它提供了一些额外的功能,例如支持硬件和云组件。

SWID (Software Identification)

SWID 是一种由 OASIS (Organization for the Advancement of Standards in Information Technology) 开发的标准,用于唯一标识软件组件。SWID 通常与其他 SBOM 格式标准一起使用,例如 SPDX 或 CycloneDX,以提供有关软件组件的更多详细信息。

  • 37
    点赞
  • 61
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值