Override Poetry's update command to audit packages before they are updated
Project description
Customs Inspector
Customs Inspector is a Python tool that hooks into Poetry's package management system
to allow for manual auditing of package changes during updates.
When you run poetry update
, Customs Inspector will open a browser with a GitHub diff like view, requesting you to confirm or reject the update before proceeding.
Demo
Note:
TESTED ONLY ON Poetry v1.4.x
This is a proof of concept. Poetry explicitly says to not use the plugin system to modify existing commands.
If this is something that is considered valuable, I would love to discuss this with Poetry's authors to potentially integrate it.
Why?
Developers are lazy, we'd rather not audit source code...
Well, we cannot afford that anymore.
I am also not interested in the snake oil automated analysis companies are selling (for now).
What if auditing was really easy to do so?
What if, we could harness the community's collective effort to find malicious packages?
Usage
# install the plugin
poetry self add customs-inspector
# run update like you normally would
poetry update
Upcoming:
- Increase speed
- Add language server support to make auditing even easier
- Add file filtering, to hide test folders, for example
- Add rules for quick auditing, for example when new sensitive APIs are used (
socket, os, sys
)
Contributions
Feedback, contributions and suggestions welcome.
License
GPL-3.0
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file customs_inspector-0.2.2.tar.gz
.
File metadata
- Download URL: customs_inspector-0.2.2.tar.gz
- Upload date:
- Size: 3.4 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.4.1 CPython/3.10.2 Linux/5.10.0-21-amd64
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a20fc7f8077e999fc7b577078b086f6b282c5c7c30303ac082c789c27caca1ae |
|
MD5 | a37f04b9265e46bf245b5ca477af7b81 |
|
BLAKE2b-256 | e1123eea798889301b68421e8e6c41d1a005305b732d63bcf988d522792769b5 |
File details
Details for the file customs_inspector-0.2.2-py3-none-any.whl
.
File metadata
- Download URL: customs_inspector-0.2.2-py3-none-any.whl
- Upload date:
- Size: 3.4 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.4.1 CPython/3.10.2 Linux/5.10.0-21-amd64
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | dee0cbb188651b3fbf50b4548e1b95c2bd46ef4aad7fc791eb55e9776167f71b |
|
MD5 | 71134247f28aaa3322ff6bc1a486d55e |
|
BLAKE2b-256 | e9b74d5ae7cd00b2f412689cc6a1697db1bf96b450f872f22f67292680586e06 |