From 213673f0db9de6885bcbe3563c87de87fc1be1e5 Mon Sep 17 00:00:00 2001 From: 0xMarcio Date: Wed, 17 Dec 2025 16:19:35 +0100 Subject: [PATCH] Fix PoC search data path and clean naming --- docs/index.html | 10 +++++----- docs/logic.js | 19 +++++++++++++++---- docs/search/index.html | 4 ++-- templates/base.html | 6 +++--- templates/epss.html | 2 +- templates/index.html | 4 ++-- templates/pipeline_base.html | 12 +++++++----- 7 files changed, 35 insertions(+), 22 deletions(-) diff --git a/docs/index.html b/docs/index.html index fd9d3e2592..e8ba354253 100644 --- a/docs/index.html +++ b/docs/index.html @@ -3,25 +3,25 @@ - CVE Intelligence + CVE PoC Hub
-

Top KEV by EPSS percentile

+

KEV with high EPSS

-

High EPSS not in KEV

+

EPSS standouts (outside KEV)

diff --git a/docs/logic.js b/docs/logic.js index 05d63b88c6..62b5c2241d 100644 --- a/docs/logic.js +++ b/docs/logic.js @@ -132,7 +132,7 @@ document.addEventListener('DOMContentLoaded', () => { if (val !== '') { controls.displayResults(); - currentSet = window.controls.doSearch(val, window.dataset); + currentSet = window.controls.doSearch(val, window.dataset || []); if (currentSet.length < totalLimit) { window.controls.setColor(colorUpdate, currentSet.length === 0 ? 'no-results' : 'results-found'); @@ -150,13 +150,24 @@ document.addEventListener('DOMContentLoaded', () => { } } - fetch('../CVE_list.json') - .then(res => res.json()) + fetch('/CVE_list.json') + .then(res => { + if (!res.ok) { + throw new Error(`Failed to load CVE list (${res.status})`); + } + return res.json(); + }) .then(data => { - window.dataset = data; + window.dataset = Array.isArray(data) ? data : []; currentSet = window.dataset; window.controls.updateResults(resultsTable, window.dataset); doSearch({ type: 'none' }); + }) + .catch(err => { + console.error(err); + window.dataset = []; + noResults.textContent = 'Unable to load CVE list'; + noResults.style.display = ''; }); form.addEventListener('submit', doSearch); diff --git a/docs/search/index.html b/docs/search/index.html index 2391f76376..30749eaed5 100644 --- a/docs/search/index.html +++ b/docs/search/index.html @@ -10,9 +10,9 @@