summaryrefslogtreecommitdiff
path: root/os
diff options
context:
space:
mode:
authorJesse Adkins <jesse_adkins7@yahoo.com>2009-08-18 21:13:40 -0700
committerAlan Coopersmith <alan.coopersmith@sun.com>2009-08-18 21:13:40 -0700
commit75b9383d8a4c113ab3c6cfc1d5efcb5d9982a1bf (patch)
treeb4cf6928102000d0fab3bea8c020957b0eba9d98 /os
parent2d34eace13c2016048c627c4e96c3b2399901078 (diff)
xserver doesn't stop all connections to localhost
X.Org Bugzilla #23329: http://bugs.freedesktop.org/show_bug.cgi?id=23329 Patch #28648: http://bugs.freedesktop.org/attachment.cgi?id=28648 I noticed in xserver at os/access.c that xorg tries to stop connections to localhost by checking against the address 127.0.0.1. However, RFC 3330 defines the localhost network as 127.0.0.0/8. This means that any IPv4 address that starts with 127 is just another name for localhost.
Diffstat (limited to 'os')
-rw-r--r--os/access.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/os/access.c b/os/access.c
index 65765799b..8c5b50af0 100644
--- a/os/access.c
+++ b/os/access.c
@@ -415,8 +415,7 @@ DefineSelf (int fd)
*/
if (family == FamilyInternet &&
!(len == 4 &&
- ((addr[0] == 127 && addr[1] == 0 &&
- addr[2] == 0 && addr[3] == 1) ||
+ ((addr[0] == 127) ||
(addr[0] == 0 && addr[1] == 0 &&
addr[2] == 0 && addr[3] == 0)))
)