[Dovecot] Variable %h not recognized in userdb_mail (passwd-file)
Michal Soltys
nozo at ziu.info
Wed Mar 14 17:51:18 EET 2007
Timo Sirainen wrote:
> On Wed, 2007-03-14 at 15:31 +0100, Michal Soltys wrote:
>> Timo Sirainen wrote:
>>> On Wed, 2007-03-14 at 14:36 +0100, Michal Soltys wrote:
>>>> As in subject, if you for instance create a simple passwd-file with:
>>>>
>>>> test at domain.tld:{plain}pass:20000:10::/home/regular/.test::userdb_mail=maildir:%h/maildir
>>>>
>>>> Dovecot (rc23 & 27) will expand %h to empty string, and try to make a
>>>> directory under /
>>> Looks like the expansion was done too early. Fixed:
>>> http://dovecot.org/list/dovecot-cvs/2007-March/008128.html
>> Now dovecot both expands %h and treats it literally, creating following
>> directory: /home/regular/.test/%h/maildir
>
> I'm not sure why it would do this. The dovecot master should expand the
> mail environment once more, so %h should have expanded. It also worked
> in my tests..
>
> Anyway, after thinking about this for a while I think the change is
> wrong anyway, so I reverted it. I think the solution for now is just to
> not use %h, since dovecot-auth can't expand it and it's not that simple
> to add the code to do that.
>
> Do you see %h elsewhere in Wiki than in MailLocation? I changed that
> now.
>
Can't find it anywhere else.
Also, some small remark could be added in
http://wiki.dovecot.org/AuthDatabase/PasswdFile and possibly in
http://wiki.dovecot.org/MailLocation, that %h cannot be used in userdb_mail
as in mail_location.
If %h could cause problems in other places (like ldap, sql,...),
http://wiki.dovecot.org/Variables might need adjusting too.
More information about the dovecot
mailing list