Commit Graph
24 Commits
Author SHA1 Message Date
eric bedc609506 test(e2e): run the reference plugins against upstream servers
A new interop lane puts a real leaf with each plugin in front of the servers
people deploy, built from source at pinned revisions: anytls-go, sing-box
stable and its testing branch, mihomo, and the original shadow-tls. Every
pair runs the stream behaviours, plus the server's padding scheme checked on
the wire, fingerprints, and the connections that must fail: wrong password,
hijacked to the real site, TLS 1.2 site in strict mode.

AnyTLS skips half-close-tail, which its protocol cannot carry. ShadowTLS
marks it a known defect: the host shuts the socket's write side while an
engine is still handshaking.

`make interop` runs the lane, `make e2e` leaves it out, and CI runs it in a
job of its own with the built servers cached. The harness no longer hands
out a port twice in one process, and builds upstream Rust servers with their
own toolchain, outside the workspace.
2026-12-03 19:31:53 +08:00
eric c08f3dd0f9 build: run the plugin suites in CI, and ignore what the plugins build
`make e2e` runs the end-to-end suite with `--strict`, minus the soak lane;
`make soak` is that lane plus the slow cost meters. `make plugin-test` covers
what an end-to-end run cannot reach -- the host's own loader and wrapper
tests, the ABI parity test, and each plugin's unit tests, one language at a
time -- and `make plugin-test-san` builds the C plugin's tests under address
and undefined-behaviour sanitizers, kept separate because not every toolchain
ships the runtimes.

CI grows a plugin job on Linux and macOS that runs the suite and
`make plugin-test`, and checks that `leaf-cli` still builds with plugin
support, since nothing else in the matrix compiles that feature. The same lane
exists for Windows but is started by hand: the suite has been through Windows
green on ARM64, and this runner is x86-64. A sanitizer lane runs the hostile
cases with the runtime exported so a plugin loads against it, and uploads the
artifact directory when a case fails. The soak workflow is the one that is
nightly: it runs the long lane out of hours with a longer timeout scale and
more meter repetitions, so its numbers are worth comparing between nights.

`.gitignore` learns the artifacts the plugin builds leave in the tree.
2026-12-03 19:31:53 +08:00
eric 15777875c2 chore: update deps 2024-05-01 23:59:44 +08:00
eric 7757552bdc refactor: rename leaf-bin -> leaf-cli 2024-04-18 16:39:58 +08:00
eric 8fd4936b86 chore: update deps 2023-09-26 08:25:12 +08:00
eric 4e6117b376 Build Android and iOS/macOS libraries on CI 2023-03-31 06:56:22 +08:00
eric 2e17847b48 Update iOS build command 2023-03-04 12:53:12 +08:00
eric 5a6c4cec96 chore: strip was stabilized 2022-04-19 02:23:41 +08:00
eric 40e79fdb93 chore: convenient iOS build target for an optimized output 2021-09-16 08:41:29 +08:00
eric 2cbec8bcd3 refactor 2021-07-02 06:37:07 +08:00
eric 822eb83ee5 tun: refine tcp stream handling 2021-05-07 13:39:40 +08:00
eric 7a892236e7 Exposes more runtime management APIs
* Added "api" config to JSON format
* Added "api-interface" and "api-port" options to Conf format
* Added "--auto-reload" flag to the command line program
* Added "--test" flag to the command line program
* Added FFIs leaf_run(), leaf_reload(), leaf_shutdown(), leaf_test_config()
* Removed FFI run_leaf()
* Added Web APIs:
  * POST /api/v1/runtime/reload
  * POST /api/v1/runtime/shutdown
2021-04-12 23:05:35 +08:00
eric a3c8eba006 ci: build ios lib with openssl by default 2021-04-07 18:58:52 +08:00
eric 021391608c refactor 2021-04-05 22:35:35 +08:00
eric ea3454f0b2 ffi: allows building as static library for all targets 2021-04-05 18:21:19 +08:00
eric e365964d7d mobile: fix crate type and cbindgen 2021-04-03 08:41:01 +08:00
eric 6ef895a274 inbound/shadowsocks: new inbound 2021-02-26 23:01:01 +08:00
eric 1be23bc85d Make feature-specific dependencies optional 2020-11-14 08:27:20 +08:00
eric 2f70780b14 Use ring and rustls on iOS 2020-10-26 18:04:34 +08:00
eric ce5366ebc4 Add OpenSSL and support more targets
* Added OpenSSL AEAD support
* Added OpenSSL TLS support
* Added mips/mipsel support

OpenSSL features can be conditinally compiled, targets not supported
by ring should use OpenSSL, e.g. mips/mipsel, while other targets
should use ring and rustls for crypto and TLS for better performance.

Crypto functions from Shadowsocks and VMess are unified in common/crypto.
2020-10-24 11:08:51 +08:00
eric 8db8a7e78c fix tun2socks-bin 2020-10-19 08:27:59 +08:00
eric 761fdb2de4 add more targets 2020-10-17 23:06:13 +08:00
ghost 2e8b16a452 disable memory profiling on iOS 2020-10-10 19:23:51 +08:00
eric 897fc87ce8 initial commit 2020-10-07 22:14:06 +08:00