Skip to content

v0.2.0

Latest

Choose a tag to compare

@github-actions github-actions released this 23 Jun 21:21
61a6cbe

catnet v0.2.0 — Stability & English Standardisation

This release contains one breaking change.
If you use catnet --format csv export input.json,
update your scripts before upgrading. See the migration note below.


⚠️ Breaking Change

export --format is no longer inherited from the root command.

Previously, the global --format flag was inherited by the export
subcommand as a side effect. This was undocumented behaviour and caused
ambiguity when both flags were present.

Before (v0.1.0):

catnet --format csv export input.json      # worked by accident

After (v0.2.0):

catnet export input.json --format csv      # required form
catnet export input.json -f csv            # shorthand also works

--format is now a required local flag on export. Omitting it
produces a clear error: required flag "format" not set.


What's New

Fixed — Test Infrastructure

  • Integration tests no longer share Cobra command state between cases.
    TestMain now instantiates a fresh rootCmd per test, eliminating
    order-dependent failures that could silently pass or fail depending
    on execution sequence. (Finding C6)
  • os.Stdout pipe is now unconditionally restored via defer in all
    integration tests that redirect standard output. Previously, a test
    failure before w.Close() would leak the file descriptor and corrupt
    subsequent test output. (Finding C7)
  • TestScanCancelledByContext has been rewritten as a subprocess test.
    The catnet binary is compiled once in TestMain and executed as a
    child process. os.Interrupt is sent only to the child PID, fully
    isolating signal delivery from the test runner process. (Finding C10)

Added — Test Coverage

  • output/human.go and output/json.go now have dedicated unit tests
    using an injected io.Writer. Coverage includes: tabwriter column
    alignment, ANSI colour flag propagation, TTY detection fallback path,
    and stderr/stdout routing for all six event types. (Finding C9)

Changed — Dependencies

  • catnet-core updated from development pseudo-version
    v0.1.1-0.20260606132841-09db82a7e02c to stable release v0.2.0.
    This brings the defensive timeout fix, pointer aliasing fix, and
    PortCount() method to all users of the CLI.

Changed — Repository

  • All Portuguese comments, documentation strings, and user-facing
    messages have been standardised to English. No functional changes.
    Flag names, exit codes, and output format are identical to v0.1.0.

Engine Dependency

This release requires catnet-core v0.2.0.
For engine-level changes (scan engine, exporters, discovery primitives),
see the catnet-core v0.2.0 release notes.


Installation

Linux / macOS — one-liner:

curl -sSL https://github.com/mendsec/catnet/releases/download/v0.2.0/catnet_Linux_x86_64.tar.gz \
  | tar xz && sudo mv catnet /usr/local/bin/

Windows:
Download catnet_Windows_x86_64.zip from the assets below,
extract, and add the folder to your PATH.

go install:

go install github.com/mendsec/catnet/cmd/catnet@v0.2.0

Verify:

catnet version
# catnet/v0.2.0 (linux/amd64) go1.26.3
# catnet-core/v0.2.0

Verify checksum (Linux example):

sha256sum -c checksums.txt --ignore-missing

Binary Assets

File Platform Arch
catnet_Linux_x86_64.tar.gz Linux amd64
catnet_Linux_arm64.tar.gz Linux arm64
catnet_Darwin_x86_64.tar.gz macOS amd64
catnet_Darwin_arm64.tar.gz macOS (Apple Silicon) arm64
catnet_Windows_x86_64.zip Windows amd64
catnet_Windows_arm64.zip Windows arm64
checksums.txt SHA-256 checksums for all archives

All binaries are statically linked. No runtime dependencies.


Full Changelog

v0.1.0...v0.2.0


Contributors

@mendsec

If you find a bug or security issue, please see
SECURITY.md
before opening a public issue.