mirror of
https://github.com/openlibrecommunity/olcng.git
synced 2026-07-03 14:05:17 +02:00
9b4cc201e77c43b6d4d6812c407c9fb584676dbd
Add support for preSharedKey in WireGuard configurations and fix the parsing function to correctly handle all necessary fields. Previously, the application did not support the optional preSharedKey parameter in WireGuard config files, forcing users to rely on JSON custom configurations. This update introduces a dedicated field for preSharedKey in the UI, aligning with Xray Core's support and simplifying the setup process for users. Changes include: - Added `preSharedKey` field in the WireGuard UI configuration. - Updated `parseWireguardConfFile` function to correctly parse `PrivateKey`, `PublicKey`, and `preSharedKey`. - Ensured `preSharedKey` is optional and handled gracefully when absent. - Updated `toOutbound` method to include `preSharedKey` in the outbound configuration. - Set `remarks` to the current Unix time during parsing. Tested with the following configuration: ```[Interface] Address = 192.168.6.66/32 DNS = 1.1.1.1,8.8.8.8 PrivateKey = eD/6cpJQaEeDH05AMeFyN3KSLLX+7YFR+MYRdgPDQ3Y= [Peer] publickey=/HS7r3waPuU7tTBLd2FlBhC+VROpJ5bwh5XXxuOoKFs= AllowedIPs = 0.0.0.0/0, ::/0 Endpoint = sg3.vpnjantit.com:1024 ``` Resolves #3512
v2rayNG
A V2Ray client for Android, support Xray core and v2fly core
Telegram Channel
Usage
Geoip and Geosite
- geoip.dat and geosite.dat files are in
Android/data/com.v2ray.ang/files/assets(path may differ on some Android device) - download feature will get enhanced version in this repo (Note it need a working proxy)
- latest official domain list and ip list can be imported manually
- possible to use third party dat file in the same folder, like h2y
More in our wiki
Development guide
Android project under V2rayNG folder can be compiled directly in Android Studio, or using Gradle wrapper. But the v2ray core inside the aar is (probably) outdated.
The aar can be compiled from the Golang project AndroidLibV2rayLite or AndroidLibXrayLite.
For a quick start, read guide for Go Mobile and Makefiles for Go Developers
v2rayNG can run on Android Emulators. For WSA, VPN permission need to be granted via
appops set [package name] ACTIVATE_VPN allow