This is the mail archive of the glibc-cvs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

GNU C Library master sources branch release/2.23/master updated. glibc-2.23-24-g28a87e0


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, release/2.23/master has been updated
       via  28a87e027450b66faf1a431fc62779297c760e29 (commit)
      from  5769d5d17cdb4770f1e08167b76c1684ad4e1f73 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=28a87e027450b66faf1a431fc62779297c760e29

commit 28a87e027450b66faf1a431fc62779297c760e29
Author: Florian Weimer <fweimer@redhat.com>
Date:   Tue Mar 29 11:27:32 2016 +0200

    nss_db: Propagate ERANGE error if parse_line fails [BZ #19837]
    
    Reproducer (needs to run as root):
    
    perl -e \
      'print "large:x:999:" . join(",", map {"user$_"} (1 .. 135))."\n"' \
      >> /etc/group
    cd /var/db
    make
    getent -s db group
    
    After the fix, the last command should list the "large" group.
    
    The magic number 135 has been chosen so that the line is shorter than
    1024 bytes, but the pointers required to encode the member array will
    cross the threshold, triggering the bug.
    
    (cherry picked from commit a6033052d08027f745867e5e346852da1959226c)

diff --git a/ChangeLog b/ChangeLog
index 29b7cf5..6635c5e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2016-03-29  Florian Weimer  <fweimer@redhat.com>
+
+	[BZ #19837]
+	* nss/nss_db/db-XXX.c (_nss_db_getENTNAME_r): Propagate ERANGE
+	error if parse_line fails.
+
 2016-04-20  Yvan Roux  <yvan.roux@linaro.org>
 
 	* stdlib/setenv.c (unsetenv): Fix ambiguous 'else'.
diff --git a/nss/nss_db/db-XXX.c b/nss/nss_db/db-XXX.c
index 03c18d7..125a5e9 100644
--- a/nss/nss_db/db-XXX.c
+++ b/nss/nss_db/db-XXX.c
@@ -288,8 +288,8 @@ CONCAT(_nss_db_get,ENTNAME_r) (struct STRUCTURE *result, char *buffer,
 	    }
 	  if (err < 0)
 	    {
-	      H_ERRNO_SET (HOST_NOT_FOUND);
-	      status = NSS_STATUS_NOTFOUND;
+	      H_ERRNO_SET (NETDB_INTERNAL);
+	      status = NSS_STATUS_TRYAGAIN;
 	      break;
 	    }
 

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog           |    6 ++++++
 nss/nss_db/db-XXX.c |    4 ++--
 2 files changed, 8 insertions(+), 2 deletions(-)


hooks/post-receive
-- 
GNU C Library master sources


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]