Thank you for your interest in contributing! This guide will help you get started.
sectools/
βββ tools/ # CLI tools (one folder per tool)
β βββ banner-grabber/
β βββ port-knocking-scanner/
βββ libs/
β βββ netutil/ # Shared Go library
β βββ sectools-common/ # Shared Rust library
βββ Cargo.toml # Rust workspace manifest
βββ .github/workflows/ # CI/CD pipelines
βββ go.mod # Go module (root)
βββ Makefile
| Requirement | Version | Purpose |
|---|---|---|
| Go | β₯ 1.24 | Build & test Go tools |
| Rust | β₯ 1.75 | Build & test Rust crates |
| libpcap-dev | any | Required by port-knocking-scanner (CGO) |
| golangci-lint | latest | Go linting |
git clone https://github.com/flaviomilan/sectools.git
cd sectools
make build
make test- Fork and branch β create a feature branch from
main. - Make changes β follow the conventions below.
- Test locally β run
make lint && make test. - Commit β use Conventional Commits format.
- Open a PR β target
main, fill out the PR template.
- Create
tools/<tool-name>/main.gowith amainpackage. - Add
var version = "dev"so the release pipeline can inject the version via-ldflags. - Reuse shared utilities from
libs/netutil/when possible. - Add tests alongside your code.
- The CI and release workflows pick up new tools automatically.
# Verify it builds
go build ./tools/<tool-name>
# Run Go tests
make test-go- Create
libs/<crate-name>/with aCargo.tomlthat inherits workspace settings. - Add the crate to
membersin the rootCargo.toml. - Add tests in
src/lib.rsor atests/directory.
# Verify it builds
cargo build -p <crate-name>
# Run Rust tests
make test-rust- Follow Effective Go guidelines.
- All code must pass
golangci-lint(see.golangci.ymlfor enabled linters). - Export functions and types that are shared; keep tool-specific logic private.
- Follow standard Rust idioms and
clippyrecommendations. - Code must pass
cargo fmt --checkandcargo clippy -- -D warnings. - Use the workspace
Cargo.tomlfor shared dependency versions.
make test # All tests (Go + Rust)
make test-go # Go tests with race detector
make test-rust # Rust testsmake lint # All linters
make lint-go # golangci-lint
make lint-rust # clippy + rustfmtEach tool is versioned independently. To release a tool:
# Create and push a tag
make release-tag TOOL=banner-grabber VERSION=v1.2.0
git push origin banner-grabber/v1.2.0The release workflow handles cross-compilation, checksums, and GitHub Release creation automatically.
Tag convention: <tool-name>/v<major>.<minor>.<patch>
Use Conventional Commits:
feat(banner-grabber): add JSON output format
fix(netutil): handle IPv6 addresses correctly
docs: update README installation section
ci: add arm64 build target
- Use the Bug Report template for bugs.
- Use the Feature Request template for ideas.
This project follows the Contributor Covenant Code of Conduct.