Ales Raszka
a8a91379d9
Add test for potential namespace
...
Test verifies that potential namespace is stored in database and it can
be loaded back to structure.
The commit also fixes few typos and bugs.
5 years ago
Ales Raszka
60ef726677
Move PotentialNamespace to LayerFeature
...
PotentialNamespace should be in LayerFeature instead of Feature struct.
Feature extractors were updated to return LayerFeature instead of
Feature.
5 years ago
Sida Chen
79af05e67d
pgsql: Fix postgres queries for feature_type
5 years ago
Sida Chen
e657d26313
database: move dbutil and testutil to database from pkg
...
Move dbutil and testutil to database from pkg
Rename all "result"
6 years ago
Sida Chen
0c1b80b2ed
pgsql: Implement database queries for detector relationship
...
* Refactor layer and ancestry
* Add tests
* Fix bugs introduced when the queries were moved
6 years ago
Sida Chen
e160616723
database: Use LayerWithContent as Layer
6 years ago
Sida Chen
2827b9342b
Update Database and Worker implementation for layer-wise feature
...
Feature extraction algorithm is changed to associate features with
ancestry layer. Database is updated to keep the relationship.
6 years ago
Sida Chen
a5c6400065
database: postgres implementation with tests.
7 years ago
Sida Chen
bffa6499b7
added support for detect multiple namespaces in a layer
...
created table layer_namespace to store the many to many unique mapping of layers and namespaces
changed v1 api to provide a list of namespaces for each layer
changed namespace detector to use all registered detectors to detect namespaces
updated tests for multiple namespaces
Fixes #150
7 years ago
Jimmy Zelinskie
9c63a63944
clair: mv updater clair and mv severity to db
7 years ago
Jimmy Zelinskie
343e24eb7e
clair: remove `types` package
...
This removes the `types` package instead moving the contents to the
top-level clair package.
This change also renames the `Priority` type to `Severity` in order to
reduce confusion.
This change also removes the IsValid method and replaces it with a safe
constructor to avoid the creation of invalid values.
Many docstrings were tweaked in the making of this commit.
7 years ago
Jimmy Zelinskie
78cef02fda
pkg: cerrors -> commonerr
7 years ago
Jimmy Zelinskie
8d29bf860d
versionfmt: convert to using constant over literal
8 years ago
Jimmy Zelinskie
033709eaea
add registerable version formats
...
Since we only ever used dpkg, this change shims everything into using
dpkg.
8 years ago
Quentin Machu
a38fbf6cfe
worker/database: Move upgrade detection logic out of database to worker
8 years ago
Quentin Machu
e7b960c05b
database: Allow specifying datastore driver by config
...
Fixes #145
8 years ago
Jimmy Zelinskie
500fc4e407
various: gofmt -s
8 years ago
Quentin Machu
5759af5bcf
database: test and fix layer updates
8 years ago
Quentin Machu
726bd3c0c6
database/api: add layer deletion support
8 years ago
Quentin Machu
82175dcfe9
*: add missing copyright headers
8 years ago
Quentin Machu
970756cd5a
database: do insert/find layers (with their features and vulnerabilities)
8 years ago
Quentin Machu
2c150b015e
*: refactor & do initial work towards PostgreSQL implementation
8 years ago