Pornography Addiction Recovery App with VPN-Based Content Blocking
Eraser is a native Android application designed to help users overcome pornography addiction through:
- VPN-based network-level content blocking (156,000+ adult domains)
- Flashcard intervention system (60 motivational cards with truly random selection)
- Journey tracking with streaks, achievements, and daily check-ins
- Analytics and reports to monitor progress
- Gamification with rewards and milestones
This is a complete rewrite of the original Flutter app in native Android using Kotlin and Jetpack Compose.
- Language: Kotlin
- UI Framework: Jetpack Compose (Material Design 3)
- Architecture: MVVM (Model-View-ViewModel)
- Database: Room 2.6.1
- Dependency Injection: Hilt 2.48
- Navigation: Jetpack Navigation Component
- Async: Coroutines + Flow
- Background Tasks: WorkManager 2.9.0
- Build System: Gradle 8.12 with Kotlin DSL
- Min SDK: 26 (Android 8.0)
- Target SDK: 34 (Android 14)
eraser-native-android/
├── app/
│ ├── src/
│ │ ├── main/
│ │ │ ├── kotlin/com/eraser/recovery/
│ │ │ │ ├── data/ # Data layer
│ │ │ │ │ ├── local/ # Room database, DAOs, entities
│ │ │ │ │ └── repository/ # Repository implementations
│ │ │ │ ├── domain/ # Business logic
│ │ │ │ │ ├── flashcard/ # Flashcard service (60 cards, random)
│ │ │ │ │ ├── journey/ # Journey tracking, streaks
│ │ │ │ │ ├── statistics/ # Analytics and reports
│ │ │ │ │ ├── achievement/ # Achievement system
│ │ │ │ │ └── notification/ # Notification service
│ │ │ │ ├── ui/ # UI layer (Jetpack Compose)
│ │ │ │ │ ├── screens/ # All app screens
│ │ │ │ │ │ ├── onboarding/
│ │ │ │ │ │ ├── home/
│ │ │ │ │ │ ├── safepage/
│ │ │ │ │ │ ├── rewards/
│ │ │ │ │ │ ├── reports/
│ │ │ │ │ │ ├── settings/
│ │ │ │ │ │ ├── history/
│ │ │ │ │ │ └── checkin/
│ │ │ │ │ ├── theme/ # Material Design 3 theme
│ │ │ │ │ └── navigation/ # Navigation graph
│ │ │ │ ├── vpn/ # VPN service (CURRENTLY NON-FUNCTIONAL)
│ │ │ │ │ ├── EraserVpnService.kt
│ │ │ │ │ ├── VpnManager.kt
│ │ │ │ │ ├── Tun2SocksManager.kt (requires native library)
│ │ │ │ │ ├── Socks5ProxyServer.kt
│ │ │ │ │ └── BlocklistService.kt (156,000+ domains)
│ │ │ │ ├── di/ # Hilt dependency injection modules
│ │ │ │ └── MainActivity.kt # Single activity
│ │ │ ├── res/ # Resources (layouts, drawables, etc.)
│ │ │ └── AndroidManifest.xml
│ │ └── test/ # Unit tests
│ └── build.gradle.kts # App-level Gradle config
├── gradle/ # Gradle wrapper
├── build.gradle.kts # Project-level Gradle config
├── settings.gradle.kts # Gradle settings
├── .gitignore
└── README.md
- Onboarding Flow (6 pages)
- Home Screen with VPN toggle (UI only)
- Safe Page Screen with flashcard intervention
- Rewards Screen with achievements
- Reports Screen with analytics
- Settings Screen
- Blocked History Screen
- Daily Check-in Screen
- Database (Room) with 6 entities
- Flashcard System (60 cards, truly random)
- Journey Tracking with streaks
- Achievement System (15+ achievements)
- Statistics Service
- Notification Service
- VPN Service - Native library
libtun2socks-jni.somissing - Content Blocking - VPN doesn't route traffic
- Real-world Intervention - Flashcards never trigger from actual blocking
- App launches without crashes
- All UI screens render correctly
- Navigation works
- Database operations work
- Flashcard random selection works
- Journey tracking works (without VPN)
- Achievements unlock correctly
- Emulator-friendly (no confusing VPN errors)
- VPN functionality (requires native library or alternative)
- Adult content blocking (depends on VPN)
- Physical device testing (VPN won't work)
- Android Studio Hedgehog (2023.1.1) or later
- JDK 17 or later
- Android SDK 34
- Gradle 8.12
- Clone the repository:
git clone https://github.com/itsoumya-d/eraser-android-native.git
cd eraser-android-native- Open in Android Studio
- Sync Gradle dependencies
- Build APK:
./gradlew clean assembleDebug- Install on device/emulator:
adb install -r app/build/outputs/apk/debug/app-debug.apkandroidx.core:core-ktx:1.12.0androidx.lifecycle:lifecycle-runtime-ktx:2.7.0
androidx.compose:compose-bom:2024.02.00androidx.compose.material3:material3
androidx.room:room-runtime:2.6.1androidx.room:room-ktx:2.6.1
com.google.dagger:hilt-android:2.48
androidx.work:work-runtime-ktx:2.9.0
[To be determined]
- Soumya Debnath (@itsoumya-d)
Note: VPN functionality is not yet implemented. The app is suitable for UI/UX testing on emulator only.