vpnhide/tools
Danila Gornushko c523e34747
feat(lsposed): add debug host control bridge (#194)
* feat(lsposed): add debug agent bridge

* feat(tools): add agent bridge MCP server

* fix(lsposed): address agent bridge review feedback

* fix(tools): format agent bridge MCP server

* fix(tools): sort MCP server imports

* fix(lsposed): centralize agent bridge lifecycle

* fix(tools): detach adb stdin in agent bridge MCP server

adb subprocesses inherited the server's stdin, which carries the MCP
JSON-RPC frames, so the adb child consumed handshake bytes and wedged
every MCP session. Run adb with stdin=DEVNULL. Switch the server shebang
to the project's uv run --script convention and add smoke-test.py, an
end-to-end MCP handshake check.

* feat(lsposed): move agent control toggle into the Developer section

The agent bridge is debug-only, so its toggle belongs with the other
developer knobs rather than the Debugging tools section. Gate it behind
BuildConfig.DEBUG so release builds (whose AgentControlBridge is a no-op
stub) don't show a dead switch.

* feat(lsposed): ship agent bridge in release, off by default

The bridge was debug-only (real impl in src/debug, no-op stub in
src/release, toggle gated by BuildConfig.DEBUG), which hid it from the
release builds used for development. Move AgentControlBridge into the
main source set so it builds everywhere, drop the BuildConfig.DEBUG
guards, and keep the toggle off by default. Because an enabled bridge
opens a loopback port other apps can use to detect VPN Hide, surface a
dashboard info note while it is on. The host token path falls back to
logcat on release builds, where run-as is unavailable.

* style(lsposed): expression body for startServer

ktlint's function-expression-body rule fires now that the early
BuildConfig.DEBUG return is gone and startServer is a single expression.
2026-06-30 00:31:17 +03:00
..
agent-mcp feat(lsposed): add debug host control bridge (#194) 2026-06-30 00:31:17 +03:00