Skip to content
dipsanaPublic

About

Secure E-Gram Panchayat platform with OTP auth, location verification, role-based workflows, and digital village services.

Topics

Resources

Security policy

Stars

1 star

Watchers

0 watching

Forks

Latest commit

ย 

History

12 Commits

Folders and files

NameName
Last commit message
Last commit date
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐ŸŒฟ LokVeda โ€” Digital E-Gram Panchayat System

LokVeda is a full-stack E-Gram Panchayat Management System designed to digitize village-level governance and citizen services while maintaining security, accessibility, and ease of use for non-technical users.

The platform provides secure authentication, role-based service workflows, application review pipelines, area-wise service management, and citizen-centric service delivery through a modern web interface.


๐Ÿš€ Version

Current Version: v2.1.0

LokVeda v2.1.0 is a complete rewrite of the original Firebase prototype and introduces a full backend architecture with authentication, authorization, workflow management, and administrative controls.

If link doesn't work click here: https://lokveda.onrender.com

If link doesn't work click here: https://github.com/dipsana/lokveda


๐Ÿ›๏ธ Project Overview

LokVeda simulates a real-world Panchayat service portal where citizens can:

  • Apply for government services
  • Track application status
  • Re-submit rejected applications
  • View approved services
  • Access services available in their area

Staff members review applications and forward valid requests to administrators.

Administrators manage services, approve applications, and oversee Panchayat operations.


๐Ÿ‘ฅ User Roles

๐Ÿ‘ค Citizen

  • Login using Aadhaar number and OTP
  • Apply for active services
  • View application status
  • Re-submit rejected applications
  • View profile information

๐Ÿง‘โ€๐Ÿ’ผ Staff

  • Review citizen applications
  • Reject incomplete applications
  • Forward valid applications to administrators
  • Review previously rejected applications

๐Ÿ›ก๏ธ Administrator

  • Activate or deactivate services
  • Approve reviewed applications
  • Review rejected applications
  • View approved applications
  • Monitor service availability within their Panchayat

โœจ Core Features

๐Ÿ” Secure Authentication

  • Aadhaar-based login
  • Email OTP verification
  • Crypto-generated OTP codes
  • Hashed OTP storage using bcrypt
  • JWT-based authentication
  • Session token management
  • Single active session per account

๐ŸŒ Location Verification

LokVeda performs geographic verification before OTP generation.

  • Citizens: Allowed within registered states
  • Staff: Allowed within 10 km of assigned area
  • Administrators: Allowed within 250 km of assigned area

Location distance is displayed using user-friendly messages.

๐Ÿ›ก๏ธ Security Controls

  • Maximum login attempt protection
  • Suspicious login detection
  • Session validation
  • Device tracking
  • IP logging
  • Location tracking
  • Account lock mechanisms

โณ Session Management

  • Auth token during login
  • Session token after verification
  • Automatic session expiry
  • Secure logout handling
  • Protection against duplicate sessions

๐ŸŒ™ Dark Mode

  • Automatic browser preference detection
  • Local preference persistence
  • Smooth transitions
  • Available throughout the application

๐Ÿค– Greeting System

Dynamic greeting messages based on:

  • User name
  • Time of day
  • Sunrise and sunset calculations

๐Ÿ“‹ Application Workflow

Citizen

Application Submitted

โ†“

Pending Review

โ†“

Reviewed by Staff

โ†“

Approved by Admin


Rejection Flow

Application Submitted

โ†“

Rejected

โ†“

Citizen Corrects Application

โ†“

Re-submitted

โ†“

Review Process Continues


๐Ÿงฉ Service Management

Administrators can activate or deactivate services independently for each Panchayat area.

Citizens only see:

  • Active services
  • Rejected applications eligible for correction

Applications already pending, reviewed, or approved are hidden from the service application page.


๐Ÿ“„ Available Services

  • Birth Certificate
  • Death Certificate
  • Property Certificate
  • Property Tax
  • Water Tax
  • MGNREGA Registration
  • RTI Application
  • Land Records
  • Welfare Schemes
  • Subsidies
  • Grievance Submission
  • Skill Training
  • Employment Assistance
  • Health Checkup Registration
  • Sanitation Requests
  • Public Notices
  • Public Works Information
  • Election Updates
  • Voter ID Services
  • Voter List Services
  • Tenders
  • Government Dues

๐Ÿ“ Project Structure โ€” LokVeda v2.1.0

