summaryrefslogtreecommitdiffstats
path: root/sys/netinet/ip_output.c
diff options
context:
space:
mode:
authorjulian <julian@FreeBSD.org>2006-08-17 00:37:03 +0000
committerjulian <julian@FreeBSD.org>2006-08-17 00:37:03 +0000
commit4fb1f1e2022c76cd6d80c4c885312f56e2d0a596 (patch)
tree226aa6adc40051f20816908fd88ce4cd31043f82 /sys/netinet/ip_output.c
parentb3160d204fc81f13c71edebc9d67009715c26bac (diff)
downloadFreeBSD-src-4fb1f1e2022c76cd6d80c4c885312f56e2d0a596.zip
FreeBSD-src-4fb1f1e2022c76cd6d80c4c885312f56e2d0a596.tar.gz
Remove the IPFIREWALL_FORWARD_EXTENDED option and make it on by default as it always was
in older versions of FreeBSD. This option is pointless as it is needed in just about every interesting usage of forward that I have ever seen. It doesn't make the system any safer and just wastes huge amounts of develper time when the system doesn't behave as expected when code is moved from 4.x to 6.x It doesn't make the system any safer and just wastes huge amounts of develper time when the system doesn't behave as expected when code is moved from 4.x to 6.x or 7.x Reviewed by: glebius MFC after: 1 week
Diffstat (limited to 'sys/netinet/ip_output.c')
-rw-r--r--sys/netinet/ip_output.c19
1 files changed, 5 insertions, 14 deletions
diff --git a/sys/netinet/ip_output.c b/sys/netinet/ip_output.c
index dcdc635..8efc288 100644
--- a/sys/netinet/ip_output.c
+++ b/sys/netinet/ip_output.c
@@ -457,20 +457,11 @@ sendit:
/* Or forward to some other address? */
fwd_tag = m_tag_find(m, PACKET_TAG_IPFORWARD, NULL);
if (fwd_tag) {
-#ifndef IPFIREWALL_FORWARD_EXTENDED
- if (!in_localip(ip->ip_src) && !in_localaddr(ip->ip_dst)) {
-#endif
- dst = (struct sockaddr_in *)&ro->ro_dst;
- bcopy((fwd_tag+1), dst, sizeof(struct sockaddr_in));
- m->m_flags |= M_SKIP_FIREWALL;
- m_tag_delete(m, fwd_tag);
- goto again;
-#ifndef IPFIREWALL_FORWARD_EXTENDED
- } else {
- m_tag_delete(m, fwd_tag);
- /* Continue. */
- }
-#endif
+ dst = (struct sockaddr_in *)&ro->ro_dst;
+ bcopy((fwd_tag+1), dst, sizeof(struct sockaddr_in));
+ m->m_flags |= M_SKIP_FIREWALL;
+ m_tag_delete(m, fwd_tag);
+ goto again;
}
#endif /* IPFIREWALL_FORWARD */
OpenPOWER on IntegriCloud