Skip to content

e1l1ya/telegram-bot-sqli-simulation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Telegram bot SQLi simulation

This repository contains a Telegram bot that simulates a SQL injection vulnerability in a voting system. This project is intended for educational purposes only to demonstrate SQL injection risks in Python applications. Do not use this bot in production or against real users.


Features

  • Vote for candidates via Telegram messages
  • Stores votes in a SQLite database
  • Admin management
  • Demonstrates how unsanitized SQL queries can be exploited
  • View current voting results

Installation

  1. Clone the repository:
git clone https://github.com/e1l1ya/telegram-bot-sqli-simulation.git
cd telegram-bot-sqli-simulation
  1. Create a virtual environment:
python -m venv venv
source venv/bin/activate   # Linux / macOS
venv\Scripts\activate      # Windows
  1. Install dependencies:
pip install -r requirements.txt
  1. Set your Telegram bot token in the code (TOKEN variable in main.py line 6).

  2. Run the bot:

python main.py

Usage

  1. Start the bot by sending /start in Telegram.
  2. Vote for a candidate by selecting a button.
  3. View results by sending /result.

Important Notes

  • This bot intentionally contains unsafe SQL queries to simulate SQL injection.
  • This project is for learning purposes only. Do not use it for real attacks.
  • All user votes are stored in votes.db.

Support

Follow HackMeLocal on Telegram for more educational security content.


License

This project is licensed under the MIT License.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages