Skip to content

Codris-exe/FakeLinkDetector

Repository files navigation

SafeLink Scanner - Web Extension

A comprehensive browser extension that scans URLs and websites to detect potential fraud, phishing attempts, and malicious content. Built with a dark theme and real-time protection features.

Features

Core Functionality

  • Real-time URL Scanning: Automatically scans the current tab's URL
  • Manual URL Analysis: Scan any URL manually through the popup interface
  • Fraud Detection Algorithms: Multiple detection methods including:
    • IP address detection (suspicious direct IP usage)
    • Suspicious top-level domains (TLDs)
    • URL shortener detection
    • Domain spoofing detection
    • Phishing keyword detection
    • Homograph attack detection
    • Excessive URL length analysis

User Interface

  • Dark Theme: Modern, sleek dark interface following user preferences
  • Risk Scoring: 0-100 risk score for each URL
  • Detailed Reports: Shows specific issues found during scanning
  • Statistics Tracking: Tracks URLs scanned and threats blocked
  • Real-time Status Updates: Loading indicators and status messages

Protection Features

  • Warning Banners: Prominent alerts for high-risk websites
  • Link Previewing: Hover over links to see risk assessment
  • Click Protection: Confirms navigation to dangerous URLs
  • Visual Indicators: Color-coded risk levels (green/yellow/red)

Background Monitoring

  • Automatic Scanning: Continuous monitoring of web navigation
  • Badge Indicators: Extension icon shows current page risk status
  • Notification System: Desktop notifications for detected threats
  • Domain Blocking: Automatic blocking of high-risk domains (optional)

Installation

For Development

  1. Clone or download this project
  2. Open Chrome/Edge and navigate to chrome://extensions/
  3. Enable "Developer mode" in the top right
  4. Click "Load unpacked" and select the project directory
  5. The extension will appear in your browser toolbar

Icon Generation

  1. Open generate_icons.html in your browser
  2. Click "Download All Icons" to get the required icon files
  3. Save them to the /icons/ directory with the correct filenames

File Structure

FakeLinkDetector/
├── manifest.json          # Extension configuration and permissions
├── popup.html             # Main popup interface
├── popup.css              # Dark theme styling
├── popup.js               # URL scanning logic and UI interactions
├── content.js             # Content script for page monitoring
├── background.js          # Background script for continuous monitoring
├── generate_icons.html    # Icon generation utility
├── icons/                 # Extension icons directory
│   └── README.md          # Icon requirements and guidelines
└── README.md              # This file

Detection Algorithms

URL Pattern Analysis

  • IP Address Detection: Flags URLs using direct IP addresses instead of domain names
  • Suspicious TLDs: Detects domains using high-risk extensions (.tk, .ml, .ga, .cf, etc.)
  • Domain Length: Identifies unusually long or complex domain structures

Content Analysis

  • Phishing Keywords: Scans for common phishing terms (login, verify, account, etc.)
  • URL Shorteners: Detects known URL shortening services
  • Homograph Attacks: Identifies domains using similar-looking characters

Domain Reputation

  • Spoofing Detection: Identifies domains mimicking legitimate companies
  • Subdomain Analysis: Flags unusual subdomain patterns
  • Whitelist Checking: Maintains list of known legitimate domains

Risk Scoring

The extension uses a cumulative scoring system:

  • 0-9 points: Safe (Green) - No significant risks detected
  • 10-24 points: Low Risk (Yellow) - Minor concerns, exercise normal caution
  • 25-49 points: Medium Risk (Orange) - Several suspicious indicators
  • 50+ points: High Risk (Red) - Multiple fraud indicators, high danger

Privacy & Security

Data Handling

  • Local Storage Only: All scan data stored locally on your device
  • No External Servers: Scanning performed entirely in-browser
  • No Data Collection: Extension doesn't collect or transmit user data
  • Minimal Permissions: Only requests necessary browser permissions

Permissions Used

  • activeTab: Access current tab URL for scanning
  • tabs: Monitor tab changes and navigation
  • storage: Store scan history and user preferences locally
  • scripting: Inject content scripts for page monitoring

Configuration

The extension includes several configurable options:

  • Notification Settings: Enable/disable desktop notifications
  • Auto-blocking: Automatically block high-risk domains
  • Scan Sensitivity: Adjust detection thresholds
  • Theme Options: Dark theme (default) with toggle capability

Development

Technologies Used

  • HTML5: Modern semantic markup
  • CSS3: Dark theme with gradients and animations
  • JavaScript ES6+: Modern JavaScript features and APIs
  • Chrome Extensions API: Manifest V3 compatibility

Key Components

  1. URLScanner Class: Main scanning logic and algorithms
  2. ContentScanner Class: Page monitoring and real-time protection
  3. BackgroundScanner Class: Background processing and notifications
  4. Dark Theme CSS: Comprehensive styling system

Limitations & Disclaimers

Technical Limitations

  • Client-side Only: Cannot perform server-side reputation checks
  • Pattern-based: Relies on pattern matching, not real-time threat intelligence
  • False Positives: May flag legitimate sites with suspicious patterns
  • No Malware Scanning: Does not scan for malware, only URL-based threats

Security Note

This extension provides an additional layer of protection but should not be considered a complete security solution. Always use updated antivirus software and practice safe browsing habits.

Support & Contribution

Issues

If you encounter any problems or have suggestions:

  1. Check the browser console for error messages
  2. Verify all files are properly loaded
  3. Ensure extension has necessary permissions

Future Enhancements

  • Integration with threat intelligence feeds
  • Machine learning-based detection
  • Community-driven whitelist/blacklist
  • Advanced reporting and analytics
  • Multi-language support

License

This project is provided as-is for educational and personal use. Feel free to modify and extend the functionality for your needs.

Changelog

Version 1.0.0

  • Initial release
  • Core URL scanning functionality
  • Dark theme interface
  • Real-time protection features
  • Background monitoring system
  • Statistics tracking
  • Icon generation utility

About

Web Extension for URL fraud detection with dark theme and real-time protection

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors