Dave Barach | 3bbcfab | 2017-08-15 19:03:44 -0400 | [diff] [blame] | 1 | /* |
Florin Coras | c5df8c7 | 2019-04-08 07:42:30 -0700 | [diff] [blame] | 2 | * Copyright (c) 2015-2019 Cisco and/or its affiliates. |
Dave Barach | 3bbcfab | 2017-08-15 19:03:44 -0400 | [diff] [blame] | 3 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | * you may not use this file except in compliance with the License. |
| 5 | * You may obtain a copy of the License at: |
| 6 | * |
| 7 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | * |
| 9 | * Unless required by applicable law or agreed to in writing, software |
| 10 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | * See the License for the specific language governing permissions and |
| 13 | * limitations under the License. |
| 14 | */ |
Ole Troan | 9d42087 | 2017-10-12 13:06:35 +0200 | [diff] [blame] | 15 | |
Jakub Grajciar | 956819a | 2020-01-03 10:02:32 +0100 | [diff] [blame] | 16 | option version = "2.0.0"; |
| 17 | |
| 18 | import "vnet/ip/ip_types.api"; |
| 19 | |
Dave Barach | 3bbcfab | 2017-08-15 19:03:44 -0400 | [diff] [blame] | 20 | /** \brief Configure TCP source addresses, for active-open TCP sessions |
| 21 | |
| 22 | TCP src/dst ports are 16 bits, with the low-order 1024 ports |
| 23 | reserved. So, it's necessary to provide a considerable number of |
| 24 | source IP addresses if one wishes to initiate a large number of |
| 25 | connections. |
| 26 | |
Jakub Grajciar | 956819a | 2020-01-03 10:02:32 +0100 | [diff] [blame] | 27 | Each of those addresses needs to have a receive adjacency - |
Dave Barach | 3bbcfab | 2017-08-15 19:03:44 -0400 | [diff] [blame] | 28 | either a /32 or a /128 - and vpp needs to answer (proxy) arps or |
Jakub Grajciar | 956819a | 2020-01-03 10:02:32 +0100 | [diff] [blame] | 29 | neighbor discovery requests for the addresses. |
Dave Barach | 3bbcfab | 2017-08-15 19:03:44 -0400 | [diff] [blame] | 30 | |
| 31 | @param client_index - opaque cookie to identify the sender |
| 32 | @param context - sender context, to match reply w/ request |
| 33 | @param is_ipv6 - 1 for ipv6, 0 for ipv4 |
| 34 | @param vrf_id - fib table / vrf id for local adjacencies |
| 35 | @param first_address - first address that TCP will use |
| 36 | @param last_address - last address that TCP will use |
| 37 | */ |
| 38 | autoreply define tcp_configure_src_addresses { |
| 39 | u32 client_index; |
| 40 | u32 context; |
Dave Barach | 3bbcfab | 2017-08-15 19:03:44 -0400 | [diff] [blame] | 41 | u32 vrf_id; |
Jakub Grajciar | 956819a | 2020-01-03 10:02:32 +0100 | [diff] [blame] | 42 | vl_api_address_t first_address; |
| 43 | vl_api_address_t last_address; |
Dave Barach | 3bbcfab | 2017-08-15 19:03:44 -0400 | [diff] [blame] | 44 | }; |