SourceForge Logo
opensource.hp.com Link to Linux and HP web site
project
 overview
 license
 getting started
 features
 try it
 download
 links
documentation
 index
 debian
 fedora core 1
 fedora core 2
 fedora core 3
 fedora core 4
 fedora core 5
 fedora core 6
 gentoo
 knoppix
 mandrake 9.0
 mandrake 10.0
 mandrake 10.1
 netbsd
 red hat 9
 red hat 8.0
 red hat 7.3
 suse 10.0
 suse 9.2
 suse 9.1
 suse 8.2
 ubuntu
 diagnosis
 support faq
 diagrams
 routing
 security
team
 developers
 cvs
 contact us
 

PPTP Client


Diagnosis HOWTO

by James Cameron
12th April 2006

You're probably here because you have a problem getting PPTP Client to work. There are many reasons why it can fail. Other people may have encountered the problem you have.

This HOWTO is a series of known problems in installation and running order. When the PPTP Client fails, it will display an error message. Search for the message in this page.

For some error messages, more detail will need to be gathered. This is done by enabling debug logging.

Near the end of the document, we also show a fault tree, and some additional documentation for using tools to determine what your problem is.

We thank the many contributors to this page. If you think you've found a solution to a common problem, please write it up in our problem, diagnosis, solution format, and submit it to the mailing list.


Contents


Conventions

Conventions used in this document:

italic text, a program name or option keyword

monospaced text, a file name

blue background, error messages or log output

green background, commands to be entered

red background, quotation

yellow background with black vertical "change bar" on right hand side, text changed in this revision (or the last month)


Installing kernel modules


Installing pppd


Installing pptp


Installing pptpconfig


Running pptpconfig


Running pptp-command


Running pptp


Running pppd (before connection)


Running pppd (during connection)


Running pppd (after connection)


Loading kernel modules

Other Problems



Fault Tree


  1. Ping PPTP Server

    Prove that you can bounce ICMP echo request packets off the PPTP Server. If you can, this shows you have a network connection to it. If you can't, it doesn't prove anything, because it could be firewalled.

    # ping pptpserver


  2. Traceroute to PPTP Server

    Prove that you can trace the route to the PPTP Server. If you can, this shows you have a network connection to it. If you can't, again it doesn't prove anything, because it could be firewalled. However, only you can tell, given your knowledge of the network near you.

    # traceroute pptpserver


  3. Connect to port 1723 on PPTP Server

    Prove that you can connect to the PPTP Server on the TCP/IP port used for call management. If you can, this shows you have half the network connectivity you need. If you can't, you must fix the problem.

    # telnet pptpserver 1723


  4. Check GRE Works

    Prove that you can exchange GRE packets between the PPTP Server and the client. To do this, run a packet tracing tool such as tcpdump at the client while starting the tunnel. You should see a connection to port 1723, followed by GRE packets in both directions. If you are new to tcpdump, we have instructions.

    For diagnosing the point at which GRE is lost in a network path;

    Note: these days with the profusion of cheap consumer-grade NAT routers and gateways, hping2 and GRE traceroute do not work as well as one would like. This is because most NAT routers use stateful inspection of the PPTP control connection to determine how and when to forward the GRE packets. Concentrate on block-box analysis using tcpdump at the end points you have access to.

    2006-04-12

    Common GRE blockages are as follows:

    • Firewalls and Gateways

      Hosts between your client and the server through which GRE must pass may be configured to block GRE. Using the GRE traceroute programs above you may be able to identify the host that is causing the block.

    • Local Filtering Rules

      The client may be configured to block GRE packets as they arrive, or before they depart. Check your iptables or ipchains configuration.

    • Simultaneous Tunnels via NAT Gateway

      If you have a NAT gateway, such as a DSL router, that presents one IP address to the network on which the PPTP Server is contacted, then only one PPTP connection can be active at once. The PPTP Server will only accept one.

      Attempting to start a second tunnel to another IP address may also fail if the NAT software cannot differentiate the two connections. This may cause the first connection to fail.

    • PPTP Server Misconfiguration

      If the PPTP Server fails to start pppd because of a syntax error in the options file or command line, the effect mimics a total loss of GRE packets from the server end. Check the server logs carefully. Start pppd manually at the server to test the options.


  5. Check MPPE Support

    MPPE support is required if you wish to connect to a PPTP Server such as Microsoft Windows VPN Server. MPPE is built as a Linux kernel module, as part of PPP 2.4.2 or later, and as a patch to the PPP 2.4.0.

    Both of the following tests must pass for MPPE support to function.


  6. Check MPPE in kernel Support

    Make sure the MPPE module can be loaded:

    # modprobe ppp-compress-18

    If this module loads without error, then all is well with it. If errors are generated, you must find the cause and fix it. There are numerous causes of a failure to load. Some of the causes are;

    1. depmod -a was not run after loading a kernel-mppe rpm,
    2. the MPPE module cannot be found in the appropriate /lib/modules directory,
    3. the MPPE module that was found cannot be loaded because of version conflicts,

    1. an old mppe.o file was left around after an upgrade that provided an ppp_mppe.o file (which results in "init_module: File exists" error if the mppe.o module is loaded somehow),
    2003-08-01

    1. the ppp_generic module cannot activate the MPPE module when it finds it needs it, because you are using PPP-MPPE 2.4.0 and the /etc/modules.conf file does not have an entry for alias ppp-compress-18 mppe,
    2. the PPP modules were compiled into the kernel statically (they must be modules for MPPE to work as a module),
    3. the ppp_async module cannot be loaded (although pptp does not use a serial port, the ppp_async module is required for data transfer with the psuedo-tty device).

  7. Check MPPE in pppd Support

    Make sure the pppd program contains MPPE support by checking for option keywords in the file. If it contains MPPE options, then it has MPPE support. If it has no MPPE options, you must obtain or build an MPPE capable version.

    # strings `which pppd`|grep -i mppe|wc --lines

    For a pppd without MPPE support, the number displayed is zero. For an MPPE capable pppd, the number is about 38, but may vary.


