Skip to content

KrishnasaiBitra/ATM_Ope_Project

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

3 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🏧 ATM Simulation System using C++


πŸš€ Overview

This project simulates a simple ATM system built in C++ featuring:

  • Two user types: Account Holders & Admin
  • Basic PIN-based authentication with XOR encryption
  • Object-Oriented Design: Classes, inheritance, encapsulation

πŸ‘₯ User Roles

πŸ‘€ Account Holder

  • Log in with PIN
  • View account details
  • Withdraw & Deposit money

πŸ›‘οΈ Admin

  • Secure login
  • View admin credentials
  • Reset any user's balance

πŸ”‘ Core Functionalities

  • PIN Encryption:
    encryptDecrypt() uses XOR with a key for basic PIN protection.

  • AccountHolder Class:
    Stores account number, name, balance, encrypted PIN.
    Methods:

    • verifyPin() – Check PIN (after decryption)
    • withdraw() – Deducts balance
    • deposit() – Adds to balance
    • showDetails() – Displays account info
  • Admin Class:
    Inherits from AccountHolder.
    Methods:

    • showDetails() – Displays admin info
    • resetBalance() – Modify user balance
  • ATM Class:
    Handles user interaction & operations.
    Methods:

    • accessAccount() – Login, view, withdraw, deposit
    • findAccount() – Search by name/account number

βš™οΈ Features

  • OOP Principles: Classes, inheritance, encapsulation
  • Simple Authentication: PIN-based, encrypted storage
  • Admin Controls: User management & balance resets
  • Interactive Input Loop: Multiple operations per session

🧩 Example Test Case

User Login:

  1. Enter account number or name (e.g., John Doe)
  2. Enter PIN (e.g., 1234)
  3. View balance, withdraw, deposit

Admin Login:

  1. Enter admin PIN (admin)
  2. Reset any user's balance

⚠️ Potential Issues & Suggested Improvements

Issue Description & Suggestions
πŸ”’ Weak PIN Encryption XOR w/ single key is insecure. Use modern hashing (SHA-256)
πŸ’Ύ No Data Persistence Data lost on exit. Use files or DB for real storage
🚫 Limited Error Handling Add input validation (e.g., negatives, non-numeric input)
πŸ›‘οΈ Admin Inheritance Admin inherits AccountHolder, but may not need balance
🧹 Input Stream Handling Careful use of cin.ignore() to avoid input glitches

πŸ“š Quick Start

g++ atm_simulation.cpp -o atm_simulation
./atm_simulation

πŸ“ Summary

A well-structured demonstration of OOP in C++ with user/admin roles, basic encryption, and ATM functionalities.
For real-world use:

  • Improve security
  • Add persistent storage
  • Enhance input validation

🎯 Try it, extend it, and make banking fun (and secure)! πŸš€

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages