-
Notifications
You must be signed in to change notification settings - Fork 77
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update vulnerabilities CVE endpoint #3386
base: main
Are you sure you want to change the base?
Conversation
PR ChecklistHow to use this checklistHow to use this checklistPR AuthorFor each section, check a box when it is true. PR ReviewerCheck that the PR checklist action did not fail. Bug ReferencesNone. Confirm
How to properly reference fixed bugs
Test UpdatesUnit Tests
Integration Tests
Documentation
Does this PR require review from someone outside the core ubuntu-pro-client team?
|
0306b2d
to
66441a4
Compare
a785e2b
to
b2303ba
Compare
rebased to accomodate commits from #3384 |
Xenial build now broken on a dict comparison - maybe ordering? |
b2303ba
to
9168c51
Compare
Similar to the data_list function, we are now creating a data_dict function to support dict objects on our DataObject definitions
The redesigned endpoint is now orientend per-package instead of per-cve. This endpoint will be the base for the vulnerability CLI commands, that will also be redesigned
Add the related_packages to each vulnerability CVE that we have, as this information will be required in some CLI commands of Pro
We are now hiding some fields that are only usefull when we are writing our CLI related CVE features
9168c51
to
5c74bf6
Compare
@renanrodrigo I have updated the PR and fixed the affected integration tests related to this change |
@@ -1,13 +1,12 @@ | |||
import datetime |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
During the rename, this file was left behind. I believe all of uaclient/api/u/pro/security/cves/cve/*
can be deleted
@@ -182,9 +182,6 @@ def get_published_date(self): | |||
return vulnerability_json_data["published_at"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You don't need to make a change, but I suppose the _common
structure is not needed anymore since there is only one API endpoint.
@@ -1,7 +1,5 @@ | |||
from uaclient import messages |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why was update
left behind if we're deleting the other two vulnerability commands in this PR?
Why is this needed?
We have redesigned the vulnerabilities CVE endpoint to per-package instead of per-cve. Now, each installed package will list all of the CVEs that it is affected by.
Test Steps