Re: Access Violation shows OpenSSL stack

Viktor Dukhovni <[email protected]> Sun, 13 Jul 2025 23:33:22 +1000
Newsgroups gmane.comp.encryption.openssl.user
Message-ID <[email protected]>
On Sun, Jul 13, 2025 at 04:58:52PM +0530, Dipak B wrote:

> DLL gets unloaded from the Windows service after making sure that Threads
> (of Windows service) that outlive this DLL are not actively executing
> functions exported by the DLL.

That's not enough, they must never again try to execute any OpenSSL
functions, or retain and use any objects returned by the unloaded
library.

> In other words, app makes sure that Windows service threads have finished
> executing functions exported by DLL and they get returned to custom pool
> where they wait for other work.

That's not sufficient, if they retain any references to OpenSSL objects,
this includes OpenSSL-specific thread-specific storage, which is not
easily reinitialised, so bottom line those threads MUST not be returned
to the thread pool, they need to terminate before OpenSSL is unloaded.

-- 
    Viktor.

-- 
You received this message because you are subscribed to the Google Groups "openssl-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openssl-users+unsubscribe-MCmKBN63+Bmbup2nOX2J7Q@public.gmane.org
To view this discussion visit https://groups.google.com/a/openssl.org/d/msgid/openssl-users/aHO1oqpiBHcNk5fR%40chardros.imrryr.org.