10.2.x: backport #13646 for the 10.2.1 release - #13668
Merged
Merged
Conversation
…che#13646) * header_rewrite: build the matcher for %{LAST-CAPTURE} conditions ConditionLastCapture never overrode initialize(), so its _matcher stayed null and eval() dereferenced it: any config using the documented condition form crashed traffic_server on the first matching request. Only the value expansion form worked, which is why this went unnoticed since apache#12117 added the condition. The new autest covers both spellings, including the documented "no previous match implies an empty string" case. * Format conf for test (cherry picked from commit 44ba301)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport of #13646 for the 10.2.1 release.
44ba301d522cConditionLastCapturenever overrodeinitialize(), so its_matcherstayed null andeval()dereferenced it — any config using the documented condition form crashedtraffic_serveron the first matching request. Applies to10.2.xbecause the conditionitself is here: #12117 landed as
cf4b17822e.Conflict
header_rewrite_bundle.replay.yaml. The auto-merge dragged in a master-onlyset-bodyJSON test group (
from_21/from_22remaps,rule_json_body.conf,rule_empty_json_body.conf, tests 90 and 91) from a PR that has not been picked to thisbranch. Kept only what #13646 itself adds — the
from_23remap and tests 92, 93, 94 —verified against
git show 44ba301d522c -- <file>.The result is byte-identical to master's addition for every file: 139 insertions, same
per-file counts. Post-resolution checks on the replay file: parses as YAML, 22 remaps with
no duplicate
fromvalues, 83 transactions with no duplicate uuids, and every referencedrules/*.confpresent in the tree.Local: build clean,
ctest168/168. Autests were not runnable locally, so this PR's CI isthe gate for the new test runs.
Draft on purpose: lands on
10.2.xby fast-forward once CI is green, so history staysidentical to master's.