Skip to content

in test, Uncaught Error for 8 digits at end of ID #3485

@ElectricNroff

Description

@ElectricNroff

On test.cve.org, searching for CVE-2025-12345678 displays "Service is currently unavailable." and Developer tools > Console has

Uncaught (in promise) Error: search() >> error with getSearchResults(), getRecordData(),
or getIdData()
    at Proxy.search (index--1GSJ9bX.js:9:8935)

Although I haven't checked, this might be caused by inconsistent regular expressions in which one has a limit of 7 digits and the others are unbounded:

return new RegExp(/^CVE-\d{4}-\d{4,7}$/, 'i').test(this.query);

const cveIdRegex = /^CVE\p{Pd}(?<year>\d{4})\p{Pd}(?<id>\d{4,})$/iu;

if (digits && digits.length > 0 && !new RegExp(/^\d{4,}$/).test(digits)) {
this.errorMessage.push('CVE-YYYY-<b>NNNN</b> must be 4 digits or greater');
}
if (this.errorMessage.length === 0 && new RegExp(/^(cve)-\d{4}-\d{4,}$/, 'i').test(this.cveId)) {

The schema, incidentally, has a limit of 19 rather than 7:
https://github.com/CVEProject/cve-schema/blob/cc1c0214befc0e2ccfb98c8f4306ec116f65fd34/schema/CVE_Record_Format.json#L54

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions