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 integration server.cookies does not return multiple cookies (DEV-2300) #386

Open
seakayone opened this issue Jun 20, 2023 · 1 comment
Assignees
Labels

Comments

@seakayone
Copy link
Contributor

seakayone commented Jun 20, 2023

Problem Description

Given an incoming request with multiple cookies,
when calling server.cookies in Lua,
then the returned table contains only a single key/value pair, with the first cookie name as lower case and the rest of the cookie header as value.

This way it is not possible to get an individual cookie value if multiple cookies are in the request because the server.cookies table alway only contains a single entry. Currently we have to get the cookie header and parse the returned string in order to be able to extract a specific cookie.

Expected Behaviour

  1. The cookie names in the returned table should be the original case and not lower case
  2. The cookie values in the returned table should be the individual values for each cookie. If n cookies are sent with the request then n entries should be in the table.

Link to internal ticket: https://linear.app/dasch/issue/DEV-2300/sipi-lua-integration-servercookies-does-not-return-multiple-cookies

@seakayone seakayone changed the title Lua integration server.cookies does not return multiple cookies Lua integration server.cookies does not return multiple cookies (DEV-2300) Jun 20, 2023
@subotic
Copy link
Contributor

subotic commented Jun 28, 2023

@lrosenth can you maybe also take a look?

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

No branches or pull requests

3 participants