示例#1
0
void mail_crypt_plugin_init(struct module *module)
{
	const char* error;
	random_init();
	if (!dcrypt_initialize("openssl", NULL, &error))
		i_fatal("dcrypt_initialize(): %s", error);
	mail_storage_hooks_add(module, &mail_crypt_mail_storage_hooks);
	/* rather kludgy. we need to hook into mail reading as early as
	   possible, but we need to hook into mail writing as late as
	   possible. we could create just two real plugins, but that's a bit
	   annoying to configure. */
	mail_storage_hooks_add_forced(&crypto_post_module,
				      &mail_crypt_mail_storage_hooks_post);
	mail_crypt_key_register_mailbox_internal_attributes();
}
示例#2
0
void doveadm_sieve_sync_init(struct module *module)
{
	mail_storage_hooks_add_forced
		(module, &doveadm_sieve_mail_storage_hooks);
}