Project

General

Profile

Bug #5934 » ipsec.xml

Example XML config - Luiz Fernando Cavalcanti, 02/26/2016 12:12 PM

 
1
	<ipsec>
2
		<preferoldsa/>
3
		<phase1>
4
			<ikeid>2</ikeid>
5
			<iketype>ikev2</iketype>
6
			<interface>opt2</interface>
7
			<remote-gateway>245.17.9.12</remote-gateway>
8
			<protocol>inet</protocol>
9
			<myid_type>myaddress</myid_type>
10
			<myid_data/>
11
			<peerid_type>peeraddress</peerid_type>
12
			<peerid_data/>
13
			<encryption-algorithm>
14
				<name>aes</name>
15
				<keylen>256</keylen>
16
			</encryption-algorithm>
17
			<hash-algorithm>md5</hash-algorithm>
18
			<dhgroup>2</dhgroup>
19
			<lifetime>28800</lifetime>
20
			<pre-shared-key>uMHjdSmi\uVW+FS**p2S!Q|%y,l?TfC#nD$~SxY/</pre-shared-key>
21
			<private-key/>
22
			<certref/>
23
			<caref/>
24
			<authentication_method>pre_shared_key</authentication_method>
25
			<descr><![CDATA[Site-to-Site City B(MPLS)]]></descr>
26
			<nat_traversal>on</nat_traversal>
27
			<mobike>off</mobike>
28
			<dpd_delay>10</dpd_delay>
29
			<dpd_maxfail>5</dpd_maxfail>
30
		</phase1>
31
		<phase1>
32
			<ikeid>1</ikeid>
33
			<iketype>ikev1</iketype>
34
			<mode>main</mode>
35
			<interface>opt1</interface>
36
			<remote-gateway>201.21.7.46</remote-gateway>
37
			<protocol>inet</protocol>
38
			<myid_type>address</myid_type>
39
			<myid_data>195.56.8.9</myid_data>
40
			<peerid_type>address</peerid_type>
41
			<peerid_data>201.21.7.46</peerid_data>
42
			<encryption-algorithm>
43
				<name>3des</name>
44
			</encryption-algorithm>
45
			<hash-algorithm>sha1</hash-algorithm>
46
			<dhgroup>2</dhgroup>
47
			<lifetime>28800</lifetime>
48
			<pre-shared-key>NoAM%?ZWEBRFTgXLkqN,aP=4rkT=3F1E;4LEux'R</pre-shared-key>
49
			<private-key/>
50
			<certref/>
51
			<caref/>
52
			<authentication_method>pre_shared_key</authentication_method>
53
			<descr><![CDATA[Site-to-Site City C]]></descr>
54
			<nat_traversal>on</nat_traversal>
55
			<mobike>off</mobike>
56
			<dpd_delay>10</dpd_delay>
57
			<dpd_maxfail>5</dpd_maxfail>
58
		</phase1>
59
		<enable/>
60
		<client>
61
			<user_source>system</user_source>
62
			<group_source>system</group_source>
63
		</client>
64
		<phase2>
65
			<ikeid>2</ikeid>
66
			<uniqid>560d96322b76c</uniqid>
67
			<mode>tunnel</mode>
68
			<reqid>1</reqid>
69
			<localid>
70
				<type>lan</type>
71
			</localid>
72
			<remoteid>
73
				<type>network</type>
74
				<address>172.16.0.0</address>
75
				<netbits>24</netbits>
76
			</remoteid>
77
			<protocol>ah</protocol>
78
			<encryption-algorithm-option/>
79
			<hash-algorithm-option>hmac_md5</hash-algorithm-option>
80
			<hash-algorithm-option>hmac_sha1</hash-algorithm-option>
81
			<pfsgroup>0</pfsgroup>
82
			<lifetime>3600</lifetime>
83
			<pinghost>172.16.0.2</pinghost>
84
			<descr><![CDATA[Site-to-Site City B(MPLS)]]></descr>
85
		</phase2>
86
		<phase2>
87
			<ikeid>1</ikeid>
88
			<uniqid>565c4978ad3fb</uniqid>
89
			<mode>tunnel</mode>
90
			<reqid>2</reqid>
91
			<localid>
92
				<type>network</type>
93
				<address>172.16.1.0</address>
94
				<netbits>24</netbits>
95
			</localid>
96
			<remoteid>
97
				<type>network</type>
98
				<address>10.50.0.0</address>
99
				<netbits>16</netbits>
100
			</remoteid>
101
			<protocol>esp</protocol>
102
			<encryption-algorithm-option>
103
				<name>3des</name>
104
			</encryption-algorithm-option>
105
			<hash-algorithm-option>hmac_sha1</hash-algorithm-option>
106
			<pfsgroup>0</pfsgroup>
107
			<lifetime>3600</lifetime>
108
			<pinghost/>
109
			<descr/><![CDATA[Site-to-Site City C]]></descr>
110
		</phase2>
111
	</ipsec>
(1-1/2)