Skip to content

sangsaist/LinkSafe-Android

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

2 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ›‘οΈ LinkSafe

Open-Source Mobile Security Platform for Real-Time URL Analysis

License: MIT Flutter Dart Kotlin Android PRs Welcome

Features β€’ Quick Start β€’ Architecture β€’ Contributing


πŸ“– Table of Contents


🌟 Overview

LinkSafe is a comprehensive mobile utility app designed to track, analyze, and verify URLs in real-time. By providing detailed risk scoring, domain whitelisting, and historical analytics, LinkSafe helps you stay safe from phishing attempts and malicious websites directly from your Android device.

🎯 Mission

Transform the uncertain experience of opening unknown links into a structured, measurable, transparent process that enables data-driven mobile security at an individual level.


πŸ’‘ The Problem

Most users face critical challenges when determining the safety of links they receive:

❌ Current State

  • βœ— Guessing whether a link is safe
  • βœ— Vulnerability to redirect loops
  • βœ— No history of scanned malicious links
  • βœ— Binary (Safe/Unsafe) warnings with no context
  • βœ— Time-consuming manual verification

βœ… With LinkSafe

  • βœ“ Automated pattern-based risk analysis
  • βœ“ Infinite redirect loop prevention
  • βœ“ Complete tracking history locally stored
  • βœ“ Granular risk scoring (0-100)
  • βœ“ Instant, on-device verification

πŸš€ Our Solution

Analysis-Driven Architecture

graph LR
    A[User Input] --> B[URL Validation]
    B --> C[Whitelist Check]
    C --> D[Pattern Checker]
    D --> E[Risk Score Computation]
    E --> F[Redirect Safety Check]
    F --> G[History Storage]
    
    style A fill:#667eea
    style B fill:#764ba2
    style C fill:#f093fb
    style D fill:#4facfe
    style E fill:#00f2fe
    style F fill:#43e97b
    style G fill:#38f9d7
Loading

Core Philosophy

Analysis is the first line of defense.
Risk scores are computed locally.
Privacy is maintained through on-device processing.

This separation ensures speed, accuracy, and maximum user privacy.


✨ Features

πŸ” Pattern Checking πŸ›‘οΈ Domain Whitelist πŸ“Š Risk Analytics πŸ“– History Tracking
Regex-based scanning Trusted site verification 0-100 Score Metric Persistent Storage
Deep URL Inspection Known safe domain bypass Confidence Indicators Shared Preferences
Redirect Loop Fixes Fast-path resolution Interactive Graphics Detailed Timestamps

πŸ•΅οΈ Advanced Detection

  • πŸ“ˆ Analyze URLs for obfuscations and suspicious characters
  • πŸ“Š Calculate granular risk scores rather than binary flags
  • πŸ… Recognize and fast-track whitelisted domains instantly
  • πŸ”„ Stop infinite redirect loops natively via Kotlin integration

πŸ“± Seamless User Experience

  • πŸ‘€ Fluid bottom navigation architecture
  • βœ… Instant risk classification and detailed reporting
  • πŸ“‰ Easily access previously checked URLs via History Screen
  • πŸ“‹ Copy and clear links intuitively

πŸ—οΈ System Architecture

High-Level Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                     User Interface (Flutter)                 β”‚
β”‚         Main Screen β€’ History Screen β€’ Bottom NavBar         β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                         β”‚ Method Channels & State
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                    Business Logic (Dart)                     β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”   β”‚
β”‚  β”‚ PatternChecker   β”‚  HistoryService  β”‚  URL Validator  β”‚   β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜   β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                         β”‚ Native Bridgework
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                   Native Layer (Android)                     β”‚
β”‚  MainActivity.kt (Redirect Loop Prevention & Invocation)     β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                         β”‚ Local Storage
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                  Database Layer (SharedPreferences)          β”‚
β”‚            Persistent History Entries β€’ User Settings        β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Data Flow

sequenceDiagram
    participant U as User
    participant UI as Flutter Frontend
    participant PC as Pattern Checker
    participant N as Native Layer (Kotlin)
    participant DB as Local Storage

    U->>UI: Enter suspicious URL
    UI->>PC: Request Analysis
    PC->>PC: Check Whitelist
    PC->>PC: Compute Risk Score (0-100)
    UI->>N: Open Link Safely
    N->>N: Prevent Redirect Loops
    UI->>DB: Store History Entry
    DB->>UI: Update History Screen
    UI->>U: Display Safe Content / Warning
