Poetry 1.1.8 does not include the security fix for mismatching package hashes
See original GitHub issueHello, it appears to me that the latest Poetry release (1.1.8) does not contain this important security fix that makes Poetry actually check the hashes of downloaded files against the hashes in poetry.lock
.
I tried to alter the hashes in my poetry.lock
and reinstall one package on Poetry 1.1.8, and it did not complain.
Also, it’s evident that this commit is not present in the chooser.py
file in the release-1.1.8
branch, but it is present in the master
version of the file.
It looks like some weird Git merging issue. Can we make sure this security fix gets included ASAP in the next release? Thank you 🙏🏼
Issue Analytics
- State:
- Created 2 years ago
- Reactions:22
- Comments:7 (1 by maintainers)
Top Results From Across the Web
Python poetry install failure - invalid hashes - Stack Overflow
I ctrl-C 'd during a poetry install , which caused one of the cached wheels to partially download and have a hash that...
Read more >Commands | Documentation | Poetry - Python dependency ...
This command will help you create a pyproject.toml file interactively by prompting you to provide basic information about your package.
Read more >poetry-dynamic-versioning - PyPI
Dynamic versioning plugin for Poetry. This is a Python 3.7+ plugin for Poetry 1.2.0+ and Poetry Core 1.0.0+ to enable dynamic versioning based...
Read more >Should You Use Upper Bound Version Constraints?
To be clear, Poetry doesn't force version pinning on you, but it does push you really, really hard to always version cap, and...
Read more >Third-party dependencies - Pants build
poetry_requirements () target generator parses the Poetry section in ... python_sources( name="lib", dependencies=[ # We don't have an import statement for ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Granted, now I get this error: • Installing auth-client (1.6.0): Failed
AttributeError
‘Link’ object has no attribute ‘name’
at ~/.pyenv/versions/3.7.9/lib/python3.7/site-packages/poetry/installation/executor.py:620 in _download_link 616│ ).hash() 617│ ) 618│ if archive_hash not in {f[“hash”] for f in package.files}: 619│ raise RuntimeError( → 620│ “Invalid hash for {} using archive {}”.format(package, archive.name) • Installing auth-client (1.6.0): Failed
AttributeError
‘Link’ object has no attribute ‘name’
WHY exactly auth-client, and another internal to my company package are failing the hash check is a different and scary question. This is on a fresh clean install with no lock file.
The hash being calculated here is sha256, but the one in the lock file is md5?
It is fixed in 1.1.9, I just checked that
poetry install
correctly detects a corrupt hash. Thanks!