Statistics#
Eight figures describe a corpus: records per period, lifecycle status, CVSS versions, severity bands, known-exploited inclusion, time to exploit, top assigners and top vendors.
Each figure is computed per source (
?source=, defaultcvelistv5).Each one can be narrowed to one period.
Request and response shapes are in the Swagger UI at
/api/. The keys are in Architecture. The passes that prepare them are in Prepared statistics figures.
Endpoints#
Figure |
Any source |
EUVD |
|---|---|---|
Records per period |
|
|
Lifecycle status |
|
|
CVSS version distribution |
|
|
Severity bands |
|
|
Known-exploited inclusion |
|
|
Time to exploit |
|
|
Top assigners |
|
|
Top vendors |
|
|
The EUVD namespace is the same code with source=euvd fixed (no source parameter).
Both are cached for STATS_CACHE_TIMEOUT (one hour by default).
Comparing sources#
GET /api/stats/vulnerability/sources returns sources: one entry per source, with
source and records, largest first. The statistics page charts the 20 largest and
lists all of them in a table.
Counts come from
index:<source>, kept current by the feeders. No reindex is needed.Only vulnerability sources are listed, not reference or enrichment feeds.
Withdrawn records are counted.
Counts are not additive.
cvelistv5,nvd,fkie_nvd,euvdand the GNA mirrors describe the same CVEs, so there is no total or percentage.
Reading an answer#
available: falseis not zero. It means the figure was never prepared for this source. The two rankings are the exception: they return an empty list instead.Most figures date from the last pass. These are live:
lifecycle status;
known-exploited membership for EUVD (other sources: as of the last
euvd --stats-scan).
time_to_exploitcarriescomputed_at.A year is a publication year, never the year in the identifier. The one exception is known-exploited per period, which uses the listing date (
basis: listed_at).A period that cannot be applied is a 400, never silently ignored.
The eight figures#
Records per period#
GET /api/stats/vulnerability/counts?source=<name>[&granularity=month&period=YYYY][&state=reserved][&basis=...]
Records per publication year, or per month of one year.
The years covered come from the source’s published index: no leading run of zeros.
periodwithoutgranularity=monthis a 400.state=reservedcounts by reservation date, on the same year axis.
basis selects which records are counted:
|
Counts |
A past year’s total |
|---|---|---|
|
every record with a publication date |
never changes |
|
only records still |
falls when one is withdrawn |
state_publishedis available forcvelistv5, the GNA sources and EUVD. Other sources answeravailable: false.On the CVE list it excludes about 12,000 withdrawn records. It then matches the severity and CVSS charts.
basis=state_publishedwithstate=reservedis a 400.STATS_DEFAULT_BASISinconfig/website.pysets the default per source. It is{"euvd": "state_published"}, and setting the option replaces it. A request that names abasisgets that one.prepared_atis set when a figure is only as fresh as the last pass, and isnullwhen the figure is live. This applies tostate_publishedfor every source, and to both bases for the GNA sources.
EUVD is different. EUVD records carry no publication date of their own:
Minted EUVDs are absent from
date_published, but counted instate_publishedunder their CVE’s date. Sostate_publishedcan be the larger figure.Its status comes from the linked CVE when there is one, otherwise from the EUVD record itself.
A past year can grow: an EUVD minted today for a 2017 CVE is added to 2017.
A published EUVD with no date at all counts in the total but in no period.
It does not match the EUVD severity and CVSS charts, which skip undated records.
After upgrading, run the EUVD pass right away: it backfills the stored status.
/api/stats/kev also has a basis field, with an unrelated meaning.
Lifecycle status#
GET /api/stats/vulnerability/status?source=<name>[&period=YYYY]
{
"source": "cvelistv5",
"total": 400321,
"published": 394048,
"reserved": 400321,
"state": { "published": 381920, "reserved": 936, "rejected": 17471 }
}
publishedandreservedcount records that carry that date. These are the same records asbasis=date_published.stategives the current lifecycle values. These are the same records asbasis=state_published.For “what does the source publish today”, use
state.published.For “how many were ever published”, use
published.
The numbers do not sum to
total: a record can carry both dates, or neither.reservedis not “awaiting publication”. On the CVE list every record has a reservation date. Usestate.reservedfor records awaiting publication.stateis absent for a source without a lifecycle index.With
period, onlypublishedandreservedare returned.totalandstatehave no meaning for a past year.
CVSS version distribution#
GET /api/stats/cvss/versions?source=<name>[&period=YYYY]
Buckets: 4.0, 3.1, 3.0, 2.0, other, unscored.
Severity bands#
GET /api/stats/cvss/scores?source=<name>[&period=YYYY]
Bands:
none,low,medium,high,critical(CVSS v3.1 ratings, applied to any version), plusunscored.The score is from the highest CVSS version of the record, as shown on its page. Where that version has several scores, the first is used. For
source=euvdit is the highest, as on the EUVD.Both CVSS figures count published records only, without withdrawn ones: about 12,000 on the CVE list. As a result, the per-year bands do not add up to
published:count:<source>:<year>.
Known-exploited inclusion#
GET /api/stats/kev?source=<name>
GET /api/stats/kev?source=<name>&granularity=year
GET /api/stats/kev?source=<name>&granularity=month&period=YYYY
Without granularity (basis: membership), the response gives:
exploited: the records in a known-exploited catalogue;the ratio of
exploitedto the total;a count per catalogue.
Details:
A bare
periodis a 400. Membership has no date; use the per-period form.Per-catalogue counts overlap. A record listed twice is counted twice, so they don’t sum to
exploited.Every configured catalogue is listed, even with zero.
unattributedcounts records whose catalogue can’t be named. A non-zero value means the catalogue reference data is missing or stale.Scope:
STATS_KEV_CATALOGSinconfig/website.pylimits a source to some catalogues. The default is{"euvd": ["CISA", "ENISA"]}, and setting the option replaces it.A scoped source answers
scoped: trueand lists only itscatalogs.Membership counts follow a scope change immediately, except where EUVD’s scope is widened or removed: its per-catalogue membership is only written for the catalogues in scope, so a catalogue brought in is counted from the next
euvd --backfill-kev. The dated figures follow at the nexteuvd --stats-scan.For EUVD, the record itself follows the same scope: its exploited flag, the
exploitedsearch filter, its exploited-since date and the exploited listing. A vulnerability listed only by a catalogue out of scope is not exploited for EUVD, and stays in that catalogue. An entry whose origin maps to no catalogue is out of any scope, as in the figures. Runeuvd --backfill-kevafter a change of scope. It refuses to run, naming the entry, while the scope names a catalogue that no GCVE KEV reference of the instance names, and the KEV sync skips its EUVD updates for as long.
EUVD maintains its membership during ingestion. For other sources,
euvd --stats-scan --stats-source <name>rebuilds it, which makes sense for CVE-keyed sources.Denominator: the narrowest population the source has, named by
total_basis. The numerator is narrowed the same way, so the ratio never exceeds 1.
|
Counted from |
Meaning |
|---|---|---|
|
|
currently published |
|
|
has a publication date |
|
|
every record held |
Per period#
With granularity (basis: listed_at):
Buckets use the date a catalogue listed the record, not its publication date. That date is
timestamps.first_seen_at, elserecorded_at, elsestatus_updated_at(neverasserted_at).catalogsis{catalogue: {period: count}}. It overlaps, like the membership counts.totalscounts each record once, in the period of its first listing. Its sum givesexploitedback.unattributed_periodsis the same series for unnamed catalogues.All series share one axis, with real zeros: consecutive years up to now, or the 12 months of the year asked for.
available: falsemeans the scan never ran for this source. The membership sets come from a different pass.
Time to exploit#
GET /api/stats/time_to_exploit?source=<name>[&period=YYYY | &granularity=year]
Days from publication to the first known-exploited listing: mean, median, p90, min and max.
period: the same summary for the records published that year.granularity=year: every year, underyears. A year with no exploited record is{"count": 0}.periodandgranularitycannot be combined.The first listing among the catalogues in scope ends the interval. A scoped source answers
scoped: trueandcatalogs, as recorded by the scan.count,cves_exploitedandentries_scannedgive the base: exploited records only. Prefer the median: one old CVE listed late moves the mean a lot.Negative intervals are kept: the catalogue listed it before publication. They are counted in
exploited_before_publication, with their mean inbefore_publication_mean_days.Only currently published records are dated.
excluded_not_publishedcounts the withdrawn and reserved ones left out. It is 0 for sources without a lifecycle index.unmatched_no_recordandunmatched_no_publication_datecount the entries that couldn’t be dated. They cover the whole source and are absent from a period summary.A period with nothing exploited answers
available: true, count: 0.
Top assigners#
GET /api/stats/assigners/ranking?source=<name>&limit=10[&period=YYYY]
limitdefaults to 10, at most 100.sourcemust be one ofcvelistv5(default),certfr_avis,certfr_alerteandeuvd. Any other value is a 400.For EUVD, the assigner comes from the linked CVE, not the EUVD record.
The EUVD rankings leave out records whose CVE was withdrawn. Other sources count every record ever published.
Top vendors#
GET /api/stats/vendors/ranking?source=<name>&limit=10[&period=YYYY]
Same limit and source values as the assigner ranking. For alias sources such as
EUVD, vendors come from the linked CVE.
Other endpoints#
These are not per-source figures. All take ?output=markdown for a Markdown table.
Endpoint |
Returns |
Parameters |
|---|---|---|
|
Vulnerabilities with the most sightings |
|
|
Vulnerabilities with the most comments |
|
|
Most frequent CWEs in |
|
|
Most credited people and organisations |
|
|
Running share of CVEs with an exploitation sighting, by sighting date |
|
/api/stats/vulnerability/count is the older single-period form of /counts. It needs
period and source, and only accepts cvelistv5, github, pysec, tailscale,
ossf_malicious_packages, variot and euvd.
Easy to confuse#
Known exploited is not the sightings ratio.
/api/stats/kevcounts catalogue membership./api/stats/sighting/exploitation_ratiocounts exploitation sightings.EUVD is not a second population. EUVD records are mostly CVE aliases: never add EUVD figures to CVE figures.
Preparing the figures#
# counts, rankings and CVSS distributions (--source <name> to limit it)
$ poetry run index_vulnerabilities
# time to exploit, known-exploited per period, and known-exploited sets for non-EUVD sources
$ poetry run euvd --stats-scan --stats-source cvelistv5
Run the reindex once on a new, restored or upgraded instance before trusting the counters. Cron lines are in Prepared statistics figures.
See also the assigner scorecard, the catalogue scorecard
and Metrics. /metrics exports the small figures, not the rankings.