Bug#680455: pptp-linux: pptp stops receiving packets when bandwidth spike
tags 680455 + patch thanks Hi Michael Thanks a lot for this report. I'll look into this one. Best regards, // Ola On Fri, Jul 06, 2012 at 10:44:56AM +1200, Michael Hudson-Doyle wrote: > Package: pptp-linux > Version: 1.7.2-6 > Severity: normal > > Dear Maintainer, > > Hi. I am reporting this bug in Debian as a favour to some Ubuntu-using > friends. While I work for Canonical I do not work on Ubuntu directly and > so apologies if I'm doing this wrong :-) > > The bug is https://bugs.launchpad.net/ubuntu/+source/pptp-linux/+bug/681617 > and the links therein indicate that upstream does not care any more. My > friend indicated that the patch helped their problem, so it seems reasonable > to ask for the patch to be included in Debian. I'll attach the debdiff > I used. > > Cheers, > mwh > > -- System Information: > Debian Release: wheezy/sid > APT prefers precise-updates > APT policy: (500, 'precise-updates'), (500, 'precise-security'), (500, > 'precise'), (100, 'precise-backports') > Architecture: amd64 (x86_64) > > Kernel: Linux 3.2.0-26-generic (SMP w/4 CPU cores) > Locale: LANG=en_NZ.UTF-8, LC_CTYPE=en_NZ.UTF-8 (charmap=UTF-8) > Shell: /bin/sh linked to /bin/dash > > Versions of packages pptp-linux depends on: > ii binutils 2.22-6ubuntu1 > ii libc6 2.15-0ubuntu10 > ii ppp 2.4.5-5ubuntu1 > > pptp-linux recommends no packages. > > pptp-linux suggests no packages. > > -- no debconf information > diff -u pptp-linux-1.7.2/pptp.c pptp-linux-1.7.2/pptp.c > --- pptp-linux-1.7.2/pptp.c > +++ pptp-linux-1.7.2/pptp.c > @@ -79,6 +79,7 @@ > int disable_buffer = 0; > int test_type = 0; > int test_rate = 100; > +int missing_window = MISSING_WINDOW; > > struct in_addr get_ip_address(char *name); > int open_callmgr(struct in_addr inetaddr, char *phonenr, int argc,char > **argv,char **envp, int pty_fd, int gre_fd); > @@ -116,13 +117,14 @@ > " --timeout Time to wait for reordered packets > (0.01 to 10 secs)\n" > " --nobuffer Disable packet buffering and reordering > completely\n" > " --idle-wait Time to wait before sending echo > request\n" > -" --max-echo-wait Time to wait before giving up > on lack of reply\n" > +" --max-echo-wait Time to wait before giving up on lack > of reply\n" > " --logstring Use instead of 'anon' in syslog > messages\n" > " --localbind Bind to specified IP address instead of > wildcard\n" > " --loglevel Sets the debugging level (0=low, > 1=default, 2=high)\n" > " --test-type Damage the packet stream by > reordering\n" > -" --test-rateDo the test every n packets\n", > - > +" --test-rateyDo the test every n packets\n" > +" --missing-window Activate 'missing window' validation > and set tolerance to packages (300=default, 6000=recommended)\n", > + > version, progname, progname); > log("%s called with wrong arguments, program not started.", progname); > exit(1); > @@ -212,6 +214,7 @@ > {"version", 0, 0, 0}, > {"test-type", 1, 0, 0}, > {"test-rate", 1, 0, 0}, > + {"missing-window", 1, 0, 0}, > {0, 0, 0, 0} > }; > int option_index = 0; > @@ -290,7 +293,21 @@ > test_type = atoi(optarg); > } else if (option_index == 14) { /* --test-rate */ > test_rate = atoi(optarg); > -} > + } else if (option_index == 15) { /* --missing window */ > + int x = atoi(optarg); > + if (x <= 0) { > + fprintf(stderr, "--missing-window must be > integer greater than zero\n"); > + log("--missing-window must be integer greater > than zero\n"); > + exit(2); > + } else if (x < 300) { > + fprintf(stderr, "--missing-window is set very > low: default=300, recommended=6000 - proceeding anyway\n"); > + log("--missing-window is set very low: > default=300, recommended=6000 - proceeding anyway\n"); > + } else { > + fprintf(stderr, "--missing-window validation is > active and set to: %d\n", x); > + log("--missing-window validation is active and > set to: %d\n", x); > + missing_window = x; > + } > + } > break; > case '?': /* unrecognised option */ > /* fall through */ > diff -u pptp-linux-1.7.2/debian/changelog pptp-linux-1.7.2/debian/changelog > --- pptp-linux-1.7.2/debian/changelog > +++ pptp-linux-1.7.2/debian/changelog > @@ -1,3 +1,9 @@ > +pptp-linux (1.7.2-6ubuntu1) precise; urgency=low > + > + *
Bug#680455: pptp-linux: pptp stops receiving packets when bandwidth spike
Package: pptp-linux Version: 1.7.2-6 Severity: normal Dear Maintainer, Hi. I am reporting this bug in Debian as a favour to some Ubuntu-using friends. While I work for Canonical I do not work on Ubuntu directly and so apologies if I'm doing this wrong :-) The bug is https://bugs.launchpad.net/ubuntu/+source/pptp-linux/+bug/681617 and the links therein indicate that upstream does not care any more. My friend indicated that the patch helped their problem, so it seems reasonable to ask for the patch to be included in Debian. I'll attach the debdiff I used. Cheers, mwh -- System Information: Debian Release: wheezy/sid APT prefers precise-updates APT policy: (500, 'precise-updates'), (500, 'precise-security'), (500, 'precise'), (100, 'precise-backports') Architecture: amd64 (x86_64) Kernel: Linux 3.2.0-26-generic (SMP w/4 CPU cores) Locale: LANG=en_NZ.UTF-8, LC_CTYPE=en_NZ.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages pptp-linux depends on: ii binutils 2.22-6ubuntu1 ii libc6 2.15-0ubuntu10 ii ppp 2.4.5-5ubuntu1 pptp-linux recommends no packages. pptp-linux suggests no packages. -- no debconf information diff -u pptp-linux-1.7.2/pptp.c pptp-linux-1.7.2/pptp.c --- pptp-linux-1.7.2/pptp.c +++ pptp-linux-1.7.2/pptp.c @@ -79,6 +79,7 @@ int disable_buffer = 0; int test_type = 0; int test_rate = 100; +int missing_window = MISSING_WINDOW; struct in_addr get_ip_address(char *name); int open_callmgr(struct in_addr inetaddr, char *phonenr, int argc,char **argv,char **envp, int pty_fd, int gre_fd); @@ -116,13 +117,14 @@ " --timeout Time to wait for reordered packets (0.01 to 10 secs)\n" " --nobuffer Disable packet buffering and reordering completely\n" " --idle-wait Time to wait before sending echo request\n" -" --max-echo-wait Time to wait before giving up on lack of reply\n" +" --max-echo-wait Time to wait before giving up on lack of reply\n" " --logstring Use instead of 'anon' in syslog messages\n" " --localbind Bind to specified IP address instead of wildcard\n" " --loglevel Sets the debugging level (0=low, 1=default, 2=high)\n" " --test-type Damage the packet stream by reordering\n" -" --test-rate Do the test every n packets\n", - +" --test-rateyDo the test every n packets\n" +" --missing-window Activate 'missing window' validation and set tolerance to packages (300=default, 6000=recommended)\n", + version, progname, progname); log("%s called with wrong arguments, program not started.", progname); exit(1); @@ -212,6 +214,7 @@ {"version", 0, 0, 0}, {"test-type", 1, 0, 0}, {"test-rate", 1, 0, 0}, + {"missing-window", 1, 0, 0}, {0, 0, 0, 0} }; int option_index = 0; @@ -290,7 +293,21 @@ test_type = atoi(optarg); } else if (option_index == 14) { /* --test-rate */ test_rate = atoi(optarg); -} + } else if (option_index == 15) { /* --missing window */ + int x = atoi(optarg); + if (x <= 0) { +fprintf(stderr, "--missing-window must be integer greater than zero\n"); +log("--missing-window must be integer greater than zero\n"); +exit(2); + } else if (x < 300) { +fprintf(stderr, "--missing-window is set very low: default=300, recommended=6000 - proceeding anyway\n"); +log("--missing-window is set very low: default=300, recommended=6000 - proceeding anyway\n"); + } else { +fprintf(stderr, "--missing-window validation is active and set to: %d\n", x); +log("--missing-window validation is active and set to: %d\n", x); +missing_window = x; + } + } break; case '?': /* unrecognised option */ /* fall through */ diff -u pptp-linux-1.7.2/debian/changelog pptp-linux-1.7.2/debian/changelog --- pptp-linux-1.7.2/debian/changelog +++ pptp-linux-1.7.2/debian/changelog @@ -1,3 +1,9 @@ +pptp-linux (1.7.2-6ubuntu1) precise; urgency=low + + * Include adj_missing_window.patch from bug #681617 + + -- Michael Hudson-Doyle Wed, 04 Jul 2012 10:29:36 +1200 + pptp-linux (1.7.2-6) unstable; urgency=low * Now depends on binutils. Closes: #587506. only in patch2: unchanged: --- pptp-linux-1.7.2.orig/pqueue.h +++ pptp-linux-1.7.2/pqueue.h @@ -9,7 +9,10 @@ extern int packet_timeout_usecs; /* assume packet is bad/spoofed if it's more than this many seqs ahead */ -#define MISSING_WINDOW 300 +/* default is NOT to check - command line override via '--missing-window '*/ +/* default value is 300 - recommended is 6000 for high speed data rates*/ +#define MISSING_WINDOW -1 +extern int missing_window; /* Packet queue structure: linked list of packets received out-of-order */ typedef struct pqueue { only in patch2: unchanged: --- pptp-linux-1.7.2.orig/pptp_gre.c +++ pptp-linux-1.7.2/pptp_