| Crates.io | proxyfor |
| lib.rs | proxyfor |
| version | 0.5.0 |
| created_at | 2024-03-06 08:31:07.911797+00 |
| updated_at | 2024-12-24 00:39:27.598617+00 |
| description | A powerful and flexible proxy CLI for capturing and inspecting HTTP(S) and WS(S) traffic |
| homepage | https://github.com/sigoden/proxyfor |
| repository | https://github.com/sigoden/proxyfor |
| max_upload_size | |
| id | 1164516 |
| size | 352,056 |
A powerful and flexible proxy CLI for capturing and inspecting HTTP(S) and WS(S) traffic.
Terminal User Interface (TUI)
Web User Interface (WebUI)
cargo install proxyfor
docker run -v ~/.proxyfor:/.proxyfor -p 8080:8080 --rm sigoden/proxyfor --web
Download from Github Releases, unzip and add proxyfor to your $PATH.
In this mode, your client applications (e.g., web browsers, curl) are configured to send their requests to proxyfor, which then forwards them to the target servers. You would configure your client to use a proxy at http://127.0.0.1:8080.
proxyfor
curl -x http://127.0.0.1:8080 httpbin.org/ip
In reverse proxy mode, proxyfor sits in front of a target server. Clients access proxyfor and it forwards the requests to the defined URL. This mode is ideal when clients cannot be configured to use a proxy.
proxyfor https://httpbin.org
curl http://127.0.0.1:8080/ip
Usage: proxyfor [OPTIONS] [URL]
Arguments:
[URL] Reverse proxy url
Options:
-l, --listen <ADDR> Listening ip and port address [default: 0.0.0.0:8080]
-f, --filters <REGEX> Only inspect http(s) traffic whose `{method} {uri}` matches the regex
-m, --mime-filters <VALUE> Only inspect http(s) traffic whose content-type matches the value
-W, --web Enable user-friendly web interface
-T, --tui Eenter TUI
-D, --dump Dump all traffics
-h, --help Print help
-V, --version Print version
proxyfor provides several ways to interact with captured traffic:
proxyfor # Enter TUI, equal to `proxyfor --tui`
proxyfor --web # Serve WebUI
proxyfor --web --tui # Serve WebUI + Enter TUI
proxyfor --dump # Dump all traffics to console
proxyfor > proxyfor.md # Dump all traffics to markdown file
Customize the listening address and port:
proxyfor -l 8081
proxyfor -l 127.0.0.1
proxyfor -l 127.0.0.1:8081
Apply regex filters to limit captured traffic based on method and URI:
proxyfor -f httpbin.org/ip -f httpbin.org/anything
proxyfor -f '/^(get|post) https:\/\/httpbin.org/'
Filter based on MIME types:
proxyfor -m application/json -m application/ld+json
proxyfor -m text/
To decrypt HTTPS traffic, you must install proxyfor's CA certificate on your device. The easiest way to do this is to use the built-in certificate installation app.
proxyfor with desired proxy settings.proxyfor as the proxy.Copyright (c) 2024-∞ proxyfor-developers.
Proxyfor is made available under the terms of either the MIT License or the Apache License 2.0, at your option.
See the LICENSE-APACHE and LICENSE-MIT files for license details.