Skip to content
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

add <detection></detection> on report import #1405

Merged
merged 11 commits into from
Feb 4, 2021
Merged

add <detection></detection> on report import #1405

merged 11 commits into from
Feb 4, 2021

Conversation

nichtsfrei
Copy link
Member

@nichtsfrei nichtsfrei commented Feb 3, 2021

What:
When importing a report with and even if it has the correct
nvt as a host_detail as well as an result within the report the
detection block was missing when importing via create_report.

To add those sections two new entries within host_details will be added
when a got found within a result.

Why:

How did you test it:

To test it you need to have a report with

  • result/detection
    in it, the source_oid of those detection must be also available as result nvt oid entry.

With that given you need to import that report into an container task and then download the report via gsa.

Checklist:

When importing a report with <detection> and even if it has the correct
nvt as a host_detail as well as an result within the report the
detection block was missing when importing via create_report.

To add those sections two new entries within host_details will be added
when a <detection> got found within a result.
src/gmp.c Outdated Show resolved Hide resolved
src/gmp.c Outdated Show resolved Hide resolved
src/gmp.c Outdated Show resolved Hide resolved
@nichtsfrei nichtsfrei marked this pull request as ready for review February 3, 2021 12:19
if else if formatting.
Copy link
Member

@timopollmeier timopollmeier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One thing I'm missing are the detected_by@... details I've noted below.
Other than that and a few things about code formatting, the PR already looks good to me.

src/gmp.c Outdated Show resolved Hide resolved
src/gmp.c Outdated Show resolved Hide resolved
src/gmp.c Outdated Show resolved Hide resolved
src/gmp.c Show resolved Hide resolved
src/gmp.c Show resolved Hide resolved
src/gmp.c Outdated Show resolved Hide resolved
src/manage_sql.c Show resolved Hide resolved
src/manage_sql.c Show resolved Hide resolved
nichtsfrei and others added 6 commits February 3, 2021 15:47
@nichtsfrei
Copy link
Member Author

One thing I'm missing are the detected_by@... details I've noted below.
Other than that and a few things about code formatting, the PR already looks good to me.

you're right changed it to use detected_by@...

@nichtsfrei nichtsfrei closed this Feb 4, 2021
@nichtsfrei nichtsfrei reopened this Feb 4, 2021
@nichtsfrei nichtsfrei merged commit b91d688 into greenbone:master Feb 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants