]> git.ipfire.org Git - thirdparty/asterisk.git/commit
res_crypto: don't modify fname in try_load_key()
authorPhilip Prindeville <philipp@redfish-solutions.com>
Fri, 16 Sep 2022 23:29:36 +0000 (17:29 -0600)
committerGeorge Joseph <gjoseph@digium.com>
Mon, 10 Oct 2022 15:12:46 +0000 (10:12 -0500)
commitc19fe636dfd1f7bc2b4d53364031748978c8ffe1
treebcec98f238fd9b15ef3fb9bd6d4aea2477582ce8
parent24b677db88c65f8a228cd49a3025db43553cf882
res_crypto: don't modify fname in try_load_key()

"fname" is passed in as a const char *, but strstr() mangles that
into a char *, and we were attempting to modify the string in place.
This is an unwanted (and undocumented) side-effect.

ASTERISK-30213

Change-Id: Ifa36d352aafeb7f9beec3f746332865c7d21e629
res/res_crypto.c