Sophie

Sophie

distrib > Fedora > 13 > x86_64 > by-pkgid > 13346d960136a7b9b0d616aaa1eb7b7e > files > 45

dbmail-2.2.17-1.fc13.x86_64.rpm


README.usermap

DBMail supports usermaps and domainmaps which will allow you to map login names to
fully qualified (unique) userids as used in the dbmail_users table or ldap. 

Rationale:

1) support 1-1 and 1-N mappings of login usernames to userids

You can use this during a transition to a new username policy. For instance, 
when you want to give all new users their email address as login, but you want 
to allow all existing users to login using their old login.

2) support IP based virtual hosting

This means you can use separate namespaces for different IP addresses dbmail
is listening on. 


The layout of the new dbmail_usermap table is as follows:

---------------------------
login      | varchar (100)
sock_allow | varchar (100)
sock_deny  | varchar (100)
userid	   | varchar (100)
---------------------------

Consider the following settings:

  | login      | sock_allow           | sock_deny            | userid
--+------------+----------------------+----------------------+-------------
1 |client      |                      |                      | client@a.com
2 |client      | inet:127.0.0.1:143   |                      | client@b.com
3 |client      | inet:10.1.1.1:143    | inet:10.1.1.1:110    | client@c.com
4 |ANY         | inet:10.1.1.2:143    |                      | %s@d.com
5 |client      |                      | inet:0.0.0.0:0       |
6 |client      | inet:127.0.0.1:143   | inet:0.0.0.0/0:110   | client
 
row 1 will give you a simple 1-1 mapping irrespective of the IP address connected to.

row 2 will allow client@b.com to login on a single IP address with imap.

row 3 will allow client@c.com to login on a single IP address with imap but will reject 
POP access on that address.

row 4 will map all logins on a single IP address to an expanded form.

row 5 will deny any kind of access to client.

row 6 will allow client@d.com to login on a single IP address with imap but will reject
POP access from any IP.