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 Tenable Nessus information model #7

Draft
wants to merge 25 commits into
base: main
Choose a base branch
from

Conversation

aj-stein-gsa
Copy link
Contributor

Committer Notes

Closes #6 when reviewed and merged.

All Submissions:

By submitting a pull request, you are agreeing to provide this contribution under the CC0 1.0 Universal public domain dedication.

Changes to Core Features:

  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your core changes, as applicable?
  • Have you included examples of how to use your new feature(s)?
  • Have you updated all website and readme documentation affected by the changes you made?

@aj-stein-gsa aj-stein-gsa self-assigned this Oct 4, 2024
It turns out that PluginPreferences and ServerPreferences do not have
the same structure internally with preferences, so we need to stop with
the generalization.
Properly add the "preferences" assembly and embed it into the item
assembly like the docs require for PluginPreferences.
You need to add the group-as to the definition of these fields because
they can be zero to unbounded cardinality, which means in JSON we need
to be explicit about serializing in the case of 1 .. N elements, even if
not zero. If not, we rightfully get the following exception from the
Metaschema module compiler when executing the command `metaschema-cli
validate-content ...`:

> Caused by: java.lang.IllegalStateException: Unable to derive the property name, due to missing group as name, for 'field-inline-definition:nessus:ReportItem/see_also@235154585'
The data as-is in real-world data doesn't use markup as guessed, so we
must consume the data as a long multiline string without markup and only
process it as a string to start.

Error messaging:

[ERROR] cvc-complex-type.2.4.b: The content of element 'plugin_output' is not complete. One of '{"http://www.nessus.org/cm":h1, "http://www.nessus.org/cm":h2, "http://www.nessus.org/cm":h3, "http://www.nessus.org/cm":h4, "http://www.nessus.org/cm":h5, "http://www.nessus.org/cm":h6, "http://www.nessus.org/cm":ul, "http://www.nessus.org/cm":ol, "http://www.nessus.org/cm":pre, "http://www.nessus.org/cm":hr, "http://www.nessus.org/cm":blockquote, "http://www.nessus.org/cm":p, "http://www.nessus.org/cm":table, "http://www.nessus.org/cm":img}' is expected. [file:/home/me/example.xml{2738,17}]
The data as-is in real-world data doesn't use date as guessed, so we
must consume the data as a long multiline string without markup and only
process it as a string to start.

Error messaging:

[ERROR] cvc-type.3.1.3: The value '2011/04/05' of element 'plugin_modification_date' is not valid. [file:/home/me/example.xml{2746,64}]
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.

Tenable Nessus Format
1 participant