-
-
Notifications
You must be signed in to change notification settings - Fork 578
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
Global Audit View: Policy Violations #3544
Global Audit View: Policy Violations #3544
Conversation
Enhances the `getViolations` method in `PolicyViolationResource` to filter the result by ACL and to also allow the use of additional filters, so that a user can get more specific results. Signed-off-by: RBickert <rbt@mm-software.com>
Adds a new test for `PolicyViolationResource` which tests the filtering by ACL of the newly enhanced `getViolations` method Signed-off-by: RBickert <rbt@mm-software.com>
Signed-off-by: RBickert <rbt@mm-software.com>
Signed-off-by: RBickert <rbt@mm-software.com>
…tions Global Audit View: Policy Violations
Coverage summary from CodacySee diff coverage on Codacy
Coverage variation details
Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: Diff coverage details
Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: See your quality gate settings Change summary preferencesCodacy stopped sending the deprecated coverage status on June 5th, 2024. Learn more |
Signed-off-by: RBickert <rbt@mm-software.com>
Signed-off-by: RBickert <rbt@mm-software.com>
Signed-off-by: RBickert <rbt@mm-software.com>
Signed-off-by: rbt-mm <113189967+rbt-mm@users.noreply.github.com>
Signed-off-by: Richard Bickert <rbt@mm-software.com>
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.
Looks good, just a minor issue with resource method annotations.
src/main/java/org/dependencytrack/resources/v1/PolicyViolationResource.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Richard Bickert <rbt@mm-software.com>
Description
This PR enhances the
/violation
API endpoint in the backend to filter the result by ACL and also allow the use of several filters.This enhancement makes it possible to quickly get all policy violations for one's projects and also to only show relevant violations by filtering them as needed. It can either be used directly via the API or through the new Policy Violations Audit view, which is introduced in the frontend PR.
Addressed Issue
#1770
Additional Details
Requires the
VIEW_POLICY_VIOLATIONS
permission.Checklist
- [ ] This PR fixes a defect, and I have provided tests to verify that the fix is effective- [ ] This PR introduces changes to the database model, and I have added corresponding update logic- [ ] This PR introduces new or alters existing behavior, and I have updated the documentation accordingly