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
help_text="A short code to identify the type of this package. For example: gem for a Rubygem, docker for a container, pypi for a Python Wheel or Egg, maven for a Maven Jar, deb for a Debian package, etc.",
169
+
max_length=16,
170
+
),
171
+
),
172
+
(
173
+
"namespace",
174
+
models.CharField(
175
+
blank=True,
176
+
help_text="Package name prefix, such as Maven groupid, Docker image owner, GitHub user or organization, etc.",
177
+
max_length=255,
178
+
),
179
+
),
180
+
(
181
+
"name",
182
+
models.CharField(blank=True, help_text="Name of the package.", max_length=100),
183
+
),
184
+
(
185
+
"version",
186
+
models.CharField(
187
+
blank=True, help_text="Version of the package.", max_length=100
188
+
),
189
+
),
190
+
(
191
+
"qualifiers",
192
+
models.CharField(
193
+
blank=True,
194
+
help_text="Extra qualifying data for a package such as the name of an OS, architecture, distro, etc.",
195
+
max_length=1024,
196
+
),
197
+
),
198
+
(
199
+
"subpath",
200
+
models.CharField(
201
+
blank=True,
202
+
help_text="Extra subpath within a package, relative to the package root.",
203
+
max_length=200,
204
+
),
205
+
),
206
+
(
207
+
"package_url",
208
+
models.CharField(
209
+
db_index=True,
210
+
help_text="The Package URL for this package.",
211
+
max_length=1000,
212
+
),
213
+
),
214
+
(
215
+
"plain_package_url",
216
+
models.CharField(
217
+
db_index=True,
218
+
help_text="The Package URL for this package without qualifiers and subpath.",
219
+
max_length=1000,
220
+
),
221
+
),
222
+
(
223
+
"is_ghost",
224
+
models.BooleanField(
225
+
db_index=True,
226
+
default=False,
227
+
help_text="True if the package does not exist in the upstream package manager or its repository.",
228
+
),
229
+
),
230
+
(
231
+
"risk_score",
232
+
models.DecimalField(
233
+
decimal_places=1,
234
+
help_text="Risk score between 0.00 and 10.00, where higher values indicate greater vulnerability risk for the package.",
235
+
max_digits=3,
236
+
null=True,
237
+
),
238
+
),
239
+
(
240
+
"version_rank",
241
+
models.IntegerField(
242
+
db_index=True,
243
+
default=0,
244
+
help_text="Rank of the version to support ordering by version. Rank zero means the rank has not been defined yet",
245
+
),
246
+
),
247
+
],
248
+
options={
249
+
"abstract": False,
250
+
},
251
+
),
155
252
migrations.CreateModel(
156
253
name="AdvisoryV2",
157
254
fields=[
@@ -177,14 +274,6 @@ class Migration(migrations.Migration):
177
274
),
178
275
),
179
276
("summary", models.TextField(blank=True)),
180
-
(
181
-
"affected_packages",
182
-
models.JSONField(
183
-
blank=True,
184
-
default=list,
185
-
help_text="A list of serializable AffectedPackage objects",
186
-
),
187
-
),
188
277
(
189
278
"date_published",
190
279
models.DateTimeField(
@@ -211,6 +300,40 @@ class Migration(migrations.Migration):
211
300
),
212
301
),
213
302
("url", models.URLField(help_text="Link to the advisory on the upstream website")),
help_text="Exploitability indicates the likelihood that a vulnerability in a software package could be used by malicious actors to compromise systems, applications, or networks. This metric is determined automatically based on the discovery of known exploits.",
315
+
max_digits=2,
316
+
null=True,
317
+
),
318
+
),
319
+
(
320
+
"weighted_severity",
321
+
models.DecimalField(
322
+
blank=True,
323
+
decimal_places=1,
324
+
help_text="Weighted severity is the highest value calculated by multiplying each severity by its corresponding weight, divided by 10.",
325
+
max_digits=3,
326
+
null=True,
327
+
),
328
+
),
329
+
(
330
+
"affecting_packages",
331
+
models.ManyToManyField(
332
+
help_text="A list of packages that are affected by this advisory.",
333
+
related_name="fixing_advisories",
334
+
to="vulnerabilities.packagev2",
335
+
),
336
+
),
214
337
(
215
338
"aliases",
216
339
models.ManyToManyField(
@@ -219,6 +342,14 @@ class Migration(migrations.Migration):
219
342
to="vulnerabilities.advisoryalias",
220
343
),
221
344
),
345
+
(
346
+
"fixed_by_packages",
347
+
models.ManyToManyField(
348
+
help_text="A list of packages that are reported by this advisory.",
0 commit comments