This is the mail archive of the libc-alpha@sources.redhat.com 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]

Re: another one (was Re: [patch] res_conf.h missing security feature)


On Mon, Jan 08, 2001 at 10:26:37AM -0500, Ben Collins wrote:
> Seems this fix didn't make it throught the resolv migration in glibc 2.2

Another two uses that are in 2.1.3, but not 2.2:

2001-01-08  Ben Collins  <bcollins@debian.org>

	* resolv/res_init.c (__res_vinit): Use __secure_getenv instead
	of getenv for LOCALDOMAIN and RES_OPTIONS.

-- 
 -----------=======-=-======-=========-----------=====------------=-=------
/  Ben Collins  --  ...on that fantastic voyage...  --  Debian GNU/Linux   \
`  bcollins@debian.org  --  bcollins@openldap.org  --  bcollins@linux.com  '
 `---=========------=======-------------=-=-----=-===-======-------=--=---'
--- resolv/res_init.c~	Mon Jan  8 11:41:38 2001
+++ resolv/res_init.c	Mon Jan  8 11:41:53 2001
@@ -186,7 +186,7 @@
 #endif
 
 	/* Allow user to override the local domain definition */
-	if ((cp = getenv("LOCALDOMAIN")) != NULL) {
+	if ((cp = __secure_getenv("LOCALDOMAIN")) != NULL) {
 		(void)strncpy(statp->defdname, cp, sizeof(statp->defdname) - 1);
 		statp->defdname[sizeof(statp->defdname) - 1] = '\0';
 		haveenv++;
@@ -424,7 +424,7 @@
 #endif /* !RFC1535 */
 	}
 
-	if ((cp = getenv("RES_OPTIONS")) != NULL)
+	if ((cp = __secure_getenv("RES_OPTIONS")) != NULL)
 		res_setoptions(statp, cp, "env");
 	statp->options |= RES_INIT;
 	return (0);

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