Signed-off-by: ale <ale@manalejandro.com>
WiFi Attack Detector
Detect and track WiFi attacks in real-time using your Android device
Features • Installation • Usage • How It Works • Contributing • License
Overview
WiFi Attack Detector is an Android application that monitors WiFi network activity to detect potential security threats. It analyzes WiFi scan results to identify suspicious patterns that may indicate various types of attacks, including deauthentication attacks, evil twin attacks, and beacon floods.
Features
🔍 Real-time WiFi Monitoring
- Continuous scanning of nearby WiFi networks
- Detection of network anomalies and suspicious patterns
- Live updates with configurable scan intervals
📊 Channel Statistics
- Visual representation of activity per WiFi channel
- Error packet estimation based on network behavior
- Threat level indicators (None, Low, Medium, High, Critical)
- Support for 2.4GHz, 5GHz, and 6GHz bands
⚠️ Attack Detection
- Deauthentication Attacks: Detects sudden disconnection patterns
- Evil Twin Attacks: Identifies duplicate SSIDs on the same channel
- Beacon Flood: Detects excessive access point beacons
- Probe Flood: Identifies suspicious probe request activity
🧭 Signal Direction Tracking
- Uses device compass and accelerometer
- Records signal strength at different orientations
- Estimates the direction of attack sources
- Visual compass display with signal indicators
📱 Modern Android UI
- Material Design 3 (Material You)
- Jetpack Compose UI
- Dark/Light theme support
- Clean, intuitive interface
Screenshots
Requirements
- Android 7.0 (API level 24) or higher
- WiFi-enabled device
- Location permissions (required for WiFi scanning)
- Compass sensor (optional, for direction tracking)
Installation
From Source
- Clone the repository:
git clone https://github.com/manalejandro/WifiAttack.git
cd WifiAttack
-
Open the project in Android Studio
-
Build and run on your device:
./gradlew assembleDebug
From Release
Download the latest APK from the Releases page.
Usage
Getting Started
- Grant Permissions: On first launch, grant location and WiFi permissions when prompted
- Start Monitoring: Tap the play button to begin WiFi scanning
- View Dashboard: Monitor overall network status and threat level
- Explore Channels: Navigate to "Channels" tab for detailed per-channel statistics
- Track Attacks: View detected attacks in the "Attacks" tab
- Find Direction: Use the "Direction" tab to locate signal sources
Understanding Threat Levels
| Level | Color | Description |
|---|---|---|
| None | Green | No suspicious activity detected |
| Low | Light Green | Minor anomalies detected |
| Medium | Orange | Moderate suspicious activity |
| High | Deep Orange | Significant threat indicators |
| Critical | Red | Active attack likely in progress |
Direction Tracking
- Navigate to the "Direction" tab
- Select a network to track from the list
- Slowly rotate your device 360 degrees
- The app will record signal strength at each direction
- The strongest signal direction indicates the likely source location
How It Works
Detection Methods
WiFi Attack Detector uses heuristic analysis of WiFi scan results to detect potential attacks:
-
Network Count Anomalies: Sudden changes in the number of visible networks may indicate beacon flood attacks or deauthentication attempts
-
RSSI Fluctuations: Rapid changes in signal strength can indicate jamming or interference attacks
-
Duplicate SSIDs: Multiple access points with the same SSID on the same channel may indicate evil twin attacks
-
Hidden Networks: Excessive hidden networks can be indicators of attack infrastructure
Limitations
⚠️ Important: This app uses publicly available Android APIs and cannot:
- Capture raw WiFi packets (requires root)
- See actual deauthentication frames
- Monitor encrypted traffic
The app provides estimates based on observable network behavior. For comprehensive WiFi security monitoring, consider dedicated hardware solutions.
Architecture
com.manalejandro.wifiattack/
├── MainActivity.kt # Main activity and navigation
├── data/
│ └── model/
│ ├── WifiNetworkInfo.kt # Network data model
│ ├── ChannelStats.kt # Channel statistics model
│ └── AttackEvent.kt # Attack event model
├── service/
│ ├── WifiScannerService.kt # WiFi scanning and analysis
│ └── DirectionSensorManager.kt # Compass and direction tracking
├── presentation/
│ ├── WifiAttackViewModel.kt # Main ViewModel
│ └── screens/
│ ├── DashboardScreen.kt # Main dashboard
│ ├── ChannelStatsScreen.kt # Channel statistics
│ ├── AttacksScreen.kt # Attack history
│ └── DirectionScreen.kt # Signal direction tracker
└── ui/
└── theme/ # Material 3 theming
Tech Stack
- Language: Kotlin
- UI Framework: Jetpack Compose
- Architecture: MVVM
- Minimum SDK: 24 (Android 7.0)
- Target SDK: 36
Dependencies
- AndroidX Core KTX
- Jetpack Compose (BOM 2024.09.00)
- Material 3 Components
- Lifecycle ViewModel Compose
- Navigation Compose
- Kotlinx Coroutines
Contributing
Contributions are welcome! Please read our Contributing Guidelines before submitting pull requests.
Development Setup
- Fork the repository
- Create a feature branch:
git checkout -b feature/your-feature - Make your changes
- Run tests:
./gradlew test - Submit a pull request
Privacy
WiFi Attack Detector:
- Does NOT collect or transmit any user data
- Does NOT require internet connection
- Only uses WiFi scanning for local analysis
- All data remains on your device
See our Privacy Policy for more details.
License
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.
Copyright 2024 manalejandro
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Disclaimer
This application is provided for educational and security research purposes. Users are responsible for ensuring compliance with local laws and regulations regarding WiFi monitoring. The developers are not responsible for any misuse of this application.
Acknowledgments
- Material Design 3 for the design system
- Jetpack Compose for the modern UI framework
- The Android security research community
Made with ❤️ for network security awareness



