• Home
  • History
  • Annotate
  • Line#
  • Navigate
  • Raw
  • Download
  • only in /asuswrt-rt-n18u-9.0.0.4.380.2695/release/src-rt-6.x.4708/router/accel-pptpd/pptpd-1.3.3/html/poptop_ads_howto/
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
2"http://www.w3.org/TR/html4/loose.dtd">
3<html>
4<head>
5<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
6<title>Poptop MSCHAP2 ADS Howto</title>
7</head>
8
9<body>
10<p><strong>14. pptpd and freeradius </strong></p>
11<p>The section covers the configuration of pptpd + freeradius + AD. If you are looking at the integration via winbind. Go to <a href="poptop_ads_howto_7.htm">this section</a>.</p>
12<hr>
13<a name="radiusd"></a><strong>14.1 Enable freeradius</strong>
14<p>To enable radiusd on bootup, use the chkconfig command.</p>
15<blockquote>
16  <pre>[root@pptp ~]# chkconfig radiusd on </pre>
17</blockquote>
18<p>To start radiusd in daemon mode:
19</p>
20<blockquote>
21  <pre>[root@pptp ~]# service radiusd start
22Starting RADIUS server: Sun Sep  4 11:26:24 2005 : Info: Starting - reading configuration files ...<br>[  OK  ]</pre>
23</blockquote>
24<p></p>
25<hr>
26<a name="pptpdradius"></a><strong>14.2 Configure pptpd </strong>
27<p>There are two configuration files for pptpd. The first one is /etc/pptpd.conf. You can very much keep it as it is except the ip address range for the ppp connections. Edit the file and add two lines at the bottom to specify the local ip address and the ip address pool for the remote connections. </p>
28<blockquote>
29  <pre>localip 10.0.0.10<br>remoteip 10.0.0.101-200 </pre>
30</blockquote>
31<p>10.0.0.10 is the ip address of the internal network card eth0. The remoteip is the address pool for the remote connections. </p>
32<p>The second configuration file is /etc/ppp/options.pptpd. I stripped off all remarks from my options.pptpd and it is like this:</p>
33<blockquote>
34  <pre>name pptpd
35refuse-pap<br>refuse-chap<br>refuse-mschap<br>require-mschap-v2<br>require-mppe-128
36ms-dns 10.0.0.1
37ms-wins 10.0.0.1
38proxyarp
39lock
40nobsdcomp
41novj
42novjccomp
43nologfd
44auth
45nodefaultroute
46plugin radius.so
47plugin radattr.so</pre>
48</blockquote>
49<p>There are two plugins we used in here. The first one radius.so is required while the second one radattr.so is optional. Radattr.so basically records the parameters passed from radius to pppd in a file. Check the man page of pppd-radattr for details. </p>
50<p>Then, we need to fix the permission of a winbind directory.</p>
51<blockquote>
52  <pre>[root@pptp ~]# chgrp radiusd /var/cache/samba/winbindd_privileged/</pre>
53</blockquote>
54<p>If you have Windows XP clients, you may want to reduce the MTU size. Add the  line, /sbin/ifconfig $1 mtu 1400, to /etc/ppp/ip-up as shown in the following list.</p>
55<blockquote>
56  <pre>[root@pptp ppp]# cat ip-up
57#!/bin/bash
58# This file should not be modified -- make local changes to
59# /etc/ppp/ip-up.local instead
60
61PATH=/sbin:/usr/sbin:/bin:/usr/bin
62export PATH
63
64LOGDEVICE=$6
65REALDEVICE=$1
66
67[ -f /etc/sysconfig/network-scripts/ifcfg-${LOGDEVICE} ] && /etc/sysconfig/network-scripts/ifup-post ifcfg-${LOGDEVICE}
68
69/etc/ppp/ip-up.ipv6to4 ${LOGDEVICE}
70
71[ -x /etc/ppp/ip-up.local ] && /etc/ppp/ip-up.local "$@"
72
73<strong>/sbin/ifconfig $1 mtu 1400</strong>
74exit 0</pre>
75</blockquote>
76<p>The above example reduces the MTU size to 1400. In my environment, I found that XP will connect the VPN and ping all servers without problems, however, it cannot connect to the Microsoft Exchange server properly. Reduce the MTU size to 1400 fixed the problem.</p>
77<p>After fixing the files and permission, we can start pptpd and connect to it from remote client. To start it:</p>
78<blockquote>
79  <pre>[root@pptp ~]# chkconfig pptpd on<br><br>[root@pptp ~]# service pptpd start<br>Starting pptpd: [  OK  ]	 </pre>
80</blockquote>
81<p>That's all on the server side. </p>
82<p><strong>Note</strong>: The client PCs require special configurations. It will be discussed in <a href="poptop_ads_howto_11.htm">here</a>.</p>
83<hr>
84<a href="poptop_ads_howto_11.htm">Next</a> &nbsp;&nbsp;<a href="poptop_ads_howto_9.htm">Previous</a>&nbsp;&nbsp;<a href="poptop_ads_howto_1.htm#toc">Content</a>
85<p>&nbsp;</p>
86</body>
87</html>
88