Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Update v2 to main #1396

Open
wants to merge 13 commits into
base: v2
Choose a base branch
from
Open

chore: Update v2 to main #1396

wants to merge 13 commits into from

Commits on Oct 22, 2024

  1. chore: Replace package level ignores with entire directory ignores in…

    … our osv-scanner.toml in fixtures (google#1337)
    
    Uses the new feature landed in google#1214
    another-rex authored Oct 22, 2024
    Configuration menu
    Copy the full SHA
    1a651fe View commit details
    Browse the repository at this point in the history
  2. feat: Migrate pomxml extractor which also performs transitive depende…

    …ncy resolution (google#1331)
    
    Part of google#1330 
    
    No functional change is made compared to the version in
    `internal/manifest`, just switched to use the osv-scalibr interface.
    
    Extractors moved to lockfilescalibr as a temporary staging ground before
    moving to osv-scalibr.
    another-rex authored Oct 22, 2024
    Configuration menu
    Copy the full SHA
    e67449e View commit details
    Browse the repository at this point in the history

Commits on Oct 25, 2024

  1. chore: Update v2 with new changes from main (google#1344)

    Co-authored-by: Xueqin Cui <[email protected]>
    Co-authored-by: Michael Kedar <[email protected]>
    3 people authored Oct 25, 2024
    Configuration menu
    Copy the full SHA
    a78c74d View commit details
    Browse the repository at this point in the history
  2. feat: Use custom pathtree library instead of third party trie (google…

    …#1341)
    
    Turns out we don't need most of the functionality of the third party
    tire library. Built a simple and focused library pathtree which is just
    a tree with insert and get functions to allow us to implement a virtual
    filesystem easily.
    another-rex authored Oct 25, 2024
    Configuration menu
    Copy the full SHA
    4069367 View commit details
    Browse the repository at this point in the history
  3. feat: Add osvscanner.json extractor (google#1338)

    Add/migrate osv-scanner.json extractor to use the scalibr format. This
    is intended to replace the current extractor located here:
    pkg/lockfile/osv-vuln-results.go
    
    This is extractor is intended to stay in osv-scanner and not moved to
    osv-scalibr as it is very osv-scanner specific.
    another-rex authored Oct 25, 2024
    Configuration menu
    Copy the full SHA
    4e7ca75 View commit details
    Browse the repository at this point in the history

Commits on Oct 27, 2024

  1. feat: migrate node-modules to a osv-scalibr extractor (google#1345)

    Ideally, node package extracts can be done with packagejson extractor
    directly (As every dir inside a node_modules directory has a
    package.json file), but that changes the image scanning snapshots too
    much to be part of this initial PR, and introduces new OS findings that
    are difficult to filter out.
    
    This keeps the existing solution of extracting directly with
    node_modules by implementing an extractor that wraps the
    `packagejsonlock` extractor to minimise snapshot changes.
    another-rex authored Oct 27, 2024
    Configuration menu
    Copy the full SHA
    1cd58a7 View commit details
    Browse the repository at this point in the history

Commits on Oct 30, 2024

  1. chore: update v2 up to date with main (google#1357)

    Signed-off-by: dependabot[bot] <[email protected]>
    Co-authored-by: Xueqin Cui <[email protected]>
    Co-authored-by: Michael Kedar <[email protected]>
    Co-authored-by: Gareth Jones <[email protected]>
    Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
    5 people authored Oct 30, 2024
    Configuration menu
    Copy the full SHA
    1ef84e7 View commit details
    Browse the repository at this point in the history
  2. feat: Update docker container scanning flag (google#1350)

    Resolves google#1316 
    
    Update the --docker flag to:
    - Only accept one image to scan at a time (to make displaying results
    easier)
    - Call new image scanning function internally.
    - Acts like a convenience function for 
    ```
    docker save <image-name> > img-name.tar && osv-scanner --experimental-oci-image=img.name.tar
    ```
    
    TODO: 
    - [x] Add an ACCEPTANCE test which uses docker to pull down a stable
    image.
    - [x] Include a docker pull first, as docker save only saves images
    already on device and does not pull images online.
    another-rex authored Oct 30, 2024
    Configuration menu
    Copy the full SHA
    1638434 View commit details
    Browse the repository at this point in the history

Commits on Nov 1, 2024

  1. feat: Use lockfile scalibr interface (google#1330)

    This PR contains all the code required to move to osv-scalibr while
    making the existing code compile and pass all tests (container tests not
    passing because of a bug in the scalibr alpine extractor).
    
    Changes not mentioned in the following list will be split off in
    separate PRs which should land before this PR.
    
    Those are:
    - [x] google#1337 
    - [x] google#1331 
    - [x] google#1338 
    - [x] google#1341
    - [x] google#1345
    
    
    Changes in this PR:
    - Fixture changes:
    - Scalibr Python requirements.txt extractor currently doesn't support
    packages without versions, so added some version strings to the test
    files
    - Image package required quite a bit of reworking to successfully
    update.
    - Add the ability to iterate through a directory via the pathtree
    library
      - Support scalibr FS interface for Layers
    - Add conversion code to convert inventories from osv-scalibr back to
    v1's lockfile and Inventory
    - This is done to minimize snapshot changes. Followup PRs should remove
    this conversion
    - Add `internal/lockfilescalibr` package:
      - `errors.go` adds common extraction errors we want to translate.
    - `translation.go` adds helper functions and translation logic between
    osv-scanner v1 extractor names, and osv-scalibr extractor names.
    
    
    
    Changes in followup PRs:
    - Delete lockfiles package and migrate everything to use osv-scalibr
    extractors
    - Remove conversion code in image
    
    ---------
    
    Signed-off-by: dependabot[bot] <[email protected]>
    Co-authored-by: Gareth Jones <[email protected]>
    Co-authored-by: Xueqin Cui <[email protected]>
    Co-authored-by: Michael Kedar <[email protected]>
    Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
    5 people authored Nov 1, 2024
    Configuration menu
    Copy the full SHA
    b15b566 View commit details
    Browse the repository at this point in the history

Commits on Nov 5, 2024

  1. chore: Update v2 to main (google#1374)

    Using a separate branch to resolve the merge conflicts, but other than
    that this is a straightforward update of the v2 branch up to the latest
    main branch.
    
    ---------
    
    Signed-off-by: dependabot[bot] <[email protected]>
    Signed-off-by: Emmanuel Ferdman <[email protected]>
    Co-authored-by: Xueqin Cui <[email protected]>
    Co-authored-by: Michael Kedar <[email protected]>
    Co-authored-by: Gareth Jones <[email protected]>
    Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
    Co-authored-by: Emmanuel Ferdman <[email protected]>
    Co-authored-by: Ignacio Vazquez <[email protected]>
    7 people authored Nov 5, 2024
    Configuration menu
    Copy the full SHA
    c9a0635 View commit details
    Browse the repository at this point in the history
  2. feat: remove deprecated public packages (google#1376)

    Follow up to google#1309
    
    BREAKING CHANGE: these packages are no longer public
    
    Co-authored-by: Rex P <[email protected]>
    G-Rath and another-rex authored Nov 5, 2024
    Configuration menu
    Copy the full SHA
    81d656a View commit details
    Browse the repository at this point in the history

Commits on Nov 13, 2024

  1. Merge main into v2 via merge_main_to_v2 branch

    Signed-off-by: Holly Gong <[email protected]>
    hogo6002 committed Nov 13, 2024
    Configuration menu
    Copy the full SHA
    ddec517 View commit details
    Browse the repository at this point in the history
  2. remove unused dependency

    hogo6002 committed Nov 13, 2024
    Configuration menu
    Copy the full SHA
    317dde7 View commit details
    Browse the repository at this point in the history