A lightweight Universal Windows proxy app based on https://github.com/eycorsican/leaf
- Comes with Leaf core:
- Domain name resolution with built-in DNS processor
tun
/http
/socks
/trojan
/ws
chainable inboundsdirect
/drop
/tls
/ws
/h2
/shadowsocks
/vmess
/trojan
/socks
chainable outboundsfailover
/tryall
/random
/retry
composed outboundsamux
multiplexing- Rule system based on IP, GeoIP and domain name
- External rules from GeoIP database and V2Ray Domain List Community
- Configuration management
- Outbound network adapter selection
- UWP VPN Platform as TUN provider
Maple as a UWP app is distributed for sideloading only. When installed, it acts as a VPN provider which you will find in the VPN Settings. Use Maple app for configuration management, as well as adding external databases.
- Grab the latest package from Release page.
- Extract everything from the package.
- Right click the certificate (named
Maple.App_x.y.z.0_x64.cer
) and select Install Certificate. - On the Certificate Import Wizard, select Local Machine. Administrator privileges may be required to proceed.
- Import the certificate to the Trusted Root Certification Authorities folder. Note: failure to import the certificate or choosing a wrong certificate store will prevent you from installing the app.
- Open the AppxBundle (named
Maple.App_x.y.z.0_x64.appxbundle
) and follow the instructions until Maple is successfully installed on your computer.
- Launch Maple from the Start menu.
- Edit configuration. Refer to https://github.com/eycorsican/leaf/blob/master/README.zh.md for further explanation.
- Save the configuration file.
- If any
EXTERNAL
orGEOIP
directive is used, drag external database files intoConfig
area. V2Ray Domain List Community database can be fetched at https://github.com/v2ray/domain-list-community/releases/latest/download/dlc.dat . For GeoIP database, see this script for inspiration. - Rename these databases accordingly (if applicable). By default, GeoIP database is
geo.mmdb
and V2Ray Domain List Community database issite.dat
. - Go to Setting page in Maple. Choose your network adapter such as
Ethernet
orWLAN
. - Launch Windows Settings app.
- Add a VPN connection.
- For VPN provider, choose Maple.
- In the Connection name box, enter Maple.
- In the Server name or address box, enter https://github.com/YtFlow/Maple .
- Select Save.
- Launch Windows Settings app.
- In the VPN Settings, select Maple, and then Connect.
Note: Modifying the current configuration file while VPN is connected will take effect immediately. - Select Disconnect to disconnect.
- VPN lifecycle management on Maple UI
- Better editing experience
- Log collection (currently logs are sent to Visual Studio Output window for debugging only)
external
entries- VPN On Demand
- Configurable routing entries
To build Leaf and Maple, a Rust nightly-x86_64-pc-windows-msvc
toolchain, Windows 10 SDK 10.0.19041 and Visual Studio 2019 with C++ Development Workflow are required. C++/WinRT Visual Studio extension must be installed to generate Windows Metadata.
- Recursively clone this repository.
- Open a PowerShell Prompt.
- Change working directory to
leaf/leaf-ffi
. cargo build -Z build-std=std,panic_abort --target x86_64-uwp-windows-msvc
.
For Release builds, usecargo build -Z build-std=std,panic_abort --target x86_64-uwp-windows-msvc --release
.
See also https://github.com/eycorsican/leaf#build .- Open
Maple.sln
in Visual Studio. - Build Solution.