CrushTest: load tests for your CrushFTP and CrushMFT servers
==============================================================

What it does
  Puts a load you choose (SFTP, FTP, FTPES, FTPS, HTTP, HTTPS: logins, uploads, downloads checked byte for byte,
  resumed uploads, listings, deletes, mixes) on your servers, measures it on both sides, shows it live, keeps every run, and compares
  runs with a verdict (for example v27 against v11). It works through load balancers and shows how the load spread.
  It sends nothing anywhere but the load itself.

Start
  Java 21 or later (25 recommended).
  Windows:  CrushTest.exe
  macOS:    CrushTest.command (or ./crushtest.sh)
  Linux:    ./crushtest.sh   (then open the address it prints)
  1. Servers: add one (an address per protocol, the users and their common password, and its admin API for the
     server-side numbers and checks). On v27 CrushTest can make its own test users instead.
  2. Run: pick the server and a profile, press Preflight, then Start.
  3. Results: every run; tick runs for A and B and Compare. PDF and HTML reports. Trend (on a run) shows one profile
     build over build, and flags a build only when it and the one before it both leave the usual band.

Safety
  - Preflight checks everything before a run, including the server's own limits: a default CrushFTP server bans an
    address that opens 100 connections in 10 seconds (3 for HTTP) and allows 100 connections per address.
  - Every load machine has hard caps (sessions, new connections, operations, MB per second) and stops by itself
    when the controller goes quiet. Abort always works. Guards stop a run when errors or latency run away, when the
    server's CPU stays above 95%, and when its disk has less than 2 GB free (see Exact server CPU for the source).
  - CrushTest only deletes what its ledger says it made (ledgers/). Test users it makes expire a day after the run
    even if nothing else removes them.
  - Saved passwords and tokens are sealed in prefs.XML with a key (crushtest.key) only your account can read.
  - TLS (per server): "system" takes only a certificate a trusted CA issued for the host, "pin" only the pinned SHA-256
    (several, comma separated, for back ends with their own), "any" whatever comes. Every connection is checked, not only
    the first; nothing is pinned on first use.

More load machines
  One machine runs out of client capacity before a v27 server does. On each extra machine, unzip CrushTest and run
  "./crushtest.sh agent" (or crushtest_init.sh install for a service). It prints a pairing code: enter it under Agents.
  "--allow host:port,..." limits where an agent may send load. An agent takes orders over the network: open its port
  (47920) only to the CrushTest machine.
  As a Linux service: sudo AGENT_ARGS="--allow server:22,server:443" ./crushtest_init.sh install, from the account it
  should run as (or RUN_USER=account); it does not install itself to run as root unless RUN_USER=root RUN_USER_ROOT_OK=yes.

HTTP and HTTPS
  By default each session keeps its connection open between requests, as a browser does. A profile can choose
  "CrushTunnel client" instead: a new connection per request, as CrushFTP's own clients make them (which runs out of
  local ports above a few hundred requests a second on one machine).

Exact server CPU
  CrushMFT 27 builds that report their own CPU time in the dashboard (process_cpu_ms) give CrushTest the exact server CPU
  per operation. For v11 (and older v27 builds), run "./crushtest.sh monitor --monitor-find CrushFTP" on the server's
  machine and pair it as a monitor of that server; without either, CrushTest shows the server's CPU % only.
  Add "--monitor-disk /path/to/the/server/data" and the monitor also reports that disk's free space, which the disk
  guard uses (otherwise only a server that has a "Disk Space Below Threshold" alert reports its free space).

Command line
  ./crushtest.sh -help
