HTTPS GET under NetCap for fx projects.
fxfetch performs one HTTPS GET with an explicit host allowlist and CA file. Status and response headers go to stderr; body to stdout (or --out under --allow). Product logic is fx; rebuild with fx build … --cli. Dual-path: emit-C and IR.
| Requires | fx 0.9.6+ (with --cli) · Mbed TLS for rebuild |
| Platforms | Windows + Linux x86_64 |
| License | GPL-3.0 (tool) · GPL-2.0-or-later (Mbed TLS; dual-licensed upstream) |
| Org | LedoCorp |
- Install fx 0.9.6+.
- Download the asset for your OS from Releases.
- Put
bin/windows/fxfetch.exeorbin/linux/fxfetchon yourPATH.
# Windows (PowerShell)
Invoke-WebRequest -Uri https://github.com/ledocorp/fxfetch/releases/download/v0.1.0/fxfetch-0.1.0-windows-x86_64.zip -OutFile fxfetch.zip
Expand-Archive fxfetch.zip -DestinationPath .
.\bin\windows\fxfetch.exe --help
# Linux
curl -LO https://github.com/ledocorp/fxfetch/releases/download/v0.1.0/fxfetch-0.1.0-linux-x86_64.tar.gz
tar xzf fxfetch-0.1.0-linux-x86_64.tar.gz
./bin/linux/fxfetch --help
Optional: fxfetch-ir is the IR dual-path binary (same CLI).
fxfetch --allow-host example.com --ca /path/to/ca-bundle.pem https://example.com/
fxfetch --allow-host example.com --ca ca.pem --headers-only https://example.com/
fxfetch --allow-host example.com --ca ca.pem --out body.bin --allow . https://example.com/file
| Flag / arg | Behavior |
|---|---|
--allow-host <host[:port]> |
Required NetCap allow (default port 443) |
--ca <pem> |
Required CA trust file |
--headers-only |
Skip body |
--out <file> --allow <dir> |
Write body under FsCap root |
<https-url> |
Must be https://… |
Exit codes: 0 ok · 1 usage · 2 host/path deny · 3 TLS/network · 4 other I/O.
Needs fx 0.9.6+ with --cli, host/cap (incl. dial TLS), this repo’s fx_fetch_ref.c, and Mbed TLS 2.28.x libs:
fx build fxfetch_lib.fx -o out --emit-c --cli \
--link fx_fetch_ref.c \
--link <host>/cap/fx_net_dial.c \
--link <host>/cap/fx_cap_runtime.c \
--link-include <host>/cap \
--link-include <mbedtls>/include \
--link-dir <mbedtls>/library \
--link-lib mbedtls --link-lib mbedx509 --link-lib mbedcrypto
On Windows also --link-lib ws2_32. Same links with --backend ir for the IR binary.
POST · forms · cookies · redirects · HTTP/2/3 · browser theater · ambient network · macOS prebuilt claim
- docs/FXFETCH.md — design summary
- docs/releases/ — release notes
- Language: ledocorp/fxlang
Copyright Shawn Londono · LedoCorp · GPL-3.0 — see LICENSE.