-
Notifications
You must be signed in to change notification settings - Fork 42
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
Populate vulnerability.reference with a link to NVD #1303
Populate vulnerability.reference with a link to NVD #1303
Conversation
@@ -73,3 +73,4 @@ terraform.rc | |||
# Vulnerability management | |||
db/ | |||
fanal/ | |||
java-db/ |
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.
not sure if it's smth specific to my machine or not, but I had this untracked dir after running cloudbeat locally with vulnerabilities yaml
vulnerability/events_creator.go
Outdated
return vul.PrimaryURL | ||
} | ||
|
||
if _, ok := vul.CVSS[trivyVul.NVD]; ok { |
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.
I'm assuming that if there is a NVD in CVSS then this vulnerability exists in NVD database and the link will be valid. It's a bit brittle in my opinion, but if we want to replace aquasec links that's the simplest way I could find
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.
Also, as far as I understand this is the same solution we have today in kibana, right?
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.
yes, exactly!
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.
nit: invert the if
if _, ok := vul.CVSS[trivyVul.NVD]; !ok {
return vul.PrimaryURL
}
📊 Allure Report - 💚 No failures were reported.
|
vulnerability/events_creator.go
Outdated
return vul.PrimaryURL | ||
} | ||
|
||
if _, ok := vul.CVSS[trivyVul.NVD]; ok { |
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.
nit: invert the if
if _, ok := vul.CVSS[trivyVul.NVD]; !ok {
return vul.PrimaryURL
}
@amirbenun updated in case you want to take a look |
1151388
to
00a6faa
Compare
…ink-to-nvd-rather-then-aquasec-domain
…ink-to-nvd-rather-then-aquasec-domain
## Summary - fixes: elastic/security-team#7490 The NVD generation logic will be happening on the `cloudbeat` side after elastic/cloudbeat#869 (comment) is done and elastic/cloudbeat#1303 is merged, so we can remove the logic from Kibana and use what's in `vulnerability.reference` --------- Co-authored-by: kibanamachine <[email protected]>
* opulate vulnerability.reference with a link to NVD * revert the if statemenet
* Implement Azure benchmark * Fixing CR * fixes * [CloudFormation] Verify installation of cfn-signal (#1328) * Bump magefile/mage-action from 2 to 3 in /.github/workflows (#1333) Bumps [magefile/mage-action](https://github.com/magefile/mage-action) from 2 to 3. - [Release notes](https://github.com/magefile/mage-action/releases) - [Commits](magefile/mage-action@v2...v3) --- updated-dependencies: - dependency-name: magefile/mage-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * go.mod: Organize require blocks and update SDKs (#1330) * Organize go.mod require blocks * Update SDKs * Remove go-errors/errors usage * [CIS GCP] Add log bucket type to asset fetcher (#1327) * add log bucket type * bump cis policies version * Rename factory package to preset (#1334) * pre-commit: golangci-lint: Auto fix supported failures (#1336) * Create a dedicated AWS organization preset (#1335) * factory.NewCisAzureFactory * Remove extra build step (#1337) * AWS CSPM Resources add ECS data (#1312) * Populate vulnerability.reference with a link to NVD (#1303) * opulate vulnerability.reference with a link to NVD * revert the if statemenet * [Cloud Security] [Telemetry] fix package policy vars to use posture field (#1325) fix package policy vars to use posture field * Use branches to get bundles (#1332) * Refactor to be compatible with main and fix compilation * Fixing linter * Adding unit tests --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: Orestis Floros <[email protected]> Co-authored-by: Amir Ben Nun <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Uri Weisman <[email protected]> Co-authored-by: Or Ouziel <[email protected]> Co-authored-by: Maxim Kholod <[email protected]> Co-authored-by: Lola <[email protected]>
Summary of your changes
This PR moves the logic existing in Kibana to Cloudbeat of populating the NVD link instead of the Aquasec link in
vulnerability.reference
field.Screenshot/Data
the field should look like the following after the change
Related Issues
Checklist