rpms/ppp/devel ppp-2.4.4-bogus_dns_addr.patch, NONE, 1.1 ppp.spec, 1.46, 1.47
Jiri Skala
jskala at fedoraproject.org
Thu Dec 11 11:52:46 UTC 2008
- Previous message: rpms/lpsk31/devel lpsk31-1.1-wrapper.in, NONE, 1.1 lpsk31.spec, 1.1, 1.2
- Next message: rpms/kdelibs/devel .cvsignore, 1.62, 1.63 kdelibs.spec, 1.398, 1.399 sources, 1.76, 1.77
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: jskala
Update of /cvs/extras/rpms/ppp/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv1321
Modified Files:
ppp.spec
Added Files:
ppp-2.4.4-bogus_dns_addr.patch
Log Message:
* Thu Dec 11 2008 Jiri Skala <jskala at redhat.com> 2.4.4.-9
- fixed #467004 PPP sometimes gets incorrect DNS servers for mobile broadband connections
ppp-2.4.4-bogus_dns_addr.patch:
--- NEW FILE ppp-2.4.4-bogus_dns_addr.patch ---
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.
*/
Index: ppp.spec
===================================================================
RCS file: /cvs/extras/rpms/ppp/devel/ppp.spec,v
retrieving revision 1.46
retrieving revision 1.47
diff -u -r1.46 -r1.47
--- ppp.spec 28 Aug 2008 21:44:37 -0000 1.46
+++ ppp.spec 11 Dec 2008 11:52:16 -0000 1.47
@@ -1,7 +1,7 @@
Summary: The PPP (Point-to-Point Protocol) daemon.
Name: ppp
Version: 2.4.4
-Release: 8%{?dist}
+Release: 9%{?dist}
License: BSD and LGPLv2+ and GPLv2+ and Public Domain
Group: System Environment/Daemons
Source0: ftp://ftp.samba.org/pub/ppp/ppp-%{version}.tar.gz
@@ -27,6 +27,7 @@
Patch24: ppp-2.4.4-closelog.patch
Patch25: ppp-2.4.4-response_len.patch
Patch26: ppp-2.4.4-new_speeds.patch
+Patch27: ppp-2.4.4-bogus_dns_addr.patch
BuildRoot: %{_tmppath}/%{name}-root
BuildPrereq: pam-devel, libpcap-devel
@@ -70,6 +71,7 @@
%patch24 -p1 -b .closelog
%patch25 -p1 -b .response_len
%patch26 -p1 -b .new_speeds
+%patch27 -p1 -b .bogus_dns_addr
rm -f scripts/*.local
rm -f scripts/*.change_resolv_conf
@@ -134,6 +136,9 @@
%doc PLUGINS
%changelog
+* Thu Dec 11 2008 Jiri Skala <jskala at redhat.com> 2.4.4.-9
+- fixed #467004 PPP sometimes gets incorrect DNS servers for mobile broadband connections
+
* Thu Aug 28 2008 Tom "spot" Callaway <tcallawa at redhat.com> 2.4.4-8
- fix license tag
- Previous message: rpms/lpsk31/devel lpsk31-1.1-wrapper.in, NONE, 1.1 lpsk31.spec, 1.1, 1.2
- Next message: rpms/kdelibs/devel .cvsignore, 1.62, 1.63 kdelibs.spec, 1.398, 1.399 sources, 1.76, 1.77
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the scm-commits
mailing list