]> git.ipfire.org Git - ipfire-3.x.git/commitdiff
ppp: Update to 2.4.5.
authorMichael Tremer <michael.tremer@ipfire.org>
Fri, 14 May 2010 00:03:13 +0000 (02:03 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Fri, 14 May 2010 00:03:13 +0000 (02:03 +0200)
pkgs/core/ppp/patches/ppp-2.4.4-bogus_dns_addr.patch [deleted file]
pkgs/core/ppp/patches/ppp-2.4.4-closelog.patch [deleted file]
pkgs/core/ppp/patches/ppp-2.4.4-fix.patch [deleted file]
pkgs/core/ppp/patches/ppp-2.4.4-new_speeds.patch [deleted file]
pkgs/core/ppp/patches/ppp-2.4.4-pppoatm-mtu.patch [deleted file]
pkgs/core/ppp/patches/ppp-2.4.4-response_len.patch [deleted file]
pkgs/core/ppp/patches/ppp-2.4.5-var_run_ppp.patch [new file with mode: 0644]
pkgs/core/ppp/ppp.nm

diff --git a/pkgs/core/ppp/patches/ppp-2.4.4-bogus_dns_addr.patch b/pkgs/core/ppp/patches/ppp-2.4.4-bogus_dns_addr.patch
deleted file mode 100644 (file)
index 4af8d7e..0000000
+++ /dev/null
@@ -1,104 +0,0 @@
-diff -up ppp-2.4.4/pppd/ipcp.c.bogus_dns_addr ppp-2.4.4/pppd/ipcp.c
---- ppp-2.4.4/pppd/ipcp.c.bogus_dns_addr       2005-08-26 01:59:34.000000000 +0200
-+++ ppp-2.4.4/pppd/ipcp.c      2008-12-11 12:39:05.000000000 +0100
-@@ -715,7 +715,8 @@ ipcp_cilen(f)
- #define LENCIADDRS(neg)               (neg ? CILEN_ADDRS : 0)
- #define LENCIVJ(neg, old)     (neg ? (old? CILEN_COMPRESS : CILEN_VJ) : 0)
- #define LENCIADDR(neg)                (neg ? CILEN_ADDR : 0)
--#define LENCIDNS(neg)         (neg ? (CILEN_ADDR) : 0)
-+#define LENCIDNS(neg) LENCIADDR(neg)
-+#define LENCIWINS(neg) LENCIADDR(neg)
-     /*
-      * First see if we want to change our options to the old
-@@ -737,7 +738,9 @@ ipcp_cilen(f)
-           LENCIVJ(go->neg_vj, go->old_vj) +
-           LENCIADDR(go->neg_addr) +
-           LENCIDNS(go->req_dns1) +
--          LENCIDNS(go->req_dns2)) ;
-+          LENCIDNS(go->req_dns2) +
-+      LENCIWINS(go->winsaddr[0]) +
-+      LENCIWINS(go->winsaddr[1])) ;
- }
-@@ -810,6 +813,19 @@ ipcp_addci(f, ucp, lenp)
-       } else \
-           neg = 0; \
-     }
-+ 
-+#define ADDCIWINS(opt, addr) \
-+    if (addr) { \
-+       if (len >= CILEN_ADDR) { \
-+           u_int32_t l; \
-+           PUTCHAR(opt, ucp); \
-+           PUTCHAR(CILEN_ADDR, ucp); \
-+           l = ntohl(addr); \
-+           PUTLONG(l, ucp); \
-+           len -= CILEN_ADDR; \
-+        } else \
-+           addr = 0; \
-+    }
-     ADDCIADDRS(CI_ADDRS, !go->neg_addr && go->old_addrs, go->ouraddr,
-              go->hisaddr);
-@@ -823,6 +839,10 @@ ipcp_addci(f, ucp, lenp)
-     ADDCIDNS(CI_MS_DNS2, go->req_dns2, go->dnsaddr[1]);
-+    ADDCIWINS(CI_MS_WINS1, go->winsaddr[0]);
-+
-+    ADDCIWINS(CI_MS_WINS2, go->winsaddr[1]);
-+
-     *lenp -= len;
- }
-@@ -1159,6 +1179,15 @@ ipcp_nakci(f, p, len, treat_as_reject)
-               try.neg_addr = 1;
-           no.neg_addr = 1;
-           break;
-+  case CI_MS_WINS1:
-+  case CI_MS_WINS2:
-+      if (cilen != CILEN_ADDR)
-+         goto bad;
-+      GETLONG(l, p);
-+      ciaddr1 = htonl(l);
-+      if (ciaddr1)
-+         try.winsaddr[citype == CI_MS_WINS2] = ciaddr1;
-+      break;
-       }
-       p = next;
-     }
-@@ -1275,6 +1304,21 @@ ipcp_rejci(f, p, len)
-       try.neg = 0; \
-     }
-+#define REJCIWINS(opt, addr) \
-+    if (addr && \
-+        ((cilen = p[1]) == CILEN_ADDR) && \
-+        len >= cilen && \
-+        p[0] == opt) { \
-+        u_int32_t l; \
-+        len -= cilen; \
-+        INCPTR(2, p); \
-+        GETLONG(l, p); \
-+        cilong = htonl(l); \
-+        /* Check rejected value. */ \
-+        if (cilong != addr) \
-+            goto bad; \
-+        try.winsaddr[opt == CI_MS_WINS2] = 0; \
-+    }
-     REJCIADDRS(CI_ADDRS, !go->neg_addr && go->old_addrs,
-              go->ouraddr, go->hisaddr);
-@@ -1288,6 +1332,10 @@ ipcp_rejci(f, p, len)
-     REJCIDNS(CI_MS_DNS2, req_dns2, go->dnsaddr[1]);
-+    REJCIWINS(CI_MS_WINS1, go->winsaddr[0]);
-+
-+    REJCIWINS(CI_MS_WINS2, go->winsaddr[1]);
-+
-     /*
-      * If there are any remaining CIs, then this packet is bad.
-      */
diff --git a/pkgs/core/ppp/patches/ppp-2.4.4-closelog.patch b/pkgs/core/ppp/patches/ppp-2.4.4-closelog.patch
deleted file mode 100644 (file)
index 6866274..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-diff -up ppp-2.4.4/pppd/main.c.closelog ppp-2.4.4/pppd/main.c
---- ppp-2.4.4/pppd/main.c.closelog     2008-03-06 22:54:19.000000000 +0100
-+++ ppp-2.4.4/pppd/main.c      2008-03-06 22:54:31.000000000 +0100
-@@ -1567,6 +1567,8 @@ safe_fork(int infd, int outfd, int errfd
-       if (errfd == 0 || errfd == 1)
-               errfd = dup(errfd);
-+      closelog();
-+
-       /* dup the in, out, err fds to 0, 1, 2 */
-       if (infd != 0)
-               dup2(infd, 0);
-@@ -1575,7 +1577,6 @@ safe_fork(int infd, int outfd, int errfd
-       if (errfd != 2)
-               dup2(errfd, 2);
--      closelog();
-       if (log_to_fd > 2)
-               close(log_to_fd);
-       if (the_channel->close)
diff --git a/pkgs/core/ppp/patches/ppp-2.4.4-fix.patch b/pkgs/core/ppp/patches/ppp-2.4.4-fix.patch
deleted file mode 100644 (file)
index 85a946c..0000000
+++ /dev/null
@@ -1,139 +0,0 @@
---- ppp-2.4.3/pppd/plugins/rp-pppoe/discovery.c.fix    2004-11-04 11:07:37.000000000 +0100
-+++ ppp-2.4.3/pppd/plugins/rp-pppoe/discovery.c        2004-11-22 16:00:24.522462124 +0100
-@@ -13,6 +13,8 @@
- #include "pppoe.h"
-+void warn __P((char *, ...));   /* log a warning message */
-+
- #ifdef HAVE_SYSLOG_H
- #include <syslog.h>
- #endif
---- ppp-2.4.3/pppd/ipv6cp.c.fix        2004-11-13 03:28:15.000000000 +0100
-+++ ppp-2.4.3/pppd/ipv6cp.c    2004-11-22 16:00:27.049114044 +0100
-@@ -151,6 +151,7 @@
-  */
- #include <stdio.h>
-+#include <stdlib.h>
- #include <string.h>
- #include <unistd.h>
- #include <netdb.h>
-@@ -1064,7 +1065,9 @@
-     return (rc);                      /* Return final code */
- }
--
-+#if defined(SOL2) || defined(__linux__)
-+int ether_to_eui64(eui64_t *p_eui64);
-+#endif
- /*
-  * ipv6_check_options - check that any IP-related options are OK,
-  * and assign appropriate defaults.
---- ppp-2.4.3/include/linux/if_pppox.h.fix     2001-12-15 01:34:24.000000000 +0100
-+++ ppp-2.4.3/include/linux/if_pppox.h 2004-11-22 16:00:27.049114044 +0100
-@@ -18,7 +18,7 @@
- #include <asm/types.h>
--#include <asm/byteorder.h>
-+#include <endian.h>
- #ifdef  __KERNEL__
- #include <linux/if_ether.h>
-@@ -97,10 +97,10 @@
- #define PTT_GEN_ERR   __constant_htons(0x0203)
- struct pppoe_hdr {
--#if defined(__LITTLE_ENDIAN_BITFIELD)
-+#if __BYTE_ORDER == __LITTLE_ENDIAN
-       __u8 ver : 4;
-       __u8 type : 4;
--#elif defined(__BIG_ENDIAN_BITFIELD)
-+#elif __BYTE_ORDER == __BIG_ENDIAN
-       __u8 type : 4;
-       __u8 ver : 4;
- #else
---- ppp-2.4.3/pppdump/deflate.c.fix    2004-02-02 04:36:46.000000000 +0100
-+++ ppp-2.4.3/pppdump/deflate.c        2004-11-22 16:02:18.071820020 +0100
-@@ -39,6 +39,7 @@
- #include <sys/types.h>
- #include <stdio.h>
- #include <stddef.h>
-+#include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
- #include "ppp_defs.h"
-@@ -237,8 +238,8 @@
- {
-     struct deflate_state *state = (struct deflate_state *) arg;
-     u_char *rptr, *wptr;
--    int rlen, olen, ospace;
--    int seq, i, flush, r, decode_proto;
-+    int rlen, olen;
-+    int seq, r;
-     rptr = mi;
-     if (*rptr == 0)
---- ppp-2.4.3/pppdump/bsd-comp.c.fix   2004-02-02 04:36:46.000000000 +0100
-+++ ppp-2.4.3/pppdump/bsd-comp.c       2004-11-22 16:00:27.052113631 +0100
-@@ -383,7 +383,7 @@
-       || options[0] != CI_BSD_COMPRESS || options[1] != CILEN_BSD_COMPRESS
-       || BSD_VERSION(options[2]) != BSD_CURRENT_VERSION
-       || BSD_NBITS(options[2]) != db->maxbits
--      || decomp && db->lens == NULL)
-+      || (decomp && db->lens == NULL))
-       return 0;
-     if (decomp) {
-@@ -556,11 +556,11 @@
-     u_int n_bits = db->n_bits;
-     u_int tgtbitno = 32-n_bits;       /* bitno when we have a code */
-     struct bsd_dict *dictp;
--    int explen, i, seq, len;
-+    int explen, seq, len;
-     u_int incode, oldcode, finchar;
-     u_char *p, *rptr, *wptr;
-     int ilen;
--    int dlen, space, codelen, extra;
-+    int dlen=0, codelen, extra;
-     rptr = cmsg;
-     if (*rptr == 0)
-@@ -616,7 +616,7 @@
-       }
-       if (incode > max_ent + 2 || incode > db->maxmaxcode
--          || incode > max_ent && oldcode == CLEAR) {
-+          || (incode > max_ent && oldcode == CLEAR)) {
-           if (db->debug) {
-               printf("bsd_decomp%d: bad code 0x%x oldcode=0x%x ",
-                      db->unit, incode, oldcode);
---- ppp-2.4.3/pppdump/pppdump.c.fix    2004-02-02 04:36:46.000000000 +0100
-+++ ppp-2.4.3/pppdump/pppdump.c        2004-11-22 16:00:27.054113356 +0100
-@@ -34,6 +34,7 @@
-  * OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-  */
- #include <stdio.h>
-+#include <stdlib.h>
- #include <unistd.h>
- #include <stdlib.h>
- #include <time.h>
-@@ -191,7 +192,7 @@
-           show_time(f, c);
-           break;
-       default:
--          printf("?%.2x\n");
-+          printf("?%.2x\n", c);
-       }
-     }
- }
-@@ -421,7 +422,7 @@
-           show_time(f, c);
-           break;
-       default:
--          printf("?%.2x\n");
-+          printf("?%.2x\n", c);
-       }
-     }
- }
diff --git a/pkgs/core/ppp/patches/ppp-2.4.4-new_speeds.patch b/pkgs/core/ppp/patches/ppp-2.4.4-new_speeds.patch
deleted file mode 100644 (file)
index 99816f7..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-diff -up ppp-2.4.4/pppd/sys-linux.c.new_speeds ppp-2.4.4/pppd/sys-linux.c
---- ppp-2.4.4/pppd/sys-linux.c.new_speeds      2008-05-12 17:44:11.000000000 -0400
-+++ ppp-2.4.4/pppd/sys-linux.c 2008-05-12 17:50:51.000000000 -0400
-@@ -849,6 +849,30 @@ struct speed {
- #ifdef B921600
-     { 921600, B921600 },
- #endif
-+#ifdef B1000000
-+    { 1000000, B1000000 },
-+#endif
-+#ifdef B1152000
-+    { 1152000, B1152000 },
-+#endif
-+#ifdef B1500000
-+    { 1500000, B1500000 },
-+#endif
-+#ifdef B2000000
-+    { 2000000, B2000000 },
-+#endif
-+#ifdef B2500000
-+    { 2500000, B2500000 },
-+#endif
-+#ifdef B3000000
-+    { 3000000, B3000000 },
-+#endif
-+#ifdef B3500000
-+    { 3500000, B3500000 },
-+#endif
-+#ifdef B4000000
-+    { 4000000, B4000000 },
-+#endif
-     { 0, 0 }
- };
diff --git a/pkgs/core/ppp/patches/ppp-2.4.4-pppoatm-mtu.patch b/pkgs/core/ppp/patches/ppp-2.4.4-pppoatm-mtu.patch
deleted file mode 100644 (file)
index 085f398..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
---- ppp-2.4.2/pppd/plugins/pppoatm/pppoatm.c.mtu       2004-10-07 13:32:05.660910432 +0100
-+++ ppp-2.4.2/pppd/plugins/pppoatm/pppoatm.c   2004-10-07 13:58:20.096559832 +0100
-@@ -175,8 +175,10 @@
- {
-       int sock;
-       struct ifreq ifr;
--      if (mtu > pppoatm_max_mtu)
--              error("Couldn't increase MTU to %d", mtu);
-+      if (pppoatm_max_mtu && mtu > pppoatm_max_mtu) {
-+              warn("Couldn't increase MTU to %d. Using %d", mtu, pppoatm_max_mtu);
-+              mtu = pppoatm_max_mtu;
-+      }
-       sock = socket(AF_INET, SOCK_DGRAM, 0);
-       if (sock < 0)
-               fatal("Couldn't create IP socket: %m");
-@@ -192,8 +194,10 @@
-                             int pcomp,
-                             int accomp)
- {
--      if (mru > pppoatm_max_mru)
--              error("Couldn't increase MRU to %d", mru);
-+      if (pppoatm_max_mru && mru > pppoatm_max_mru) {
-+              warn("Couldn't increase MRU to %d. Using %d", mru, pppoatm_max_mru);
-+              mru = pppoatm_max_mru;
-+      }
- }
- void plugin_init(void)
diff --git a/pkgs/core/ppp/patches/ppp-2.4.4-response_len.patch b/pkgs/core/ppp/patches/ppp-2.4.4-response_len.patch
deleted file mode 100644 (file)
index 27e082b..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-diff -up ppp-2.4.4/pppd/chap_ms.c.response_len ppp-2.4.4/pppd/chap_ms.c
---- ppp-2.4.4/pppd/chap_ms.c.response_len      2008-03-06 23:07:18.000000000 +0100
-+++ ppp-2.4.4/pppd/chap_ms.c   2008-03-06 23:07:49.000000000 +0100
-@@ -852,7 +852,7 @@ ChapMS2(u_char *rchallenge, u_char *Peer
-     u_char *p = &response[MS_CHAP2_PEER_CHALLENGE];
-     int i;
--    BZERO(response, sizeof(*response));
-+    BZERO(response, MS_CHAP2_RESPONSE_LEN);
-     /* Generate the Peer-Challenge if requested, or copy it if supplied. */
-     if (!PeerChallenge)
diff --git a/pkgs/core/ppp/patches/ppp-2.4.5-var_run_ppp.patch b/pkgs/core/ppp/patches/ppp-2.4.5-var_run_ppp.patch
new file mode 100644 (file)
index 0000000..2c49927
--- /dev/null
@@ -0,0 +1,30 @@
+diff -up ppp-2.4.5/pppd/pathnames.h.var_run_ppp ppp-2.4.5/pppd/pathnames.h
+--- ppp-2.4.5/pppd/pathnames.h.var_run_ppp     2010-02-12 16:36:14.479362718 +0100
++++ ppp-2.4.5/pppd/pathnames.h 2010-02-12 16:38:24.995330994 +0100
+@@ -7,9 +7,13 @@
+ #ifdef HAVE_PATHS_H
+ #include <paths.h>
++#define _SUBPATH_PPP       "ppp/"
+ #else /* HAVE_PATHS_H */
+ #ifndef _PATH_VARRUN
+ #define _PATH_VARRUN  "/etc/ppp/"
++#define _SUBPATH_PPP
++#else
++#define _SUBPATH_PPP       "ppp/"
+ #endif
+ #define _PATH_DEVNULL "/dev/null"
+ #endif /* HAVE_PATHS_H */
+@@ -46,10 +50,10 @@
+ #endif /* IPX_CHANGE */
+ #ifdef __STDC__
+-#define _PATH_PPPDB   _ROOT_PATH _PATH_VARRUN "pppd2.tdb"
++#define _PATH_PPPDB   _ROOT_PATH _PATH_VARRUN _SUBPATH_PPP "pppd2.tdb"
+ #else /* __STDC__ */
+ #ifdef HAVE_PATHS_H
+-#define _PATH_PPPDB   "/var/run/pppd2.tdb"
++#define _PATH_PPPDB   "/var/run/ppp/pppd2.tdb"
+ #else
+ #define _PATH_PPPDB   "/etc/ppp/pppd2.tdb"
+ #endif
index 5df5344f6c7e280e36dd75afef00e81ea9e19113..a5ff6db4db99fb3764f134af4f3c0301031dec28 100644 (file)
@@ -25,7 +25,7 @@
 include $(PKGROOT)/Include
 
 PKG_NAME       = ppp
-PKG_VER        = 2.4.4
+PKG_VER        = 2.4.5
 PKG_REL        = 0
 
 PKG_MAINTAINER =