Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Provides a Ruby API to NVD JSON Feeds.
.gz
/.zip
JSON feed files..gz
/.zip
JSON feed files..gz
/.zip
JSON feed files, without extracting them..gz
/.zip
JSON feed files.require 'nvd/json_feeds'
Access the Modified CVEs feed:
NVD::JSONFeeds[:modified]
# => #<NVD::JSONFeeds::Feed:0x0000556b4db58660
# @gz=
# #<NVD::JSONFeeds::GzFeedURI: https://nvd.nist.gov/feeds/json/cve/1.1/nvdcve-1.1-modified.json.gz>,
# @meta=
# #<NVD::JSONFeeds::MetaFeedURI: https://nvd.nist.gov/feeds/json/cve/1.1/nvdcve-1.1-modified.meta>,
# @name=:modified,
# @zip=
# #<NVD::JSONFeeds::ZipFeedURI: https://nvd.nist.gov/feeds/json/cve/1.1/nvdcve-1.1-modified.json.zip>>
Access the Recent CVEs feed:
NVD::JSONFeeds[:recent]
# => #<NVD::JSONFeeds::Feed:0x0000556b4da14c68
# @gz=
# #<NVD::JSONFeeds::GzFeedURI: https://nvd.nist.gov/feeds/json/cve/1.1/nvdcve-1.1-recent.json.gz>,
# @meta=
# #<NVD::JSONFeeds::MetaFeedURI: https://nvd.nist.gov/feeds/json/cve/1.1/nvdcve-1.1-recent.meta>,
# @name=:recent,
# @zip=
# #<NVD::JSONFeeds::ZipFeedURI: https://nvd.nist.gov/feeds/json/cve/1.1/nvdcve-1.1-recent.json.zip>>
Access the year 2020 CVEs feed:
NVD::JSONFeeds[2020]
# => #<NVD::JSONFeeds::Feed:0x0000556b4d55da80
# @gz=
# #<NVD::JSONFeeds::GzFeedURI: https://nvd.nist.gov/feeds/json/cve/1.1/nvdcve-1.1-2020.json.gz>,
# @meta=
# #<NVD::JSONFeeds::MetaFeedURI: https://nvd.nist.gov/feeds/json/cve/1.1/nvdcve-1.1-2020.meta>,
# @name=2020,
# @zip=
# #<NVD::JSONFeeds::ZipFeedURI: https://nvd.nist.gov/feeds/json/cve/1.1/nvdcve-1.1-2020.json.zip>>
Read the .meta
feed file:
meta = NVD::JSONFeeds[2020].meta.parse
# => #<NVD::JSONFeeds::Meta:0x0000556b4e6f4960
meta.last_modified_date
# => #<DateTime: 2021-01-17T03:17:48-05:00 ((2459232j,29868s,0n),-18000s,2299161j)>
meta.size
# => 67524038
meta.zip_size
# => 3777141
meta.gz_size
# => 3777005
meta.sha256
# => "9288B92370FC4D6E92ACB6FFDDDA378C4B9F1B3B5257105BD6D92535DA46BD55"
Download the .zip
/.gz
feed file:
zip_feed = NVD::JSONFeeds[2020].zip.download(dest)
# => #<NVD::JSONFeeds::ZipFeedFile: ...>
gz_feed = NVD::JSONFeeds[2020].gz.download(dest)
# => #<NVD::JSONFeeds::GzFeedFile: ...>
Access a pre-downloaded .zip
/.gz
feed file:
zip_feed = NVD::JSONFeeds::ZipFeedFile.new('path/to/nvdcve-1.1-2020.json.zip')
# => #<NVD::JSONFeeds::ZipFeedFile: ...>
gz_feed = NVD::JSONFeeds::GzFeedFile.new('path/to/nvdcve-1.1-2020.json.gz')
# => #<NVD::JSONFeeds::GzFeedFile: ...>
Parse a .zip
/.gz
feed file (without extracting it):
cve_feed = zip_feed.parse
# => #<NVD::JSONFeeds::Schema::CVEFeed: ...>
cve_feed = gz_feed.parse
# => #<NVD::JSONFeeds::Schema::CVEFeed: ...>
Extracts a .zip
/.gz
feed file:
json_feed = zip_feed.extract(dest_dir)
# => #<NVD::JSONFeeds::JSONFeedFile: ...>
json_feed = gz_feed.extract
# => #<NVD::JSONFeeds::JSONFeedFile: ...>
Access a pre-extracted .json
feed file:
json_feed = NVD::JSONFeeds::JSONFeed.new('path/to/nvdcve-1.1-2020.json')
# => #<NVD::JSONFeeds::JSONFeedFile: ...>
cve_feed = json_feed.parse
# => #<NVD::JSONFeeds::Schema::CVEFeed: ...>
$ gem install nvd-json_feeds
gem 'nvd-json_feeds', '~> 0.1'
Copyright (c) 2021 Hal Brodigan
See {file:LICENSE.txt} for details.
FAQs
Unknown package
We found that nvd-json_feeds demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.