-
Notifications
You must be signed in to change notification settings - Fork 21
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
fix(var): patch set_uri_args #59
Conversation
|
cdf8a56
to
ae8ce72
Compare
ae8ce72
to
dd4d882
Compare
set_uri_args modifies the $args variable without accessing our patched metatable. For it to work we need to invalidate our index whenever the function is called. fix for Kong/kong#10080
dd4d882
to
b36c9bb
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me!
patch the `req.set_header` function to invalidate the relevant `variable_index` entry for the modified header. Specifically, after normalizing the header name, the corresponding `variable_index` entry is set to `nil`. This ensures that subsequent accesses to `ngx.var.http_*` variables will bypass the cached index and fetch the updated header value. same fix way as: #59 Fix: [KAG-5963](https://konghq.atlassian.net/browse/KAG-5963) Signed-off-by: tzssangglass <tzssangglass@gmail.com>
patch the `req.set_header` function to invalidate the relevant `variable_index` entry for the modified header. Specifically, after normalizing the header name, the corresponding `variable_index` entry is set to `nil`. This ensures that subsequent accesses to `ngx.var.http_*` variables will bypass the cached index and fetch the updated header value. same fix way as: #59 Fix: KAG-5963 Fix: FTI-6406 Signed-off-by: tzssangglass <tzssangglass@gmail.com>
patch the `req.set_header` function to invalidate the relevant `variable_index` entry for the modified header. Specifically, after normalizing the header name, the corresponding `variable_index` entry is set to `nil`. This ensures that subsequent accesses to `ngx.var.http_*` variables will bypass the cached index and fetch the updated header value. same fix way as: #59 Fix: KAG-5963 Fix: FTI-6406 Signed-off-by: tzssangglass <tzssangglass@gmail.com>
patch the req.set_header function to invalidate the relevant variable_index entry for the modified header. Specifically, after normalizing the header name, the corresponding variable_index entry is set to nil. This ensures that subsequent accesses to ngx.var.http_* variables will bypass the cached index and fetch the updated header value. same fix way as: #59 Fix: KAG-5963 Fix: FTI-6406 Signed-off-by: tzssangglass <tzssangglass@gmail.com>
patch the req.set_header function to invalidate the relevant variable_index entry for the modified header. Specifically, after normalizing the header name, the corresponding variable_index entry is set to nil. This ensures that subsequent accesses to ngx.var.http_* variables will bypass the cached index and fetch the updated header value. same fix way as: #59 Fix: KAG-5963 Fix: FTI-6406 Signed-off-by: tzssangglass <tzssangglass@gmail.com>
patch the req.set_header function to invalidate the relevant variable_index entry for the modified header. Specifically, after normalizing the header name, the corresponding variable_index entry is set to nil. This ensures that subsequent accesses to ngx.var.http_* variables will bypass the cached index and fetch the updated header value. same fix way as: #59 Fix: KAG-5963 Fix: FTI-6406 Signed-off-by: tzssangglass <tzssangglass@gmail.com> Co-authored-by: Samuele <samuele@konghq.com>
patch the `req.set_header` function to invalidate the relevant `variable_index` entry for the modified header. Specifically, after normalizing the header name, the corresponding `variable_index` entry is set to `nil`. This ensures that subsequent accesses to `ngx.var.http_*` variables will bypass the cached index and fetch the updated header value. same fix way as: #59 Fix: KAG-5963 Fix: FTI-6406 Signed-off-by: tzssangglass <tzssangglass@gmail.com>
* fix(var): patch set_header (#97) patch the `req.set_header` function to invalidate the relevant `variable_index` entry for the modified header. Specifically, after normalizing the header name, the corresponding `variable_index` entry is set to `nil`. This ensures that subsequent accesses to `ngx.var.http_*` variables will bypass the cached index and fetch the updated header value. same fix way as: #59 Fix: KAG-5963 Fix: FTI-6406 Signed-off-by: tzssangglass <tzssangglass@gmail.com> * update KONG_VERSION in GitHub Actions workflow to release/3.7.x Signed-off-by: tzssangglass <tzssangglass@gmail.com> --------- Signed-off-by: tzssangglass <tzssangglass@gmail.com>
patch the `req.set_header` function to invalidate the relevant `variable_index` entry for the modified header. Specifically, after normalizing the header name, the corresponding `variable_index` entry is set to `nil`. This ensures that subsequent accesses to `ngx.var.http_*` variables will bypass the cached index and fetch the updated header value. same fix way as: #59 Fix: KAG-5963 Fix: FTI-6406 Signed-off-by: tzssangglass <tzssangglass@gmail.com>
patch the `req.set_header` function to invalidate the relevant `variable_index` entry for the modified header. Specifically, after normalizing the header name, the corresponding `variable_index` entry is set to `nil`. This ensures that subsequent accesses to `ngx.var.http_*` variables will bypass the cached index and fetch the updated header value. same fix way as: #59 Fix: KAG-5963 Fix: FTI-6406 Signed-off-by: tzssangglass <tzssangglass@gmail.com>
patch the `req.set_header` function to invalidate the relevant `variable_index` entry for the modified header. Specifically, after normalizing the header name, the corresponding `variable_index` entry is set to `nil`. This ensures that subsequent accesses to `ngx.var.http_*` variables will bypass the cached index and fetch the updated header value. same fix way as: #59 Fix: KAG-5963 Fix: FTI-6406 Signed-off-by: tzssangglass <tzssangglass@gmail.com>
set_uri_args modifies the $args variable without accessing our patched metatable. For it to work properly we can invalidate our index table for the value "args" whenever the function
set_uri_args
is called. This way the next access to ngx.var.args will miss the index and fetch the real value of $args.fix for Kong/kong#10080
KAG-410