]> 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:13:26 +0000 (10:13 -0500)
commit44684fdd5167b140195f97fae72a786e3dfc881e
tree3679c411ce59086b17b2d2e97fdecf82e7a2993a
parent109c2335ef9cc707c6708d5a93bbe05288344f50
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