lokveda/
โ”‚
โ”œโ”€โ”€ ๐Ÿ“ controllers/
โ”‚ โ”œโ”€โ”€ auth.controller.js
โ”‚ โ”œโ”€โ”€ dashboard.controller.js
โ”‚ โ””โ”€โ”€ service.controller.js
โ”‚
โ”œโ”€โ”€ ๐Ÿ“ middleware/
โ”‚ โ””โ”€โ”€ auth.middleware.js
โ”‚
โ”œโ”€โ”€ ๐Ÿ“ models/
โ”‚ โ”œโ”€โ”€ area.model.js
โ”‚ โ”œโ”€โ”€ polygon.model.js
โ”‚ โ”œโ”€โ”€ service.model.js
โ”‚ โ””โ”€โ”€ user.model.js
โ”‚
โ”œโ”€โ”€ ๐Ÿ“ routes/
โ”‚ โ”œโ”€โ”€ admin.route.js
โ”‚ โ”œโ”€โ”€ citizen.route.js
โ”‚ โ”œโ”€โ”€ global.route.js
โ”‚ โ””โ”€โ”€ staff.route.js
โ”‚
โ”œโ”€โ”€ ๐Ÿ“ public/
โ”‚ โ”‚
โ”‚ โ”œโ”€โ”€ ๐Ÿ“ css/
โ”‚ โ”‚ โ”œโ”€โ”€ auth.css
โ”‚ โ”‚ โ”œโ”€โ”€ dashboard.css
โ”‚ โ”‚ โ”œโ”€โ”€ home.css
โ”‚ โ”‚ โ”œโ”€โ”€ profile.css
โ”‚ โ”‚ โ”œโ”€โ”€ style-global.css
โ”‚ โ”‚ โ”œโ”€โ”€ utilities.css
โ”‚ โ”‚ โ””โ”€โ”€ ๐Ÿ“ services/
โ”‚ โ”‚
โ”‚ โ”œโ”€โ”€ ๐Ÿ“ js/
โ”‚ โ”‚ โ”œโ”€โ”€ auth.js
โ”‚ โ”‚ โ””โ”€โ”€ script-global.js
โ”‚ โ”‚
โ”‚ โ”œโ”€โ”€ ๐Ÿ“ images/
โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“ background/
โ”‚ โ”‚ โ”‚ โ”œโ”€โ”€ lokveda-dark.png
โ”‚ โ”‚ โ”‚ โ””โ”€โ”€ lokveda-light.png
โ”‚ โ”‚ โ”‚
โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“ icons/
โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“ services/
โ”‚ โ”‚ โ”‚
โ”‚ โ”‚ โ”œโ”€โ”€ default-avatar.png
โ”‚ โ”‚ โ”œโ”€โ”€ default-service.jpg
โ”‚ โ”‚ โ”œโ”€โ”€ favicon.png
โ”‚ โ”‚ โ””โ”€โ”€ preview.png
โ”‚ โ”‚
โ”‚ โ””โ”€โ”€ ๐Ÿ“ uploads/
โ”‚ โ””โ”€โ”€ ๐Ÿ“ profile-pics/
โ”‚
โ”œโ”€โ”€ ๐Ÿ“ views/
โ”‚ โ”‚
โ”‚ โ”œโ”€โ”€ ๐Ÿ“ partials/
โ”‚ โ”‚ โ”œโ”€โ”€ header.ejs
โ”‚ โ”‚ โ”œโ”€โ”€ nav.ejs
โ”‚ โ”‚ โ”œโ”€โ”€ footer.ejs
โ”‚ โ”‚ โ””โ”€โ”€ ๐Ÿ“ forms/
โ”‚ โ”‚
โ”‚ โ”œโ”€โ”€ ๐Ÿ“ services/
โ”‚ โ”‚ โ”œโ”€โ”€ applications.ejs
โ”‚ โ”‚ โ”œโ”€โ”€ apply.ejs
โ”‚ โ”‚ โ”œโ”€โ”€ create.ejs
โ”‚ โ”‚ โ”œโ”€โ”€ menu.ejs
โ”‚ โ”‚ โ”œโ”€โ”€ status.ejs
โ”‚ โ”‚ โ”œโ”€โ”€ update.ejs
โ”‚ โ”‚ โ””โ”€โ”€ view.ejs
โ”‚ โ”‚
โ”‚ โ”œโ”€โ”€ auth.ejs
โ”‚ โ”œโ”€โ”€ dashboard.ejs
โ”‚ โ”œโ”€โ”€ home.ejs
โ”‚ โ””โ”€โ”€ profile.ejs
โ”‚
โ”œโ”€โ”€ ๐Ÿ“ services/
โ”‚ โ””โ”€โ”€ email.service.js
โ”‚
โ”œโ”€โ”€ ๐Ÿ“ documentation/
โ”‚
โ”œโ”€โ”€ index.js
โ”‚
โ”œโ”€โ”€ .gitignore
โ”œโ”€โ”€ CHANGELOG.md
โ”œโ”€โ”€ LICENSE
โ”œโ”€โ”€ README.md
โ”œโ”€โ”€ SECURITY.md
โ”œโ”€โ”€ package-lock.json
โ””โ”€โ”€ package.json


Forms Supported

