You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// we should not remove affected components - otherwise it might happen, that we remove a vulnerability from the database (check runCleanupJobs) and therefore lose the append only property of this database - which makes it so fast and simple currently.
Copy file name to clipboardExpand all lines: vulndb/osv_service.go
+30Lines changed: 30 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -20,8 +20,10 @@ import (
20
20
"context"
21
21
"encoding/json"
22
22
"fmt"
23
+
"io"
23
24
"log/slog"
24
25
"net/http"
26
+
"os"
25
27
"slices"
26
28
"strings"
27
29
"sync"
@@ -103,6 +105,7 @@ type zipJob struct {
103
105
}
104
106
105
107
constnumberOfZipWorkers=10
108
+
constdebugLocalZip=false// set to true to read the zip files from disk instead of fetching them from the network; useful for debugging and development to speed up the import process
106
109
107
110
vardeduplicateCveMap= sync.Map{} // map[string]struct{} to track already processed CVE IDs and avoid duplicates
108
111
@@ -287,6 +290,21 @@ func (s osvService) fetchEcosystemEntriesViaZip(zipPushWaitGroup *sync.WaitGroup
0 commit comments