Book Image

OpenVPN 2 Cookbook

Book Image

OpenVPN 2 Cookbook

Overview of this book

Table of Contents (19 chapters)
OpenVPN 2 Cookbook
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Proxy-arp


In this recipe, we will use the proxy-arp feature of the Linux kernel to make the VPN clients appear as part of the server-side LAN. This eliminates the need to use bridging, which is desirable in most cases.

Getting ready

We use the following network layout:

This recipe uses the PKI files created in the first recipe of this chapter. For this recipe, we used the server computer that run CentOS 5 Linux and OpenVPN 2.1.1. The client was running Windows XP SP3 and OpenVPN 2.1.1. For the server, one should keep the configuration file basic-udp-server.conf from the recipe Server-side routing at hand. For the Windows client, keep the configuration file, basic-udp-client.ovpn, from the recipe Using an ifconfig-pool block at hand.

How to do it...

  1. Create the server config file by adding the following lines to the basic-udp-server.conf file:

    script-security 2
    client-connect    /etc/openvpn/cookbook/proxyarp-connect.sh
    client-disconnect /etc/openvpn/cookbook/proxyarp-disconnect.sh
    

    Save it as...