App-layer plugin preliminary work 5053 v2.4#11426
Closed
catenacyber wants to merge 4 commits intoOISF:masterfrom
Closed
App-layer plugin preliminary work 5053 v2.4#11426catenacyber wants to merge 4 commits intoOISF:masterfrom
catenacyber wants to merge 4 commits intoOISF:masterfrom
Conversation
THashInitConfig may not allocate array and increase memuse. Such a failure leads to THashShutdown which should not decrease the memuse. Ticket: 7135
Ticket: 5053
Ticket: 5053
Ticket: 5053
victorjulien
reviewed
Jul 4, 2024
victorjulien
reviewed
Jul 4, 2024
|
|
||
| const char *name; | ||
| switch (al->proto) { | ||
| switch (f->proto) { |
Member
There was a problem hiding this comment.
instead of doing this at runtime, can we do it at init time and store the result in EveJsonSimpleAppLayerLogger?
victorjulien
reviewed
Jul 4, 2024
| FatalError("Failed to allocate simple_json_applayer_loggers"); | ||
| } | ||
| // ALPROTO_HTTP1 special: uses some options flags | ||
| RegisterSimpleJsonApplayerLogger(ALPROTO_FTP, EveFTPLogCommand); |
Member
There was a problem hiding this comment.
can we move these into the respective parsers?
Contributor
Author
There was a problem hiding this comment.
In the end, we want to.
But this is not obvious now : when the respective parsers register themselves, we do not know yet ALPROTO_MAX
So, I would like to keep this for a later PR...
Contributor
Author
|
Continued in #11429 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Link to ticket: https://redmine.openinfosecfoundation.org/issues/
Preliminary work for https://redmine.openinfosecfoundation.org/issues/5053
Describe changes:
Small PR good in itself.
#11373 next round
Based on #11425 to get green CI :-p
Still more work to do : I guess stack allocated arrays are fine, but the global variables cf
git grep '\[ALPROTO_MAX'inneed to be allocated and freed, with taking care of the initialization order, so that we know
ALPROTO_MAXfinal value...