Git Product home page Git Product logo

Comments (6)

evonide avatar evonide commented on May 7, 2024

Thanks that's good to know! Unfortunately, the dependency https://github.com/kotakanbe/go-cve-dictionary/ we use to fetch and incorporate the NVD data seems to be unaware of Reference tags such as Third Party Advisory.

Particularly, looking at: https://github.com/kotakanbe/go-cve-dictionary/blob/master/models/models.go#L257

// Reference is Child model of Jvn/Nvd.
// It holds reference information about the CVE.
type Reference struct {
	gorm.Model `json:"-" xml:"-"`
	NvdJSONID  uint `json:"-" xml:"-"`
	JvnID      uint `json:"-" xml:"-"`

	Source string
	Link   string `sql:"type:text"`
}

You can see that the column for tags is missing. I think this is processed in https://github.com/kotakanbe/go-cve-dictionary/blob/master/fetcher/nvd/json/nvd.go#L253
tag := strings.Join(ref.TAGS, " ")
but not stored anywhere.

One approach would be to provide a pull request to modify the data models and to store the tags data seperated by ',' as is the case in the NVD provided JSON format (https://nvd.nist.gov/feeds/json/cve/1.1/nvdcve-1.1-recent.json.zip), too.

from vulncode-db.

sbs2001 avatar sbs2001 commented on May 7, 2024

@evonide Thanks for the research.

For the PR solution to work, #41 should be get done with.

A quick fix would be to modify vulncode-db's go-cve-dictionary fork . With some minor refactors propagating our changes to latest upstream will be easy(and then file a PR there) .

If this works for you please assign me this ticket (and expect a PR soon :) ) .

from vulncode-db.

evonide avatar evonide commented on May 7, 2024

Sounds good I'll get back once I've looked into resolving #41.

from vulncode-db.

evonide avatar evonide commented on May 7, 2024

Hey Shivam, as promised I've updated go-cve-dictionary to the latest state in #41.
Assigning to you as suggested. Please let me know if I can help with this.

from vulncode-db.

sbs2001 avatar sbs2001 commented on May 7, 2024

@evonide please review #45 .

Unrelated to this, but I was wondering why are their migrations for the cve database at 2 places ? There's migrations at alembic and also go-cve-dictionary creates the same schema. This creates issues when go-cve-dictionary is ran before frontend. The alembic migrations then attempt to create the same schema which was created before by go-cve-dictionary.

from vulncode-db.

evonide avatar evonide commented on May 7, 2024

Thanks and fully agreed Shivam! I'll look into how to best resolve this soon.

from vulncode-db.

Related Issues (20)

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.