TriFrost

TriFrost 0.48.0

|peterver

News

This release upgrades TriFrost's observability layer with faster scramblers, enhanced infrastructure secret detection, and smarter host resolution while continuing to refine the core developer experience.

Added

  • feat: Added OMIT_PRESETS.infra to automatically redact infrastructure secrets like GitHub tokens, Stripe keys, AWS/GCP credentials, and JWT-style tokens. The infra preset is also included in the defaults used by the log scrambler. Scrambling (introduced in 0.28.0) helps redact sensitive fields from logs, see redaction & scrambling docs for details.
  • feat: Added ctx.domain getter, which extracts the domain from the resolved host (e.g. sub.example.com -> example.com).
  • feat: Host configuration now uses TRIFROST_HOST, falling back to SERVICE_HOST and HOST environment variables. Treating them as canonical in non-trusted environments.

Improved

  • perf: ~10% faster isValidTraceId via optimized ASCII range checks in Logger module
  • perf: Improved createScrambler(), with smarter pattern matching and lazy cloning, performance across all presets improved by 20–50%, even with expanded infra redaction.
  • qol: Observability traces now include http.host for better visibility and trace correlation.
  • security: Host detection from headers (x-forwarded-host, forwarded) now only occurs when trustProxy: true is explicitly enabled (default in trusted environments like Cloudflare Workers). Otherwise, it falls back to environment-based resolution or 0.0.0.0.
  • misc: Adjusted build system to dual-build ESM + CJS output.

Breaking

  • Removed host as an option on App. Host is now determined entirely from environment variables or request headers (see Added and Improved).

Faster scramblers, smarter defaults, and no secrets left behind.

New Scrambling Benchmark:

New Scrambling Benchmark
New Scrambling Benchmark

Old Scrambling Benchmark:

Screenshot from 2025-06-09 12-21-57
Screenshot from 2025-06-09 12-21-57

Stay fast. Stay minimal. Stay frosty ❄️.

Loved the read? Share it with others