Skip to content

SBOM - Software Bill of Materials

The SBOM module in Polski for WooCommerce downloads a CycloneDX 1.4 JSON software bill of materials for the Polski plugin, listing the Composer packages it ships (and npm packages in a development checkout) with their versions and Package URLs. It is meant for software manufacturers, runs on demand and is off by default.

Under the EU Cyber Resilience Act, manufacturers of products with digital elements draw up an SBOM (Annex I Part II); a shop that only sells goods has no such duty. The format is accepted by most SBOM consumers (Trivy, Dependency-Track, Grype).

Both formats are widely accepted. CycloneDX 1.4 JSON was chosen because the shape is simpler, is consumed directly by Trivy and Dependency-Track, and uses Package URLs (purl) which ship out-of-the-box for Composer and npm.

Enable SBOM (software bill of materials) in Polski > Modules; it is off by default. The download screen is then linked from Polski > Reports & Tools.

For each target directory the generator reads:

File Content
vendor/composer/installed.json PHP packages shipped in the plugin package
composer.lock PHP packages (sections packages and packages-dev; dev packages get scope: optional), development checkout only
package-lock.json JavaScript packages, development checkout only. The published package has no lock file, so JavaScript libraries bundled into the plugin scripts are not listed
Plugin header Name and version (from VERSION constant)

The generator runs on-demand only. The JSON is not cached - generation for a FREE plugin with around 100 dependencies takes under 200 ms.

  • polski - the FREE plugin (WP_PLUGIN_DIR/polski or Polski\PLUGIN_DIR)

The file is served with:

Content-Type: application/vnd.cyclonedx+json; charset=utf-8
Content-Disposition: attachment; filename="<slug>-sbom-<version>-<UTC timestamp>.cdx.json"

Example (truncated):

{
"bomFormat": "CycloneDX",
"specVersion": "1.4",
"serialNumber": "urn:uuid:5a3b....",
"version": 1,
"metadata": {
"timestamp": "2026-04-19T08:30:00+00:00",
"tools": [{ "vendor": "WPPoland", "name": "Polski SBOM generator", "version": "1.0" }],
"component": {
"type": "application",
"bom-ref": "wppoland/polski",
"name": "polski",
"version": "2.1.0",
"publisher": "WPPoland"
}
},
"components": [
{
"type": "library",
"bom-ref": "composer:woocommerce/woocommerce-blocks",
"name": "woocommerce/woocommerce-blocks",
"version": "10.8.4",
"scope": "required",
"purl": "pkg:composer/woocommerce/woocommerce-blocks@10.8.4",
"licenses": [{ "license": { "id": "GPL-3.0-or-later" } }]
}
]
}
Terminal window
trivy sbom polski-sbom-2.1.0-20260419-083000.cdx.json
  1. Create a project in Dependency-Track (one per plugin).
  2. Upload the JSON via the UI or the /api/v1/bom endpoint.
  3. Connect the project to a CI pipeline so that every release updates the BOM.

Under the Cyber Resilience Act, manufacturers of products with digital elements draw up an SBOM (Annex I Part II); it is not a duty of a shop that sells goods. A manufacturer can keep the CycloneDX JSON next to each tagged release as part of its technical documentation. The filename embeds the version and UTC timestamp so artefacts stay unique across releases.

  • UI and download: manage_woocommerce
  • Nonce: polski_sbom_download (required for the POST action)
  • Transitive dependency relationships (dependencies tree) are not emitted yet (flat list only)
  • WordPress itself is not a component in the BOM (it is the runtime, not a bundled dependency)
  • Version discovered from the plugin constants only - not from the composer.json field
  • No HMAC signature on the BOM

Under the Cyber Resilience Act the SBOM duty (Annex I Part II) is on manufacturers of products with digital elements. A shop that only sells goods has no such duty; the module is for shops that also publish their own software.

Any CycloneDX 1.4 consumer, for example Trivy, Grype or Dependency-Track.

Only in a development checkout that has package-lock.json. The published plugin package has no lock file, so JavaScript bundled into its scripts is not listed.