Loading

πŸ› οΈ Technology Stack

Frontend & Core Logic

Flutter Dart

Native Integration & Persistence

Android Kotlin Shared Preferences

Layer Technology Purpose
Framework Flutter Cross-platform UI toolkit
Language Dart Core application logic
Native Base Kotlin Android specific integrations (Redirects)
Storage SharedPreferences Fast, persistent local data
Routing Flutter Navigator Smooth screen transitions
Analytics PatternChecker Service Risk computation algorithm

πŸš€ Quick Start

Option 1: Build from Source β€” 5 Minutes

# 1. Clone the repository
git clone https://github.com/sangsaist/LinkSafe-Android.git
cd LinkSafe-Android

# 2. Get dependencies
flutter pub get

# 3. Connect your Android device or start an emulator

# 4. Run the application
flutter run

System Requirements

  • Flutter SDK 3.x+
  • Android Studio / Android SDK
  • Minimum Android SDK Version: 21 (Lollipop)
  • Target Android SDK Version: 33+

πŸ”’ Security Features

  • βœ… On-Device Analysis – URLs are analyzed locally without sending personal data to third parties.
  • βœ… Anti-Redirect Loops – Native Kotlin defenses stop infinite tracking redirects.
  • βœ… Risk Scoring Engine – Heuristics-based scoring for precise threat detection.
  • βœ… Granular Whitelisting – Bypasses scans for definitively safe domains to eliminate false positives.
  • βœ… Non-Persistent Tracking – App does not track user location or inject trackers.

πŸ—ΊοΈ Roadmap

Project status: Active development and refinement.

βœ… v1.0 – Foundation (Current)

  • βœ… Bottom Navigation integration
  • βœ… URL PatternChecking logic
  • βœ… Basic User Interface
  • βœ… Infinite redirect prevention in Android layer
  • βœ… Granular risk scoring (0-100) implementation
  • βœ… History Service with persistent local storage
  • βœ… Whitelisted domains database

πŸ”œ v1.5 – Enhanced Analytics (Planned)

  • πŸ”„ Integration with external threat intelligence APIs (e.g., Google Safe Browsing)
  • πŸ”„ URL shortener unmasking
  • πŸ”„ Background clipboard scanning
  • πŸ”„ Advanced visualizations for URL components

πŸ“Š v2.0 – Cross-Platform (Future)

  • πŸ“Š iOS Compatibility and Native Swift bridging
  • πŸ“Š Web Extension integration
  • πŸ“Š Cloud sync for URL history

πŸ“ Project Structure

LinkSafe-Android/
β”œβ”€β”€ android/
β”‚   β”œβ”€β”€ app/src/main/kotlin/
β”‚   β”‚   └── .../MainActivity.kt # Redirect Logic & Method Channels
β”œβ”€β”€ lib/
β”‚   β”œβ”€β”€ main.dart               # Entry point & App Shell
β”‚   β”œβ”€β”€ screens/                
β”‚   β”‚   β”œβ”€β”€ checker_screen.dart # Main URL Scanner UI
β”‚   β”‚   └── history_screen.dart # Checked Links History UI
β”‚   β”œβ”€β”€ services/
β”‚   β”‚   β”œβ”€β”€ pattern_checker.dart# Risk Scoring & Whitelist
β”‚   β”‚   └── history_service.dart# SharedPreferences wrapper
β”‚   └── models/
β”‚       └── history_entry.dart  # Data model for checked URLs
β”œβ”€β”€ pubspec.yaml                # Flutter dependencies
└── README.md

🀝 Contributing

Contributions are welcome! Help us make mobile browsing safer for everyone.

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/your-feature
  3. Commit your changes: git commit -m 'feat: Add your feature'
  4. Push to the branch: git push origin feature/your-feature
  5. Open a Pull Request

πŸ“„ License

This project is licensed under the MIT License β€” see the LICENSE file for details.


Built with ❀️ for Security

Making the Web Safe, One Link at a Time.

⬆ Back to Top


Β© 2026 LinkSafe. Open Source Project under MIT License.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors