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

Errors fixed #1482

Merged
merged 1 commit into from
Mar 7, 2022
Merged

Errors fixed #1482

merged 1 commit into from
Mar 7, 2022

Conversation

vel21ripn
Copy link
Contributor

Fixed errors for bigendian platforms in ndpiReader.
All address and port comparisons and hash calculations are done with
endian in mind.
The get_ndpi_flow_info() function searched for an existing flow for the
forward and reverse direction of the packet.
The ndpi_workflow_node_cmp() function looked for a flow regardless of
the packet's direction. This is what led to an error in determining the
direction of transmission of the packet.

Fixed error in "synscan" test: the number of packets in the forward and
reverse direction is incorrectly defined (verified via tcpdump).

@IvanNardi
Copy link
Collaborator

IvanNardi commented Mar 7, 2022

@vel21ripn , could you please push a new version with the following patch?

--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -305,10 +305,10 @@ jobs:
             "uname -a &&
             lscpu | grep Endian
             "
-      - name: Configure and compile (no tests) using qemu for the specified architecture (s390x - big endian)
+      - name: Configure and compile using qemu for the specified architecture (s390x - big endian)
         if: startsWith(matrix.os, 'ubuntu') && startsWith(matrix.arch, 's390x')
         uses: docker://multiarch/ubuntu-core:s390x-bionic
-        with: #./tests/do.sh disabled because we know we have some problems with big-endian machines
+        with:
           args: >
             bash -c
             "apt-get -y update &&
@@ -318,5 +318,6 @@ jobs:
             make -C example ndpiSimpleIntegration &&
             make -C rrdtool &&
             make -C python &&
+            ./tests/do.sh &&
             ./tests/do-unit.sh

Fixed errors for bigendian platforms in ndpiReader.
All address and port comparisons and hash calculations are done with
endian in mind.
The get_ndpi_flow_info() function searched for an existing flow for the
forward and reverse direction of the packet.
The ndpi_workflow_node_cmp() function looked for a flow regardless of
the packet's direction. This is what led to an error in determining the
direction of transmission of the packet.

Fixed error in "synscan" test: the number of packets in the forward and
reverse direction is incorrectly defined (verified via tcpdump).

Fixed bug with icmp protocol checksum check for big endian platforms.
@sonarcloud
Copy link

sonarcloud bot commented Mar 7, 2022

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 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@utoni
Copy link
Collaborator

utoni commented Mar 7, 2022

Thanks for fixing this long term issue.

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.

3 participants