> For the complete documentation index, see [llms.txt](https://docs.monarchlinux.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.monarchlinux.com/basics/shell-aliases/network-and-pentest.md).

# Network and pentest

See [Shell aliases and functions](https://docs.monarchlinux.com/basics/shell-aliases.md) for command discovery and personal overrides. For isolated testing environments and applications, see [Pentest tools](https://docs.monarchlinux.com/basics/pentest-tools.md).

## Inspect local listeners

`sop` is an alias for `show-open-ports`. It displays listening TCP and UDP ports in numerical order, including local addresses, process names and PIDs. IPv6 addresses and multiple socket owners are preserved. Collection uses sudo.

```bash
sop
```

Colors are enabled only in a terminal. Redirected output, `NO_COLOR` and dumb terminals disable them. This lists local listeners; it does not scan remote hosts.

## Serve files temporarily

`pysrv` creates `/tmp/empty` if needed, then serves it with Python's HTTP server. It stops if directory creation fails, but does not empty an existing directory.

Check its contents before sharing it and stop the server with Ctrl+C when finished. Python's default server may be reachable from other machines, depending on your firewall. For an explicitly local-only server, use:

```bash
python -m http.server --bind 127.0.0.1 --directory /tmp/empty
```

## Probe an authorized URL list

`probe-urls <file>` requests each URL in a file and prints its HTTP status, downloaded body size and effective URL. Quote file paths containing spaces. URLs containing backslashes and a final line without a newline are preserved.

```bash
probe-urls './authorized targets.txt'
```

The helper disables TLS certificate verification. Use it only for systems you are authorized to test; it is not a replacement for certificate validation.

## HTTP shortcuts

* `crl`: curl with Monarch's configured browser-style request options.
* `crli`: the same request with response headers sent to stderr.
* `crlix`: the same request routed through the local proxy at `127.0.0.1:8080`.

These shortcuts disable TLS certificate verification. Inspect their exact definitions with `alias crl`, `alias crli` and `alias crlix` before relying on them; prefer plain curl when you need its normal security defaults.

## Read ffuf results

`fu` applies the shipped ffuf options, including JSON output and all status codes. You still supply the target and wordlist. Inspect `alias fu` first. Only fuzz systems for which you have explicit authorization.

Use `cfu` to display an existing ffuf JSON result file as tab-separated status, length, lines, words and URL columns:

```bash
cfu './results with spaces.json'
```

Keep the original JSON as evidence; the helper's sorted table is a view of the results, not a substitute for the complete result file.
