Bug#566351: libgcrypt11: should not change user id as a side effect

Werner Koch wk at gnupg.org
Wed Nov 7 10:31:16 CET 2012

On Sat,  3 Nov 2012 18:29, ametzler at downhill.at.eu.org said:

> comment sums it up:
> <https://bugs.launchpad.net/debian/+source/sudo/+bug/423252/comments/72>

Well, it is the usual problem with inter-library dependencies.  We will
never be able to get this right.  The DSO is just not designed to work
with completely independent libraries.  I don't like to say, but in this
regard Windows DLLs are a better solution.

Although we can't solve all the problems we will be able to solve the
thread initialization problem.  Libgcrypt 1.6 will ignore the thread
callbacks and assume pthread.  Semaphores are then used for locking and
provide a way to do thread-safe initialization.  The hopefully minor
drawback is that one needs to link against librt.

> +       err = ath_install (va_arg (arg_ptr, void *), any_init_done);
> +-      if (! err)
> +-      global_init ();

Okay, if that works, fine.  It might break other things; I don't know.
There are enough selftests to hopefully detect such a break (in
particular in FIPS mode).



Die Gedanken sind frei.  Ausnahmen regelt ein Bundesgesetz.

More information about the Gcrypt-devel mailing list