Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,20 @@

Versions follow `v*.*.*` with dots. Dates are US Eastern.

## 0.9.0 · 2026-11-22

A tool for every day: find any request, read any body, keep a recording.

- Filters above Flows: status, errors, method and type at one click; More filters for size, duration, process, the hosts to focus on and the hosts to leave out. Or type them as browser developer tools take them: `status-code:404`, `method:POST`, `domain:*.example.com`, `mime-type:image/`, `larger-than:100k`, `process:curl`, with a `-` in front to leave those out. The Body switch searches inside the recorded bodies.
- Bodies read properly: indented, coloured JSON, HTML and XML with folding, Raw, Hex, images and forms, and find. A body of several megabytes shows its first lines at once and the rest within a second.
- WebSocket messages, sent and received, live in a Messages tab.
- HTTP/2: browsers and gRPC programs speak HTTP/2 to FormNET where it opens HTTPS, and Flows shows what each side spoke.
- Sessions: File > Save Session keeps a recording as a `.formnet` file (it holds the passwords and tokens the requests carried, and the dialog says so), Open Session brings one back, Import HAR reads a HAR from a browser or another tool.
- Copy All as cURL: one script for sh, PowerShell or cmd that sends every listed request again.
- Upstream proxy: FormNET can send its traffic on through your company's proxy (HTTP, HTTPS or SOCKS5, with a list of hosts reached directly), in Preferences > Capture.
- The Process column names the program behind a short request, such as one curl call, on macOS and Linux. Windows still names programs every 2 seconds, so very short requests there may show none.
- Every label added in 0.7.0, 0.8.0 and 0.9.0 is translated in all the family's languages.

## 0.8.0 · 2026-11-22

Change what passes through FormNET, and capture a phone.
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
VERSION := v0.8.0
VERSION := v0.9.0
LDFLAGS := -s -w -X github.com/nodemode-dev/formnet/internal/app.Version=$(VERSION)
GO_BUILD := CGO_ENABLED=0 go build -trimpath -ldflags "$(LDFLAGS)"
TARGETS := linux/amd64 linux/arm64 darwin/amd64 darwin/arm64 windows/amd64
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
</p>

<p align="center">
<img alt="version v0.8.0" src="https://img.shields.io/badge/version-v0.8.0-eef0f4?style=flat-square">
<img alt="version v0.9.0" src="https://img.shields.io/badge/version-v0.9.0-eef0f4?style=flat-square">
<img alt="Go 1.26" src="https://img.shields.io/badge/Go-1.26-00ADD8?style=flat-square&logo=go&logoColor=white">
<img alt="TypeScript and Vite" src="https://img.shields.io/badge/TypeScript-Vite-3178c6?style=flat-square">
<img alt="macOS, Windows, Linux" src="https://img.shields.io/badge/macOS%20%C2%B7%20Windows%20%C2%B7%20Linux-native-2f7bf5?style=flat-square">
Expand Down
22 changes: 22 additions & 0 deletions cmd/formnet/attribute.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
package main

import (
"time"

"github.com/nodemode-dev/formnet/internal/flow"
"github.com/nodemode-dev/formnet/internal/machine"
)

// clientOwner names the program behind a proxy client: from a background
// lookup of that one port (started when the proxy accepts the connection)
// whose answer names the stored flows when it comes, and meanwhile, or when
// it comes too late, from the machine view's latest snapshot.
func clientOwner(monitor *machine.Monitor, store *flow.Store) func(string) (int, string, bool) {
lookup := machine.NewAttributor(func(client string, since time.Time, pid int, name string) { store.Attribute(client, since, pid, name) }, monitor.Owner)
return func(client string) (int, string, bool) {
if pid, name, ok := lookup.Owner(client); ok {
return pid, name, ok
}
return monitor.Owner(client)
}
}
6 changes: 4 additions & 2 deletions cmd/formnet/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ Settings (environment):
FORMNET_SYSTEM_PROXY 1 to point the system proxy at formnet while it runs, 0 not to (macOS, Windows); default off
FORMNET_REMOTE_CAPTURE 1 to let other devices use the proxy on this computer's network addresses, 0 not to; default off
FORMNET_REMOTE_ALLOW addresses or CIDR ranges allowed to, comma-separated; at least one is needed to turn it on
FORMNET_UPSTREAM_PROXY http://, https:// or socks5://[user:password@]host:port that formnet's own connections go through, or off; for this run only

