be traveling either upstream or downstream. Each node port in the steer- ing network is either facing upstream or downstream. In Figure 5.6, downstream-facing ports are colored grey and upstream-facing ports are colored black. All packets that arrive on a downstream-facing port are traveling upstream, and vice versa. Packets arriving on transit ports may be traveling in either direction. In this case, the direction is known based on the destination MAC address, which will correspond to either an upstream-facing or downstream-facing service or router port. Other remote networks Internet Upstream facing port Downstream facing port Transit port Figure 5.6 Illustration of port direction. 5.2 Service Function Chaining 5.2.1.2 Realize Policies with Multiple Forwarding Tables In theory, a single TCAM-like table could be used to specify the required functionality, as in OpenFlow 1.0 or pswitch. However, this would not be a scalable solution because it would involve the cross-product of subscribers, applications, and ports. Using indirec- tion and multiple tables, we separate this into multiple steps, resulting in linear scaling of each table. Six mandatory tables are used in each OF switch, as shown in rect- angular in Figure 5.7. We introduce each table as follows. The first table is the direction table. It uses the ingress port as the key, and serves two purposes: to determine whether the packet arrived on a node port or a transit port, and in which direction the packet is headed. The key for the MAC table is the packet's destination MAC address. Based on the contents of this table, the packet will either be transmit- ted to a directly connected service or router on a node port, forwarded out to another transit port, or dropped. The next table is the subscriber table. It is used to get a subscriber's default service set for the current direction. The key is the direction bit together with the subscriber's IP address. The subscriber's IP address comes from either the source or destination IP address fields, depend- ing 