Skip to content

Upgrading rubygems-update 3 to 4

Breaking3.7.2 → 4.0.23Breaking9Security13Deprecated3New17Changed62Fixed56Other27

BreakingUpgrade verdict

9 breaking changes and 12 security fixes.

  • The internal deprecation helper module is gone.
  • Removes the deprecated `-C` option from gem build.
  • Removes deprecated Gem::Specification#has_rdoc, has_rdoc= and has_rdoc?.
  • Removes the deprecated `gem query` command.
Top 5 of 24 that need code or config changes
Breaking9
Removes unused Gem::Deprecate.
Gem::Deprecate
Removes the deprecated -C option from gem build.
gem build-C
Removes deprecated Gem::Specification#has_rdoc, has_rdoc= and has_rdoc?.
Gem::Specification#has_rdocGem::Specification#has_rdoc=Gem::Specification#has_rdoc?
Removes the deprecated gem query command.
gem query
Removes deprecated Gem::DependencyInstaller#find_gems_with_sources.
Gem::DependencyInstaller#find_gems_with_sources
Removes deprecated methods of RubyGems.
Removes compatibility.rb for RubyGems 4.0.
compatibility.rb
Makes verification methods private.
Switch to 4.0.0.dev in development version.
Security12
Drops setuid, setgid and sticky bits when extracting gems.
Keeps credentials on redirects only within the same origin.
Rejects Bundler redirects that downgrade https to http.
Rejects SafeMarshal collection lengths longer than the remaining input.
SafeMarshal
Validates the platform field in Gem::Installer#verify_spec.
Gem::Installer#verify_spec
Restricts UserDefined handling to an explicit class set for Gem::SafeMarshal.
Gem::SafeMarshal
Filters git command output against the configured URI.
Redacts URI userinfo from settings names in the Bundler User-Agent.
Validates gem name before building compact index cache paths.
Prevents archive extraction from escaping destination_dir via pre-existing symlinks.
destination_dir
Restricts what schemes are acceptable in the remote fetcher.
Bumps the vendored URI library to 1.0.4.
URI
Deprecated3
Deprecates the --default option of the install command.
gem install--default
Deprecates Gem::Specification#datadir.
Gem::Specification#datadir
Deprecate comparing Gem::Version objects with strings.