]> git.kaiwu.me - haproxy.git/commit
REGTESTS: protobuf: add regression test for nested vs flat paths
authorFrederic Lecaille <flecaille@haproxy.com>
Thu, 16 Jul 2026 15:41:18 +0000 (17:41 +0200)
committerFrederic Lecaille <flecaille@haproxy.com>
Thu, 16 Jul 2026 15:41:18 +0000 (17:41 +0200)
commitcbe54688eaa15a6a2690a68f87b6a43339ab0a51
treedc75640682341cd6bbc1a918e7f7714404de494c
parent9993f29007cac184ce8b9ab42e4ba8c780f38da6
REGTESTS: protobuf: add regression test for nested vs flat paths

This patch adds a new VTC regression test to validate the protobuf()
sample converter and prevent future regressions.

It tests four distinct scenarios to ensure correct behavior:
  - validating legitimate nested path extraction (e.g., path "1.2") on a
    nested payload.
  - ensuring flat path extraction (path "2") is blocked when the field is
    actually inside a nested payload.
  - validating legitimate flat sibling extraction (path "2") on a flat
    payload.
  - ensuring nested path extraction (path "1.2") is blocked when run on
    a flat sibling payload which was fixed by this commit

    BUG/MEDIUM: protobuf: fix nested path bypass in field lookup
reg-tests/protobuf/nested_and_flat.vtc [new file with mode: 0644]