]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MINOR: jwt: Copy input and parameters in dedicated buffers in jwt_verify converter
authorRemi Tricot-Le Breton <rlebreton@haproxy.com>
Mon, 30 Jun 2025 14:56:22 +0000 (16:56 +0200)
committerWilliam Lallemand <wlallemand@haproxy.com>
Mon, 30 Jun 2025 15:59:55 +0000 (17:59 +0200)
commit3465f88f8ab9c3f163d73938765f741c2b7e6a67
tree73e5d3ae044d82e92727c3f568050a0f57f05956
parent5ba0a2d5270f2ba52a3022578e52fb5709bff3cb
BUG/MINOR: jwt: Copy input and parameters in dedicated buffers in jwt_verify converter

When resolving variable values the temporary trash chunks are used so
when calling the 'jwt_verify' converter with two variable parameters
like in the following line, the input would be overwritten by the value
of the second parameter :
    var(txn.bearer),jwt_verify(txn.jwt_alg,txn.cert)
Copying the values into dedicated alloc'ed buffers prevents any new call
to get_trash_chunk from erasing the data we need in the converter.

This patch can be backported up to 2.8.
src/sample.c