ipsec: infra for selecting backends
[vpp.git] / src / vnet / ipsec / ipsec.api
index 0765839..148cdcd 100644 (file)
@@ -13,7 +13,7 @@
  * limitations under the License.
  */
 
-option version = "1.0.0";
+option version = "2.0.0";
 
 /** \brief IPsec: Add/delete Security Policy Database
     @param client_index - opaque cookie to identify the sender
@@ -364,7 +364,7 @@ autoreply define ikev2_set_esp_transforms
 
     @param name - IKEv2 profile name
     @param lifetime - SA maximum life time in seconds (0 to disable)
-    @param lifetime_jitter - Jitter added to prevent simultaneounus rekeying
+    @param lifetime_jitter - Jitter added to prevent simultaneous rekeying
     @param handover - Hand over time
     @param lifetime_maxdata - SA maximum life time in bytes (0 to disable)
     
@@ -441,6 +441,26 @@ autoreply define ikev2_initiate_rekey_child_sa
   u32 ispi;
 };
 
+/** \brief Dump IPsec all SPD IDs
+    @param client_index - opaque cookie to identify the sender
+    @param context - sender context, to match reply w/ request
+*/
+define ipsec_spds_dump {
+  u32 client_index;
+  u32 context;
+};
+
+/** \brief Dump IPsec all SPD IDs response
+    @param client_index - opaque cookie to identify the sender
+    @param spd_id - SPD instance id (control plane allocated)
+    @param npolicies - number of policies in SPD
+*/
+define ipsec_spds_details {
+  u32 context;
+  u32 spd_id;
+  u32 npolicies;
+}; 
+
 /** \brief Dump ipsec policy database data
     @param client_index - opaque cookie to identify the sender
     @param context - sender context, to match reply w/ request
@@ -495,6 +515,31 @@ define ipsec_spd_details {
     u64 packets;
 };
 
+/** \brief IPsec: Get SPD interfaces
+    @param client_index - opaque cookie to identify the sender
+    @param context - sender context, to match reply w/ request
+    @param spd_index - SPD index
+    @param spd_index_valid - if 1 spd_index is used to filter
+      spd_index's, if 0 no filtering is done
+*/
+define ipsec_spd_interface_dump {
+    u32 client_index;
+    u32 context;
+    u32 spd_index;
+    u8 spd_index_valid;
+};
+
+/** \brief IPsec: SPD interface response
+    @param context - sender context which was passed in the request
+    @param spd_index - SPD index
+    @param sw_if_index - index of the interface
+*/
+define ipsec_spd_interface_details {
+    u32 context;
+    u32 spd_index;
+    u32 sw_if_index;
+};
+
 /** \brief Add or delete IPsec tunnel interface
     @param client_index - opaque cookie to identify the sender
     @param context - sender context, to match reply w/ request
@@ -658,6 +703,42 @@ autoreply define ipsec_tunnel_if_set_sa {
   u8 is_outbound;
 };
 
+/** \brief Dump IPsec backends
+    @param client_index - opaque cookie to identify the sender
+    @param context - sender context, to match reply w/ request
+*/
+define ipsec_backend_dump {
+  u32 client_index;
+  u32 context;
+};
+
+/** \brief IPsec backend details
+    @param name - name of the backend
+    @param protocol - IPsec protocol (value from ipsec_protocol_t)
+    @param index - backend index
+    @param active - set to 1 if the backend is active, otherwise 0
+*/
+define ipsec_backend_details {
+  u32 context;
+  u8 name[128];
+  u8 protocol;
+  u8 index;
+  u8 active;
+};
+
+/** \brief Select IPsec backend
+    @param client_index - opaque cookie to identify the sender
+    @param context - sender context, to match reply w/ request
+    @param protocol - IPsec protocol (value from ipsec_protocol_t)
+    @param index - backend index
+*/
+autoreply define ipsec_select_backend {
+  u32 client_index;
+  u32 context;
+  u8 protocol;
+  u8 index;
+};
+
 /*
  * Local Variables:
  * eval: (c-set-style "gnu")