-
Notifications
You must be signed in to change notification settings - Fork 26
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
Empty rolie #357
Empty rolie #357
Conversation
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.
Please see my comments.
BTW: Shouldn't the change in the csaf_provider
to generate the appropriated ROLIE feeds be part of this PR or do you want to have that separate?
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.
LGTM
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.
- The creation of empty ROLIE feeds when setting up a provider (using
csaf_uploader -a create
) is not implemented (but it would make the test much easier). - Using the aggregator with an empty ROLIE feed (e.g. create a provider, upload one document, delete all entries from the ROLIE feed) results in an error.
Happy to discuss the issues - maybe I misunderstood something
I can confirm that there is some problem with the aggregator. If the feed is empty, something doesn't work as expected:
In that case the provider won't be listed in the aggregator.json. On the other hand, is this a real issue? Does an aggregator want to list an "empty" CSAF provider? Why should the aggregator do this? According to the provider, I can't find the right option to create the ROLIE feed. For the different TLP-Level there won't be create any feeds. |
Intended behavior:
|
Documented in #377 |
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.
LGTM
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.
LGTM
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.
Please see my comments. Additional remarks:
- I couldn't test the
csaf_aggreagtor
change because List provider with empty feeds #377. It fails as soon as you have a ROLIE feed with an emptyentry
array. See example error message:'Example_Company_02' failed: open /var/www/aggregator-data/Example_Company_02-2023-06-23-222130/white/csaf-feed-tlp-white.json: no such file or directory
. - There is still some confusion regarding the error message and its meaning in the
csaf_checker.
- The change in c495006 didn't fix the issue in the
csaf_provider
. Theentry
array is still empty when delivered.
7a63832
@JanHoefelmeyer #357 (comment) still exists - the other two have been resolved with the last 3 commits. There are also merge conflicts... |
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.
The merge conflict resolution seems to be gone wrong - now any domain requested fails. I haven't found the line number yet where the issue is. But basically, it reports
2023/06/30 20:43:10 Failed to find valid provider-metadata.json for domain domain.tld. Continuing with next domain.
{
"version": "2.1.1-123-g30c2218",
"date": "2023-06-30T18:43:02.567470825Z"
}
for any valid domain
…ed errStop handling while there.
@tschmidtb51 That was indeed a problem introduced by a faulty merge. I cleaned up the error handling in commit 89e69a7 . |
I was able to run |
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.
LGTM and works
@s-l-teichmann Thank you for the fast fix! |
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.
LGTM
Solves #336
Csaf checker explicitely filters out if the schema error was no entries and will give a warning for this error only.
Csaf aggregator creates "empty" ROLIE feeds if no entries are present.
Csaf Provider already has an option to create ROLIE feeds during setup. This is currently not mandatory, however, but would be possible to make mandatory if needed.
Csaf Downloader will find feeds with emptry entry, but will not download anything from them.