New dependencies in requirements.txt
should include --hash
#262
Labels
enhancement
New feature or request
requirements.txt
should include --hash
#262
Details
Using
--hash
when describing dependencies inrequirements.txt
would help to ensure that the right version is being used and validate against any potential supply chain attacks. Inrequirements.txt
it ends up looking something like this:We should make sure to add the
--hash
value when updatingrequirements.txt
files. This means that it will be necessary to encode the sha256 from PyPI in the dependency object itself. We should definitely do this for our security package and we should probably do it fordefusedxml
as well.As far as I can tell, using
--hash
is not valid with our other dependency locations such assetup.py
andpyproject.toml
, but it bears a bit of further investigation.This idea was originally proposed in pixee/python-security#10
The text was updated successfully, but these errors were encountered: