Skip to content

Neeshant01/Desi-spy

Desi Spy

A consent-based local monitoring demo built with Python and Flask for educational testing, device diagnostics, optional screenshot capture, optional webcam capture, and simple dashboard export workflows.

Important Safety Note

This repository is for consent-based, authorized, educational use only.

  • do not use it on devices you do not own or explicitly control
  • do not collect screenshots, webcam images, or device data without clear permission
  • do not present this project as a stealth or covert surveillance tool

Problem It Solves

This project demonstrates how a lightweight client-server monitoring workflow can be built for learning purposes: collect local device information with consent, send it to a Flask server, and inspect or export the captured data from a simple dashboard.

Key Features

  • Collects basic device information
  • Fetches public IP with fallback handling
  • Optional screenshot capture with explicit prompt
  • Optional webcam capture with explicit prompt
  • Sends collected data to a Flask endpoint
  • Displays stored entries in a minimal dashboard
  • Supports JSON export of stored records

Tech Stack

  • Python
  • Flask
  • Requests
  • PyAutoGUI
  • OpenCV

Project Structure

.
|-- client/
|   `-- client.py
|-- server/
|   `-- app.py
|-- requirements.txt
`-- README.md

Requirements

  • Python 3.10+
  • A local environment with camera and screenshot permissions if you want to test capture flows

Installation

  1. Create a virtual environment.
python -m venv .venv
.venv\Scripts\activate
  1. Install dependencies.
pip install -r requirements.txt

Configuration

Optional environment variables:

  • DESI_SPY_SERVER_URL for the client upload endpoint
  • DESI_SPY_DATA_FILE for custom server-side storage location
  • HOST and PORT for the Flask server
  • FLASK_DEBUG=1 only for local debugging

Run Locally

Start the server:

cd server
python app.py

Then start the client:

cd client
python client.py

The client will ask for permission before capturing a screenshot or webcam image.

Usage Notes

  • Best used on a local machine or trusted LAN for demo purposes
  • Export collected data from the /export endpoint
  • Review what is collected before sharing any output

Limitations

  • Dashboard UI is intentionally simple
  • Data is stored in a local JSON file, not a database
  • Screenshot and webcam behavior depend on local device permissions
  • This project is not positioned as a production monitoring platform

Privacy and Ethics

  • explicit consent is required before optional media capture
  • keep storage local unless you fully understand the privacy impact
  • avoid collecting sensitive data in real-world scenarios
  • document usage clearly if you demo this project to others

Demo Plan

Suggested demo title:

  • Desi Spy Demo: Consent-Based Local Monitoring with Python and Flask

Suggested screenshot filenames:

  • docs/images/client-consent-prompts.png
  • docs/images/flask-dashboard.png
  • docs/images/export-workflow.png

Suggested Open Graph preview idea:

  • A split layout showing the terminal-based client prompts and the lightweight dashboard with the title Consent-Based Monitoring Demo

Roadmap

  • Add a cleaner dashboard interface
  • Improve storage handling and data review UX
  • Add better testability around capture-free flows
  • Keep safety messaging strong and visible

Contributing

Contributions are welcome for clarity, safety, maintainability, and documentation improvements.

See CONTRIBUTING.md for details.

License

This repository is available under the MIT License.

Author

Built by Nishant Kumar

About

Consent-based local monitoring demo built with Python and Flask for device diagnostics, optional capture flows, and dashboard export.

Topics

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages