swh.vulns.osv.model module#
- class swh.vulns.osv.model.BaseModel[source]#
Bases:
object- to_dict()[source]#
Wrapper of attr.asdict that can be overridden by subclasses that have special handling of some of the fields.
- class swh.vulns.osv.model.OSVVulnerabilityEvent(vulnerability_id: str, event_type: Literal['introduced', 'fixed', 'last_affected', 'limit'], origin_url: str, swhid: CoreSWHID | None = None, version: str | None = None, vulnerability_severity: Literal['CVSS_V2', 'CVSS_V3', 'CVSS_V4', 'Ubuntu'] | None = None)[source]#
Bases:
BaseModelModel that represents an OSV vulnerability event for a software origin.
See https://ossf.github.io/osv-schema/ for more details about the OSV database schema.
Method generated by attrs for class OSVVulnerabilityEvent.
- vulnerability_id#
OSV vulnerability identifier
- event_type#
Type of vulneraibility event
- origin_url#
Software origin URL
- swhid#
SWHID of software objects (either release or revision) related to the vulnerability event
- version#
Optional software version associated to the SWHID
- vulnerability_severity#
Severity of vulnerability