]> 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:33 +0000 (10:12 -0500)
commit5daf32bb143493ac61f5257e54de423bd9e03986
treeba565c330717514c60b6b5e49bfe7a550de35ce2
parentbc9ee15b93fa66842c14878bcb0b7d87af5b6d09
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