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

HTTP: rework state machine #1966

Merged
merged 1 commit into from
May 16, 2023
Merged

HTTP: rework state machine #1966

merged 1 commit into from
May 16, 2023

Conversation

IvanNardi
Copy link
Collaborator

@IvanNardi IvanNardi commented May 6, 2023

The goal if to correlate the right request-response pair, exporting
metadata from only one transaction (for example, the right url & return
state pair)

As a nice side effect, the code should be much cleaner, but that is a
matter of taste.

Two differences respect to the previous code:

  • as it happens in the CI, if in the flow there are only one response
    (before) and one request (after), only the metadata of the response are
    saved/exported
  • for performance reasons, we don't call ndpi_parse_packet_line_info()
    anymore for ALL packets triggering the HTTP dissector, but only for the
    packets that we already know belong to an HTTP flow. This is the reason
    for the changes in RTSP/SOAP/... code

@IvanNardi IvanNardi marked this pull request as draft May 6, 2023 13:02
@IvanNardi IvanNardi force-pushed the http-rework2 branch 2 times, most recently from 359cbaa to 975e7f7 Compare May 6, 2023 18:43
@IvanNardi IvanNardi changed the title HTTP: WIP HTTP: rework state machine May 6, 2023
@IvanNardi IvanNardi marked this pull request as ready for review May 6, 2023 18:44
The goal if to correlate the right request-response pair, exporting
metadata from only one transaction (for example, the right url & return
state pair)

As a nice side effect, the code should be much cleaner, but that is a
matter of taste.

Two differences respect to the previous code:
* as it happens in the CI, if in the flow there are only one response
(before) and one request (after), only the metadata of the response are
saved/exported
* for performance reasons, we don't call `ndpi_parse_packet_line_info()`
anymore for ALL packets triggering the HTTP dissector, but only for the
packets that we already know belong to an HTTP flow. This is the reason
for the changes in RTSP/SOAP/... code
@sonarcloud
Copy link

sonarcloud bot commented May 15, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 2 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

Copy link
Collaborator

@utoni utoni left a comment

Choose a reason for hiding this comment

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

Good job, @IvanNardi <3

@IvanNardi
Copy link
Collaborator Author

Good job, @IvanNardi <3

Thanks to you for the multiple reviews!

@IvanNardi IvanNardi merged commit 4e186f6 into ntop:dev May 16, 2023
@IvanNardi IvanNardi deleted the http-rework2 branch May 16, 2023 14:01
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.

2 participants