├── README.md └── psswdmngr.py /README.md: -------------------------------------------------------------------------------- 1 | 🔐 Password Manager 2 | 3 | A lightweight and secure password manager for storing, generating, and managing credentials. This project helps users protect sensitive information with encryption while maintaining ease of access and usability. 4 | 5 | 🚀 Features 6 | 7 | Secure Storage: All passwords are encrypted before being saved. 8 | 9 | Password Generator: Create strong, random passwords with custom rules. 10 | 11 | Search & Retrieve: Easily find stored accounts by name or category. 12 | 13 | Cross-Platform: Works on Windows, macOS, and Linux (depending on implementation). 14 | 15 | Simple UI/CLI: Manage passwords via a clean interface or terminal commands. 16 | 17 | 🛠️ Installation 18 | 19 | Clone the repository: 20 | 21 | git clone https://github.com/your-username/Password_Manager.git 22 | cd Password_Manager 23 | 24 | 25 | Install dependencies (example for Python): 26 | 27 | pip install -r requirements.txt 28 | 29 | 30 | Run the application: 31 | 32 | python main.py 33 | 34 | 📖 Usage 35 | 36 | Add a password: 37 | 38 | python main.py add 39 | 40 | 41 | Retrieve a password: 42 | 43 | python main.py get 44 | 45 | 46 | Generate a password: 47 | 48 | python main.py generate 49 | 50 | 51 | List all accounts: 52 | 53 | python main.py list 54 | 55 | 56 | (Adjust commands depending on your implementation — CLI, GUI, or API.) 57 | 58 | 🔒 Security Notes 59 | 60 | Master password is required to unlock the vault. 61 | 62 | Data is encrypted using industry-standard algorithms (e.g., AES-256). 63 | 64 | Ensure you never share your master password. 65 | 66 | For extra safety, store your database file in a secure location. 67 | 68 | 📂 Project Structure 69 | Password_Manager/ 70 | │── main.py # Entry point 71 | │── manager.py # Core password manager logic 72 | │── storage/ # Database or file-based storage 73 | │── utils/ # Helpers (encryption, validation, etc.) 74 | │── requirements.txt # Dependencies 75 | │── README.md # Documentation 76 | 77 | 🧩 Roadmap 78 | 79 | Add browser extension support 80 | 81 | Enable cloud synchronization 82 | 83 | Implement 2FA for vault access 84 | 85 | Create desktop app with GUI 86 | 87 | 🤝 Contributing 88 | 89 | Contributions are welcome! Please fork the repository and submit a pull request. 90 | 91 | Author Name: Anslem Otutu 92 | Github: https://github.com/Otutu11 93 | 94 | 95 | 📜 License 96 | 97 | This project is licensed under the MIT License. 98 | -------------------------------------------------------------------------------- /psswdmngr.py: -------------------------------------------------------------------------------- 1 | import tkinter as tk 2 | from tkinter import messagebox, simpledialog 3 | from cryptography.fernet import Fernet 4 | 5 | 6 | def load_key(): 7 | try: 8 | with open("key.key", "rb") as file: 9 | return file.read() 10 | except FileNotFoundError: 11 | messagebox.showerror("Error", "Key file not found! Generate it first.") 12 | return None 13 | 14 | 15 | def view_passwords(): 16 | try: 17 | with open("passwords.txt", "r") as f: 18 | passwords = f.readlines() 19 | 20 | if not passwords: 21 | messagebox.showinfo("View Passwords", "No stored passwords.") 22 | return 23 | 24 | decrypted_passwords = [] 25 | for line in passwords: 26 | user, passw = line.strip().split("|") 27 | decrypted_passwords.append(f"User: {user} | Password: {fer.decrypt(passw.encode()).decode()}") 28 | 29 | messagebox.showinfo("Stored Passwords", "\n".join(decrypted_passwords)) 30 | except FileNotFoundError: 31 | messagebox.showerror("Error", "Passwords file not found!") 32 | 33 | 34 | def add_password(): 35 | name = simpledialog.askstring("Input", "Enter Account Name:") 36 | if not name: 37 | return 38 | pwd = simpledialog.askstring("Input", "Enter Password:", show='*') 39 | if not pwd: 40 | return 41 | 42 | with open("passwords.txt", "a") as f: 43 | f.write(f"{name}|{fer.encrypt(pwd.encode()).decode()}\n") 44 | 45 | messagebox.showinfo("Success", "Password added successfully!") 46 | 47 | 48 | key = load_key() 49 | if key: 50 | fer = Fernet(key) 51 | 52 | # Create UI 53 | root = tk.Tk() 54 | root.title("Password Manager") 55 | root.geometry("300x200") 56 | 57 | tk.Label(root, text="Password Manager", font=("Arial", 14, "bold")).pack(pady=10) 58 | 59 | view_button = tk.Button(root, text="View Passwords", command=view_passwords) 60 | view_button.pack(pady=5) 61 | 62 | add_button = tk.Button(root, text="Add Password", command=add_password) 63 | add_button.pack(pady=5) 64 | 65 | exit_button = tk.Button(root, text="Exit", command=root.quit) 66 | exit_button.pack(pady=5) 67 | 68 | root.mainloop() 69 | --------------------------------------------------------------------------------