A comprehensive ATM management system implemented in C that allows users to manage bank accounts with various features including account creation, transactions, and account management.
- ✅ User registration and login with duplicate name checking
- ✅ Create new accounts (savings, current, fixed-term)
- ✅ View all accounts for a user
- ✅ Check detailed account information with interest calculations
- ✅ Make transactions (deposit/withdraw) with validation
- ✅ Update account information (country/phone)
- ✅ Remove existing accounts with confirmation
- ✅ Transfer account ownership between users
- ✅ Comprehensive input validation and error handling
- Password input masking during login/registration
- User authentication and authorization
- Account ownership validation
- Input sanitization and validation
- GCC compiler
- Make utility
- Git (for cloning)
- Clone the repository:
git clone https://learn.zone01kisumu.ke/git/oumouma/atm-management-system- Navigate to the project directory:
cd atm-management-system- Compile the project:
make clean
make- Run the application:
./atm.
├── data/
│ ├── users.txt # User credentials storage
│ └── records.txt # Account records storage
├── src/
│ ├── main.c # Main program and menu system
│ ├── auth.c # Authentication functions
│ ├── system.c # Core system functions
│ └── header.h # Function declarations and structures
├── Makefile # Build configuration
├── test_atm.sh # Testing guidance script
├── test_interest.c # Interest calculation verification
└── README.md # This file
Once the application is running, you'll see a menu-driven interface. Follow the on-screen prompts to:
- Register a new user account or Login with existing credentials
- Create new bank accounts (savings, current, fixed-term)
- View all your accounts or check detailed account information
- Make transactions (deposit/withdraw)
- Update account information
- Remove accounts or transfer ownership
- Alice: password
q1w2e3r4t5y6 - Michel: password
q1w2e3r4t5y6
- Savings: 7% annual interest (calculated monthly: balance × 0.07 ÷ 12)
- Current: No interest
- Fixed01: 4% annual interest (1 year term: balance × 0.04)
- Fixed02: 5% annual interest (2 year term: balance × 0.05 × 2)
- Fixed03: 8% annual interest (3 year term: balance × 0.08 × 3)
- Savings: Monthly on the deposit day
- Fixed accounts: Lump sum on maturity date
- Current: No interest
- Savings/Current accounts: Allow deposits and withdrawals
- Fixed accounts: No transactions allowed (deposits/withdrawals blocked)
- Withdrawal validation: Cannot withdraw more than available balance
- Amount validation: All amounts must be positive
id name password
0 Alice q1w2e3r4t5y6
1 Michel q1w2e3r4t5y6
id userId userName accountId date country phone balance accountType
0 0 Alice 834213 10/10/2012 UK 291231392 1001.20 saving
gcc test_interest.c -o test_interest && ./test_interest./test_atm.shThe system passes all audit requirements including:
- User registration with duplicate checking
- Account creation with proper validation
- Interest calculations matching expected values:
- Saving account ($1001.20): $5.84 monthly interest
- Fixed01 account ($1001.20): $40.05 total interest
- Fixed02 account ($1001.20): $100.12 total interest
- Fixed03 account ($1001.20): $240.29 total interest
- Transaction restrictions on fixed accounts
- Account removal and ownership transfer
checkAccountDetails(): View account with interest calculationsmakeTransaction(): Handle deposits/withdrawals with validationupdateAccountInfo(): Update country/phone with file persistenceremoveAccount(): Delete account with confirmationtransferOwnership(): Transfer account to another usercalculateInterest(): Compute interest based on account type
- File I/O error checking
- Input validation for all user inputs
- Account existence verification
- User ownership validation
- Transaction amount validation
This project is for educational purposes as part of the Zone01 curriculum.