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

binary input format #201

Merged
merged 3 commits into from Nov 1, 2022
Merged

binary input format #201

merged 3 commits into from Nov 1, 2022

Conversation

pspacek
Copy link
Contributor

@pspacek pspacek commented Oct 21, 2022

Add ability to read binary input using TCP stream format (2 bytes packet length, then packet binary, repeat).

New format is used when new option -B is in use. Avoids need to reencode packets repeatedly, and allows to send nonsense packets as well.

New option -B allows to read datafile formated like TCP stream with DNS
messages.
@pspacek pspacek changed the title Draft: binary input format binary input format Oct 26, 2022
@pspacek
Copy link
Contributor Author

pspacek commented Oct 26, 2022

@jelu I think this is ready for review.

@jelu
Copy link
Member

jelu commented Nov 1, 2022

This is gonna take a while to review. Btw, you've missed perf_datafile_next() usage in resperf.c.

- `datafile`:
  - Move format to structure and set during open
  - `read_one_blob()`:
    - remove unused variables
    - change read to be a two step, first size then wire data
    - fix calc of what's in the buffer
  - prefix format enums will full type name
- `dns`:
  - remove `perf_dns_change_qid()`
- `dnsperf`:
  - reformat man-page and add exclusivity of `-B`
  - `do_send()`: use pointer to buffer to send instead of overwriting `msg`
- `resperf`: fix usage of new functions
- `test/test7`:
  - fix shell code to work with generic `/bin/sh`
  - fix usage in build directory
@jelu
Copy link
Member

jelu commented Nov 1, 2022

triggering webhooks

@jelu jelu closed this Nov 1, 2022
@jelu jelu reopened this Nov 1, 2022
@jelu
Copy link
Member

jelu commented Nov 1, 2022

#build

- `datafile`: fix strict-aliasing warning
@jelu jelu merged commit 7fb3b02 into DNS-OARC:develop Nov 1, 2022
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.

None yet

2 participants