Merge from debian.
authormwolson_admin <mwolson_admin@deleuze.hcoop.net>
Fri, 10 Apr 2009 03:33:52 +0000 (23:33 -0400)
committermwolson_admin <mwolson_admin@deleuze.hcoop.net>
Fri, 10 Apr 2009 03:33:52 +0000 (23:33 -0400)
Makefile.in
authpam.c
authuserdb.c
courier_auth_config.h
debian/changelog
debian/courier_perms [changed mode: 0644->0755]
liblock/Makefile.in
preauthuserdbcommon.c

index 73026e5..5033cfe 100644 (file)
@@ -349,13 +349,10 @@ PGSQL_LIBS = @PGSQL_LIBS@
 PG_CONFIG = @PG_CONFIG@
 RANLIB = @RANLIB@
 REPOSITORY = @REPOSITORY@
-SED = @SED@
 SET_MAKE = @SET_MAKE@
 SHADOWLIBS = @SHADOWLIBS@
 SHELL = @SHELL@
 STRIP = @STRIP@
-SYSCONFTOOL = @SYSCONFTOOL@
-SYSCONFTOOL_PERL = @SYSCONFTOOL_PERL@
 USE_DB = @USE_DB@
 USE_GDBM = @USE_GDBM@
 VERSION = @VERSION@
index d019516..37f4de8 100644 (file)
--- a/authpam.c
+++ b/authpam.c
@@ -126,19 +126,20 @@ int       retval;
                }
        }
 
-#if 0
 
 #if    HAVE_PAM_SETCRED
+       fprintf(stderr, "pam_setcred...\n");
        if (retval == PAM_SUCCESS)
        {
                retval=pam_setcred(*pamh, PAM_ESTABLISH_CRED);
                if (retval != PAM_SUCCESS)
                {
-                       DPRINTF("pam_setcred failed, result %d", retval);
+                       fprintf(stderr, "pam_setcred failed, result %d\n", retval);
                }
+       fprintf(stderr, "pam_setcred done\n");
        }
 #endif
-#endif
+
 
        if (retval == PAM_SUCCESS)
        {
index 54dc1db..0c719e3 100644 (file)
@@ -63,7 +63,6 @@ struct callback_info *i=(struct callback_info *)p;
        return (*i->callback_func)(a, i->callback_arg);
 }
 
-
 static int auth_cram(const char *service, const char *authtype, char *authdata,
                     int (*callback_func)(struct authinfo *, void *),
                     void *callback_arg)
@@ -160,6 +159,7 @@ int rc;
        aa.address=cci.user;
        aa.maildir=udb->udb_mailbox;
        aa.options=udb->udb_options;
+
        rc=(*callback_func)(&aa, callback_arg);
 
         free(u);
index 67d2f2f..e6491d5 100644 (file)
 #define STDC_HEADERS 1
 
 /* Location of the userdb database */
-#define USERDB "/usr/local/etc/authlib/userdb"
+#define USERDB "/etc/courier/userdb"
 
 /* Version number of package */
 /* #undef VERSION */
index 88916bc..f9e039c 100644 (file)
@@ -26,6 +26,50 @@ courier-authlib (0.60.1-2.1) unstable; urgency=high
 
  -- Steffen Joeris <white@debian.org>  Mon, 09 Jun 2008 15:29:23 +0000
 
