Commit graph

102 commits

Author SHA1 Message Date
Christopher Angelo Phillips
3e0af43383
chore: pin dependencies (#994) 2022-11-14 21:23:42 +00:00
Weston Steimel
e33b1203a1
feat: consider well-known false-positive generating CPE target SW components in match filtering logic (#961)
Enhances the CPE target software component match filtering logic to consider ecosystems which aren't currently supported by
syft cataloging but are well-known sources of false-positives. This currently adds support for filtering various
permutations of `wordpress`, `joomla`, and `drupal`

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>
2022-11-02 20:21:14 +00:00
Weston Steimel
a2ab617cef
chore: grype quality pipeline latest label updates and images (#976)
Signed-off-by: Weston Steimel <weston.steimel@anchore.com>
2022-11-01 21:20:49 +00:00
Weston Steimel
4cda526992
implement v5 db schema to support improved matching between rpm appstream modules (#944)
Adds support for a `package_qualifiers` column to allow evaluating package matches to vulnerabilities based on more than just version constraints. Currently adds an rpm-modularity qualifier in order to support matching to correct app stream module in order to reduce false positives within rpm-based distro ecosystems. In order to prevent an increase in false positive matches for previous versions of grype using the v4 schema, this change (along with the vulnerability source driver parser updates) requires bumping the schema to v5.

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>
Signed-off-by: Alex Goodman <alex.goodman@anchore.com>
Co-authored-by: Alex Goodman <alex.goodman@anchore.com>
2022-10-18 00:34:47 +01:00
Weston Steimel
cd634961e6
expand quality gate image set to include rpm appstreams-related images (#952)
Signed-off-by: Weston Steimel <weston.steimel@anchore.com>
2022-10-10 17:10:10 +01:00
Weston Steimel
539e64204a
chore: add more quality gate images (#950)
Signed-off-by: Weston Steimel <weston.steimel@anchore.com>
2022-10-06 15:01:49 +01:00
Alex Goodman
d4587ddeec
Add in-depth quality gate checks (#949)
* add in-depth quality gate checks

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* add quality tests to PR checks

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>
2022-10-05 16:26:26 -04:00
Keith Zantow
ba73ab362a
Add support for scanning RPM files (#917) 2022-09-09 14:56:37 -04:00
Chapman Pendery
d5b825e40b
feat: extract use cpes in matching logic to be configurable (#911) 2022-09-06 09:55:35 -04:00
skuethe
ae37eb4a05
Add s390x build support (#720)
Co-authored-by: Christopher Phillips <christopher.phillips@anchore.com>
2022-08-18 16:28:10 -04:00
Christopher Angelo Phillips
74fd591caf
update golanci-lint, goreleaser, cosign (#850) 2022-07-28 14:55:14 -04:00
Christopher Angelo Phillips
991d16879a
update grype to use syft v0.52.0 (#838) 2022-07-22 16:12:18 +00:00
Zac Medico
30943e032b
add Gentoo matching support (#813)
Co-authored-by: Christopher Phillips <christopher.phillips@anchore.com>
2022-07-19 09:37:21 -04:00
Christopher Angelo Phillips
addbd07b4f
Add new matcher files for golang => remove main module FP matches (#829) 2022-07-18 13:14:03 -04:00
artsv79
2233736e98
add DBCloser. Clients can aviod db connection leak if vulnerability db is loaded many times (#825) 2022-07-12 09:54:42 -04:00
Christopher Angelo Phillips
cb6bddfeeb
bump syft version to v0.51.0 (#822) 2022-07-11 15:15:12 -04:00
cpendery
e2fff6c22f
feat: implement grype db diff command (#812)
Co-authored-by: Alex Goodman <alex.goodman@anchore.com>
Co-authored-by: Weston Steimel <weston.steimel@anchore.com>
Co-authored-by: Christopher Angelo Phillips <32073428+spiffcs@users.noreply.github.com>
2022-07-11 09:46:59 -04:00
Christopher Angelo Phillips
0e0a9d9e7a
update syft to v0.50.0 (#818) 2022-07-06 14:48:21 +00:00
Weston Steimel
44032c514c
Finalize v4 Grype schema (#803)
* initial v4 schema setup

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* update v3 => v4 for unit tests

-- did NOT update
    - grype/db/v3/*

Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>

* use nullable string in sqlite so null values get represented correctly

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* add missing unit test case for dotnet

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* Add db writer function for calling sqlite vacuum

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* adding normalization of package names at database adapter layer

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* refactor namespaces for v4

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* update v4 stuff to use sqlite fork

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* Namespace should satisfy Stringer interface

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* normalize CPEs before comparison

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* vulnerability exclusion => vulnerability match exclusion

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* updates to vulnerability match exclusion models

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* add initial vulnerability match exclusion store unit tests

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* make vuln match exclusion constraints nullable

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* move vuln match namespace into constraints object and refactor

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* check db match constraints to ensure there aren't any unknown fields and add json hints

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* ensure we only keep compatible match exclusion constraints

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* use omitempty on all match exclusion structs

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* remove db v4 schema resolver and namespace types

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* rename Vacuum to Close

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* lint fixes + remove panic on vuln provider creation

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* WIP match exclusions

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* build list of ignore rules from v4 db records

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* quick attempt at a new uber object

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* just pass around the full object for now to quickly get to a usable state

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* fix panic when no vuln db loaded

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* use interfaces for db.store function signatures

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* Flatten the match exclusion constraint model to simplify logic

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* updating some tests

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* fix panic when no db update possible

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* more tests

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* WIP fixing match exclusion constraint usability and json mapping logic

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* add v4 db diff logic (excluding vulnerability_match_exclusion data for now)

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* lint fix

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* update integration tests

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* nvd -> nvd:cpe namespace updates

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* ensure test store uses v4 normalized names

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* set the grype db update url to staging for v4

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* prevent more segfaults on database open

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* add continue when unable to load ignore rules

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* remove db.Status from the Store object

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* fix compare_sbom_input_vs_lib_test.go

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

* remove staging endpoint now that v4 is published

Signed-off-by: Weston Steimel <weston.steimel@anchore.com>

Co-authored-by: Christopher Phillips <christopher.phillips@anchore.com>
Co-authored-by: Alex Goodman <alex.goodman@anchore.com>
2022-07-05 19:03:16 +01:00
cpendery
90df6815e6
feat: add diffing 2 databases to v3 store functionality (#789) 2022-06-28 14:22:37 -04:00
Christopher Angelo Phillips
0703bae977
update grype to latest syft patch v0.48.1 (#790) 2022-06-17 15:45:33 +00:00
Jonas Xavier
2a587d0890
ignore gemfile rich version for semVer comparison (#776)
* ignore gemfile rich version during comparision

Signed-off-by: Jonas Xavier <jonasx@anchore.com>

* update search and version tests

Signed-off-by: Jonas Xavier <jonasx@anchore.com>

* fix int tests and lint error

Signed-off-by: Jonas Xavier <jonasx@anchore.com>

* nit on error message

Signed-off-by: Jonas Xavier <jonasx@anchore.com>

* split based on arch in gem version

Signed-off-by: Jonas Xavier <jonasx@anchore.com>

* reuse semVer constraint

Signed-off-by: Jonas Xavier <jonasx@anchore.com>

* more constraint tests cases

Signed-off-by: Jonas Xavier <jonasx@anchore.com>

* feedback changes

Signed-off-by: Jonas Xavier <jonasx@anchore.com>

* more comments and tests

Signed-off-by: Jonas Xavier <jonasx@anchore.com>

* add lower case version check

Signed-off-by: Jonas Xavier <jonasx@anchore.com>

* feedback changes

Signed-off-by: Jonas Xavier <jonasx@anchore.com>

* validate that ruby version work with semver and gem version

Signed-off-by: Jonas Xavier <jonasx@anchore.com>

* more comments and tests

Signed-off-by: Jonas Xavier <jonasx@anchore.com>

* rename gem version format const

Signed-off-by: Jonas Xavier <jonasx@anchore.com>
2022-06-10 14:09:58 -04:00
Christian Kotzbauer
731abaab72
Add syft v0.46.0 Dotnet support (#747) 2022-05-13 12:46:31 -04:00
Jonas Xavier
523f5ce9c0
Consume attestation files (#706)
* add key flag to attest validation

Signed-off-by: Jonas Galvão Xavier <jonas.agx@gmail.com>

* mvp: verify sig and extract sbom

Signed-off-by: Jonas Galvão Xavier <jonas.agx@gmail.com>

* wip read attestation without scheme

Signed-off-by: Jonas Galvão Xavier <jonas.agx@gmail.com>

* go mod tidy

Signed-off-by: Jonas Galvão Xavier <jonas.agx@gmail.com>

* mvp consuming attestations - needs unit tests

Signed-off-by: Jonas Galvão Xavier <jonas.agx@gmail.com>

* remove prototype file

Signed-off-by: Jonas Galvão Xavier <jonas.agx@gmail.com>

* drop local syft from go.mod

Signed-off-by: Jonas Galvão Xavier <jonas.agx@gmail.com>

* fix order of sbom parsing strategies

Signed-off-by: Jonas Galvão Xavier <jonas.agx@gmail.com>

* handle implicit attestation input

Signed-off-by: Jonas Galvão Xavier <jonas.agx@gmail.com>

* wip

Signed-off-by: Jonas Galvão Xavier <jonas.agx@gmail.com>

* add test for invalid attestation key

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* rebase and go-mod-tidy

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* consume attestation via stdin

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* attestation test for stdin

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* validate input and content for attestation

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* add stdin test

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* fix config tags

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* add int test to ignore attestation validation

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* fix cycloneDX attestation fixture

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* add tampered att test

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* add tampered predicate type test

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* improve docs/help on atttestation

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* feedback changes

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* upgrade to latest syft

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* fall through when guessing between sbom and att

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* go mod tidy

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* fix butter finger rebase

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* drop default key value

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* assert error messages

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* better test/cli coverage

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* fix stdin decode test

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* fix goimports

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* tui - verified attestation and feedback changes

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* better naming

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* add attestation section to config file

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* emit event for skipped verification

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* use public key name

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* feedback changes

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>

* nit

Signed-off-by: Jonas Galvão Xavier <jonasx@anchore.com>
2022-04-21 11:52:42 -07:00
Christopher Angelo Phillips
95f68b4c33
Add java.Matcher configuration to includes maven upstream sha1 query (#714) 2022-04-13 13:01:22 -04:00
Jonas Xavier
182c86d11d
Migrate LocationSet and add Dart support (#703) 2022-04-01 08:21:37 -07:00
Alex Goodman
cc8e7836f3
Add platform selection (#666) 2022-03-15 13:13:05 +00:00
Keith Zantow
cbdec2ae5e
Update to Syft v0.41.4 (#664) 2022-03-14 17:15:09 -04:00
Keith Zantow
fc8e13f5b8
Support for SBOMs with incomplete linux distribution or CPE information (#606) 2022-03-03 16:31:46 -05:00
Alex Goodman
ad9918a681
Add gosimports linter (#647) 2022-03-03 14:50:24 -05:00
Alex Goodman
4af3cf7455
reduce PR CI pain and flakyness (#652) 2022-03-02 14:03:19 -05:00
Alex Goodman
598af89b2e
Upgrade install.sh to support installations for previous versions (#636) 2022-02-15 17:29:24 -05:00
Alex Goodman
5aa85338d6
Normalize release assets and refactor install.sh (#630)
* refactor release to keep snapshot assets in parity with release assets

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* refactor install.sh and put under test

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* tidy go.sum

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* add mac acceptance test to github actions workflow

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* rm use of goreleaser in cli tests

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* go mod tidy with go 1.17

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>
2022-02-11 19:24:25 +00:00
Alex Goodman
c9f2716389
Abstract upstream package before matching (#607)
* add metadata extraction from pURLs

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* extract upstream packages before matching

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* put pkg.UpstreamPackages under test

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* remove pURL related processing

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* pull in syft spdx decoding

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* allow for more flexible GHSA namespace and source extraction

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* add matching parity integration tests for all supported formats

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* bump syft to get spdx tv fix

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>
2022-02-10 21:43:12 +00:00
Alex Goodman
2f8682b3db
Add ability to merge matches (#602)
* enable merging of matches

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* add ability for matches constructor to take initial matches

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* update tests to include IDs on package objects

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* rename common matcher helper package to search package

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* rename search functions and add SearchByCriteria

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* cleanup imports

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>
2022-01-25 10:29:16 -05:00
Alex Goodman
6e3aa6a8d7
Add strong distro type (#585)
* add strong distro type

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* nit changes

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* update grype/db package to use distro pointer

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* source distro type from release name

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* bump syft to pull in distro type updates

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* bump lint timeout

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>
2022-01-12 13:47:27 -05:00
Alex Goodman
2647cd0d9e
Port grype-db to grype (#587)
* port grype-db to grype

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* migrate vulnerability provider implementation to db package

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* upgrade path import validations

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* fix linting issues

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>
2022-01-12 10:03:22 -05:00
Alex Goodman
c88ee0e8f5
add expose minimal search configuration (#579)
Signed-off-by: Alex Goodman <alex.goodman@anchore.com>
2022-01-09 06:14:57 -05:00
Christopher Angelo Phillips
64d4dbb993
update syft version for new release (#578)
* update syft

Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>

* update CatalogPackages to use new cataloger config struct

Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>

* add new valid CPE to matcher tests
Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>

* update integration tests

Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>
2022-01-07 17:57:44 -05:00
Keith Zantow
647d6fb770
Add --exclude flag (#551) 2021-12-21 12:52:07 -05:00
Eng Zer Jun
0781fb028b
refactor: move from io/ioutil to io and os packages (#543)
The io/ioutil package has been deprecated as of Go 1.16, see
https://golang.org/doc/go1.16#ioutil. This commit replaces the existing
io/ioutil functions with their new definitions in io and os packages.

Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
2021-12-15 09:35:04 -05:00
Alex Goodman
51e1b6307b
Update syft, jotframe, and validations pipeline (#512)
* update syft and jotframe

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* update validations and release pipeline

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* moved terminal package to golang.org/x/term

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* update integration tests to account for package relationships

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* add license exception for xz

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* update Location and Coordinate references

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* remove benchmark tests

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* remove mac acceptance tests

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* add syft-grype relationship notes in DEVELOPING.md

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>
2021-11-30 18:10:07 +00:00
Dan Luhring
70ec3bfb71
Support for private certificate authorities during DB curation (#494)
* Add injectable HTTP client to file getter

Signed-off-by: Dan Luhring <dan.luhring@anchore.com>

* WIP: Map config for custom CA certs

Signed-off-by: Dan Luhring <dan.luhring@anchore.com>

* update curator and add tests

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* add TLS helper scripts

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* remove grype-db local mod edit

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* tidy go modules

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* use ssl.context over deprecated fn

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* disallow tls 1 and 1.1

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* suppress non-archive sources for fetch-to-dir capability

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* ensure DB load failure does not panic

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* address review comments

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

Co-authored-by: Alex Goodman <alex.goodman@anchore.com>
2021-11-22 16:59:38 +00:00
Christopher Angelo Phillips
a2762bbbf0
Bump syft version => v0.30.1 (#498)
* update syft version with correct arguments

Signed-off-by: Christopher Angelo Phillips <christopher.phillips@anchore.com>

* bump integration tests with new presenter format

Signed-off-by: Christopher Angelo Phillips <christopher.phillips@anchore.com>

* update integration tests to remove php-composer failure

Signed-off-by: Christopher Angelo Phillips <christopher.phillips@anchore.com>
2021-11-15 17:11:56 -05:00
Alex Goodman
afc9de6058
Fix hang when running as a subprocess (#484)
* use named pipe bit on stdin as indicator for piped input

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* ensure stdin is ignored when the CLI hints are present

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* add CLI test to cover subprocess integration behavior

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* added test case for java regression

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* remove extra line in makefile

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>
2021-10-29 14:51:58 +00:00
Christopher Angelo Phillips
9cd917d29c
Add windows support (#464)
* update grype to compile windows

Signed-off-by: spiffcs <christopher.phillips@anchore.com>
Signed-off-by: Christopher Angelo Phillips <christopher.phillips@anchore.com>

* update go mod with new stereoscope

Signed-off-by: Christopher Angelo Phillips <christopher.phillips@anchore.com>

* update build comments

Signed-off-by: Christopher Angelo Phillips <christopher.phillips@anchore.com>

* small build tags

Signed-off-by: Christopher Angelo Phillips <christopher.phillips@anchore.com>

* add goreleaser windows

Signed-off-by: Christopher Angelo Phillips <christopher.phillips@anchore.com>

* bump syft version

Signed-off-by: Christopher Angelo Phillips <christopher.phillips@anchore.com>

* update tests

Signed-off-by: Christopher Angelo Phillips <christopher.phillips@anchore.com>

* update test images to use newest pinned golang

Signed-off-by: Christopher Angelo Phillips <christopher.phillips@anchore.com>
2021-10-22 13:46:56 -04:00
Dan Luhring
19a513a42a
Silence usage and errors on root command (#462)
* Silence usage and errors on root command

Signed-off-by: Dan Luhring <dan.luhring@anchore.com>

* show help when no args are given

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* remove comments

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* add cli test for help behavior

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

Co-authored-by: Alex Goodman <alex.goodman@anchore.com>
2021-10-20 09:50:59 -04:00
Sam Dacanay
2dd41311cb
Retrieve target from directory sbom types in addition to image types (#440)
* Retrieve target from directory sbom types in addition to image types

Signed-off-by: Samuel Dacanay <sam.dacanay@anchore.com>

* add dir sbom ingest test

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

Co-authored-by: Alex Goodman <alex.goodman@anchore.com>
2021-10-06 13:59:36 +00:00
Alex Goodman
6fe9fc2c8c
update linter + fix whitespace (#443)
Signed-off-by: Alex Goodman <alex.goodman@anchore.com>
2021-10-06 09:49:42 -04:00
Alex Goodman
b1f3be4520
Upgrade config, UI, and command package patterns (#406)
* split and upgrade config processing

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* upgrade UI organization

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* expose logger writter

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* add (unused) signal handler

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* add (unused) event loop abstraction

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* update aux commands to use Cobra RunE over Run

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* upgrade root command to use new event loop and signal handler

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* update CLI test to account for config representation

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* update dependencies + fix linting

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* decompose application config parse func + add missing config struct tags

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>

* restore unparam lint exclusion for registry config

Signed-off-by: Alex Goodman <alex.goodman@anchore.com>
2021-10-01 13:03:50 -04:00