Repository navigation
Conversation
…ages - gem manager: Homebrew Ruby's gems, including the ones that ship with Ruby (marked as default or bundled). Outdated from gem outdated, release dates from rubygems.org, CVEs and malware from OSV for every installed version. Updates install the exact version the scan saw, with --conservative so dependencies that already fit stay put. macOS's own Ruby is left alone. - Projects: Gemfile.lock (registry gems only; GIT and PATH sources are skipped, platform builds fold into one version). It isn't fixable: Bundler would run the project's Gemfile, which is Ruby code. - Docker: gems found from specifications/*.gemspec, with the image cache versioned so already-read images are read again once.
Default and bundled gems also get newer with brew upgrade ruby, so 43 of the 44 outdated gems on a fresh Homebrew Ruby were noise. A newer release of one now only counts when OSV knows a vulnerability in the installed version (one querybatch per scan; if OSV can't be reached they all count, as before). The rest are marked newer: shown with their new version and an update button, kept out of the outdated counts and update-all, and still held by the cooldown and the malware check.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds Ruby gems in all three places pkgdash looks at packages.
gem manager (new card and page)
/usr/bin/rubyis left alone, like its Python.gem outdated; release dates for the cooldown from rubygems.org.gem install <gem> --version <scanned version> --conservative --no-document, behind the usual malware and cooldown gate. Names and versions are validated before they reach the command.Projects:
Gemfile.lockis read (GEM sections only; GIT/PATH sources and the project's own gems are skipped). Fixing it is refused on purpose:bundle lockevaluates the project'sGemfile, which is Ruby code, and pkgdash's fixes never run project code.Docker: gems inside images (
specifications/*.gemspec), also checked against OSV's malware list. The per-image cache is versioned so images already read get read again once.Tested against a real Homebrew Ruby (84 gems, 44 outdated; the audit found a real advisory in
json2.18.0). New unit tests cover the manager, Gemfile.lock parsing including hostile input, and Docker gemspecs. The Atheris fuzzer picks up the new parser fromLOCKFILESautomatically, with a new seed.Ruby's own gems (default and bundled) only count as outdated when OSV knows a vulnerability in the installed version, since
brew upgrade rubyupdates them too. The rest show their newer version with an update button, stay out of the counts and update-all, and are still held by the cooldown and malware check. On a real Homebrew Ruby: 1 outdated (json, vulnerable) instead of 44.