Files
ARTEX/server
BaaRai 7a9b4fdf76 feat(server): rewrite-rule API and compiled snapshot for the proxy
GET, POST, PUT and DELETE /api/traffic/rewrite-rules and
POST /api/traffic/rewrite-rules/{id}/toggle manage the rules behind
requireAuth. A rule is validated on save (400), created disabled, and
validated again before the toggle enables it. The value of a sensitive action
is never returned; an update sent without it keeps the stored value when the
stored rule has a sensitive action of the same type and header name at the
same position.

The manager compiles the enabled rules after traffic.Open and after every
change, and publishes the snapshot with Traffic.SetRewriteRules, an atomic
swap. An enabled rule the validation refuses is left out and reported as
load_error.

The proxy stores the snapshot and does not apply it: a test sends the same
request with and without matching rules and compares what the target
receives, what the client receives and what is recorded.
2026-11-17 00:12:09 +01:00
..
2026-07-26 04:27:45 -04:00
2026-07-26 04:27:45 -04:00
2026-08-24 14:14:15 +08:00
2026-08-24 14:14:15 +08:00
2026-08-28 12:56:29 +08:00
2026-10-23 18:12:38 -03:00
2026-08-25 12:05:26 +08:00
2026-08-25 12:05:26 +08:00