Skip to content

2.0.0

Latest

Choose a tag to compare

@Rapid-carbon-neutralization Rapid-carbon-neutralization released this 01 Nov 00:18
2fcf1c2

IriX Node 2.0.0

Stable release following the 2.0.0 RC. This release focuses on production security:
always-on DDoS/CC protection, client device binding, configurable admin network
policy, and a long list of authentication, lifecycle, and performance hardening
changes accumulated since the RC.

Prebuilt binaries are attached to this release. Produced by GitHub Actions for commit 2fcf1c2 from the successful CI run below; SHA256SUMS is attached for verification.

Download

CI artifacts are ZIP archives named irix-node-<os>-<arch>; this release publishes the extracted binaries with the same base names (Windows adds .exe):

Platform Architecture Artifact
Windows amd64 irix-node-windows-amd64
Windows arm64 irix-node-windows-arm64
Linux amd64 irix-node-linux-amd64
Linux arm64 irix-node-linux-arm64
Linux arm (v7) irix-node-linux-arm
macOS amd64 irix-node-darwin-amd64
macOS arm64 irix-node-darwin-arm64
FreeBSD amd64 irix-node-freebsd-amd64
FreeBSD arm64 irix-node-freebsd-arm64
OpenBSD amd64 irix-node-openbsd-amd64
OpenBSD arm64 irix-node-openbsd-arm64
NetBSD amd64 irix-node-netbsd-amd64

If the CI artifacts have expired, either push a v* tag to run the Release
workflow, or build from source:

CGO_ENABLED=0 go build -trimpath -ldflags "-s -w" -o irix-node ./cmd/irix-node

Highlights

Always-on DDoS/CC protection

The HTTP layer now has a defense stage in front of audit, CORS, vault gating, and
all business routes. It cannot be disabled at runtime or by configuration; only
its thresholds are tunable.

  • Per-IP token buckets and in-flight request limits.
  • A global anonymous request budget across all IPs, so rotating source addresses
    cannot reset the total allowance.
  • Per-User-Agent concurrency and rate aggregation across IPs. A User-Agent that
    exceeds the configured concurrency or rate is banned globally for a period.
  • Automatic bans expire automatically; repeated triggers increase the duration
    up to 24 hours. Manual and config-defined bans always take precedence.
  • Bounded tracking tables with eviction. A full table never turns into a blanket
    rejection of every new source address.
  • Strict HTTP header validation, including:
    • Via, Forwarded, X-Forwarded-*, X-Real-IP, CF-Connecting-IP,
      Proxy-Connection, and other proxy-chain markers.
    • Request-smuggling shapes: Content-Length plus Transfer-Encoding,
      duplicate Content-Length, duplicate Host, hop-by-hop injection.
    • Duplicate singleton headers such as Authorization, X-Auth-Token, and
      User-Agent.
    • Method-override headers, TRACE/TRACK/CONNECT, invalid Upgrade,
      invalid Expect, oversized or excessive headers, and overlong User-Agent
      values.
  • Manual ban management persisted in {data}/defense.json.
  • Management API: GET /api/defense/status, POST /api/defense/ban,
    DELETE /api/defense/ban.
  • Loopback clients are exempt from rate limits and automatic bans so the local
    panel cannot lock itself out. Hard header violations and manual/configured
    User-Agent bans still apply to loopback.

Client device binding

Accounts can now be bound to client-held device keys. The server stores only the
public key and a signed descriptor; the private key stays on the client and can
be protected by TPM 2.0, an OS keychain, or a restricted file.

  • Ed25519 and ECDSA P-256 keys.
  • One-time, 60-second challenges for registration and login.
  • Login signature over the challenge, account, device ID, timestamp, proof key,
    and server TLS fingerprint.
  • Per-request proof after login: X-Device-Id, X-Session-Timestamp,
    X-Session-Seq, and X-Session-Proof using HMAC-SHA256 with a monotonic
    sequence window. A stolen session token without the proof key cannot call the
    API.
  • optional and required account policies. optional is the default and
    keeps existing password-only clients working. required rejects password-only
    login and requires TLS.
  • Device login and bound sessions require TLS; the challenge response returns the
    server certificate fingerprint for client-side pinning.
  • Device management and admin APIs:
    • POST /api/auth/device/challenge
    • GET/POST /api/auth/devices
    • POST /api/auth/devices/revoke
    • GET/DELETE /api/accounts/devices
    • PUT /api/accounts/device-policy
  • Account database migration is automatic. New objects: account_devices,
    accounts.device_policy, sessions.device_id, sessions.proof_key.
  • Signed device descriptors can carry OS, build, app version, install ID, and
    hardware class for inventory and future risk scoring. They are metadata, not
    an authentication factor.

Protocol specification and client handoff checklist:
https://github.com/MCFSO/IriX-Node/blob/main/docs/device-binding.md

Configurable admin network policy

Administrator accounts are still restricted to loopback, RFC 1918, IPv6 ULA, and
IPv6 link-local sources by default. The restriction is now explicitly
configurable:

  • Command line: -admin-intranet-only=false
  • Config file: "adminIntranetOnly": false
  • Default: true