The system currently supports 22 government services:

  • Birth Certificate
  • Death Certificate
  • Property Registration
  • Land Records
  • Property Tax
  • Water Tax
  • Grievance Submission
  • RTI Requests
  • MGNREGA Registration
  • Welfare Schemes
  • Subsidies
  • Skill Training
  • Employment Assistance
  • Health Checkup Registration
  • Sanitation Requests
  • Election Updates
  • Voter ID Services
  • Voter List Verification
  • Public Notices
  • Public Works Tracking
  • Government Tenders
  • Utility Dues

Architecture Overview

Client Browser
      โ”‚
      โ–ผ
 Express Routes
      โ”‚
      โ–ผ
 Controllers
      โ”‚
      โ–ผ
 Middleware
      โ”‚
      โ–ผ
 Mongoose Models
      โ”‚
      โ–ผ
 MongoDB Database

Security Layers

  1. Aadhaar Validation
  2. Location Verification
  3. OTP Verification
  4. JWT Authentication
  5. Session Validation
  6. Role-Based Authorization
  7. Service Access Control
  8. Account Locking Protection

Core Modules

Authentication Module

  • Aadhaar Verification
  • Email OTP Verification
  • JWT Authentication
  • Device Session Tracking
  • Suspicious Login Detection

Service Module

  • Dynamic Form Rendering
  • Application Submission
  • Application Review
  • Application Approval
  • Application Rejection
  • Email Service Updates

Administration Module

  • Service Activation
  • Service Deactivation
  • Area-wise Management
  • Application Approval Workflow

Dashboard Module

  • Citizen Dashboard
  • Staff Dashboard
  • Admin Dashboard

UI Module

  • Dark Mode
  • Responsive Design
  • Dynamic Navigation
  • Friendly Status Messaging
  • Area-aware Footer

๐Ÿ› ๏ธ Technology Stack

Frontend

  • HTML5
  • CSS3
  • JavaScript
  • EJS

Backend

  • Node.js
  • Express.js

Database

  • MongoDB
  • Mongoose

Authentication & Security

  • JWT
  • bcrypt
  • crypto
  • validator

Communication

  • Nodemailer

๐Ÿƒโ€โ™‚๏ธโ€โžก๏ธ Deployment Infrastructure

  • Render โ€” Application hosting and deployment platform used for running the Node.js and Express.js server in a cloud environment.
  • Cloudflare (Planned / Future Integration) โ€” Intended for DNS management, performance optimization, SSL enhancement, caching, and protection against automated bots and malicious traffic.

๐Ÿ—๏ธ Architecture

LokVeda follows the MVC (Model-View-Controller) architecture.

Models

  • User
  • Service
  • Area
  • Polygon

Controllers

  • Authentication Controller
  • Dashboard Controller
  • Service Controller

Middleware

  • Authentication Middleware
  • Session Validation
  • Authorization Checks

Views

  • Home
  • Authentication
  • Dashboard
  • Profile
  • Services
  • Applications
  • Status Tracking

Services

  • Centralized Email Service
  • Sends secure OTP verification emails
  • Sends application status emails (Submitted, Approved and Rejected)
  • Provides reusable HTML email templates across the application

๐ŸŽจ User Experience Highlights

  • Friendly status messages
  • Responsive layouts
  • Area-aware service visibility
  • Rejected form auto-fill
  • Consistent navigation system
  • Accessible visual hierarchy
  • Low learning curve for rural users

โš ๏ธ Current Limitations

  • File uploads not implemented
  • PDF generation not implemented
  • Document downloads not implemented
  • Search functionality postponed
  • Notifications not implemented
  • Analytics dashboard not implemented

๐Ÿ”ฎ Future Scope

  • File upload support
  • PDF generation
  • Digital document downloads
  • SMS notifications
  • Advanced analytics
  • Search and filtering
  • Multi-language support
  • Mobile application
  • Profile images currently use demonstration avatars stored locally within the application. User-uploaded profile images and cloud-based media storage are planned for future releases
  • Custom domain integration through Cloudflare
  • Enhanced security using Cloudflare bot protection and traffic filtering
  • Global content delivery optimization through Cloudflare CDN

๐Ÿ“œ License

This project is licensed under the MIT License.


๐Ÿ‘จโ€๐Ÿ’ป Developer

Dipsana Roy

Lead Developer, System Architect, Backend Developer, Frontend Developer, Database Designer, Documentation Author


๐Ÿ“Œ Academic Note

LokVeda was developed as an academic project demonstrating secure authentication, role-based access control, workflow management, session security, and digital governance concepts in a Panchayat-level service delivery system.

About

Secure E-Gram Panchayat platform with OTP auth, location verification, role-based workflows, and digital village services.

Topics

Resources

Security policy

Stars

1 star

Watchers

0 watching

Forks

Releases

Contributors

Languages