Thank you for taking the time to correct my input and provide this guidance. I hope to make better contributions in future.
I knew my “solution” was a quick hack; but as I couldn’t find out (quickly) where the dummy message was instantiated, I couldn’t work out what its side-effects might be.
What matters is that the ipsec_destroy() function will now actually tear down an IPSec SA, because none were being removed before. Output from “ip xfrm state list” would indicate
perhaps 10 SA’s while only one ipsec-3gpp capable UE was active (and unreachable in a VoLTE call).
From: Daniel-Constantin Mierla ***@***.***>
Sent: Wednesday, November 22, 2023 10:17 AM
To: kamailio/kamailio ***@***.***>
Cc: BISHOP James (JRC-ISPRA) ***@***.***>; Author ***@***.***>
Subject: Re: [kamailio/kamailio] Add AoR argument to ims_ipsec_pcscf ipsec_destroy() (PR #3645)
Merged manually. However, as I did the merge, I noticed:
* the docs were not updated to reflect the new parameter for ipsec_destroy() - you have to update the xml files inside doc/ subfolder when adding/changing module parameters or functions. This time I did it, you can review to see if you want to add more there
* the change of msg structure ruri is not safe by just changing the string pointer and the length, you have to use C function rewrite_uri(...) from the core because old value might need to be freed and r-uri-parsed structure invalidated. But such change then it is permanet, if you need it to stay like that, then use $ru = ...; in config, functions like ipsec_destroy() must not change it permanently (at least not without documenting such behaviour). Therefore I pushed another commit to the module which is no longer replacing msg structure r-uri field, but uses the config parameter to build the contact info.
I also changed the fixup code to use an existing helper function from core, which simplifies that part.
You have to test with latest git master branch and see if it works as expected, if not, then open an issue.
—
Reply to this email directly, view it on GitHub<https://urldefense.com/v3/__https:/github.com/kamailio/kamailio/pull/3645*issuecomment-1822383640__;Iw!!DOxrgLBm!GFbbiUFbkTtqNYXnyfvYp32RnIiQvNg0Wgy7SN0EN0XlJeRWW4qy6h5Z4bxw0qjNlAReI5ILiIA3HmUbMA6C0xsL7SS-Boc$>, or unsubscribe<https://urldefense.com/v3/__https:/github.com/notifications/unsubscribe-auth/AM4GRXMJFHNNUK6W7N5AUEDYFW7KHAVCNFSM6AAAAAA7PS6Q3SVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMRSGM4DGNRUGA__;!!DOxrgLBm!GFbbiUFbkTtqNYXnyfvYp32RnIiQvNg0Wgy7SN0EN0XlJeRWW4qy6h5Z4bxw0qjNlAReI5ILiIA3HmUbMA6C0xsLfrlYonk$>.
You are receiving this because you authored the thread.Message ID: ***@***.***>
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <kamailio/kamailio/pull/3645/c1822450006@github.com>