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

LUA function to dump client headers in the order received #11886

Open
mach0gr opened this issue Nov 27, 2024 · 1 comment
Open

LUA function to dump client headers in the order received #11886

mach0gr opened this issue Nov 27, 2024 · 1 comment
Assignees
Milestone

Comments

@mach0gr
Copy link

mach0gr commented Nov 27, 2024

The currently exposed LUA function ts.client_request.get_headers() is returning a LUA table holding all headers and their values. However, Lua tables are inherently unordered, which makes preserving the original order of headers impossible.

I would like to put a feture request to expose a LUA function that can return the headers in a big string or on an indexed LUA table.
Preserving the order or headers in the order the client sent them is important for troubleshooting purposes as well as client fingerprinting.

This process is already available in your output_header test plugin seen here
https://github.com/apache/trafficserver/blob/9.2.x/example/plugins/c-api/output_header/output_header.c#L72

can you expose it to LUA ?

@shukitchan shukitchan self-assigned this Nov 27, 2024
@shukitchan shukitchan added this to the 10.1.0 milestone Nov 27, 2024
@shukitchan
Copy link
Contributor

I will take a look at it next week.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants