An educational package demonstrating that pip packages can freely access your filesystem. Think before you install.
Project description
a_package_that_demo_pypi_vulnerability
An educational package that demonstrates a fundamental security concern with the Python packaging ecosystem: any package you pip install can freely access your entire filesystem.
What does it do?
When you call the demonstrate_vulnerability() function, it:
- Walks your entire home directory
- Lists every file it finds along with its size
- Prints a warning explaining what just happened
Nothing is exfiltrated, uploaded, or sent anywhere. All output goes to your terminal. The point is to show you what a malicious package could do silently.
Why does this exist?
When you run pip install some-package, that package's code runs with your full user permissions. There is no sandbox, no permission prompt, and no filesystem restriction. A malicious package could:
- Read your SSH keys, cloud credentials, and browser cookies
- Scan your source code and configuration files
- Send all of this to a remote server — silently, at install time
This package makes that risk tangible by showing you exactly how much of your filesystem is accessible to any installed Python code.
Installation
pip install a_package_that_demo_pypi_vulnerability
Usage
from a_package_that_demo_pypi_vulnerability import demonstrate_vulnerability
demonstrate_vulnerability()
Disclaimer
This package is for educational purposes only. It does not collect, transmit, or store any data. No code runs at install time — the demonstration only executes when you explicitly call the function. Use it to learn about supply-chain security risks and to make informed decisions about the packages you install.
License
MIT
Project details
Release history Release notifications | RSS feed
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file a_package_that_demo_pypi_vulnerability-0.1.0.tar.gz.
File metadata
- Download URL: a_package_that_demo_pypi_vulnerability-0.1.0.tar.gz
- Upload date:
- Size: 2.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ee653b8c0cc3c99a901f745d4e2cea538735434acbb1764e495710c65cffb949
|
|
| MD5 |
30335d2aec340a38e5f19e4944bf5225
|
|
| BLAKE2b-256 |
422fad9c848c1836ab5ba4109b9ce8fc9118111bfb9fbd4d6992f89ffdc0503e
|
File details
Details for the file a_package_that_demo_pypi_vulnerability-0.1.0-py3-none-any.whl.
File metadata
- Download URL: a_package_that_demo_pypi_vulnerability-0.1.0-py3-none-any.whl
- Upload date:
- Size: 4.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cac0262e7ee68eb7fa8a48377f3d243df07aa09c2886f3ec9b027f7cb4520d8e
|
|
| MD5 |
17d156e1bf51f0cd538d21568503fa19
|
|
| BLAKE2b-256 |
b51de2b04f71f52d74c0efdf9bff4bb70b263bf8224f624114b5bf00e652cc2f
|