Ed Warnicke | cb9cada | 2015-12-08 15:45:58 -0700 | [diff] [blame] | 1 | |
| 2 | set int ip address GigabitEthernet2/1/0 1.2.3.4/24 |
| 3 | set int state GigabitEthernet2/1/0 up |
| 4 | set int state tuntap-0 down |
| 5 | |
| 6 | |
| 7 | cre sub GigabitEthernet2/1/0 1 dot1q 1 |
| 8 | cre sub GigabitEthernet2/1/0 2 dot1q 2 |
| 9 | cre sub GigabitEthernet2/1/0 3 dot1q 3 |
| 10 | cre sub GigabitEthernet2/2/0 1 dot1q 1 |
| 11 | cre sub GigabitEthernet2/2/0 100 dot1q 100 |
| 12 | |
| 13 | |
| 14 | set int l2 tag-rewrite GigabitEthernet2/1/0.1 pop 1 |
| 15 | set int l2 tag-rewrite GigabitEthernet2/1/0.2 pop 1 |
| 16 | |
| 17 | |
| 18 | l2tp session add client 11::1 our 22::2 l2-interface GigabitEthernet2/1/0.1 |
| 19 | l2tp session add client 11::1 our 22::3 l2-interface GigabitEthernet2/1/0.2 local-session-id 2 l2-sublayer-present |
| 20 | |
| 21 | ip route 11::1/128 via GigabitEthernet2/2/0 |
| 22 | set ip6 neighbor GigabitEthernet2/2/0 11::1 00:02:04:06:08:0a |
| 23 | |
| 24 | enable ip6 interface GigabitEthernet2/2/0 |
| 25 | |
| 26 | set int ip6 l2tpv3 GigabitEthernet2/2/0 |
| 27 | |
| 28 | set int state GigabitEthernet2/1/0 up |
| 29 | set int state GigabitEthernet2/1/0.1 up |
| 30 | set int state GigabitEthernet2/1/0.2 up |
| 31 | set int state GigabitEthernet2/1/0.3 up |
| 32 | set int state GigabitEthernet2/2/0 up |
| 33 | |
| 34 | |
| 35 | trace add pg-input 2 |
| 36 | |
| 37 | clear error |
| 38 | clear run |
| 39 | clear int |
| 40 | |
| 41 | packet-generator new { |
| 42 | name decap |
| 43 | limit 10 |
| 44 | size 200-200 |
Ed Warnicke | cb9cada | 2015-12-08 15:45:58 -0700 | [diff] [blame] | 45 | node ethernet-input |
| 46 | interface GigabitEthernet2/2/0 |
| 47 | data { |
| 48 | IP6: 00:50:00:00:00:01 -> 00:50:56:b7:29:7a |
| 49 | L2TP: 11::1 -> 22::2 |
| 50 | L2TP: session_id 1 cookie 0xffffffffffffffff |
| 51 | IP4: 00:55:55:55:00:01 -> 00:dd:dd:dd:00:01 |
| 52 | UDP: 1.2.3.4 -> 5.6.7.8 |
| 53 | incrementing 8 |
| 54 | } |
| 55 | } |
| 56 | |
| 57 | packet-generator new { |
| 58 | name decap_bad_sid |
| 59 | limit 30 |
| 60 | size 200-200 |
Ed Warnicke | cb9cada | 2015-12-08 15:45:58 -0700 | [diff] [blame] | 61 | node ethernet-input |
| 62 | interface GigabitEthernet2/2/0 |
| 63 | data { |
| 64 | IP6: 00:50:00:00:00:01 -> 00:50:56:b7:29:7a |
| 65 | L2TP: 11::1 -> 22::2 |
| 66 | L2TP: session_id 0x999 cookie 0xffffffffffffffff |
| 67 | IP4: 00:55:55:55:00:01 -> 00:dd:dd:dd:00:01 |
| 68 | UDP: 1.2.3.4 -> 5.6.7.8 |
| 69 | incrementing 8 |
| 70 | } |
| 71 | } |
| 72 | |
| 73 | packet-generator new { |
| 74 | name decap_bad_cookie |
| 75 | limit 50 |
| 76 | size 200-200 |
Ed Warnicke | cb9cada | 2015-12-08 15:45:58 -0700 | [diff] [blame] | 77 | node ethernet-input |
| 78 | interface GigabitEthernet2/2/0 |
| 79 | data { |
| 80 | IP6: 00:50:00:00:00:01 -> 00:50:56:b7:29:7a |
| 81 | L2TP: 11::1 -> 22::2 |
| 82 | L2TP: session_id 1 cookie 0x3333ffffffffffff |
| 83 | IP4: 00:55:55:55:00:01 -> 00:dd:dd:dd:00:01 |
| 84 | UDP: 1.2.3.4 -> 5.6.7.8 |
| 85 | incrementing 8 |
| 86 | } |
| 87 | } |
| 88 | |
| 89 | packet-generator new { |
| 90 | name encap |
| 91 | limit 100 |
Ed Warnicke | cb9cada | 2015-12-08 15:45:58 -0700 | [diff] [blame] | 92 | node ethernet-input |
| 93 | interface GigabitEthernet2/1/0 |
| 94 | data { |
| 95 | IP4: 0000.5555.0002 -> 00:00:dd:dd:00:02 vlan 1 |
| 96 | UDP: 1.2.3.4 -> 5.6.7.8 |
| 97 | incrementing 8 |
| 98 | } |
| 99 | } |
| 100 | |
| 101 | packet-generator new { |
| 102 | name decap_sublayer |
| 103 | limit 300 |
| 104 | size 200-200 |
Ed Warnicke | cb9cada | 2015-12-08 15:45:58 -0700 | [diff] [blame] | 105 | node ethernet-input |
| 106 | interface GigabitEthernet2/2/0 |
| 107 | data { |
| 108 | IP6: 00:50:00:00:00:01 -> 00:50:56:b7:29:7a |
| 109 | L2TP: 11::1 -> 22::3 |
| 110 | L2TP: session_id 2 cookie 0xffffffffffffffff l2_sublayer 0 |
| 111 | IP4: 00:55:55:55:00:01 -> 00:dd:dd:dd:00:01 |
| 112 | UDP: 1.2.3.4 -> 5.6.7.8 |
| 113 | incrementing 8 |
| 114 | } |
| 115 | } |
| 116 | |
| 117 | packet-generator new { |
| 118 | name encap_sublayer |
| 119 | limit 700 |
Ed Warnicke | cb9cada | 2015-12-08 15:45:58 -0700 | [diff] [blame] | 120 | node ethernet-input |
| 121 | interface GigabitEthernet2/1/0 |
| 122 | data { |
| 123 | IP4: 0000.5555.0002 -> 00:00:dd:dd:00:02 vlan 2 |
| 124 | UDP: 1.2.3.4 -> 5.6.7.8 |
| 125 | incrementing 8 |
| 126 | } |
| 127 | } |
| 128 | |