FreeBSD Bugzilla – Attachment 7066 Details for
Bug 15575
Bugfix of port: net/dante
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
file.diff
file.diff (text/plain), 2.90 KB, created by
anders
on 1999-12-19 23:30:01 UTC
(
hide
)
Description:
file.diff
Filename:
MIME Type:
Creator:
anders
Created:
1999-12-19 23:30:01 UTC
Size:
2.90 KB
patch
obsolete
>diff -Nur dante.old/patches/patch-aa dante/patches/patch-aa >--- dante.old/patches/patch-aa Thu Jan 1 01:00:00 1970 >+++ dante/patches/patch-aa Sun Dec 19 21:39:00 1999 >@@ -0,0 +1,76 @@ >+--- sockd/sockd_io.c.orig Thu Sep 2 12:53:05 1999 >++++ sockd/sockd_io.c Sun Dec 19 21:37:35 1999 >+@@ -44,7 +44,7 @@ >+ #include "common.h" >+ >+ static const char rcsid[] = >+-"$Id: sockd_io.c,v 1.159 1999/09/02 10:42:04 michaels Exp $"; >++"$Id: sockd_io.c,v 1.162 1999/12/16 09:01:25 michaels Exp $"; >+ >+ /* >+ * Accept io objects from mother and does io on them. We never >+@@ -819,8 +819,8 @@ >+ >+ /* >+ * If client hasn't sent us it's address yet we have to >+- * assume the first packet is from is it. Client can only >+- * blame itself if not. >++ * assume the first packet is from is it. >++ * Client can only blame itself if not. >+ */ >+ if (io->in.raddr.sin_addr.s_addr == htonl(INADDR_ANY) >+ || io->in.raddr.sin_port == htons(0)) { >+@@ -836,30 +836,19 @@ >+ >+ /* LINTED pointer casts may be troublesome */ >+ sockaddr2sockshost((struct sockaddr *)&io->in.raddr, &io->src); >+- >+- /* >+- * Do a rulecheck here with destination set to NULL, >+- * if that isn't permitted nothing else is either from >+- * this source so disconnect it. >+- */ >+- if (!rulespermit(io->in.s, &io->rule, &io->state, &io->src, >+- NULL)) { >+- delete_io(mother, io, io->in.s, IO_SRCBLOCK); >+- return; >+- } >+ } >+ >+ /* >+- * When we receive the first packet we also have a fixed >+- * source so connect the socket, both for better performance >+- * and so that getpeername() will work on it, for >+- * libwrap/rulespermit(). >++ * When we receive the first packet we also have a fixed source >++ * so connect the socket, both for better performance and so >++ * that getpeername() will work on it (libwrap/rulespermit()). >+ */ >+- if (io->in.read == 0) { /* could happend more than once, but ok. */ >++ if (io->in.read == 0) { /* could happen more than once, but ok. */ >+ /* LINTED pointer casts may be troublesome */ >+ if (!sockaddrareeq((struct sockaddr *)&io->in.raddr, &from)) { >+ char src[MAXSOCKADDRSTRING], dst[MAXSOCKADDRSTRING]; >+ >++ /* perhaps this should be LOG_DEBUG. */ >+ slog(LOG_NOTICE, >+ "%s(0): %s: expected from %s, got it from %s", >+ VERDICT_BLOCKs, protocol2string(io->state.protocol), >+@@ -871,6 +860,17 @@ >+ >+ if (connect(io->in.s, &from, sizeof(from)) != 0) { >+ delete_io(mother, io, io->in.s, IO_ERROR); >++ return; >++ } >++ >++ /* >++ * Do a rulecheck here with destination set to NULL. >++ * If that isn't permitted nothing else is either from >++ * this source so might as well disconnect it. >++ */ >++ if (!rulespermit(io->in.s, &io->rule, &io->state, &io->src, >++ NULL)) { >++ delete_io(mother, io, io->in.s, IO_SRCBLOCK); >+ return; >+ } >+ }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 15575
: 7066