From c4500a034a9136461cc7f2562d688c55fabe6a05 Mon Sep 17 00:00:00 2001 From: Byteintosh <158021536+Byteintosh@users.noreply.github.com> Date: Tue, 26 Mar 2024 23:00:30 +0700 Subject: [PATCH] =?UTF-8?q?=F0=9F=93=9DAdd=20documentation?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 22 +++++++++++++++++++++- main.py | 4 ++-- 2 files changed, 23 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index dec1934..5a932f0 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,22 @@ # Simple-TOTP -Simple TOTP Program using Python. + +This repository contains the code for a simple Time-based One-Time Password (TOTP) generator. + +## Usage + +1. Install the required dependencies by running `pip install pyotp`. +2. Add secret and password in `secret key` `password here` +3. Run the `main.py` script to generate a TOTP. + +## Build to exe + +1. Install pyinstaller by running `pip install pyinstaller` +2. Build by running `pyinstaller main.py --onefile --noconsole` + +## License + +This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for more information. + +## Acknowledgements + +Special thanks to the developers of [pyotp](https://github.com/pyotp/pyotp) for providing the library used in this project. \ No newline at end of file diff --git a/main.py b/main.py index 9727275..0b1be1c 100644 --- a/main.py +++ b/main.py @@ -3,11 +3,11 @@ import os import tkinter as tk -totp = pyotp.TOTP("") +totp = pyotp.TOTP("secret key") def check_password(): password = password_entry.get() - if password == "": + if password == "password here": def update_totp(): current_totp = totp.now() totp_label.config(text="Current TOTP: \n" + current_totp) # Update the label with current TOTP