Why are the pppd options different?

PPTP Client depends on PPP. See our diagrams for why. PPP needs MPPE support to interoperate with certain PPTP servers.

There are three PPP MPPE versions, and their history is shown in the graph below:

PPP History Graph

There are two parts to the PPP MPPE support, for each version. One part is in the kernel, and the other part is in the pppd program. These two parts must be the same general version. If they are mixed, the result can be that the pppd program reports the kernel has no support.

Comparing the two versions in detail:

PPP-MPPE 2.4.0

  • no further development?
  • no response to problems
  • has known problems such as kernel panics
  • OpenSSL license directly conflicts with kernel license
  • when loaded, does not indicate a license conflict
  • requires /etc/modules.conf changes
  • module file name mppe.o (or ppp_mppe.o)
  • +mppe-128 (inconsistent with existing option names)
  • mppe-stateless
  • require-chapms-v2 (incorrect protocol name)
PPP 2.4.2 and later

  • ongoing development by PPP project
  • active response to problems by developers
  • has no known problems at this time (stay tuned)
  • BSD license does not conflict (as much) with kernel license
  • when loaded, indicates a license conflict
  • requires no /etc/modules.conf changes
  • module file name ppp_mppe.o
  • require-mppe-128
  • nomppe-stateful
  • require-mschap-v2
The two versions of pppd have different command line options.

If you are upgrading from the old PPP-MPPE 2.4.0 package, change /etc/ppp/options.pptp, and any existing tunnels in /etc/ppp/peers, to adopt correct naming for pppd options relating to MPPE support.

The following table compares the options between the versions.

PPP-MPPE 2.4.0 option PPP 2.4.2 option Explanation
mppe-40 require-mppe require-mppe requires the use of MPPE, disabling all other compression types, and enabling both 40-bit and 128-bit encryption. It is then up to the server what level of encryption is adopted. require-mppe-40 and require-mppe-128 are like require-mppe but use 40-bit and 128-bit encryption respectively, rather than allowing the server to choose.
mppe-128 require-mppe
mppe-stateless nomppe-stateful Stateless is now the default, you'd have to use mppe-stateful to turn it off.
require-chapms-v2 refuse-pap refuse-chap refuse-mschap refuse-eap A client cannot require a method of authentication of itself, but it can refuse a method offered. The "require" forms of these options are intended for use by servers, and if used on a client will force authentication of the server by the client, which will generally fail.

The option naming used previously on the PPTP Client project was for an unofficial MPPE patch to PPP. Since then, the PPP project has derived their own naming that is consistent with other pppd options.


What are those CCP MPPE bitmasks?

PPP negotiates MPPE with the PPTP Server using the Compression Control Protocol (CCP). When using debug logs, pppd decodes the CCP packets. How this is done depends on the version:

The following table describes the bits and their meanings:

PPP-MPPE 2.4.0PPP 2.4.2MeaningExplanation
0x01000000 +H Stateless use stateless encryption (less vulnerable to packet loss).
0x00000080 +M 56-bit use 56-bit key lengths for encryption (not supported).
0x00000040 +S 128-bit use 128-bit key lengths for encryption (less easy to decrypt than 40-bit).
0x00000020 +L 40-bit use 40-bit key lengths for encryption (more easy to decrypt than 128-bit).
0x00000010 +D Obsolete obsolete, usage unknown.
0x00000001 +C Compression use compression, see more about MPPC.

The values in the PPP-MPPE 2.4.0 column must be logically ORed. So, if you see a message <mppe 1 0 0 e1> this shows that the PPTP Server is prepared to support any of the above encryption types. Your system running pppd will likely respond with <mppe 1 0 0 60> which shows that it will not support MPPC, or 56-bit keys, but will support stateless 128-bit or 40-bit encryption.

Wanted: what the various PPTP Servers out there initially propose or will settle on given specific configuration options. We plan to build a list, to make it easier to understand why certain PPTP Servers are giving trouble.


What does ConfReq, ConfAck, ConfNak, and ConfRej mean?

ConfReq
Proposal
These options and values are desired.
ConfAck
Acceptance
These