Hello, first of all, thank you for your reply. However it still doesn't work. Infact with he suggested configuration, when user receives a new mail I have this error:
2025-05-12 16:37:17 lmtp(284205): Error: lmtp-server: conn 1.2.3.4:52582 [2]: rcpt crypto.test@example.com: Failed to initialize user: mail_crypt_plugin: main: crypt_private_key_password unset, no password to decrypt the key file
I have no more the error referred to raw user but this time I have the problem related to "user". I cannot understand why, when dovecot receives a new email it says "no password to decrypt the key file", why it tries to decrypt the key file? It has just to crypt the new arrived email using the public key that is available from LDAP userdb. Password is not available when an email is received but just when an email should be read.
Is it possible it is a bug? Is it possible nobody uses such a configuration?
Thanks.