1234567891011121314151617181920212223 |
- # Not complete!!
- # Covers only changes to queries
- password_query = SELECT \
- CONCAT(`virtual_users`.`username`, '@', `virtual_domains`.`name`) as `user`, `virtual_users`.`password` \
- FROM `mailserver`.`virtual_users` \
- INNER JOIN `mailserver`.`virtual_domains` \
- ON `virtual_domains`.`id` = `virtual_users`.`domain_id` \
- AND `virtual_domains`.`name` = SUBSTRING_INDEX('%u', '@', -1) \
- WHERE `virtual_users`.`username` = SUBSTRING_INDEX('%u', '@', 1);
- # Alternatively (suppport login as aliases) Read more about this in the tutorial
- #password_query = SELECT \
- # CONCAT(`virtual_users`.`username`, '@', `virtual_domains`.`name`) as `user`, `virtual_users`.`password` \
- # FROM `mailserver`.`virtual_alias` \
- # INNER JOIN `virtual_users`.`user_id`
- # ON `virtual_users`.`id` = `virtual_aliases`.`user_id` \
- # INNER JOIN `mailserver`.`virtual_domains` \
- # ON `virtual_domains`.`id` = `virtual_users`.`domain_id` \
- # AND `virtual_domains`.`name` = SUBSTRING_INDEX('%u', '@', -1) \
- # WHERE `virtual_alias`.`alias` = SUBSTRING_INDEX('%u', '@', 1);
|