Rewrite Modes
UA3F supports three HTTP rewrite modes. The mode controls how HTTP requests and responses enter the rewrite pipeline.
rewrite-mode: RULEGLOBAL
GLOBAL rewrites User-Agent headers globally.
rewrite-mode: GLOBAL
user-agent: "FFF"
user-agent-regex: ""
user-agent-partial-replace: falseuser-agentis the replacement value.user-agent-regexlimits which User-Agent values are rewritten. Empty means all values.user-agent-partial-replacereplaces only the regex-matched part instead of the whole header.
Use GLOBAL for simple deployments where one User-Agent policy applies to all HTTP requests.
DIRECT
DIRECT forwards traffic without HTTP rewriting.
rewrite-mode: DIRECTUse it to verify routing, firewall rules, and proxy behavior before enabling rewrite logic.
RULE
RULE evaluates configured rule lists and executes the action attached to matching rules.
rewrite-mode: RULE
header-rewrite: []
body-rewrite: []
url-redirect: []For requests, UA3F evaluates Body rules, Header rules, then URL redirect rules. For responses, it evaluates Body rules and then Header rules.
Rules are evaluated top to bottom within each list. Evaluation stops after a match unless the rule has continue: true.
rewrite-direction controls whether an action applies to REQUEST or RESPONSE. Header and Body actions default to REQUEST when omitted.
