openwrtv3/package/network/services
Jo-Philipp Wich 5380fa27e9 ppp: correct module loaded check in proto_pptp_setup
proto_pptp_setup is responsible for loading the required modules to establish
a pptp connection to a foreign peer. The function checks whether all required
modules are already loaded, before actually loading them.

It seems that the filter being used to accomplish this, is not restrictive
enough in some cases. For instance when pptp nat helper modules are present on
a system, and already loaded before a pptp connection is enabled. Then the
search filter (possibly) returns the following for module=pptp, where actually
no matches are expected, resulting in the pptp.ko module not being loaded,
thereby failing to establish the pptp connection.

# module="pptp" ; grep "$module" /proc/modules
nf_nat_pptp 1312 0 - Live 0x86ce7000
nf_conntrack_pptp 3072 1 nf_nat_pptp, Live 0x86cb9000
nf_nat_proto_gre 784 1 nf_nat_pptp, Live 0x86cba000
nf_conntrack_proto_gre 2368 1 nf_conntrack_pptp, Live 0x86cbf000
nf_nat 9792 13 nf_nat_rtsp,nf_nat_tftp,nf_nat_sip,nf_nat_pptp,nf_nat_h323,nf_nat_proto_gre,nf_nat_amanda,nf_nat_irc,nf_nat_ftp,ipt_REDIRECT,ipt_NETMAP,ipt_MASQUERADE,iptable_nat, Live 0x86ca8000
nf_conntrack 37264 31 nf_nat_rtsp,nf_conntrack_rtsp,nf_nat_tftp,nf_conntrack_tftp,nf_nat_snmp_basic,nf_conntrack_snmp,nf_nat_sip,nf_conntrack_sip,nf_nat_pptp,nf_conntrack_pptp,nf_nat_h323,nf_conntrack_h323,nf_conntrack_proto_gre,nf_nat_amanda,nf_conntrack_amanda,nf_conntrack_broadcast,nf_nat_irc,nf_conntrack_irc,nf_nat_ftp,nf_conntrack_ftp,ipt_MASQUERADE,iptable_nat,nf_nat,xt_helper,xt_connmark,xt_connbytes,xt_conntrack,xt_CT,xt_NOTRACK,xt_state,nf_conntrack_ipv4, Live 0x86c90000

The search filter can be made more accurate/restrictive, by requiring the
occurance of the exact name of the module at the beginning of a line in
/proc/modules.

# module="pptp" ; grep "^$module " /proc/modules
pptp 13296 2 - Live 0x86e80000

Signed-off-by: Tijs Van Buggenhout <tvb@able.be>

SVN-Revision: 38358
2013-10-10 14:58:12 +00:00
..
authsae authsae: add myself as a maintainer 2013-07-26 10:03:03 +00:00
dnsmasq fix various init scripts 2013-09-23 21:58:36 +00:00
dropbear dropbear: update to 2013.59 (released 4 october 2013) 2013-10-10 14:42:05 +00:00
ead ead: fix compile errors with recent kernels 2013-07-20 12:56:07 +00:00
hostapd hostapd: recognize 8021x as an authentication mode 2013-10-08 11:09:52 +00:00
ipset-dns procd: convert various packages to procd style init.d scripts 2013-09-17 21:45:30 +00:00
lldpd lldpd: Add libbsd dependency when using eglibc 2013-08-25 18:47:08 +00:00
openvpn openvpn: rework initscript (fixes #14299) 2013-10-09 11:25:09 +00:00
openvpn-easy-rsa openvpn-easy-rsa: fix typo in version (#12958) 2013-02-06 22:17:11 +00:00
ppp ppp: correct module loaded check in proto_pptp_setup 2013-10-10 14:58:12 +00:00
relayd fix various init scripts 2013-09-23 21:58:36 +00:00
samba36 build: consistently use 'depends on' instead of 'depends' 2013-04-17 15:36:41 +00:00
uhttpd uhttpd: add a config option for using ustream-polarssl, and use it by default 2013-09-29 11:26:09 +00:00