Linux Kernel VPN implementation source code analysis (1)

Source: Internet
Author: User
1. Introduction to VPN in Linux


Generally,
Linux
Lower
VPN
The implemented protocol stack can be divided into application layer and Network Layer
VPN
, Application Layer
VPN
For example
SSL VPN
Well-known open-source implementations include:
Openvpn
And the network layer is usually
IPSec VPN
.
SSL VPN
The text will not be described.
Openvpn
There are many materials, so you can study them on your own.



Actually
Linux2.6
At least three kernel implementations
VPN
.
VPN
They are
Ipip
Protocol,
Ipgre
Protocols and
IPSec
Protocol, the files in the kernel source code are
Ipip. c
,
Ip_gre.c
And
Xfrm
. However
IPSec VPN openswan
There are four types. These four methods can be divided into two types in terms of implementation principle. One is to use a virtual Nic to establish a tunnel, which can be run by inserting the corresponding kernel module,
Linux2.6
Kernel
Ipip
Protocol,
Ipgre
Protocols and
Openswan
Of
IPSec
Protocol, the other is directly implemented in the kernel, that is, the kernel implementation
IPSec VPN
. Therefore, the preceding three implementations are very similar.



For
Linux2.6
Built-in in the kernel
IPSec
(Note:
Linux2.4
The kernel can be supported by patching). This article will not do any analysis, because some predecessors have done a good analysis. For more information, see
Http://blog.chinaunix.net/u/12313/showart_313220.html

Unfortunately, this old guy
Blog
It has not been updated for a long time.
Linux2.6
Built-in in the kernel
IPSec
Open-source tools
IPSec Tool
.



This article will begin step-by-step analysis
Linux2.6.30
Kernel Implementation Based on Virtual Network Card
VPN
First from the simplest
Ipip
The Protocol starts.

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.