[dovecot-cvs] dovecot/src/auth db-passwd-file.c, 1.25.2.3, 1.25.2.4 passdb-bsdauth.c, 1.14.2.1, 1.14.2.2 passdb-cache.c, 1.17.2.4, 1.17.2.5 passdb-checkpassword.c, 1.18.2.11, 1.18.2.12 passdb-pam.c, 1.37.2.10, 1.37.2.11 passdb-passwd.c, 1.17, 1.17.2.1 passdb-shadow.c, 1.18, 1.18.2.1 passdb-sia.c, 1.1.2.1, 1.1.2.2 passdb-vpopmail.c, 1.24.2.1, 1.24.2.2 userdb-passwd.c, 1.18.2.3, 1.18.2.4 userdb-prefetch.c, 1.3.2.2, 1.3.2.3 userdb-vpopmail.c, 1.21.2.2, 1.21.2.3
tss at dovecot.org
tss at dovecot.org
Sat Mar 10 15:24:14 EET 2007
- Previous message: [dovecot-cvs] dovecot/src/plugins/mail-log mail-log-plugin.c, 1.5, 1.6
- Next message: [dovecot-cvs] dovecot/src/auth db-passwd-file.c, 1.28, 1.29 mech-gssapi.c, 1.10, 1.11 passdb-bsdauth.c, 1.16, 1.17 passdb-cache.c, 1.21, 1.22 passdb-checkpassword.c, 1.32, 1.33 passdb-pam.c, 1.48, 1.49 passdb-passwd.c, 1.18, 1.19 passdb-shadow.c, 1.19, 1.20 passdb-sia.c, 1.3, 1.4 passdb-vpopmail.c, 1.26, 1.27 userdb-passwd.c, 1.21, 1.22 userdb-prefetch.c, 1.5, 1.6 userdb-vpopmail.c, 1.23, 1.24
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /var/lib/cvs/dovecot/src/auth
In directory talvi:/tmp/cvs-serv477
Modified Files:
Tag: branch_1_0
db-passwd-file.c passdb-bsdauth.c passdb-cache.c
passdb-checkpassword.c passdb-pam.c passdb-passwd.c
passdb-shadow.c passdb-sia.c passdb-vpopmail.c userdb-passwd.c
userdb-prefetch.c userdb-vpopmail.c
Log Message:
Added more debug logging.
Index: db-passwd-file.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/db-passwd-file.c,v
retrieving revision 1.25.2.3
retrieving revision 1.25.2.4
diff -u -d -r1.25.2.3 -r1.25.2.4
--- db-passwd-file.c 1 Jul 2006 19:42:25 -0000 1.25.2.3
+++ db-passwd-file.c 10 Mar 2007 13:24:11 -0000 1.25.2.4
@@ -389,6 +389,7 @@
{
struct passwd_file *pw;
struct passwd_user *pu;
+ const char *username;
if (!db->vars)
pw = db->default_file;
@@ -413,13 +414,18 @@
if (!passwd_file_sync(pw)) {
auth_request_log_info(request, "passwd-file",
- "no passwd file");
+ "no passwd file: %s", pw->path);
return NULL;
}
t_push();
- pu = hash_lookup(pw->users, !db->domain_var ? request->user :
- t_strcut(request->user, '@'));
+ username = !db->domain_var ? request->user :
+ t_strcut(request->user, '@');
+
+ auth_request_log_debug(request, "passwd-file",
+ "lookup: user=%s file=%s", username, pw->path);
+
+ pu = hash_lookup(pw->users, username);
if (pu == NULL)
auth_request_log_info(request, "passwd-file", "unknown user");
t_pop();
Index: passdb-bsdauth.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/passdb-bsdauth.c,v
retrieving revision 1.14.2.1
retrieving revision 1.14.2.2
diff -u -d -r1.14.2.1 -r1.14.2.2
--- passdb-bsdauth.c 15 Oct 2006 21:31:19 -0000 1.14.2.1
+++ passdb-bsdauth.c 10 Mar 2007 13:24:11 -0000 1.14.2.2
@@ -19,6 +19,8 @@
struct passwd *pw;
int result;
+ auth_request_log_debug(request, "bsdauth", "lookup");
+
pw = getpwnam(request->user);
if (pw == NULL) {
auth_request_log_info(request, "bsdauth", "unknown user");
Index: passdb-cache.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/passdb-cache.c,v
retrieving revision 1.17.2.4
retrieving revision 1.17.2.5
diff -u -d -r1.17.2.4 -r1.17.2.5
--- passdb-cache.c 16 Feb 2007 17:22:58 -0000 1.17.2.4
+++ passdb-cache.c 10 Mar 2007 13:24:11 -0000 1.17.2.5
@@ -23,8 +23,12 @@
/* value = password \t ... */
value = auth_cache_lookup(passdb_cache, request, key, &node, &expired);
- if (value == NULL || (expired && !use_expired))
+ if (value == NULL || (expired && !use_expired)) {
+ auth_request_log_debug(request, "cache",
+ value == NULL ? "miss" : "expired");
return FALSE;
+ }
+ auth_request_log_debug(request, "cache", "hit");
if (*value == '\0') {
/* negative cache entry */
@@ -79,8 +83,12 @@
return FALSE;
value = auth_cache_lookup(passdb_cache, request, key, &node, &expired);
- if (value == NULL || (expired && !use_expired))
+ if (value == NULL || (expired && !use_expired)) {
+ auth_request_log_debug(request, "cache",
+ value == NULL ? "miss" : "expired");
return FALSE;
+ }
+ auth_request_log_debug(request, "cache", "hit");
if (*value == '\0') {
/* negative cache entry */
Index: passdb-checkpassword.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/passdb-checkpassword.c,v
retrieving revision 1.18.2.11
retrieving revision 1.18.2.12
diff -u -d -r1.18.2.11 -r1.18.2.12
--- passdb-checkpassword.c 16 Feb 2007 17:26:17 -0000 1.18.2.11
+++ passdb-checkpassword.c 10 Mar 2007 13:24:11 -0000 1.18.2.12
@@ -221,15 +221,9 @@
auth_request_log_error(request, "checkpassword",
"dup2() failed: %m");
} else {
- /* very simple argument splitting. */
- cmd = t_strconcat(module->checkpassword_path, " ",
- module->checkpassword_reply_path, NULL);
- args = t_strsplit(cmd, " ");
-
/* Besides passing the standard username and password in a
pipe, also pass some other possibly interesting information
via environment. Use UCSPI names for local/remote IPs. */
- /* */
env_put("PROTO=TCP"); /* UCSPI */
env_put(t_strconcat("SERVICE=", request->service, NULL));
if (request->local_ip.family != 0) {
@@ -264,9 +258,13 @@
env_put_extra_fields(fields);
}
+ /* very simple argument splitting. */
+ cmd = t_strconcat(module->checkpassword_path, " ",
+ module->checkpassword_reply_path, NULL);
auth_request_log_debug(request, "checkpassword",
- "Executed: %s", cmd);
+ "execute: %s", cmd);
+ args = t_strsplit(cmd, " ");
execv(args[0], (char **)args);
auth_request_log_error(request, "checkpassword",
"execv(%s) failed: %m", args[0]);
Index: passdb-pam.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/passdb-pam.c,v
retrieving revision 1.37.2.10
retrieving revision 1.37.2.11
diff -u -d -r1.37.2.10 -r1.37.2.11
--- passdb-pam.c 22 Feb 2007 12:23:49 -0000 1.37.2.10
+++ passdb-pam.c 10 Mar 2007 13:24:11 -0000 1.37.2.11
@@ -431,6 +431,7 @@
service = module->service_name != NULL ?
module->service_name : request->service;
+ auth_request_log_debug(request, "pam", "lookup service=%s", service);
if (worker) {
/* blocking=yes code path in auth worker */
Index: passdb-passwd.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/passdb-passwd.c,v
retrieving revision 1.17
retrieving revision 1.17.2.1
diff -u -d -r1.17 -r1.17.2.1
--- passdb-passwd.c 13 Jan 2006 20:25:57 -0000 1.17
+++ passdb-passwd.c 10 Mar 2007 13:24:11 -0000 1.17.2.1
@@ -20,6 +20,8 @@
struct passwd *pw;
bool result;
+ auth_request_log_debug(request, "passwd", "lookup");
+
pw = getpwnam(request->user);
if (pw == NULL) {
auth_request_log_info(request, "passwd", "unknown user");
Index: passdb-shadow.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/passdb-shadow.c,v
retrieving revision 1.18
retrieving revision 1.18.2.1
diff -u -d -r1.18 -r1.18.2.1
--- passdb-shadow.c 13 Jan 2006 20:25:57 -0000 1.18
+++ passdb-shadow.c 10 Mar 2007 13:24:11 -0000 1.18.2.1
@@ -20,6 +20,8 @@
struct spwd *spw;
bool result;
+ auth_request_log_debug(request, "shadow", "lookup");
+
spw = getspnam(request->user);
if (spw == NULL) {
auth_request_log_info(request, "shadow", "unknown user");
Index: passdb-sia.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/passdb-sia.c,v
retrieving revision 1.1.2.1
retrieving revision 1.1.2.2
diff -u -d -r1.1.2.1 -r1.1.2.2
--- passdb-sia.c 8 Oct 2006 21:25:14 -0000 1.1.2.1
+++ passdb-sia.c 10 Mar 2007 13:24:11 -0000 1.1.2.2
@@ -35,6 +35,8 @@
{
char *argutility = "dovecot";
+ auth_request_log_debug(request, "sia", "lookup");
+
/* check if the password is valid */
if (sia_validate_user(checkpw_collect, 1, &argutility, NULL,
(char *)request->user, NULL, NULL, NULL,
Index: passdb-vpopmail.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/passdb-vpopmail.c,v
retrieving revision 1.24.2.1
retrieving revision 1.24.2.2
diff -u -d -r1.24.2.1 -r1.24.2.2
--- passdb-vpopmail.c 15 Oct 2006 20:30:04 -0000 1.24.2.1
+++ passdb-vpopmail.c 10 Mar 2007 13:24:11 -0000 1.24.2.2
@@ -24,6 +24,10 @@
struct vqpasswd *vpw;
char *password;
+ auth_request_log_debug(auth_request, "vpopmail",
+ "lookup user=%s domain=%s",
+ vpop_user, vpop_domain);
+
vpw = vpopmail_lookup_vqp(auth_request, vpop_user, vpop_domain);
if (vpw == NULL) {
*result_r = PASSDB_RESULT_USER_UNKNOWN;
@@ -86,9 +90,6 @@
return;
}
- auth_request_log_debug(request, "vpopmail",
- "crypted password=%s", password);
-
tmp_pass = crypted_pass;
scheme = password_get_scheme(&tmp_pass);
if (scheme == NULL)
Index: userdb-passwd.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/userdb-passwd.c,v
retrieving revision 1.18.2.3
retrieving revision 1.18.2.4
diff -u -d -r1.18.2.3 -r1.18.2.4
--- userdb-passwd.c 12 Feb 2007 21:48:31 -0000 1.18.2.3
+++ userdb-passwd.c 10 Mar 2007 13:24:11 -0000 1.18.2.4
@@ -16,6 +16,8 @@
struct passwd *pw;
struct auth_stream_reply *reply;
+ auth_request_log_debug(auth_request, "passwd", "lookup");
+
pw = getpwnam(auth_request->user);
if (pw == NULL) {
auth_request_log_info(auth_request, "passwd", "unknown user");
Index: userdb-prefetch.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/userdb-prefetch.c,v
retrieving revision 1.3.2.2
retrieving revision 1.3.2.3
diff -u -d -r1.3.2.2 -r1.3.2.3
--- userdb-prefetch.c 16 Jan 2007 13:18:21 -0000 1.3.2.2
+++ userdb-prefetch.c 10 Mar 2007 13:24:11 -0000 1.3.2.3
@@ -88,6 +88,8 @@
else {
struct auth_stream_reply *reply;
+ auth_request_log_debug(auth_request, "prefetch", "success");
+
/* import the string into request. since the values were
exported they are already in escaped form in the string. */
reply = auth_stream_reply_init(auth_request);
Index: userdb-vpopmail.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/auth/userdb-vpopmail.c,v
retrieving revision 1.21.2.2
retrieving revision 1.21.2.3
diff -u -d -r1.21.2.2 -r1.21.2.3
--- userdb-vpopmail.c 16 Jan 2007 13:23:26 -0000 1.21.2.2
+++ userdb-vpopmail.c 10 Mar 2007 13:24:11 -0000 1.21.2.3
@@ -27,6 +27,10 @@
return NULL;
}
+ auth_request_log_debug(auth_request, "vpopmail",
+ "lookup user=%s domain=%s",
+ vpop_user, vpop_domain);
+
vpw = vauth_getpw(vpop_user, vpop_domain);
if (vpw == NULL) {
auth_request_log_info(request, "vpopmail", "unknown user");
- Previous message: [dovecot-cvs] dovecot/src/plugins/mail-log mail-log-plugin.c, 1.5, 1.6
- Next message: [dovecot-cvs] dovecot/src/auth db-passwd-file.c, 1.28, 1.29 mech-gssapi.c, 1.10, 1.11 passdb-bsdauth.c, 1.16, 1.17 passdb-cache.c, 1.21, 1.22 passdb-checkpassword.c, 1.32, 1.33 passdb-pam.c, 1.48, 1.49 passdb-passwd.c, 1.18, 1.19 passdb-shadow.c, 1.19, 1.20 passdb-sia.c, 1.3, 1.4 passdb-vpopmail.c, 1.26, 1.27 userdb-passwd.c, 1.21, 1.22 userdb-prefetch.c, 1.5, 1.6 userdb-vpopmail.c, 1.23, 1.24
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the dovecot-cvs
mailing list