When disabled, a warning is written to the startup log. The switch applies to
both admin login and already-issued admin sessions. Ordinary accounts are not
affected. Device binding requirements remain independent and still require TLS.

Account and authentication hardening

  • Pairing codes and fixed API keys are gone. First startup generates a random
    administrator account and prints the credentials once.
  • Login brute-force protection covers both account+IP and IP dimensions.
  • Password changes and account deletion revoke existing sessions across SQL,
    Redis, and the in-process cache.
  • Session tokens remain valid for 30 days with sliding renewal.
  • Per-endpoint permissions are enforced for non-admin accounts; admins bypass the
    endpoint switches.
  • Zip-bomb protection for archive extraction.
  • Audit body redaction now also covers device proof keys.

Reliability and performance

  • Node lifecycle and shutdown orchestration were consolidated: stop accepting
    requests, drain HTTP, wait for process starts, flush state, stop instances and
    FRP, close databases, and drain logs in a deterministic order.
  • Instance configuration persistence uses asynchronous debounced writes, with a
    final flush on shutdown.
  • Request-path caching and overview sampling remove repeated I/O from hot paths.
  • File descriptor limits are raised automatically on Unix where possible.
  • High-concurrency connection handling was tuned, including header size limits,
    request-body idle timeouts, and bounded audit/instance log buffers.
  • Windows data directories avoid the system drive by default.
  • Embedded/low-resource presets reduce log buffers and memory limits on small
    devices.

Platform support

The CI matrix validates windows, linux, darwin, freebsd, openbsd, and
netbsd on amd64/arm64, plus linux/arm v7. The daemon is pure Go with
CGO_ENABLED=0; SQLite support is isolated behind build tags for platforms where
the pure-Go driver is unavailable.

New configuration

The defense block in config.json tunes the always-on protection. It has no
enabled switch; setting "enabled": false is ignored with a startup warning.

Key Default Description
maxIPConcurrent 64 Maximum in-flight requests per source IP
maxUserAgentConcurrent 32 Maximum in-flight requests per User-Agent across all IPs
ipRatePerSecond 60 Per-IP token refill rate
userAgentRatePerSecond 40 Per-User-Agent token refill rate across all IPs
globalRatePerSecond 1000 Global anonymous request budget
globalBurst 2000 Global anonymous burst capacity
banMinutes 10 Base automatic ban duration
blockedUserAgents [] Permanently blocked User-Agent values

Top-level configuration:

Key Default Description
adminIntranetOnly true Restrict admin login and sessions to loopback/private networks

Upgrade notes

  1. Back up the data directory, especially accounts.db, before upgrading.
  2. Account schema changes run automatically at startup. Existing databases gain
    the device-binding columns and the account_devices table; existing rows keep
    working.
  3. Existing clients continue to work because device binding is optional by
    default. The login response now also includes deviceBound and deviceId.
  4. To require device binding for an account:
    • Enable TLS (tls-mode=auto or manual).
    • Register at least one device for that account.
    • Set PUT /api/accounts/device-policy with {"policy":"required"}.
    • The client must implement the protocol in docs/device-binding.md.
  5. Remote administrators must set adminIntranetOnly=false (or start with
    -admin-intranet-only=false); otherwise admin login from public addresses is
    rejected with HTTP 403. This is intentional and on by default.
  6. The defense stage cannot be turned off. If thresholds do not fit your traffic,
    tune the defense block instead of looking for a disable switch.
  7. If you terminate TLS at a reverse proxy, the node cannot provide a TLS
    fingerprint and device-binding required mode is not available. Run TLS on
    the node or keep the proxy on loopback.

Verification

The release commit passed:

  • gofmt -l .
  • go vet ./...
  • go test ./...
  • go test -race -count=1 -short ./...
  • go build ./cmd/irix-node
  • Cross-compilation for all 12 targets listed above

Latest CI run:
https://github.com/MCFSO/IriX-Node/actions/runs/41207171728

Security notes and limitations

  • HTTP-layer protection cannot absorb a volumetric L3/L4 DDoS. Use a firewall,
    upstream scrubbing, or a scrubbing provider in front of public deployments.
  • Device binding in this release records keyProtection but does not verify TPM
    endorsement certificates, PCR values, or remote attestation. TPM 2.0 is a
    client-side key store here, not a server-verified attestation.
  • The per-request proof authenticates the request envelope; body integrity still
    depends on TLS. Pin the server certificate fingerprint returned by the device
    challenge.
  • Browser WebSocket clients cannot set custom proof headers. Accounts with
    required device policy should use the desktop client for console access.
  • Node-to-node cluster calls using an admin session token will be rejected once
    that session is device-bound. Use a dedicated non-admin service account with
    only the required cluster permissions.
  • If the only administrator loses all bound devices, recover by setting
    accounts.device_policy back to optional directly in the account database,
    or by using another administrator. Password reset does not bypass device
    binding.

Documentation

Full changelog since 2.0.0 RC:
rc-v2.0.0...2fcf1c2