Skip to content

nikhilpredicts/OTP-Verification-System-Python

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

8 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ” OTP Verification System (Python)

This project is a Python-based OTP (One-Time Password) verification system designed to enhance user authentication via email. It generates a secure 6-digit OTP and sends it to the user's email address for validation. Simple, functional, and ideal for scenarios where basic email-based security is required.


πŸ“ Repository Structure

Got it, Nikhil! Here's a clean and informative section you can add to your README.md to explain your repository structureβ€”tailored to showcase clarity and professionalism:


πŸ“ Repository Structure

This repository is neatly organized to support both presentation and implementation of the OTP Verification system:

OTP Verification System Python/
β”œβ”€β”€ Presentation/
β”‚   └── OTP Verification.pdf
β”‚       β†ͺ️ Project presentation highlighting objectives, workflow, code walkthrough, and test cases
β”‚
β”œβ”€β”€ Source File/
β”‚   └── Python_Capstone_Project_iynb.ipynb
β”‚       β†ͺ️ Jupyter Notebook containing the full implementation of the OTP verification system
β”‚       β†ͺ️ Includes function definitions, email integration, verification logic, and test scenario outputs
β”‚
β”œβ”€β”€ README.md
    β†ͺ️ Professional documentation describing project goals, structure, features, setup, and contact info


πŸš€ Features

  • βœ… Random 6-digit OTP generation
  • πŸ“§ Email delivery using Gmail SMTP
  • πŸ” User verification with retry attempts
  • ⚠️ Error handling for invalid emails and failed attempts

πŸ› οΈ Tech Stack

  • Python
  • Google Colab / Jupyter Notebook
  • SMTP (smtplib)
  • email.mime modules

🧩 Functions Explained

Function Name Purpose
otp() Generates a secure 6-digit OTP
send_otp_email() Sends the OTP to user’s email address
verify_otp() Prompts user to enter OTP and validates input
main() Integrates the process and handles flow control

πŸ§ͺ Test Scenarios

  • βœ… Scenario 1: Valid email and correct OTP β€” access granted
  • ❌ Scenario 2: Invalid email β€” email sending fails
  • πŸ” Scenario 3: Incorrect OTP entered multiple times β€” access denied

🎯 Learning Outcomes

  • Crafting real-time email verification logic in Python
  • Implementing user input validation and flow control
  • Error handling and robustness
  • Use of SMTP for secure email communication

πŸ“– Presentation

Refer to Presentation/OTP Verification.pdf for a structured walkthrough of the system’s architecture, code highlights, and test case breakdowns.


🀝 Acknowledgements

Built by Nikhil Karaka, Special thanks to documentation resources that supported SMTP and Python module implementation.


πŸ“¬ Contact

For queries or suggestions, feel free to reach out via email or connect on GitHub.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published