Interception, the passthrough list and the system proxy chosen in the web
client are kept in <data>/settings.json; FORMNET_INTERCEPT,
Expand Down Expand Up @@ -204,11 +205,12 @@ func serve(stdout, stderr io.Writer) int {
Passthrough: passthrough,
InterceptMode: mode,
Trusted: authority.TrustedNow,
Owner: monitor.Owner,
Owner: clientOwner(monitor, store),
Refuse: []string{apiAddr, proxyAddr},
Log: log,
})
startRemote := useTraffic(px, cfg, saved, log)
useUpstream(px, cfg, saved, log)
proxyErr := make(chan error, 1)
go func() { proxyErr <- px.Serve(ctx, bound.proxy) }()

Expand All @@ -217,7 +219,7 @@ func serve(stdout, stderr io.Writer) int {
terminals := terminal.New(terminal.Options{APIAddr: apiAddr, ProxyAddr: proxyAddr, CAPath: info.Path, Log: log})
defer terminals.Close()
api := &http.Server{
Handler: server.Handler(server.Deps{Addr: apiAddr, Token: token, Store: store, Proxy: px, CA: authority, Machine: monitor, Dist: formnet.Dist(), Log: log, Notices: bound.notices, Quit: stop, Remember: remember, SystemProxy: systemProxy, BodyLimit: cfg.BodyLimit, Terminals: terminals, Traffic: px}),
Handler: server.Handler(server.Deps{Addr: apiAddr, Token: token, Store: store, Proxy: px, CA: authority, Machine: monitor, Dist: formnet.Dist(), Log: log, Notices: bound.notices, Quit: stop, Remember: remember, SystemProxy: systemProxy, BodyLimit: cfg.BodyLimit, Terminals: terminals, Traffic: px, Protocol: px, Data: cfg.Data}),
ReadHeaderTimeout: 10 * time.Second,
IdleTimeout: 90 * time.Second,
}
Expand Down
39 changes: 39 additions & 0 deletions cmd/formnet/upstream.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
package main

import (
"log/slog"

"github.com/nodemode-dev/formnet/internal/config"
"github.com/nodemode-dev/formnet/internal/proxy"
"github.com/nodemode-dev/formnet/internal/settings"
)

// useUpstream gives the proxy the upstream proxy from the data folder, or
// from FORMNET_UPSTREAM_PROXY, which wins for this run and is never written.
func useUpstream(px *proxy.Proxy, cfg config.Config, saved *settings.File, log *slog.Logger) {
var kept proxy.UpstreamSetting
if u := saved.Current().Upstream; u != nil {
kept = proxy.UpstreamSetting{Enabled: u.Enabled, URL: u.URL, Bypass: u.Bypass, Username: u.Username, Password: u.Password}
}
opts := proxy.UpstreamOptions{
Saved: kept,
Remember: func(s proxy.UpstreamSetting) error {
return saved.SetUpstream(settings.Upstream{Enabled: s.Enabled, URL: s.URL, Bypass: s.Bypass, Username: s.Username, Password: s.Password})
},
}
if cfg.UpstreamSet {
env, err := proxy.UpstreamFromURL(cfg.UpstreamProxy, kept.Bypass)
if err != nil {
log.Warn("FORMNET_UPSTREAM_PROXY not used; no upstream proxy in this run", "err", err)
env = proxy.UpstreamSetting{Bypass: kept.Bypass}
}
opts.Env = &env
}
if err := px.UseUpstream(opts); err != nil {
log.Warn("upstream proxy not used until the next change", "err", err)
return
}
if st := px.Upstream(); st.Active {
log.Info("outgoing connections go through the upstream proxy", "upstream", st.URL, "bypass", len(st.Bypass), "from_env", st.FromEnv)
}
}
Loading
Loading