Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Re-initialize OpenLDAP TLS context during plugin initialization
When shinken-broker starts in the default daemon mode, it closes all open files. If OpenLDAP is in use and the TLS implementation is GnuTLS, then this may cause the random data source /dev/urandom to be closed. This often results in the following error: Warning : [webui] The mod auth-active-directory raise an exception: {'info': "Error in the system's randomness device.", 'desc': "Can't contact LDAP server"}, I'm tagging it to restart later In order to ensure the TLS context is valid for OpenLDAP, set the option OPT_X_TLS_NEWCTX during plugin initialization. This will cause OpenLDAP to re-initialize it's TLS context, which will cause GnuTLS to re-open /dev/urandom.
- Loading branch information