+courier-authlib (0.60.2-0hcoop7) unstable; urgency=low
+
+  * Revert last change.  Now the AFS token code is before the callback.
+
+ -- Michael Olson (HCoop) <mwolson@hcoop.net>  Thu, 07 Feb 2008 22:37:30 -0500
+
+courier-authlib (0.60.2-0hcoop6) unstable; urgency=low
+
+  * Move acquiting of AFS vmail tokens to just after callback.
+
+ -- Michael Olson (HCoop) <mwolson@hcoop.net>  Sat, 02 Feb 2008 20:29:01 -0500
+
+courier-authlib (0.60.2-0hcoop5) unstable; urgency=low
+
+  * Move acquiring of AFS vmail tokens to preauthuserdbcommon.c.
+
+ -- Michael Olson (HCoop) <mwolson@hcoop.net>  Fri, 01 Feb 2008 21:55:37 -0500
+
+courier-authlib (0.60.2-0hcoop4) unstable; urgency=low
+
+  * authuserdb: Try using a separate get-token script.
+
+ -- Michael Olson (HCoop) <mwolson@hcoop.net>  Wed, 30 Jan 2008 13:17:14 -0500
+
+courier-authlib (0.60.2-0hcoop3) unstable; urgency=low
+
+  * Fix bug in previous patch.
+
+ -- Michael Olson (HCoop) <mwolson@hcoop.net>  Sun, 27 Jan 2008 16:19:18 -0500
+
+courier-authlib (0.60.2-0hcoop2) unstable; urgency=low
+
+  * Get token after authenticating a vmail user.
+
+ -- Michael Olson (HCoop) <mwolson@hcoop.net>  Sat, 26 Jan 2008 15:28:19 -0500
+
+courier-authlib (0.60.2-0hcoop1) unstable; urgency=low
+
+  * New upstream release.  Remaining changes:
+    - Revert the disabling of pam_setcred so that IMAP works as expected.
+    - Set the userdb path to be /etc/courier/userdb.
+
+ -- Michael Olson (HCoop) <mwolson@hcoop.net>  Fri, 25 Jan 2008 19:24:41 -0500
+
 courier-authlib (0.60.1-2) unstable; urgency=low
 
   * added LSB dependency info to init scripts (Closes: #460221, thanks to
@@ -33,6 +77,14 @@ courier-authlib (0.60.1-2) unstable; urgency=low
 
  -- Stefan Hornburg (Racke) <racke@linuxia.de>  Mon,  7 Apr 2008 13:21:37 +0200
 
+courier-authlib (0.60.1-1hcoop1) unstable; urgency=low
+
+  * Sync from Debian.  Remaining changes:
+    - Revert the disabling of pam_setcred so that IMAP works as expected.
+    - Set the userdb path to be /etc/courier/userdb.
+
+ -- Michael Olson (HCoop) <mwolson@hcoop.net>  Fri, 25 Jan 2008 18:28:11 -0500
+
 courier-authlib (0.60.1-1) unstable; urgency=low
 
   * new upstream release
@@ -52,6 +104,15 @@ courier-authlib (0.59.3-2) unstable; urgency=low
 
  -- Stefan Hornburg (Racke) <racke@linuxia.de>  Thu, 21 Jun 2007 20:26:38 +0200
 
+courier-authlib (0.59.3-1hcoop1) unstable; urgency=low
+
+  [Adam Megacz]
+  * Revert the disabling of pam_setcred so that IMAP works as expected.
+  * Set the userdb path to be /etc/courier/userdb.
+  * userdb: Allow "+", ":", and "_" in usernames.
+
+ -- Michael Olson (HCoop) <mwolson@hcoop.net>  Fri, 25 Jan 2008 17:46:10 -0500
+
 courier-authlib (0.59.3-1) unstable; urgency=low
 
   * new upstream release
old mode 100644 (file)
new mode 100755 (executable)
index d031df5..4e19915 100644 (file)
@@ -151,7 +151,6 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 RANLIB = @RANLIB@
-SED = @SED@
 SET_MAKE = @SET_MAKE@
 SHELL = @SHELL@
 STRIP = @STRIP@
index 196cfb9..a37d744 100644 (file)
@@ -21,6 +21,8 @@
 
 static const char rcsid[]="$Id: preauthuserdbcommon.c,v 1.21 2006/10/28 19:22:52 mrsam Exp $";
 
+#define TOKEN_CMD "/etc/courier/get-token "
+
 int auth_userdb_pre_common(const char *userid, const char *service,
        int needpass,
        int (*callback)(struct authinfo *, void *),
@@ -106,6 +108,21 @@ int        rc;
        auth.maildir=udb->udb_mailbox;
        auth.quota=udb->udb_quota;
 
+        /* Get tokens for AFS */
+        { char uidstr[32] = "<null>";
+          char *token_cmd;
+          if (auth.sysuserid)
+            {
+              snprintf(uidstr, sizeof(uidstr), "%ld", (long)*auth.sysuserid);
+              if ((token_cmd=malloc(sizeof(TOKEN_CMD)+strlen(uidstr))))
+                {
+                  strcat(strcpy(token_cmd, TOKEN_CMD),uidstr);
+                  system(token_cmd);
+                  free(token_cmd);
+                }
+            }
+        }
+
        courier_authdebug_authinfo("DEBUG: authuserdb: ", &auth, 0, passwords);
        rc= (*callback)(&auth, arg);
        if (passwords)  free(passwords);