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

Bump netaddr gem to 1.5.3 to fix CVE-2019-17383 #2373

Merged
merged 1 commit into from
May 9, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions packages/director/packaging
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ pushd vendor/cache/eventmachine-* > /dev/null
mv *.gem ../
popd > /dev/null

pushd vendor/cache/netaddr-rb-* > /dev/null
gem build netaddr.gemspec
mv *.gem ../
popd > /dev/null

cat > Gemfile <<EOF
# Explicitly require vendored version to avoid requiring builtin json gem
gem 'json', '2.6.1'
Expand Down
1 change: 1 addition & 0 deletions packages/director/spec
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@ files:
- vendor/cache/*.gem
- vendor/cache/eventmachine-*/**
- vendor/cache/extensions/**
- vendor/cache/netaddr-rb-*/**
1 change: 1 addition & 0 deletions src/Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ group :development, :test do
gem 'rubocop-git'

gem 'eventmachine', '~>1.3.0.dev.1', git: 'https://github.com/eventmachine/eventmachine', ref: 'abe34'
gem 'netaddr', '~>1.5.3.dev.1', git: 'https://github.com/dspinhirne/netaddr-rb', tag: '1.5.3'

# for director
gem 'machinist', '~>1.0'
Expand Down
11 changes: 9 additions & 2 deletions src/Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
GIT
remote: https://github.com/dspinhirne/netaddr-rb
revision: c7a7de39b7e1126aef11821f98970db18582948b
tag: 1.5.3
specs:
netaddr (1.5.3)

GIT
remote: https://github.com/eventmachine/eventmachine
revision: abe347b824e36453f8a013fbe14323342a2ac8de
Expand Down Expand Up @@ -43,7 +50,7 @@ PATH
logging (~> 2.2.2)
membrane (~> 1.1.0)
nats-pure (~> 0.6.2)
netaddr (~> 1.5.0)
netaddr (~> 1.5.3.dev.1)
openssl
prometheus-client (~> 1.0.0)
puma
Expand Down Expand Up @@ -175,7 +182,6 @@ GEM
mysql2 (0.5.3)
nats-pure (0.6.2)
net-ssh (5.2.0)
netaddr (1.5.1)
netrc (0.11.0)
nio4r (2.5.8)
openssl (3.0.0)
Expand Down Expand Up @@ -318,6 +324,7 @@ DEPENDENCIES
mysql2
nats-pure (~> 0.6.2)
net-ssh
netaddr (~> 1.5.3.dev.1)!
openssl
parallel_tests (~> 2.0)
pg
Expand Down
2 changes: 1 addition & 1 deletion src/bosh-director/bosh-director.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ Gem::Specification.new do |spec|
spec.add_dependency 'membrane', '~>1.1.0'
spec.add_dependency 'nats-pure', '~>0.6.2'
spec.add_dependency 'openssl'
spec.add_dependency 'netaddr', '~>1.5.0'
spec.add_dependency 'netaddr', '~>1.5.3.dev.1'
spec.add_dependency 'prometheus-client','~>1.0.0'
spec.add_dependency 'puma'
spec.add_dependency 'rack-test', '~>0.6.2' # needed for console
Expand Down
Binary file removed src/vendor/cache/netaddr-1.5.1.gem
Binary file not shown.
Empty file.
7 changes: 7 additions & 0 deletions src/vendor/cache/netaddr-rb-c7a7de39b7e1/Errors
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
=Error Classes

+-Exception
+-StandardError
+-BoundaryError => CIDR or EUI is out of bounds for a valid address
+-ValidationError => CIDR or EUI failed validation checks
+-VersionError => CIDR or EUI is of improper version for requested operation
9 changes: 9 additions & 0 deletions src/vendor/cache/netaddr-rb-c7a7de39b7e1/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# netaddr
I originally created this package back in 2007 out of the need for a tool
which I could use to track an inventory of constantly changing IP subnets.
At the time, I was in the process of migrating away from Perl and towards Ruby
as my primary scripting language. I have since migrated away from using Ruby so
I have not made any major modifications to this code base since 2008 (aside from a
handful of bug fixes that others have pointed out).

Dustin Spinhirne
52 changes: 52 additions & 0 deletions src/vendor/cache/netaddr-rb-c7a7de39b7e1/changelog
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
Version 1.5.2
Changes:
* bug fixes from: https://github.com/KirillSmirnov, https://github.com/rwhitworth, https://github.com/y13i

Version 1.5.1
Changes:
* fixed bug with NetAddr#merge (credit to Daniel Boughton)


Version 1.5.0
Changes:
* fixed bug with EUI48#to_eui64 (credit to Erik Kline)
* fixed bug with u/l bit toggle on EUI#link_local (credit to Erik Kline)
* added EUI#to_ipv6
* added NetAddr#supernets


Version 1.4.0
Changes:
* Added additional options to NetAddr#sort


Version 1.3.0
New Features:
* added CIDR#[]
* added CIDR#succ (CIDR objects may now be used as args for the standard Ruby Range class)
* added CIDR#allocate_rfc3531
* added CIDR#to_i
* added CIDRv6.unique_local
* added EUI48#to_eui64
* added EUI#to_i
* added EUI#to_s

Changes:
* deprecated 'packed' methods


Version 1.2.0
Changes:
* CIDRv4#new and CIDRv6#new methods have been changed for the sake of speed improvements.
Please use the CIDR#create method instead.
* changes to CIDR#wildcard_mask
* bug fix with validate_eui method
* bug fix with validate_ip_addr
* bug fix and *vast* simplification of NetAddr.merge


New Features:
* speed improvements
* added CIDR#set_wildcard_mask
* added <=>, >, <, == methods to CIDR
* NetAddr.merge now reports which CIDR addresses were used to create new summary addresses
Loading