2 Documentation Deep inspection of HTTP traffic on symmetric chain.
3 ... Nodes are located on the same VM.
6 Resource ../../../../../libraries/GBP/OpenFlowUtils.robot
7 Resource ../Variables.robot
8 Resource ../Connections.robot
10 Suite Setup Start Connections
11 Suite Teardown Close Connections
15 Start HTTP on h36_2 on Port 80
16 [Documentation] Starting HTTP service on docker container.
19 ... client_ip=10.0.35.2
21 ... server_ip=10.0.36.2
26 Switch Connection GPSFC1_CONNECTION
27 Start HTTP Service on Docker ${SERVER_NAME} ${SERVICE_PORT}
30 [Documentation] Test HTTP request from a docker container to serving docker container.
31 Curl from Docker ${CLIENT_NAME} ${SERVER_IP} service_port=${SERVICE_PORT}
33 Start Endless Curl on h35_2 on port 80
34 [Documentation] Starting endless HTTP session for traffic inspection.
35 Start Endless Curl from Docker ${CLIENT_NAME} ${SERVER_IP} ${SERVICE_PORT} sleep=1
37 On GBPSFC1 Send HTTP req h35_2-h36_2 to GBPSFC2
38 [Documentation] HTTP traffic inspection.
39 Switch Connection GPSFC1_CONNECTION
40 ${flow} Inspect Classifier Outbound
42 ... out_port=${VXLAN_GPE_PORT}
43 ... eth_type=${ETHER_TYPE}
44 ... inner_src_ip=${CLIENT_IP}
45 ... inner_dst_ip=${SERVER_IP}
46 ... next_hop_ip=${GBPSFC2}
49 ... dst_port=${SERVICE_PORT}
50 ${nsp_35_2-nsp_36_2} GET NSP Value From Flow ${flow}
51 Set Global Variable ${NSP_path1} ${nsp_35_2-nsp_36_2}
53 On GBPSFC2 Send HTTP req h35_2-h36_2 to GBPSFC3
54 [Documentation] HTTP traffic inspection.
55 Switch Connection GPSFC2_CONNECTION
56 Inspect Service Function Forwarder
57 ... in_port=${VXLAN_GPE_PORT}
58 ... out_port=${VXLAN_GPE_PORT}
59 ... outer_src_ip=${GBPSFC1}
60 ... outer_dst_ip=${GBPSFC2}
61 ... eth_type=${ETHER_TYPE}
62 ... inner_src_ip=${CLIENT_IP}
63 ... inner_dst_ip=${SERVER_IP}
64 ... next_hop_ip=${GBPSFC3}
69 On GBPSFC3 Send HTTP req h35_2-h36_2 to GBPSFC2
70 [Documentation] HTTP traffic inspection.
71 Switch Connection GPSFC3_CONNECTION
72 Inspect Service Function
73 ... in_port=${VXLAN_GPE_PORT}
74 ... out_port=${VXLAN_GPE_PORT}
75 ... outer_src_ip=${GBPSFC2}
76 ... outer_dst_ip=${GBPSFC3}
77 ... eth_type=${ETHER_TYPE}
78 ... inner_src_ip=${CLIENT_IP}
79 ... inner_dst_ip=${SERVER_IP}
80 ... next_hop_ip=${GBPSFC2}
84 On GBPSFC2 Send HTTP req h35_2-h36_2 to GBPSFC4
85 [Documentation] HTTP traffic inspection.
86 Switch Connection GPSFC2_CONNECTION
87 Inspect Service Function Forwarder
88 ... in_port=${VXLAN_GPE_PORT}
89 ... out_port=${VXLAN_GPE_PORT}
90 ... outer_src_ip=${GBPSFC3}
91 ... outer_dst_ip=${GBPSFC2}
92 ... eth_type=${ETHER_TYPE}
93 ... inner_src_ip=${CLIENT_IP}
94 ... inner_dst_ip=${SERVER_IP}
95 ... next_hop_ip=${GBPSFC4}
100 On GBPSFC4 Send HTTP req h35_2-h36_2 to GBPSFC5
101 [Documentation] HTTP traffic inspection.
102 Switch Connection GPSFC4_CONNECTION
103 Inspect Service Function Forwarder
104 ... in_port=${VXLAN_GPE_PORT}
105 ... out_port=${VXLAN_GPE_PORT}
106 ... outer_src_ip=${GBPSFC2}
107 ... outer_dst_ip=${GBPSFC4}
108 ... eth_type=${ETHER_TYPE}
109 ... inner_src_ip=${CLIENT_IP}
110 ... inner_dst_ip=${SERVER_IP}
111 ... next_hop_ip=${GBPSFC5}
116 On GBPSFC5 Send HTTP req h35_2-h36_2 to GBPSFC4
117 [Documentation] HTTP traffic inspection.
118 Switch Connection GPSFC5_CONNECTION
119 Inspect Service Function
120 ... in_port=${VXLAN_GPE_PORT}
121 ... out_port=${VXLAN_GPE_PORT}
122 ... outer_src_ip=${GBPSFC4}
123 ... outer_dst_ip=${GBPSFC5}
124 ... eth_type=${ETHER_TYPE}
125 ... inner_src_ip=${CLIENT_IP}
126 ... inner_dst_ip=${SERVER_IP}
127 ... next_hop_ip=${GBPSFC4}
131 On GBPSFC4 Send HTTP req h35_2-h36_2 to GBPSFC1
132 [Documentation] HTTP traffic inspection.
133 Switch Connection GPSFC4_CONNECTION
134 Inspect Service Function Forwarder
135 ... in_port=${VXLAN_GPE_PORT}
136 ... out_port=${VXLAN_GPE_PORT}
137 ... outer_src_ip=${GBPSFC5}
138 ... outer_dst_ip=${GBPSFC4}
139 ... eth_type=${ETHER_TYPE}
140 ... inner_src_ip=${CLIENT_IP}
141 ... inner_dst_ip=${SERVER_IP}
142 ... next_hop_ip=${GBPSFC1}
147 On GBPSFC1 Send HTTP req h35_2-h36_2 to h36_2
148 [Documentation] HTTP traffic inspection.
149 Switch Connection GPSFC1_CONNECTION
150 Inspect Classifier Inbound
151 ... in_port=${VXLAN_GPE_PORT}
153 ... eth_type=${ETHER_TYPE}
154 ... inner_src_ip=${CLIENT_IP}
155 ... inner_dst_ip=${SERVER_IP}
156 ... outer_src_ip=${GBPSFC4}
157 ... outer_dst_ip=${GBPSFC1}
162 On GBPSFC1 Send HTTP resp h36_2-h35_2 to GBPSFC4
163 [Documentation] HTTP traffic inspection.
164 Switch Connection GPSFC1_CONNECTION
165 ${flow} Inspect Classifier Outbound
167 ... out_port=${VXLAN_GPE_PORT}
168 ... eth_type=${ETHER_TYPE}
169 ... inner_src_ip=${SERVER_IP}
170 ... inner_dst_ip=${CLIENT_IP}
171 ... next_hop_ip=${GBPSFC4}
174 ... src_port=${SERVICE_PORT}
175 ${nsp_36_2-nsp_35_2} GET NSP Value From Flow ${flow}
176 Set Global Variable ${NSP_path2} ${nsp_36_2-nsp_35_2}
178 On GBPSFC4 Send HTTP resp h36_2-h35_2 to GBPSFC5
179 [Documentation] HTTP traffic inspection.
180 Switch Connection GPSFC4_CONNECTION
181 Inspect Service Function Forwarder
182 ... in_port=${VXLAN_GPE_PORT}
183 ... out_port=${VXLAN_GPE_PORT}
184 ... outer_src_ip=${GBPSFC1}
185 ... outer_dst_ip=${GBPSFC4}
186 ... eth_type=${ETHER_TYPE}
187 ... inner_src_ip=${SERVER_IP}
188 ... inner_dst_ip=${CLIENT_IP}
189 ... next_hop_ip=${GBPSFC5}
194 On GBPSFC5 Send HTTP resp h36_2-h35_2 to GBPSFC4
195 [Documentation] HTTP traffic inspection.
196 Switch Connection GPSFC5_CONNECTION
197 Inspect Service Function
198 ... in_port=${VXLAN_GPE_PORT}
199 ... out_port=${VXLAN_GPE_PORT}
200 ... outer_src_ip=${GBPSFC4}
201 ... outer_dst_ip=${GBPSFC5}
202 ... eth_type=${ETHER_TYPE}
203 ... inner_src_ip=${SERVER_IP}
204 ... inner_dst_ip=${CLIENT_IP}
205 ... next_hop_ip=${GBPSFC4}
209 On GBPSFC4 Send HTTP resp h36_2-h35_2 to GBPSFC2
210 [Documentation] HTTP traffic inspection.
211 Switch Connection GPSFC4_CONNECTION
212 Inspect Service Function Forwarder
213 ... in_port=${VXLAN_GPE_PORT}
214 ... out_port=${VXLAN_GPE_PORT}
215 ... outer_src_ip=${GBPSFC5}
216 ... outer_dst_ip=${GBPSFC4}
217 ... eth_type=${ETHER_TYPE}
218 ... inner_src_ip=${SERVER_IP}
219 ... inner_dst_ip=${CLIENT_IP}
220 ... next_hop_ip=${GBPSFC2}
225 On GBPSFC2 Send HTTP resp h36_2-h35_2 to GBPSFC3
226 [Documentation] HTTP traffic inspection.
227 Switch Connection GPSFC2_CONNECTION
228 Inspect Service Function Forwarder
229 ... in_port=${VXLAN_GPE_PORT}
230 ... out_port=${VXLAN_GPE_PORT}
231 ... outer_src_ip=${GBPSFC4}
232 ... outer_dst_ip=${GBPSFC2}
233 ... eth_type=${ETHER_TYPE}
234 ... inner_src_ip=${SERVER_IP}
235 ... inner_dst_ip=${CLIENT_IP}
236 ... next_hop_ip=${GBPSFC3}
241 On GBPSFC3 Send HTTP resp h36_2-h35_2 to GBPSFC2
242 [Documentation] HTTP traffic inspection.
243 Switch Connection GPSFC3_CONNECTION
244 Inspect Service Function
245 ... in_port=${VXLAN_GPE_PORT}
246 ... out_port=${VXLAN_GPE_PORT}
247 ... outer_src_ip=${GBPSFC2}
248 ... outer_dst_ip=${GBPSFC3}
249 ... eth_type=${ETHER_TYPE}
250 ... inner_src_ip=${SERVER_IP}
251 ... inner_dst_ip=${CLIENT_IP}
252 ... next_hop_ip=${GBPSFC2}
256 On GBPSFC2 Send HTTP resp h36_2-h35_2 to GBPSFC1
257 [Documentation] HTTP traffic inspection.
258 Switch Connection GPSFC2_CONNECTION
259 Inspect Service Function Forwarder
260 ... in_port=${VXLAN_GPE_PORT}
261 ... out_port=${VXLAN_GPE_PORT}
262 ... outer_src_ip=${GBPSFC3}
263 ... outer_dst_ip=${GBPSFC2}
264 ... eth_type=${ETHER_TYPE}
265 ... inner_src_ip=${SERVER_IP}
266 ... inner_dst_ip=${CLIENT_IP}
267 ... next_hop_ip=${GBPSFC1}
272 On GBPSFC1 Send HTTP resp h36_2-h35_2 to h35_2
273 [Documentation] HTTP traffic inspection.
274 Switch Connection GPSFC1_CONNECTION
275 Inspect Classifier Inbound
276 ... in_port=${VXLAN_GPE_PORT}
278 ... eth_type=${ETHER_TYPE}
279 ... inner_src_ip=${SERVER_IP}
280 ... inner_dst_ip=${CLIENT_IP}
281 ... outer_src_ip=${GBPSFC2}
282 ... outer_dst_ip=${GBPSFC1}
288 [Documentation] Verifying that different paths were taken.
289 Should Not Be Equal As Numbers ${NSP_path1} ${NSP_path2}
291 Stop Endless Curl on h35_2 on port 80
292 [Documentation] Stopping endless HTTP session after traffic inspection finishes.
293 Switch Connection GPSFC1_CONNECTION
294 Stop Endless Curl from Docker ${CLIENT_NAME}
296 Stop HTTP on h36_2 on Port 80
297 [Documentation] Stopping HTTP service on the docker container.
298 Stop HTTP Service on Docker ${SERVER_NAME}