This module provides a custom OkHttpClient implementation for React Native apps, allowing you to easily add SSL pinning and other custom network configurations to your Android app.
This module creates a custom OkHttpClientFactory that disables SSL certificate validation. This is useful for development and testing purposes, but should not be used in production without careful consideration of the security implications.
- Android
- Install the package:
npm install react-native-okhttps
# or
yarn add react-native-okhttps
- Rebuild and reinstall your app:
Note: If you encounter any issues, try uninstalling the app from your device/emulator before rebuilding and reinstalling.
The current implementation disables SSL certificate validation, which can be a significant security risk. This should only be used for development and testing purposes. For production use, implement proper SSL pinning or certificate validation.
We welcome contributions to improve this module. Please submit issues and pull requests on our GitHub repository.