This manual page documents briefly the
vpnc is a
VPN client for the Cisco 3000 VPN Concentrator, creating a IPSec-like
connection as a tunneling network device for the local system. It uses
the TUN/TAP driver in Linux kernel 2.4 and above and device tun(4)
on BSD. The created connection is presented as a tunneling network
device to the local system.
OBLIGATORY WARNING: the most used configuration (XAUTH authentication
with pre-shared keys and password authentication) is insecure by design,
be aware of this fact when you use vpnc to exchange sensitive data like
The vpnc daemon by itself does not set any routes, but it calls
vpnc-script to do this job. vpnc-script displays
a connect banner. If the concentrator supplies a network list
for split-tunneling these networks are added to the routing table.
Otherwise the default-route will be modified to point to the tunnel.
Further a host route to the concentrator is added in the later case.
If the client host needs DHCP, care must be taken to add another
host route to the DHCP-Server around the tunnel.
The vpnc-disconnect command is used to terminate
the connection previously created by vpnc
and restore the previous routing configuration.
The daemon reads configuration data from the following places:
command line options
config file(s) specified on the command line
prompting the user if not found above
vpnc can parse options and
in any order. However the first
place to set an option wins.
which do not contain a /
will be searched at
will be used.
If no configuration file
is specified on the command-line
at all, both
will be loaded.
The program options can be either given as arguments (but not all of them
for security reasons) or be stored in a configuration file.
command is executed using system() to configure the interface,
routing and so on. Device name, IP, etc. are passed using enviroment
variables, see README. This script is executed right after ISAKMP is
done, but before tunneling is enabled. It is called when vpnc
enables using no encryption for data traffic (key exchanged must be encrypted)
Enable no encryption
--application-version <ASCII string>
Application Version to report. Note: Default string is generated at runtime.
Default: Cisco Systems VPN Client 0.5.3:Linux
Application version <ASCII string>
--ifname <ASCII string>
visible name of the TUN/TAP interface
Interface name <ASCII string>
mode of TUN/TAP interface:
tun: virtual point to point interface (default)
tap: virtual ethernet interface
Interface mode <tun/tap>
Show verbose debug messages
0: Do not print debug information.
1: Print minimal debug information.
2: Show statemachine and packet/payload type information.
3: Dump everything exluding authentication data.
99: Dump everything INCLUDING AUTHENTICATION data (e.g. PASSWORDS).
Don't detach from the console after login
store the pid of background process in <filename>
local IP to use for ISAKMP / ESP / ... (0.0.0.0 == automatically assign)
Local Addr <ip/hostname>
local ISAKMP port number to use (0 == use random port)
Local Port <0-65535>
Local UDP port number to use (0 == use random port).
This is only relevant if cisco-udp nat-traversal is used.
This is the _local_ port, the remote udp port is discovered automatically.
It is especially not the cisco-tcp port.
Cisco UDP Encapsulation Port <0-65535>
Send DPD packet after not receiving anything for <idle> seconds.
Use 0 to disable DPD completely (both ways).
DEPRECATED extension, see README.Debian for details
DEPRECATED extension, see README.Debian for details
Prints your configuration; output can be used as vpnc.conf
The default configuration file. You can specify the same config
directives as with command line options and additionaly
both supplying a cleartext password. Scrambled passwords from the Cisco
configuration profiles can be used with
IPSec obfuscated secret
Xauth obfuscated password.
for further details.
vpnc will read configuration files in this directory when
the config filename (with or without .conf) is specified on the command line.
This is an example vpnc.conf with pre-shared keys:
The lines begin with a keyword (no leading spaces!).
The values start exactly one space after the keywords, and run to the end of
line. This lets you put any kind of weird character (except CR, LF and NUL) in
your strings, but it does mean you can't add comments after a string, or spaces
In case the the CA-Dir option is used, your certificate needs to be
named something like 722d15bd.X, where X is a manually assigned number to
make sure that files with colliding hashes have different names. The number
can be derived from the certificate file itself:
See also the
option to generate a config file, and the example file in the package
documentation directory where more advanced usage is demonstrated.
Advanced features like manual setting of multiple target routes and
disabling /etc/resolv.conf rewriting is documented in the README of the
The vpnc-connect stript shipped with Debian has some additional
Custom route setting
By default, the default route is deleted after connection and replaced
with the new one (going trough the VPN tunnel device). However, some
people wish to limit the target address range to few IP ranges.
This can be done using the config directive
in the config file. For example:
Target networks 126.96.36.199/24 10.1.0.0/16
Multiple config profiles management
You can have multiple config files and select one on connection by
specifying a short profile name instead of a config file path. In this
case, the file
is used as config file (where PROFILE is the short profile name).
If the package
is installed and the VPN gateway sends some DNS server data, the
script will use resolution to integrate the received data into
To disable this behaviour, set the config directive
Certificate support (Pre-Shared-Key + XAUTH is known to be insecure).
Further points can be found in the TODO file.
This man-page has been written by Eduard Bloch <blade(at)debian.org> and
Christian Lackas <delta(at)lackas.net>, based on vpnc README by
Maurice Massar <vpnc(at)unix-ag.uni-kl.de>.
granted to copy, distribute and/or modify this document under
the terms of the GNU General Public License, Version 2 any
later version published by the Free Software Foundation.
On Debian systems, the complete text of the GNU General Public
License can be found in /usr/share/common-licenses/GPL.