A comprehensive Android solution that forces USB UVC cameras to be the only available system cameras, completely blocking internal cameras while maintaining system stability and Play Integrity.
This project provides a runtime-only solution for forcing USB UVC cameras as the exclusive system cameras on Android devices. It's specifically designed for the Pixel 8a (akita) running EvolutionX 15, but compatible with other Android 10+ devices.
- Complete Internal Camera Blocking: Internal front/back cameras become inaccessible
- UVC Camera Promotion: USB UVC cameras are mapped to camera IDs 0 and 1
- System-wide Enforcement: Works with all camera apps and video calling applications
- Dual-layer Protection: LSPosed Java hooks + Zygisk native enforcement
- Play Integrity Safe: Maintains system integrity and passes safety checks
- Runtime Only: No ROM building, vendor modifications, or HAL changes required
- Device: Pixel 8a (akita) or any Android 10+ device
- ROM: EvolutionX 15 (Android 15) or any Android 10+ ROM
- Root: Magisk with Zygisk enabled
- Framework: LSPosed installed and active
- Architecture: ARM64 (arm64-v8a)
- USB UVC Camera: UVC compliant USB camera
- USB OTG: Device must support USB OTG functionality
- Power: Adequate power delivery for USB camera
- CameraManager Hooks: Intercepts camera enumeration and access
- Camera ID Remapping: Maps UVC cameras to IDs 0 and 1
- App Compatibility: Works with all Java-based camera apps
- Runtime Injection: No permanent system modifications
- NDK Camera Hooks: Intercepts native Camera2 API calls
- Low-level Enforcement: Blocks camera access at native level
- Performance Optimized: Minimal overhead and system impact
- Universal Coverage: Works with native camera implementations
- Module Management: Easy installation via Magisk Manager
- Boot Service: Automatic initialization on device boot
- Permission Handling: Automatic permission granting
- System Integration: Seamless integration with Android system
UvcCameraEnforcer/
βββ app/ # LSPosed Module
β βββ src/main/
β β βββ java/com/yourname/uvccameraenforcer/
β β β βββ MainHook.kt # Main Xposed hooks
β β β βββ MainActivity.kt # Module UI
β β βββ assets/
β β β βββ xposed_init # Xposed initialization
β β βββ res/
β β β βββ values/
β β β βββ xposed_scope.xml # Hook scope configuration
β β βββ AndroidManifest.xml # Module manifest
β βββ build.gradle.kts # Gradle configuration
βββ zygisk/ # Native Zygisk Module
β βββ src/
β β βββ main.cpp # C++ hooks implementation
β βββ CMakeLists.txt # CMake build configuration
β βββ build.gradle.kts # Gradle configuration
βββ magisk/ # Magisk Module Files
β βββ module.prop # Module metadata
β βββ install.sh # Installation script
β βββ service.sh # Boot service
β βββ README.md # Module documentation
βββ build_magisk.sh # Build script
βββ INSTALLATION.md # Installation guide
βββ DEMO.md # Demo instructions
βββ README.md # This file
- Download the latest
UvcCameraEnforcer_v1.0.zip - Install via Magisk Manager
- Reboot device
- Enable module in LSPosed Manager
- Connect USB UVC camera
- Test with any camera app
See INSTALLATION.md for comprehensive installation guide.
- Android Studio or Android SDK
- NDK (Native Development Kit)
- Gradle
- Git
# Clone repository
git clone <repository-url>
cd UvcCameraEnforcer
# Build everything
chmod +x build_magisk.sh
./build_magisk.sh# Build LSPosed module
./gradlew assembleDebug
# Build Zygisk module
cd zygisk
../gradlew assembleRelease
# Package into Magisk module
# Follow build_magisk.sh script- Connect your USB UVC camera to the device
- Open any camera app (Google Camera, Instagram, WhatsApp, etc.)
- The app will only see and use the UVC camera
- Internal cameras will be completely inaccessible
- Open the UVC Camera Enforcer app to check status
- View detected cameras and their mappings
- Enable debug logging if needed
- Camera Enumeration: Verify only UVC cameras are listed
- App Testing: Test with multiple camera apps
- Video Calling: Test with WhatsApp, Discord, Zoom
- System Stability: Ensure no crashes or instability
- Play Integrity: Verify safety checks pass
- Camera 0: First UVC camera
- Camera 1: Second UVC camera (if available)
- Internal cameras: Completely blocked
- All apps: Use UVC camera exclusively
The module identifies UVC cameras by:
- External lens facing (
LENS_FACING_EXTERNAL) - Hardware model containing "UVC" or "USB"
- Common UVC vendor IDs (Logitech, Sonix, Realtek, etc.)
- Java Layer: Xposed hooks on CameraManager methods
- Native Layer: PLT hooks on Camera2 NDK functions
- System Integration: Magisk module for boot-time initialization
- No system partition modifications
- Reversible installation
- Play Integrity compliant
- Minimal performance impact
- Module not working: Check LSPosed activation and permissions
- UVC camera not detected: Verify USB OTG and camera compatibility
- App crashes: Check logcat for specific error messages
- Play Integrity issues: Temporarily disable module to isolate
# View module logs
logcat | grep UvcCameraEnforcer
# Check camera enumeration
logcat | grep CameraManager
# System information
getprop ro.product.model
magisk -vThis project is released under the MIT License. See LICENSE file for details.
This module modifies system camera behavior. Use at your own risk. The developer is not responsible for any damage to your device or loss of functionality.
Contributions are welcome! Please:
- Fork the repository
- Create a feature branch
- Make your changes
- Test thoroughly
- Submit a pull request
For issues and support:
- Check the troubleshooting section
- Provide device model, Android version, and ROM details
- Include logcat output when reporting issues
- Create detailed bug reports with reproduction steps
See DEMO.md for instructions on creating a demonstration video showing the module in action.
Note: This is a highly technical Android development project intended for developers with experience in LSPosed, Zygisk, Magisk modules, and Android Camera2 internals. Generic explanations or conceptual diagrams are not considered valid submissions - only working modules with actual implementations.