Skip to content

Commit eca7367

Browse files
authored
docs: add user-facing component guides (#57)
1 parent c6e62d2 commit eca7367

48 files changed

Lines changed: 1215 additions & 2 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

Makefile

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ GOPATH_BIN=$(shell go env GOPATH)/bin
66
EXE_SUFFIX=$(if $(filter Windows_NT,$(OS)),.exe,)
77
GOLANGCI_LINT=$(GOPATH_BIN)/golangci-lint$(EXE_SUFFIX)
88

9-
.PHONY: build build-full build-lite fmt fmt-check lint install-hooks test run generate docs-config docs-schema docs-schema-md docs-support-matrix smoke qa licenses
9+
.PHONY: build build-full build-lite fmt fmt-check lint install-hooks test run generate docs-config docs-schema docs-schema-md docs-support-matrix docs-components smoke qa licenses
1010

1111
build: build-full build-lite
1212

@@ -43,7 +43,7 @@ qa: build-full
4343
run:
4444
go run ./cmd/bomly $(ARGS)
4545

46-
generate: docs-config docs-schema docs-schema-md docs-support-matrix
46+
generate: docs-config docs-schema docs-schema-md docs-support-matrix docs-components
4747

4848
docs-config:
4949
go run ./internal/support/cmd/configref
@@ -57,6 +57,9 @@ docs-schema-md:
5757
docs-support-matrix:
5858
go run ./internal/support/cmd/supportmatrix
5959

60+
docs-components:
61+
go run ./internal/support/cmd/componentdocs
62+
6063
licenses:
6164
go run github.com/google/go-licenses@$(GO_LICENSES_VERSION) save ./... \
6265
--save_path=./licenses \

README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,14 @@ Bomly has native detectors for:
111111

112112
Bomly also supports many additional ecosystems through Syft-backed detection. See [docs/SUPPORT_MATRIX.md](docs/SUPPORT_MATRIX.md) for the generated matrix.
113113

114+
For user-friendly component guides, see:
115+
116+
- [Detectors](docs/DETECTORS.md): how Bomly finds package-manager evidence and builds dependency graphs
117+
- [Matcher guides](docs/MATCHERS.md): how optional enrichment adds vulnerabilities, licenses, and lifecycle data
118+
- [Auditors](docs/AUDITORS.md): how `--audit` turns existing vulnerability data into findings
119+
- [Detector ecosystem guides](docs/detectors/ecosystems/README.md): generated per-ecosystem detector chains and evidence patterns
120+
- [Matcher reference](docs/matchers/README.md): generated per-matcher behavior and output notes
121+
114122
## Core Commands
115123

116124
### `bomly scan`
@@ -129,8 +137,13 @@ bomly scan --sbom --path ./existing-sbom.json
129137

130138
# Filter to runtime dependencies only
131139
bomly scan --scope runtime
140+
141+
# Explore the result in the interactive terminal UI
142+
bomly scan --interactive
132143
```
133144

145+
`scan` is offline-safe unless you opt into enrichment. Use `--enrich` when you want Bomly to call external vulnerability, license, or lifecycle services. Use `--audit` when you want Bomly to evaluate vulnerability data that already exists on packages. Use both together when you want fetched vulnerability data evaluated in one run.
146+
134147
### `bomly explain`
135148

136149
Use `explain` to show the dependency path that introduced a package.

docs/AUDITORS.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Auditors
2+
3+
Auditors evaluate a graph and produce findings.
4+
5+
The default policy auditor looks at vulnerability data that is already present on packages. It does not make network calls on its own. If you want Bomly to fetch vulnerability data and then evaluate policy in one command, run `bomly scan --enrich --audit`.
6+
7+
## When Auditors Run
8+
9+
- `bomly scan --audit` evaluates the full graph.
10+
- `bomly explain --audit` evaluates the selected component context.
11+
- `bomly diff --audit` classifies introduced, resolved, and persisted findings.
12+
13+
## Findings
14+
15+
Findings have a normalized shape: ID, kind, severity, package, title, reasons, and source. Text output summarizes them for humans, JSON exposes them for automation, and SARIF is available for audit results with `--format sarif`.

docs/DETECTORS.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# Detectors
2+
3+
Detectors are the part of Bomly that read a project, container, or SBOM and turn the evidence into a dependency graph.
4+
5+
Bomly plans detector work before a scan starts. It looks for package-manager evidence such as lockfiles, manifests, workflow files, or SBOM documents, then runs the best detector chain for each discovered subproject. Native detectors run first when Bomly can produce a richer graph itself. Syft-backed detection fills coverage gaps and container/image scenarios.
6+
7+
## When Detectors Run
8+
9+
- `bomly scan` runs detectors to build the graph.
10+
- `bomly explain` reuses the same detector planning before finding dependency paths.
11+
- `bomly diff` runs detectors for each side of the comparison unless you diff SBOM files.
12+
- Detector plugins participate in the same planning flow when they declare package-manager evidence.
13+
14+
## Detector Chains
15+
16+
A detector chain is the ordered list Bomly tries for a package manager. The first detector is preferred. A later detector is a fallback when the preferred detector is not ready, not applicable, or cannot produce graph data.
17+
18+
Some detectors can run an ecosystem tool such as `npm`, `go`, `mvn`, `dart`, `swift`, or `sbt`. Bomly does not install package managers for you. Use `--install-first` only when you want detectors that support it to run their normal dependency-install command before resolving the graph.
19+
20+
## Generated Ecosystem Guides
21+
22+
The pages in `docs/detectors/ecosystems/` are generated from Bomly's registry. Each page lists supported package managers, evidence patterns, chain order, install-first support, and the native commands users may need on `PATH`.

docs/MATCHERS.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Matchers
2+
3+
Matchers enrich packages after Bomly has built a dependency graph.
4+
5+
Bomly is offline-safe by default. Network-backed matchers only run when package enrichment is explicitly enabled, for example with `bomly scan --enrich`. Matchers attach data such as vulnerabilities, license metadata, and end-of-life signals to packages. Auditors can then evaluate the enriched graph when `--audit` is enabled.
6+
7+
## What Matchers Add
8+
9+
- Vulnerability matchers add vulnerability IDs, severity, aliases, CVSS, fixed versions, references, and KEV signals where available.
10+
- License matchers add license evidence from external package metadata services.
11+
- Lifecycle matchers add ecosystem/runtime end-of-life metadata.
12+
13+
## Generated Matcher Guides
14+
15+
The pages in `docs/matchers/` are generated from Bomly's matcher descriptors and known runtime behavior. They list when each matcher runs, whether it uses the network, cache expectations, and the output fields users should expect.

docs/README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# Bomly Documentation
2+
3+
Start here when you want to understand what Bomly scans, what it adds, and which output to use.
4+
5+
## Guides
6+
7+
- [Support Matrix](SUPPORT_MATRIX.md): generated overview of supported ecosystems and package managers
8+
- [Detectors](DETECTORS.md): how Bomly discovers projects and builds dependency graphs
9+
- [Matchers](MATCHERS.md): how optional enrichment adds vulnerability, license, and lifecycle data
10+
- [Auditors](AUDITORS.md): how Bomly turns vulnerability data into findings
11+
- [Managed Plugins](PLUGINS.md): install, enable, verify, and run external detectors, matchers, and auditors
12+
- [CI](CI.md): validation, smoke tests, release packaging, and automation notes
13+
14+
## Generated References
15+
16+
- [Config Reference](CONFIG_REFERENCE.md)
17+
- [Detector ecosystem guides](detectors/ecosystems/README.md)
18+
- [Matcher reference](matchers/README.md)
19+
- [JSON schema docs](schemas/scan.md)
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# Detector Ecosystem Guides
2+
3+
These generated pages explain how Bomly detects each supported ecosystem.
4+
5+
- [alpm](alpm.md)
6+
- [apk](apk.md)
7+
- [conda](conda.md)
8+
- [cpp](cpp.md)
9+
- [dart](dart.md)
10+
- [dotnet](dotnet.md)
11+
- [dpkg](dpkg.md)
12+
- [elixir](elixir.md)
13+
- [erlang](erlang.md)
14+
- [github-actions](github-actions.md)
15+
- [go](go.md)
16+
- [haskell](haskell.md)
17+
- [homebrew](homebrew.md)
18+
- [lua](lua.md)
19+
- [maven](maven.md)
20+
- [nix](nix.md)
21+
- [npm](npm.md)
22+
- [ocaml](ocaml.md)
23+
- [php](php.md)
24+
- [portage](portage.md)
25+
- [prolog](prolog.md)
26+
- [python](python.md)
27+
- [r](r.md)
28+
- [rpm](rpm.md)
29+
- [ruby](ruby.md)
30+
- [rust](rust.md)
31+
- [sbom](sbom.md)
32+
- [scala](scala.md)
33+
- [snap](snap.md)
34+
- [swift](swift.md)
35+
- [terraform](terraform.md)
36+
- [wordpress](wordpress.md)

docs/detectors/ecosystems/alpm.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Alpm Detectors
2+
3+
<!-- Auto-generated by make generate. Do not edit manually. -->
4+
5+
Bomly uses these detector chains when it finds `alpm` package-manager evidence.
6+
7+
| Package manager | Detector chain | Evidence patterns | Install-first support | Native command hints |
8+
| --- | --- | --- | --- | --- |
9+
| `alpm` | `syft-detector` | `var/lib/pacman/local/*/desc` | No | `syft for bomly-lite` |
10+
11+
## How To Read This
12+
13+
- Bomly tries detector chains from left to right.
14+
- Evidence patterns are files or paths Bomly uses during planning.
15+
- Install-first support means `--install-first` can run the ecosystem's normal install command before graph resolution.
16+
- Syft-backed entries provide broad compatibility, especially for containers and ecosystems without native Bomly graph resolution.

docs/detectors/ecosystems/apk.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Apk Detectors
2+
3+
<!-- Auto-generated by make generate. Do not edit manually. -->
4+
5+
Bomly uses these detector chains when it finds `apk` package-manager evidence.
6+
7+
| Package manager | Detector chain | Evidence patterns | Install-first support | Native command hints |
8+
| --- | --- | --- | --- | --- |
9+
| `apk` | `syft-detector` | `lib/apk/db/installed` | No | `syft for bomly-lite` |
10+
11+
## How To Read This
12+
13+
- Bomly tries detector chains from left to right.
14+
- Evidence patterns are files or paths Bomly uses during planning.
15+
- Install-first support means `--install-first` can run the ecosystem's normal install command before graph resolution.
16+
- Syft-backed entries provide broad compatibility, especially for containers and ecosystems without native Bomly graph resolution.

docs/detectors/ecosystems/conda.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Conda Detectors
2+
3+
<!-- Auto-generated by make generate. Do not edit manually. -->
4+
5+
Bomly uses these detector chains when it finds `conda` package-manager evidence.
6+
7+
| Package manager | Detector chain | Evidence patterns | Install-first support | Native command hints |
8+
| --- | --- | --- | --- | --- |
9+
| `conda` | `syft-detector` | `conda-meta/*.json` | No | `syft for bomly-lite` |
10+
11+
## How To Read This
12+
13+
- Bomly tries detector chains from left to right.
14+
- Evidence patterns are files or paths Bomly uses during planning.
15+
- Install-first support means `--install-first` can run the ecosystem's normal install command before graph resolution.
16+
- Syft-backed entries provide broad compatibility, especially for containers and ecosystems without native Bomly graph resolution.

0 commit comments

Comments
 (0)