Filip Tehlar | d5a3380 | 2021-02-20 02:26:17 +0000 | [diff] [blame^] | 1 | create host-interface name vpp |
| 2 | set interface ip addr host-vpp 192.168.10.2/24 |
| 3 | set interface state host-vpp up |
| 4 | |
| 5 | create host-interface name priv |
| 6 | set interface ip addr host-priv 192.168.3.1/24 |
| 7 | set interface state host-priv up |
| 8 | |
| 9 | ikev2 profile add pr1 |
| 10 | ikev2 profile set pr1 auth shared-key-mic string Vpp123 |
| 11 | ikev2 profile set pr1 id local fqdn vpp.home |
| 12 | ikev2 profile set pr1 id remote fqdn roadwarrior.vpn.example.com |
| 13 | |
| 14 | ikev2 profile set pr1 traffic-selector local ip-range 192.168.3.0 - 192.168.3.255 port-range 0 - 65535 protocol 0 |
| 15 | ikev2 profile set pr1 traffic-selector remote ip-range 192.168.5.0 - 192.168.5.255 port-range 0 - 65535 protocol 0 |
| 16 | |
| 17 | event-logger clear |
| 18 | trace add af-packet-input 100 |
| 19 | |
| 20 | create ipip tunnel src 192.168.10.2 dst 192.168.10.1 |
| 21 | ikev2 profile set pr1 tunnel ipip0 |
| 22 | ip route add 192.168.5.0/24 via 192.168.10.1 ipip0 |
| 23 | set interface unnumbered ipip0 use host-vpp |
| 24 | |
| 25 | ikev2 set liveness 30 4 |
| 26 | ikev2 set logging level 4 |