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 ICMP Layer #3

Open
vaguue opened this issue Feb 14, 2024 · 0 comments
Open

Add ICMP Layer #3

vaguue opened this issue Feb 14, 2024 · 0 comments
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed

Comments

@vaguue
Copy link
Owner

vaguue commented Feb 14, 2024

Feature Request: ICMP Layer Support

Objective: Enhance the lib/layers module by introducing an ICMP layer that can read and create ICMP packets, aligning with the existing layer interface structure.

Detailed Description

The ICMP (Internet Control Message Protocol) layer is used by network devices, including routers, to send error messages and operational information indicating success or failure when communicating with another IP address. Implementing this layer will enable our library to handle ICMP packets, both in parsing and creation scenarios.

Starting Point

For the implementation, please refer to the existing exampleLayer.js in lib/layers as a base structure for the new layer.

Requirements:

  1. ICMP Layer Implementation: The ICMP layer should be capable of understanding and constructing ICMP packets. It should adhere to the specifications outlined for ICMP packets, including fields like type, code, checksum and the rest.

  2. Interface Compliance: The new ICMP layer must comply with the existing layer interface to ensure compatibility with the rest of the library. This includes implementing any required methods and properties defined in the layer interface.

  3. Testing: Comprehensive tests must be written to cover:

    • Parsing ICMP packets from a buffer and verifying the accuracy of the parsed data.
    • Creating ICMP packets and ensuring the generated buffer is correct as per ICMP specifications.
    • Comparison with existing protocol layers and their tests for consistency in implementation and testing approach.

Reference:

Developers should refer to the implementation and tests of adjacent protocols within the lib/layers directory for guidance on structure, coding standards, and testing methodologies.

Outcome: By introducing ICMP layer support, the library will be significantly more versatile in handling network traffic, paving the way for more advanced features and use cases.

Next Steps:

  1. Review the ICMP protocol specifications.
  2. Design the ICMP layer interface in alignment with the existing layer structure.
  3. Implement the ICMP layer, followed by the development of unit tests.
  4. Perform thorough testing to ensure reliability and compliance with ICMP standards.

Contributions: We welcome contributions for this feature. If you are interested in working on this, please comment below, and let's discuss how we can collaborate effectively. For any questions or to propose implementation details, feel free to reach out or start a discussion in this issue.

@vaguue vaguue added enhancement New feature or request help wanted Extra attention is needed good first issue Good for newcomers labels Feb 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant