In the sieve plugin settings i have plugin { ... sieve_user_email = %u }
Variables pages says %u = full username (e.g. user@domain)
This config seems to work in practice, the email is from: the users email address.
However on starting dovecot im getting a warning twice:
dovecot[35893]: managesieve: Warning: sieve: Invalid address value for
setting sieve_user_email': Missing domain dovecot[35893]: master: Dovecot v2.3.8 (9df20d2db) starting up for imap, lmtp, sieve dovecot[35897]: managesieve: Warning: sieve: Invalid address value for setting
sieve_user_email': Missing domain
So is there really an issue? Or just an improper warning?
On 29/07/2021 22:39 dovecot@ptld.com wrote:
In the sieve plugin settings i have plugin { ... sieve_user_email = %u }
Variables pages says %u = full username (e.g. user@domain)
This config seems to work in practice, the email is from: the users email address.
However on starting dovecot im getting a warning twice: dovecot[35893]: managesieve: Warning: sieve: Invalid address value for setting
sieve_user_email': Missing domain dovecot[35893]: master: Dovecot v2.3.8 (9df20d2db) starting up for imap, lmtp, sieve dovecot[35897]: managesieve: Warning: sieve: Invalid address value for setting
sieve_user_email': Missing domainSo is there really an issue? Or just an improper warning?
Maybe some of your users do not have domain in the username? %u will only expand into user@domain if the username has domain. It won't magic up the domain value there.
So if your username is magick
%u will always expand into magick
.
Aki
On 08-09-2021 12:55 am, Aki Tuomi wrote:
In the sieve plugin settings i have plugin { ... sieve_user_email = %u }
Variables pages says %u = full username (e.g. user@domain)
This config seems to work in practice, the email is from: the users email address.
However on starting dovecot im getting a warning twice: dovecot[35893]: managesieve: Warning: sieve: Invalid address value for setting
sieve_user_email': Missing domain dovecot[35893]: master: Dovecot v2.3.8 (9df20d2db) starting up for imap, lmtp, sieve dovecot[35897]: managesieve: Warning: sieve: Invalid address value for setting
sieve_user_email': Missing domainMaybe some of your users do not have domain in the username? %u will only expand into user@domain if the username has domain. It won't magic up the domain value there.
Im not getting my head around what you are saying. This happens on dovecot startup. To my knowledge there isn't any username being evaluated. Where would dovecot be pulling a username from? I assumed it was just testing the syntax of the config not grabbing random user data.
As far as maybe some users don't have domains in their username, still having trouble getting my head around that idea. I didn't know a maildir/ location had a "username" embedded into it. Isn't mail access determined by login verification and where mail_location tells dovecot where to find the maildir/ files for that login? I mean if i just change mail_location then doesn't that completely change the correlation between "username" and ones email?
For my situation im using sql to lookup login info.
mail_home = /email/%d/%2n/%n/_dovecot mail_location = maildir:/email/%d/%2n/%n/_folders:INDEX=/email/%d/%2n/%n/_dovecot:CONTROL=/email/%d/%2n/%n/_dovecot password_query = SELECT inbox AS userdb_user, passwd AS password, CONCAT('*:storage=', diskQuota, 'm') AS userdb_quota_rule FROM accounts WHERE email = '%u'
Sql Columns 'email' and 'inbox' both store the same full "user@domain.com". The 'email' column acts as login username and the 'inbox' column acts as maildir/ location. Other relevant configuration...
protocol lmtp { mail_plugins = $mail_plugins sieve } plugin { ... sieve = file:~/../_sieve;active=~/../_sieve/.active_sieve sieve_user_email = %u }
Where is my misunderstanding on this and/or what is dovecot looking at on startup to determine there isn't a domain in usernames for sieve when no one has logged in yet? Or should i trick sieve by putting %n@%d instead of %u for sieve_user_email?
On 09/08/2021 16:57 dovecot@ptld.com wrote:
On 08-09-2021 12:55 am, Aki Tuomi wrote:
In the sieve plugin settings i have plugin { ... sieve_user_email = %u }
Variables pages says %u = full username (e.g. user@domain)
This config seems to work in practice, the email is from: the users email address.
However on starting dovecot im getting a warning twice: dovecot[35893]: managesieve: Warning: sieve: Invalid address value for setting
sieve_user_email': Missing domain dovecot[35893]: master: Dovecot v2.3.8 (9df20d2db) starting up for imap, lmtp, sieve dovecot[35897]: managesieve: Warning: sieve: Invalid address value for setting
sieve_user_email': Missing domainMaybe some of your users do not have domain in the username? %u will only expand into user@domain if the username has domain. It won't magic up the domain value there.
Im not getting my head around what you are saying. This happens on dovecot startup. To my knowledge there isn't any username being evaluated. Where would dovecot be pulling a username from? I assumed it was just testing the syntax of the config not grabbing random user data.
As far as maybe some users don't have domains in their username, still having trouble getting my head around that idea. I didn't know a maildir/ location had a "username" embedded into it. Isn't mail access determined by login verification and where mail_location tells dovecot where to find the maildir/ files for that login? I mean if i just change mail_location then doesn't that completely change the correlation between "username" and ones email?
For my situation im using sql to lookup login info.
mail_home = /email/%d/%2n/%n/_dovecot mail_location = maildir:/email/%d/%2n/%n/_folders:INDEX=/email/%d/%2n/%n/_dovecot:CONTROL=/email/%d/%2n/%n/_dovecot password_query = SELECT inbox AS userdb_user, passwd AS password, CONCAT('*:storage=', diskQuota, 'm') AS userdb_quota_rule FROM accounts WHERE email = '%u'
Sql Columns 'email' and 'inbox' both store the same full "user@domain.com". The 'email' column acts as login username and the 'inbox' column acts as maildir/ location. Other relevant configuration...
protocol lmtp { mail_plugins = $mail_plugins sieve } plugin { ... sieve = file:~/../_sieve;active=~/../_sieve/.active_sieve sieve_user_email = %u }
Where is my misunderstanding on this and/or what is dovecot looking at on startup to determine there isn't a domain in usernames for sieve when no one has logged in yet? Or should i trick sieve by putting %n@%d instead of %u for sieve_user_email?
Hm. Overlooked the "on startup" part. This sounds like a bug, maybe.
Aki
participants (2)
-
Aki Tuomi
-
dovecot@ptld.com