mirror of
https://github.com/openbsd/src.git
synced 2024-12-21 23:18:00 -08:00
Allow UDP for built-in inetd(8) services on 127.0.0.1.
This restriction was added in year 2000 due to IPv6 compatible and mapped addresses. Nowadays our kernel does not support these IPv6 features and blocks localhost addresses on non-loopback interfaces. Make IPv4 127.0.0.1/8 and IPv6 ::1 behave identically and provide local services if configured. OK mvs@ deraadt@
This commit is contained in:
parent
f4863b1258
commit
1c33b230a8
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: inetd.c,v 1.164 2023/04/19 12:58:16 jsg Exp $ */
|
||||
/* $OpenBSD: inetd.c,v 1.165 2023/09/03 22:01:00 bluhm Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1983,1991 The Regents of the University of California.
|
||||
@ -444,7 +444,7 @@ dg_badinput(struct sockaddr *sa)
|
||||
if (IN_MULTICAST(in.s_addr))
|
||||
goto bad;
|
||||
switch ((in.s_addr & 0xff000000) >> 24) {
|
||||
case 0: case 127: case 255:
|
||||
case 0: case 255:
|
||||
goto bad;
|
||||
}
|
||||
if (dg_broadcast(&in))
|
||||
|
Loading…
Reference in New Issue
Block a user