Giter Club home page Giter Club logo

meta-fbvuln's Introduction

meta-fbvuln

An OpenEmbedded layer containing a class for collecting vulnerability management metadata for continuous vulnerability scanning of target images.

The processing performed by this class is derived from the cve-check.bbclass in oe-core.

Usage

Add this layer to your bblayers.conf:

echo 'BBLAYERS += "/path/to/meta-fbvuln"' >> conf/bblayers.conf

Interit this class in local.conf:

echo 'INHERIT += "fbvuln-manifest"' >> conf/local.conf

Build an image as you normally would:

bitbake core-image-minimal

Once your build has completed you can locate the generated vulnerability tracking files:

ls -1 tmp/deploy/images/*/*.fbvuln.csv

You will find one vulnerability tracking file per image built for the target. Within this file are comma-separated lines containing six fields: vendor, product, version, software environment, hardware environment and patched vulnerabilities.

As an example, Cairo may appear as:

,cairo,1.16.0,linux_kernel,x64,CVE-2017-7475 CVE-2018-19876 CVE-2019-6461 CVE-2019-6462

The above snippet shows that no vendor is needed to disambiguate the cairo CPE. The software has been compiled to run under Linux on an x86-64 system and has had four vulnerabilities addressed through patching.

Another representative example is Chromium (from meta-browser):

google,chrome,80.0.3987.132,linux_kernel,x64,
chromium,chromium,80.0.3987.132,linux_kernel,x64,

In the case of Chromium, you'll see that two tracking entries are produced: one for Chrome official releases and one for Chromium (vulnerabilities are often tracked against one, but not the other).

Collected tracking data should be regularly fed through a vulnerability analysis pipeline while your software images are deployed and supported. You may wish to consider the nvdtools project for this scanning, using the csv2cpe and cpe2cve tools to process your data from a scheduled job.

Configuration

You'll very likely want to set the CPE target hardware and software environments in your generated vulnerability tracking files. You can do so by setting the CPE_TARGET_SW and CPE_TARGET_HW variables (for example, in your local.conf - using x86-64) as follows:

echo 'CPE_TARGET_SW ?= "linux_kernel"' >> conf/local.conf
echo 'CPE_TARGET_HW ?= "x64"' >> conf/local.conf

There's no easily searchable source of valid target hardware (or software!) enumerations available. If you leave either of these out you risk hitting false positives, but if you get either of these wrong you risk false negatives. Your best bet it to search the NIST NVD database for example values.

License

meta-fbvuln licensed under the MIT license, as found in the LICENSE file.

meta-fbvuln's People

Contributors

r1mikey avatar eugenejinfb avatar kjannan avatar mcallahan avatar williamspatrick avatar

Stargazers

Andrei Makeev avatar Daniel Iziourov avatar  avatar Denis Denisov avatar  avatar

Watchers

 avatar Breno Leitao avatar Sam Gao avatar James Cloos avatar  avatar Sam Delacruz avatar Franck STAUFFER avatar André Carvalho avatar  avatar Cami Williams avatar Andrei Makeev avatar Amit avatar Dmitry Vinnik avatar  avatar Chinmay Pandhare avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.