set MTU on tunnel interface so the kernel will re-fragment large packets to within MRU
authorbodea <bodea>
Thu, 17 Nov 2005 07:35:35 +0000 (07:35 +0000)
committerbodea <bodea>
Thu, 17 Nov 2005 07:35:35 +0000 (07:35 +0000)
Changes
l2tpns.c
l2tpns.h
l2tpns.spec

diff --git a/Changes b/Changes
index 40f7944..f39d9d5 100644 (file)
--- a/Changes
+++ b/Changes
@@ -1,3 +1,9 @@
+* Thu Nov 17 2005 Brendan O'Dea <bod@optus.net> 2.1.12
+- Set MTU on tunnel interface so the kernel will re-fragment large
+  packets to within MRU.
+- Fix TCP checksum recalc.
+- NAK silly MRU values for peer.
+
 * Mon Nov 14 2005 Brendan O'Dea <bod@optus.net> 2.1.11
 - Fix fragment handling in ip_filter.
 - Exclude counter when comparing filter rules.
index 6effc9f..39f72d7 100644 (file)
--- a/l2tpns.c
+++ b/l2tpns.c
@@ -4,7 +4,7 @@
 // Copyright (c) 2002 FireBrick (Andrews & Arnold Ltd / Watchfront Ltd) - GPL licenced
 // vim: sw=8 ts=8
 
-char const *cvs_id_l2tpns = "$Id: l2tpns.c,v 1.149 2005/11/17 06:46:24 bodea Exp $";
+char const *cvs_id_l2tpns = "$Id: l2tpns.c,v 1.150 2005/11/17 07:35:35 bodea Exp $";
 
 #include <arpa/inet.h>
 #include <assert.h>
@@ -554,6 +554,13 @@ static void inittun(void)
                LOG(0, 0, 0, "Error setting tun queue length: %s\n", strerror(errno));
                exit(1);
        }
+       /* set MTU to modem MRU + 4 (tun header) */
+       ifr.ifr_mtu = MRU + 4;
+       if (ioctl(ifrfd, SIOCSIFMTU, (void *) &ifr) < 0)
+       {
+               LOG(0, 0, 0, "Error setting tun MTU: %s\n", strerror(errno));
+               exit(1);
+       }
        ifr.ifr_flags = IFF_UP;
        if (ioctl(ifrfd, SIOCSIFFLAGS, (void *) &ifr) < 0)
        {
index 1412cbd..6efb15f 100644 (file)
--- a/l2tpns.h
+++ b/l2tpns.h
@@ -1,5 +1,5 @@
 // L2TPNS Global Stuff
-// $Id: l2tpns.h,v 1.98 2005/11/14 08:38:02 bodea Exp $
+// $Id: l2tpns.h,v 1.99 2005/11/17 07:35:35 bodea Exp $
 
 #ifndef __L2TPNS_H__
 #define __L2TPNS_H__
@@ -15,7 +15,7 @@
 #include <sys/types.h>
 #include <libcli.h>
 
-#define VERSION        "2.1.11"
+#define VERSION        "2.1.12"
 
 // Limits
 #define MAXTUNNEL      500             // could be up to 65535
index 65d22dd..be68d99 100644 (file)
@@ -1,6 +1,6 @@
 Summary: A high-speed clustered L2TP LNS
 Name: l2tpns
-Version: 2.1.11
+Version: 2.1.12
 Release: 1
 Copyright: GPL
 Group: System Environment/Daemons
@@ -43,5 +43,5 @@ rm -rf %{buildroot}
 %attr(644,root,root) /usr/share/man/man[58]/*
 
 %changelog
-* Mon Nov 14 2005 Brendan O'Dea <bod@optus.net> 2.1.11-1
-- 2.1.11 release, see /usr/share/doc/l2tpns-2.1.11/Changes
+* Thu Nov 17 2005 Brendan O'Dea <bod@optus.net> 2.1.12-1
+- 2.1.12 release, see /usr/share/doc/l2tpns-2.1.12/Changes