Author: Arthur de Jong <adejong@debian.org>
Last-Update: 2013-08-14
Forwarded: <unknown>. Fixed in 1.3.6rc1
Bug-Debian: http://bugs.debian.org/717235
Description: not request the whole passwd DB at each login.

Index: git/modules/mod_auth.c
===================================================================
--- git.orig/modules/mod_auth.c	2016-12-10 20:55:51.120194113 +0100
+++ git/modules/mod_auth.c	2016-12-10 20:55:51.116194128 +0100
@@ -836,16 +836,23 @@
 }
 
 static void ensure_open_passwd(pool *p) {
-  /* Make sure pass/group is open.
-   */
+  /* Make sure pass/group is open. */
   pr_auth_setpwent(p);
   pr_auth_setgrent(p);
 
   /* On some unices the following is necessary to ensure the files
-   * are open.  (BSDI 3.1)
+   * are open (BSDI 3.1)
    */
   pr_auth_getpwent(p);
   pr_auth_getgrent(p);
+
+  /* Per Debian bug report:
+   *   https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=717235
+   * we might want to do another set{pw,gr}ent(), to play better with
+   * some NSS modules.
+   */
+  pr_auth_setpwent(p);
+  pr_auth_setgrent(p);
 }
 
 /* Next function (the biggie) handles all authentication, setting
