-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Consider tracking provenance of build-time dependencies #15
Comments
like MBOM: https://en.wikipedia.org/wiki/Manufacturing_bill_of_materials ? |
This can certainly be done, it would be a feature request to projects which are building Python packages. Likely a good place to start would be cibuildwheel? If I'm understanding the CycloneDX forumation correctly, this would take a snapshot of the entire environment of packages/tools for the cibuildwheel container and then list them all under:
Does that match your expectations? |
I believe so. Do you want me to do it? Or do you prefer to handle that discussion yourself? For context, I am exploring the current state of tooling and specs to see what's doable to achieve traceable and bitwise reproducible builds for scikit-learn, its dependencies and other scientific Python packages that ship native extensions in their wheels:
I am no CycloneDX expert, but that sounds reasonable. Maybe we can try to find other software communities who are more mature in that respect and see how they use the CycloneDX formulation field in practice (assuming some do). EDIT: I could not find any usage example for the "formulation" field of CycloneDX on GitHub: https://github.com/search?q=path%3A*.cdx.json+formulation&type=code |
@jkowalleck I find the MBOM concept as described in Wikipedia a bit fuzzy. CycloneDX's formulation, on the other hand, seems relevant. I am not familiar with the SPDX spec either, so I am not sure if what I described above can be naturally mapped to it with an explicit distinction between runtime and build time dependencies. |
@ogrisel The PEP itself isn't yet provisional, it will hopefully be sometime next week. But we can certainly get the ball rolling. I can create a few top-level issues there. |
here is a guide on MBOM: https://github.com/CycloneDX/guides/tree/main/MBOM/en THere are also guides on SBOM and OBOM.
Runtime-depednencies -> SBOM/OBOM |
Note that SPDX also has a build profile that could serve this purpose: But the interpretation of the |
The list of https://github.com/psf/sboms-for-python-packages?tab=readme-ov-file#phantom-dependencies does not explicitly list build time dependencies for inclusion in the SBOM. I am thinking of:
patchelf
which is a system dependency of auditwheel);Tracking the name, digest and version number of those build-time tools could be useful even if the wheel does not directly include files coming from those tools. In particular, this would allow tracing the downstream impact of a tampered build tool that has been discovered to inject malware hidden into compiled extensions shipped in the generated Python package (see compiler backdoors).
Furthermore, it would be helpful to track build tool versioning info to help automate independent reproducible build attempts as a proactive way to detect previously unreported tampered components in a software supply chain.
The text was updated successfully, but these errors were encountered: