https://github.com/kourva/picklepasswd
Simple script to access password information in /etc/passwd
https://github.com/kourva/picklepasswd
base64 etc etc-passwd passwd pickle pickling python python3 self-modifying-code
Last synced: about 1 month ago
JSON representation
Simple script to access password information in /etc/passwd
- Host: GitHub
- URL: https://github.com/kourva/picklepasswd
- Owner: Kourva
- Created: 2023-09-12T17:38:50.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-08-28T15:43:44.000Z (9 months ago)
- Last Synced: 2025-03-26T04:34:45.709Z (about 2 months ago)
- Topics: base64, etc, etc-passwd, passwd, pickle, pickling, python, python3, self-modifying-code
- Language: Python
- Homepage:
- Size: 13.7 KB
- Stars: 5
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
![]()
PicklePasswd
Simple script to access password information in /etc/passwd
# About
This script demonstrates how someone could create a simple script to potentially access your password information without your knowledge.1. **Initialization**: After running `init.py`, this script will generate a pickle file in the same directory as `init.py`.
2. **Platform Check**: When executed, the script will check the platform. If it's not Linux, the script will delete itself to avoid any unintended consequences on incompatible systems.
3. **Execution**: When you run `run.py`, the script will load the pickle file and modify itself.
4. **Second Execution**: If you execute `run.py` for the second time the main script will attempt to access information stored in `/etc/passwd`. It will then save this information in a file called `.passwd` within the same directory as the script and once the code runs successfully, the script will change its own source code to a simple "Hello, World!" comment, effectively altering its functionality.
**Note that this script is not harmfull or any other type of viruses. this will just read a file, main porpse is to show how pickle viruses work.**# Installation
+ Clone repository
```bash
git clone https://github.com/Kourva/PicklePasswd
```
+ Open source folder
```bash
cd PicklePasswd
```
+ Execute `init.py` to create pickle script
```bash
python3 init.py
```
+ Execute `run.py` to load pickle script
```bash
python3 run.py
```
+ Execute `run.py` again to run script
```bash
python3 run.py
```