Skip to content

Commit 4dcd85f

Browse files
authored
Add files via upload
1 parent 8b39bbb commit 4dcd85f

File tree

4 files changed

+44
-0
lines changed

4 files changed

+44
-0
lines changed

tunneling/ipsec-GW1.sh

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
#!/usr/sbin/setkey -f
2+
3+
flush;
4+
spdflush;
5+
# AH
6+
add 10.0.0.1 10.0.3.2 ah 15700 -A hmac-md5 "1234567890123456";
7+
add 10.0.3.2 10.0.0.1 ah 24500 -A hmac-md5 "1234567890123456";
8+
# ESP
9+
add 10.0.0.1 10.0.3.2 esp 15701 -E 3des-cbc "123456789012123456789012";
10+
add 10.0.3.2 10.0.0.1 esp 24501 -E 3des-cbc "123456789012123456789012";
11+
spdadd 10.0.0.1 10.0.3.2 any -P out ipsec
12+
esp/transport//require
13+
ah/transport//require;
14+
spdadd 10.0.3.2 10.0.0.1 any -P in ipsec
15+
esp/transport//require
16+
ah/transport//require;

tunneling/ipsec-GW2.sh

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#!/usr/sbin/setkey -f
2+
3+
flush;
4+
spdflush;
5+
# AH
6+
add 10.0.0.1 10.0.3.2 ah 15700 -A hmac-md5 "1234567890123456";
7+
add 10.0.3.2 10.0.0.1 ah 24500 -A hmac-md5 "1234567890123456";
8+
# ESP
9+
add 10.0.0.1 10.0.3.2 esp 15701 -E 3des-cbc "123456789012123456789012";
10+
add 10.0.3.2 10.0.0.1 esp 24501 -E 3des-cbc "123456789012123456789012";
11+
12+
spdadd 10.0.3.2 10.0.0.1 any -P out ipsec
13+
esp/transport//require
14+
ah/transport//require;
15+
spdadd 10.0.0.1 10.0.3.2 any -P in ipsec
16+
esp/transport//require
17+
ah/transport//require;

tunneling/setupTunnelGW1.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#!/bin/sh
2+
#creamos túnel asignando como host del otro extremo GW2
3+
ip tunnel add foo mode sit remote 10.0.3.2
4+
#activamos el túnel
5+
ip link set foo up
6+
#añadimos regla para enrutar el tráfico IPv6 hacia el túnel
7+
ip -6 r add 2000::/3 dev foo

tunneling/setupTunnelGW2.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#!/bin/sh
2+
ip tunnel add foo mode sit remote 10.0.0.1
3+
ip link set foo up
4+
ip -6 r add 2000::/3 dev foo

0 commit comments

Comments
 (0)