[Dovecot] Username bug in '%%' variables selects
Victor
xnasx at yandex.ru
Thu Apr 5 16:51:32 EEST 2012
Hi! Forgive my bad English.
I trying to set up shared folders, but I can't.
I shared INBOX of 'victor at domain.com' for 'victor at testmail.domain.com'
There is my debugging results:
doveadm acl debug -u victor at testmail.domain.com INBOX.shared.victor at domain.com.
doveadm(victor at testmail.domain.com): Error: Couldn't create namespace 'INBOX.shared.' for user victor at domain: userdb didn't return a home directory, but mail_location used it (%h): maildir:%h
That's I seen in logs:
auth-worker: Debug: sql(victor at domain): SELECT CONCAT('/var/spool/mail/', SUBSTRING_INDEX(email, '@', -1), '/', SUBSTRING_INDEX(email, '@', 1)) as home from `users` WHERE email='victor at domain'
What happened with my username? 'victor at domain' is not correct value.
My config:
namespace {
inbox = yes
location =
prefix = INBOX.
separator = .
type = private
}
namespace {
hidden = no
list = yes
location = maildir:%%h
prefix = INBOX.shared.%%u.
separator = .
subscriptions = no
type = shared
}
password_query = \
SELECT email as username, password \
FROM users WHERE email = '%u'
user_query = SELECT CONCAT('/var/spool/mail/', SUBSTRING_INDEX(email, '@', -1), '/', SUBSTRING_INDEX(email, '@', 1)) as home from `users` WHERE email='%u'
Please, help me!
--
Best regards,
Victor
More information about the dovecot
mailing list