Mercurial > dovecot > core-2.2
changeset 9802:fc0022950bad HEAD
Renamed auth-master socket to auth-userdb socket.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Mon, 17 Aug 2009 12:52:22 -0400 |
parents | 825fd2b3f48e |
children | 7f9fcd00a819 |
files | dovecot-example.conf dovecot-master-example.conf src/auth/main.c src/lib-storage/mail-storage-settings.c |
diffstat | 4 files changed, 13 insertions(+), 34 deletions(-) [+] |
line wrap: on
line diff
--- a/dovecot-example.conf Mon Aug 17 10:45:29 2009 -0400 +++ b/dovecot-example.conf Mon Aug 17 12:52:22 2009 -0400 @@ -833,7 +833,7 @@ # UNIX socket path to master authentication server to find users. # This is used by imap (for shared users) and lda. -#auth_socket_path = /var/run/dovecot/auth-master +#auth_socket_path = /var/run/dovecot/auth-userdb auth default { # Space separated list of wanted authentication mechanisms: @@ -1064,27 +1064,6 @@ # X509_NAME_get_text_by_NID() which returns the subject's DN's # CommonName. #ssl_username_from_cert = no - - # It's possible to export the authentication interface to other programs: - #socket listen { - #master { - # Master socket provides access to userdb information. It's typically - # used to give Dovecot's local delivery agent access to userdb so it - # can find mailbox locations. - #path = /var/run/dovecot/auth-master - #mode = 0600 - # Default user/group is the one who started dovecot-auth (root) - #user = - #group = - #} - #client { - # The client socket is generally safe to export to everyone. Typical use - # is to export it to your SMTP server so it can do SMTP AUTH lookups - # using it. - #path = /var/run/dovecot/auth-client - #mode = 0660 - #} - #} } # If you wish to use another authentication server than dovecot-auth, you can
--- a/dovecot-master-example.conf Mon Aug 17 10:45:29 2009 -0400 +++ b/dovecot-master-example.conf Mon Aug 17 12:52:22 2009 -0400 @@ -37,15 +37,15 @@ mode = 0666 } - # postfix smtp-auth + # Postfix smtp-auth + #unix_listener { + # path = /var/spool/postfix/private/auth + # mode = 0666 + #} + + # Dovecot LDA unix_listener { - path = /var/spool/postfix/private/auth - mode = 0666 - } - - # dovecot LDA - unix_listener { - path = auth-master + path = auth-userdb mode = 0600 } }
--- a/src/auth/main.c Mon Aug 17 10:45:29 2009 -0400 +++ b/src/auth/main.c Mon Aug 17 12:52:22 2009 -0400 @@ -129,7 +129,7 @@ checking the socket path name. */ struct sockaddr_un sa; socklen_t addrlen = sizeof(sa); - size_t len; + const char *suffix; if (getsockname(conn->listen_fd, (void *)&sa, &addrlen) < 0) i_fatal("getsockname(%d) failed: %m", conn->listen_fd); @@ -138,8 +138,8 @@ conn->listen_fd); } - len = strlen(sa.sun_path); - if (len > 7 && strcmp(sa.sun_path + len - 7, "-master") == 0) + suffix = strrchr(sa.sun_path, '-'); + if (strcmp(suffix, "master") == 0) *type = AUTH_SOCKET_MASTER; else *type = AUTH_SOCKET_CLIENT;
--- a/src/lib-storage/mail-storage-settings.c Mon Aug 17 10:45:29 2009 -0400 +++ b/src/lib-storage/mail-storage-settings.c Mon Aug 17 12:52:22 2009 -0400 @@ -161,7 +161,7 @@ static struct mail_user_settings mail_user_default_settings = { MEMBER(base_dir) PKG_RUNDIR, - MEMBER(auth_socket_path) "auth-master", + MEMBER(auth_socket_path) "auth-userdb", MEMBER(mail_uid) "", MEMBER(mail_gid) "",