ChebuNET
ChebuNET

Open-source components

ChebuNET for iPhone and iPad uses the Xray-core networking engine through the libXray library. We modified a few engine files to make it fit the memory limits of the iOS VPN extension. Under the MPL-2.0 license, the source code of those changes is open.

Download source · tar.gz, 65 KB

SHA-256: 6b40ec01eaf1ffde4a1843bf42d4d6b0ee7e175d7cd7e40ecfeecb17817239dd · SHA256SUMS

Components and versions

Patch set rx256+obs8+oom+mem3+xh+pc+doh+ob+why+oc+slp+en — the same marker is compiled into the engine of the app. Xray-core and libXray depend on further open-source Go modules (BSD, Apache-2.0, MIT and others). They are listed in the go.mod files of the upstream sources at the commits above; the full license text of each module is in its upstream repository.

What we changed

Modified Xray-core files (MPL-2.0):

  • proxy/tun/stack_gvisor.go — smaller per-connection TCP buffers, a cap on half-open connections, an emergency abort when memory runs out
  • proxy/tun/udp_fullcone.go — shorter packet queue per UDP flow
  • app/observatory/observer.go — limited number of parallel health probes, probe connections bound to the lifetime of the probe
  • transport/internet/grpc/dial.go — optional idle timeout and fixed windows for gRPC
  • app/dns/nameserver_doh.go — a stuck DNS-over-HTTPS connection is closed and reopened
  • app/proxyman/outbound/handler.go — optional connection outcome log for the in-app diagnostics
  • transport/internet/splithttp/dialer.go — upload memory limits and idle timeout for XHTTP

libXray: memory/memory_ios.go is replaced, and memory/policy.go, memory/prof.go (with tests) are added — a memory policy for the iOS VPN extension instead of the default one.

What is in the archive

  • modified/ — the full text of every modified or added file
  • patches/ — the same changes as unified diffs against the upstream commits
  • tools/libxray/ — the scripts that apply the changes (patch_tun_buffers.py, patch_memory_policy.py) and build the iOS library (build_ios.sh)
  • LICENSE (MPL-2.0), LICENSE.libXray (MIT) and README.txt with step-by-step reproduction

The archive contains source code only, no binaries. Code comments are in Russian.

License notice

This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at https://mozilla.org/MPL/2.0/.

libXray: Copyright (c) 2023-2025 XTLS, MIT License — the full text is included in the archive.

Questions about the source code: support@chebunet.app.