[sr-dev] [kamailio/kamailio] tls: allow export session keys (#2785)

Daniel-Constantin Mierla notifications at github.com
Mon Jun 28 08:41:44 CEST 2021

In my opinion there are issues of concurrency in writing to the file. It seems to be open in the main process, during the initialisation and then write to it during runtime from kamailio processes. Writing from multiple processes to the same file is going to have unpredictable content.

The solution would be to either have a lock around and do every time: lock, open file, write, close unlock; or create a consumer process that write to the file and the others produce data that is sent to it. Another option would be that each process writes to dedicated file (e.g., filename-pid).

I also noticed that the file name is reallocated in pkg using a local variable in a function and not freed.

You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-dev/attachments/20210627/7a430bb0/attachment.htm>

More information about the sr-dev mailing list