Skip to content

Definition for ethernet flow control packets.#649

Merged
mrmonday merged 1 commit intolibpnet:mainfrom
AJMansfield:ethernet_flow_control
May 30, 2024
Merged

Definition for ethernet flow control packets.#649
mrmonday merged 1 commit intolibpnet:mainfrom
AJMansfield:ethernet_flow_control

Conversation

@AJMansfield
Copy link
Copy Markdown
Contributor

This is a pretty obsolete protocol and ended up not being useful for what I'd hoped it would be, but I wrote an implementation for it anyway so the world might as well have it.

Copy link
Copy Markdown
Contributor

@stevedoyle stevedoyle left a comment

Choose a reason for hiding this comment

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

Missing unit test?

@AJMansfield
Copy link
Copy Markdown
Contributor Author

AJMansfield commented Oct 19, 2023

Missing unit test?

AFAIK the standard doesn't give any test vectors, so I'm not sure how to meaningfully test this.

Inventing a test vector myself wouldn't add anything: if there were an error, given the declarative nature of the code here the error would inevitably be a misinterpretation of the standard rather than a mis-implementation of that interpretation -- so adding a test vector I've concocted myself would likely amount to just writing down the same mistake twice.

Would using Wireshark to create the test vector be appropriate here? Given that it's a much more mature project it might not be unreasonable to consider its behavior as "authoritative enough".

@stevedoyle
Copy link
Copy Markdown
Contributor

Would using Wireshark to create the test vector be appropriate here? Given that it's a much more mature project it might not be unreasonable to consider its behavior as "authoritative enough".

I think using Wireshark or tcpdump to capture a reference/test packet is a good approach.

@mrmonday
Copy link
Copy Markdown
Contributor

Thanks!

@mrmonday mrmonday merged commit 053e508 into libpnet:main May 30, 2024
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