1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-20 11:11:24 +00:00
freebsd/lib/libc
John Polstra c97c8f4a3c Fix a bug in __ivaliduser_sa() which caused some rsh/rlogin attempts
to fail needlessly if a reverse DNS lookup of the IP address didn't
come up with a hostname.  As a comment in the code clearly stated,
the "damn hostname" was looked up only for the purpose of netgroup
matching.  But if that lookup failed, the function bailed out
immediately even though in many cases netgroup matching would not
be used.

This change marks the hostname as unknown but continues.  Where
netgroup matching is performed, an unknown hostname is handled
conservatively.  I.e., for "+@netgroup" (accept) entries an unknown
hostname never matches, and for "-@netgroup" (reject) entries an
unknown hostname always matches.

In the lines affected (only), I also fixed a few bogus casts.  There
are others, and in fact this entire file would be a good candidate
for a cleanup sweep.

Reviewed by:	imp (wearing his flourescent yellow Security Team cap)
MFC after:	2 days
2002-08-24 17:37:42 +00:00
..
alpha Generate the normal asm stubs for all sysv system calls. Use these instead 2002-05-23 23:51:57 +00:00
amd64 Use '_end' symbol instead of 'end' to initialize minbrk and curbrk 2002-08-08 17:28:07 +00:00
compat-43 Assume __STDC__, remove non-__STDC__ code. 2002-05-28 17:03:12 +00:00
db Assume __STDC__, remove non-__STDC__ code. 2002-05-28 17:03:12 +00:00
gen Note that <sys/types.h> in no longer a prerequisite for <utime.h> and 2002-08-24 00:39:43 +00:00
gmon Check for defined(__i386__) instead of just defined(i386) since the compiler 2002-05-30 07:00:42 +00:00
i386 Include <stdlib.h> to have abort() and exit() declared. 2002-08-15 11:58:24 +00:00
ia64 We cannot use an alloc with only inputs and/or locals. The kernel 2002-08-23 03:47:50 +00:00
include Do not use __progname directly (except in [gs]etprogname(3)). 2002-03-29 22:43:43 +00:00
locale o Merge <machine/ansi.h> and <machine/types.h> into a new header 2002-08-21 16:20:02 +00:00
net Fix a bug in __ivaliduser_sa() which caused some rsh/rlogin attempts 2002-08-24 17:37:42 +00:00
nls Now, malloc is fixed, remove ENOMEM hardcode 2002-08-12 11:47:19 +00:00
posix1e Update TE policy and MAC text conversion routines to support partial 2002-08-09 03:09:38 +00:00
powerpc _C_LABEL -> CNAME 2002-05-17 05:11:13 +00:00
quad
regex
rpc xdr.3 is added to MAN in ../xdr/Makefile.inc where it belongs, so don't 2002-08-19 23:06:00 +00:00
sparc64 Add missing ret instruction to the ptrace() syscall wrapper. 2002-07-11 15:48:02 +00:00
stdio o Merge <machine/ansi.h> and <machine/types.h> into a new header 2002-08-21 16:20:02 +00:00
stdlib s/EDOFUS/EDOOFUS/ 2002-08-21 17:11:00 +00:00
stdtime Use one line for each function argument to keep the line 2002-08-15 18:57:57 +00:00
string Add a manual page for wcswidth(). 2002-08-20 03:40:45 +00:00
sys Note that <sys/types.h> in no longer a prerequisite for <utime.h> and 2002-08-24 00:39:43 +00:00
xdr Removed duplicated MLINKS which make(1) recently started warning about. 2002-08-15 12:31:01 +00:00
yp Spell void * as void * rather than caddr_t. This is complicated by the 2002-04-28 15:18:50 +00:00
Makefile
Makefile.inc PowerPC does not have profile support yet. 2002-05-15 20:07:31 +00:00