# Oxidepath
Oxidepath is an experimental Rust proxy core targeting behavioral compatibility with mihomo v1.19.34. The first alpha provides loopback TCP forwarding through HTTP CONNECT and SOCKS5 with a small subset of the YAML configuration.
## Run the alpha
```sh
cargo install --path . --locked
oxidepath -t -f config.yaml
oxidepath -f config.yaml
```
```yaml
mixed-port: 7890
allow-lan: false
mode: rule
rules:
- DST-PORT,25,REJECT
- DOMAIN-SUFFIX,internal.example,DIRECT
- IP-CIDR,192.0.2.0/24,REJECT,no-resolve
- MATCH,DIRECT
```
Clients can use `http://127.0.0.1:7890` for HTTPS tunneling or `socks5h://127.0.0.1:7890` for TCP connections. Set `port` or `socks-port` to run a dedicated listener. A port of `0` disables that listener. Direct connections use configured `hosts` entries or the operating system resolver for hostnames. The default configuration path is `$XDG_CONFIG_HOME/oxidepath/config.yaml` or `$HOME/.config/oxidepath/config.yaml`.
The alpha accepts `allow-lan: false` and rejects unrecognized configuration keys. It handles HTTP CONNECT and unauthenticated SOCKS5 TCP CONNECT. Full HTTP forwarding, proxy authentication, UDP, mihomo's DNS service, external proxy protocols, and TUN are pending. See the [compatibility matrix](compat/README.md) in the source repository for the tested cases.
## Run the compatibility suite
On Linux x86-64 or AArch64, use Python 3.11 or later.
```sh
cargo build --locked
python3 compat/run.py --candidate target/debug/oxidepath
```
The runner downloads and verifies the official archive against `compat/reference.json`. Pass `--reference-archive /path/to/archive.gz` to run with an existing copy. Tests use temporary configuration directories and loopback TCP services.
Oxidepath is distributed under GPL-3.0-only.