/* Hey Emacs use -*- mode: C -*- */
/*
 * Copyright (c) 2015-2016 Cisco and/or its affiliates.
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at:
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

option version = "5.0.2";

import "vnet/ipsec/ipsec_types.api";
import "vnet/interface_types.api";
import "vnet/ip/ip_types.api";
import "vnet/interface_types.api";
import "vnet/tunnel/tunnel_types.api";

/** \brief IPsec: Add/delete Security Policy Database
    @param client_index - opaque cookie to identify the sender
    @param context - sender context, to match reply w/ request
    @param is_add - add SPD if non-zero, else delete
    @param spd_id - SPD instance id (control plane allocated)
*/

autoreply define ipsec_spd_add_del
{
  u32 client_index;
  u32 context;
  bool is_add;
  u32 spd_id;
};

/** \brief IPsec: Add/delete SPD from interface

    @param client_index - opaque cookie to identify the sender
    @param context - sender context, to match reply w/ request
    @param is_add - add security mode if non-zero, else delete
    @param sw_if_index - index of the interface
    @param spd_id - SPD instance id to use for lookups
*/


autoreply define ipsec_interface_add_del_spd
{
  u32 client_index;
  u32 context;

  bool is_add;
  vl_api_interface_index_t sw_if_index;
  u32 spd_id;
};

/** \brief IPsec: Add/delete Security Policy Database entry

    @param client_index - opaque cookie to identify the sender
    @param context - sender context, to match reply w/ request
    @param is_add - add SPD if non-zero, else delete
    @param entry - Description of the entry to add/dell
*/
define ipsec_spd_entry_add_del
{
  option deprecated;
  u32 client_index;
  u32 context;
  bool is_add;
  vl_api_ipsec_spd_entry_t entry;
};

/** \brief IPsec: Add/delete Security Policy Database entry v2

    @param client_index - opaque cookie to identify the sender
    @param context - sender context, to match reply w/ request
    @param is_add - add SPD if non-zero, else delete
    @param entry - Description of the entry to add/dell
*/
define ipsec_spd_entry_add_del_v2
{
  u32 client_index;
  u32 context;
  bool is_add;
  vl_api_ipsec_spd_entry_v2_t entry;
};

/** \brief IPsec: Reply Add/delete Security Policy Database entry

    @param context - sender context, to match reply w/ request
    @param retval - success/fail rutrun code
    @param stat_index - An index for the policy in the stats segment @ /net/ipec/policy
*/
define ipsec_spd_entry_add_del_reply
{
  option deprecated;
  u32 context;
  i32 retval;
  u32 stat_index;
};

/** \brief IPsec: Reply Add/delete Security Policy Database entry v2

    @param context - sender context, to match reply w/ request
    @param retval - success/fail rutrun code
    @param stat_index - An index for the policy in the stats segment @ /net/ipec/policy
*/
define ipsec_spd_entry_add_del_v2_reply
{
  u32 context;
  i32 retval;
  u32 stat_index;
};

/** \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
    @param spd_id - SPD instance id
    @param sa_id - SA id, optional, set to ~0 to see all policies in SPD
*/
define ipsec_spd_dump {
    u32 client_index;
    u32 context;
    u32 spd_id;
    u32 sa_id;
};

/** \brief IPsec policy database response
    @param context - sender context which was passed in the request
    €param entry - The SPD entry.
    @param bytes - byte count of packets matching this policy
    @param packets - count of packets matching this policy
*/
define ipsec_spd_details {
    u32 context;
    vl_api_ipsec_spd_entry_t entry;
};

/** \brief IPsec: Add/delete Security Association Database entry
    @param client_index - opaque cookie to identify the sender
    @param context - sender context, to match reply w/ request
    @param entry - Entry to add or delete
 */
define ipsec_sad_entry_add_del
{
  option deprecated;
  u32 client_index;
  u32 context;
  bool is_add;
  vl_api_ipsec_sad_entry_t entry;
};

define ipsec_sad_entry_add_del_v2
{
  u32 client_index;
  u32 context;
  bool is_add;
  vl_api_ipsec_sad_entry_v2_t entry;
};

define ipsec_sad_entry_add_del_v3
{
  u32 client_index;
  u32 context;
  bool is_add;
  vl_api_ipsec_sad_entry_v3_t entry;
};
define ipsec_sad_entry_add
{
  u32 client_index;
  u32 context;
  vl_api_ipsec_sad_entry_v3_t entry;
};
autoreply define ipsec_sad_entry_del
{
  u32 client_index;
  u32 context;
  u32 id;
};

/** \brief An API to update the tunnel parameters and the ports associated with an SA

    Used in the NAT-T case when the NAT data changes
    @param client_index - opaque cookie to identify the sender
    @param context - sender context, to match reply w/ request
    @param sa_id - the id of the SA to update
    @param is_tun - update the tunnel if non-zero, else update only the ports
    @param tunnel - sender context, to match reply w/ request
    @param udp_src_port - new src port for NAT-T. Used if different from 0xffff
    @param udp_dst_port - new dst port for NAT-T. Used if different from 0xffff
 */
autoreply define ipsec_sad_entry_update
{
  u32 client_index;
  u32 context;
  u32 sad_id;
  bool is_tun;
  vl_api_tunnel_t tunnel;
  u16 udp_src_port [default=0xffff];
  u16 udp_dst_port [default=0xffff];
};

define ipsec_sad_entry_add_del_reply
{
  option deprecated;
  u32 context;
  i32 retval;
  u32 stat_index;
};

define ipsec_sad_entry_add_del_v2_reply
{
  u32 context;
  i32 retval;
  u32 stat_index;
};

define ipsec_sad_entry_add_del_v3_reply
{
  u32 context;
  i32 retval;
  u32 stat_index;
};
define ipsec_sad_entry_add_reply
{
  u32 context;
  i32 retval;
  u32 stat_index;
};

/** \brief Add or Update Protection for a tunnel with IPSEC

    Tunnel protection directly associates an SA with all packets
    ingress and egress on the tunnel. This could also be achieved by
    assigning an SPD to the tunnel, but that would incur an unnessccary
    SPD entry lookup.

    For tunnels the ESP acts on the post-encapsulated packet. So if this
    packet:
      +---------+------+
      | Payload | O-IP |
      +---------+------+
    where O-IP is the overlay IP addrees that was routed into the tunnel,
    the resulting encapsulated packet will be:
      +---------+------+------+
      | Payload | O-IP | T-IP |
      +---------+------+------+
    where T-IP is the tunnel's src.dst IP addresses.
    If the SAs used for protection are in transport mode then the ESP is
    inserted before T-IP, i.e.:
      +---------+------+-----+------+
      | Payload | O-IP | ESP | T-IP |
      +---------+------+-----+------+
    If the SAs used for protection are in tunnel mode then another
    encapsulation occurs, i.e.:
      +---------+------+------+-----+------+
      | Payload | O-IP | T-IP | ESP | C-IP |
      +---------+------+------+-----+------+
    where C-IP are the crypto endpoint IP addresses defined as the tunnel
    endpoints in the SA.
    The mode for the inbound and outbound SA must be the same.

    @param client_index - opaque cookie to identify the sender
    @param context - sender context, to match reply w/ request
    @param sw_id_index - Tunnel interface to protect
    @param nh - The peer/next-hop on the tunnel to which the traffic
                should be protected. For a P2P interface set this to the
                all 0s address.
    @param sa_in - The ID [set] of inbound SAs
    @param sa_out - The ID of outbound SA
*/
typedef ipsec_tunnel_protect
{
  vl_api_interface_index_t sw_if_index;
  vl_api_address_t nh;
  u32 sa_out;
  u8 n_sa_in;
  u32 sa_in[n_sa_in];
};

autoreply define ipsec_tunnel_protect_update
{
  u32 client_index;
  u32 context;

  vl_api_ipsec_tunnel_protect_t tunnel;
};

autoreply define ipsec_tunnel_protect_del
{
  u32 client_index;
  u32 context;

  vl_api_interface_index_t sw_if_index;
  vl_api_address_t nh;
};

/**
 * @brief Dump all tunnel protections
 */
define ipsec_tunnel_protect_dump
{
  u32 client_index;
  u32 context;
  vl_api_interface_index_t sw_if_index;
};

define ipsec_tunnel_protect_details
{
  u32 context;
  vl_api_ipsec_tunnel_protect_t tun;
};

/** \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;
    vl_api_interface_index_t sw_if_index;
};

typedef ipsec_itf
{
  u32 user_instance [default=0xffffffff];
  vl_api_tunnel_mode_t mode;
  vl_api_interface_index_t sw_if_index;
};

/** \brief Create an IPSec interface
 */
define ipsec_itf_create {
  u32 client_index;
  u32 context;
  vl_api_ipsec_itf_t itf;
};

/** \brief Add IPsec interface interface response
    @param context - sender context, to match reply w/ request
    @param retval - return status
    @param sw_if_index - sw_if_index of new interface (for successful add)
*/
define ipsec_itf_create_reply
{
  u32 context;
  i32 retval;
  vl_api_interface_index_t sw_if_index;
};

autoreply define ipsec_itf_delete
{
  u32 client_index;
  u32 context;
  vl_api_interface_index_t sw_if_index;
};

define ipsec_itf_dump
{
  u32 client_index;
  u32 context;
  vl_api_interface_index_t sw_if_index;
};

define ipsec_itf_details
{
  u32 context;
  vl_api_ipsec_itf_t itf;
};

/** \brief Dump IPsec security association
    @param client_index - opaque cookie to identify the sender
    @param context - sender context, to match reply w/ request
    @param sa_id - optional ID of an SA to dump, if ~0 dump all SAs in SAD
*/
define ipsec_sa_dump
{
  option deprecated;
  u32 client_index;
  u32 context;
  u32 sa_id;
};
define ipsec_sa_v2_dump
{
  u32 client_index;
  u32 context;
  u32 sa_id;
};
define ipsec_sa_v3_dump
{
  u32 client_index;
  u32 context;
  u32 sa_id;
};

/** \brief IPsec security association database response
    @param context - sender context which was passed in the request
    @param entry - The SA details
    @param sw_if_index - sw_if_index of tunnel interface, policy-based SAs = ~0
    @param salt - 4 byte salt
    @param seq - current sequence number for outbound
    @param seq_hi - high 32 bits of ESN for outbound
    @param last_seq - highest sequence number received inbound
    @param last_seq_hi - high 32 bits of highest ESN received inbound
    @param replay_window - bit map of seq nums received relative to last_seq if using anti-replay
    @param stat_index - index for the SA in the stats segment @ /net/ipsec/sa
*/
define ipsec_sa_details {
  option deprecated;
  u32 context;
  vl_api_ipsec_sad_entry_t entry;

  vl_api_interface_index_t sw_if_index;
  u32 salt;
  u64 seq_outbound;
  u64 last_seq_inbound;
  u64 replay_window;

  u32 stat_index;
};
define ipsec_sa_v2_details {
  u32 context;
  vl_api_ipsec_sad_entry_v2_t entry;

  vl_api_interface_index_t sw_if_index;
  u32 salt;
  u64 seq_outbound;
  u64 last_seq_inbound;
  u64 replay_window;

  u32 stat_index;
};
define ipsec_sa_v3_details {
  u32 context;
  vl_api_ipsec_sad_entry_v3_t entry;

  vl_api_interface_index_t sw_if_index;
  u64 seq_outbound;
  u64 last_seq_inbound;
  u64 replay_window;

  u32 stat_index;
};

/** \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;
  string name[128];
  vl_api_ipsec_proto_t protocol;
  u8 index;
  bool 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;
  vl_api_ipsec_proto_t protocol;
  u8 index;
};


/** \brief IPsec Set Async mode
    @param client_index - opaque cookie to identify the sender
    @param context - sender context, to match reply w/ request
    @param async_enable - ipsec async mode on or off
*/
autoreply define ipsec_set_async_mode {
  u32 client_index;
  u32 context;
  bool async_enable;
};

counters esp_decrypt {
  rx_pkts {
    severity info;
    type counter64;
    units "packets";
    description "ESP pkts received";
  };
  rx_post_pkts {
    severity info;
    type counter64;
    units "packets";
    description "ESP-POST pkts received";
  };
  handoff {
    severity info;
    type counter64;
    units "packets";
    description "hand-off";
  };
  decryption_failed {
    severity error;
    type counter64;
    units "packets";
    description "ESP decryption failed";
  };
  integ_error {
    severity error;
    type counter64;
    units "packets";
    description "integrity check failed";
  };
  crypto_engine_error {
    severity error;
    type counter64;
    units "packets";
    description "crypto engine error (packet dropped)";
  };
  replay {
    severity error;
    type counter64;
    units "packets";
    description "SA replayed packet";
  };
  runt {
    severity error;
    type counter64;
    units "packets";
    description "undersized packet";
  };
  no_buffers {
    severity error;
    type counter64;
    units "packets";
    description "no buffers (packet dropped)";
  };
  oversized_header {
    severity error;
    type counter64;
    units "packets";
    description "buffer with oversized header (dropped)";
  };
  no_tail_space {
    severity error;
    type counter64;
    units "packets";
    description "no enough buffer tail space (dropped)";
  };
  tun_no_proto {
    severity error;
    type counter64;
    units "packets";
    description "no tunnel protocol";
  };
  unsup_payload {
    severity error;
    type counter64;
    units "packets";
    description "unsupported payload";
  };
};

counters esp_encrypt {
  rx_pkts {
    severity info;
    type counter64;
    units "packets";
    description "ESP pkts received";
  };
  post_rx_pkts {
    severity info;
    type counter64;
    units "packets";
    description "ESP-post pkts received";
  };
  handoff {
    severity info;
    type counter64;
    units "packets";
    description "Hand-off";
  };
  seq_cycled {
    severity error;
    type counter64;
    units "packets";
    description "sequence number cycled (packet dropped)";
  };
  crypto_engine_error {
    severity error;
    type counter64;
    units "packets";
    description "crypto engine error (packet dropped)";
  };
  crypto_queue_full {
    severity error;
    type counter64;
    units "packets";
    description "crypto queue full (packet dropped)";
  };
  no_buffers {
    severity error;
    type counter64;
    units "packets";
    description "no buffers (packet dropped)";
  };
  no_protection {
    severity error;
    type counter64;
    units "packets";
    description "no protecting SA (packet dropped)";
  };
  no_encryption {
    severity error;
    type counter64;
    units "packets";
    description "no Encrypting SA (packet dropped)";
  };
};

counters ah_encrypt {
  rx_pkts {
    severity info;
    type counter64;
    units "packets";
    description "AH pkts received";
  };
  crypto_engine_error {
    severity error;
    type counter64;
    units "packets";
    description "crypto engine error (packet dropped)";
  };
  seq_cycled {
    severity error;
    type counter64;
    units "packets";
    description "sequence number cycled (packet dropped)";
  };
};

counters ah_decrypt {
  rx_pkts {
    severity info;
    type counter64;
    units "packets";
    description "AH pkts received";
  };
  decryption_failed {
    severity error;
    type counter64;
    units "packets";
    description "AH decryption failed";
  };
  integ_error {
    severity error;
    type counter64;
    units "packets";
    description "Integrity check failed";
  };
  no_tail_space {
    severity error;
    type counter64;
    units "packets";
    description "not enough buffer tail space (dropped)";
  };
  drop_fragments {
    severity error;
    type counter64;
    units "packets";
    description "IP fragments drop";
  };
  replay {
    severity error;
    type counter64;
    units "packets";
    description "SA replayed packet";
  };
};

counters ipsec_tun {
  rx {
    severity info;
    type counter64;
    units "packets";
    description "good packets received";
  };
  disabled {
    severity error;
    type counter64;
    units "packets";
    description "ipsec packets received on disabled interface";
  };
  no_tunnel {
    severity error;
    type counter64;
    units "packets";
    description "no matching tunnel";
  };
  tunnel_mismatch {
    severity error;
    type counter64;
    units "packets";
    description "SPI-tunnel mismatch";
  };
  nat_keepalive {
    severity info;
    type counter64;
    units "packets";
    description "NAT Keepalive";
  };
  too_short {
    severity error;
    type counter64;
    units "packets";
    description "Too Short";
  };
  spi_0 {
    severity info;
    type counter64;
    units "packets";
    description "SPI 0";
  };
};

paths {
  "/err/esp4-encrypt" "esp_encrypt";
  "/err/esp4-encrypt-post" "esp_encrypt";
  "/err/esp4-encrypt-tun" "esp_encrypt";
  "/err/esp4-encrypt-tun-post" "esp_encrypt";
  "/err/esp6-encrypt" "esp_encrypt";
  "/err/esp6-encrypt-post" "esp_encrypt";
  "/err/esp6-encrypt-tun" "esp_encrypt";
  "/err/esp6-encrypt-tun-post" "esp_encrypt";
  "/err/esp-mpls-encrypt-tun" "esp_encrypt";
  "/err/esp-mpls-encrypt-tun-post" "esp_encrypt";
  "/err/esp4-decrypt" "esp_decrypt";
  "/err/esp4-decrypt-post" "esp_decrypt";
  "/err/esp4-decrypt-tun" "esp_decrypt";
  "/err/esp4-decrypt-tun-post" "esp_decrypt";
  "/err/esp6-decrypt" "esp_decrypt";
  "/err/esp6-decrypt-post" "esp_decrypt";
  "/err/esp6-decrypt-tun" "esp_decrypt";
  "/err/esp6-decrypt-tun-post" "esp_decrypt";
  "/err/ah4-encrypt" "ah_encrypt";
  "/err/ah6-encrypt" "ah_encrypt";
  "/err/ipsec4-tun-input" "ipsec_tun";
  "/err/ipsec6-tun-input" "ipsec_tun";
};

/*
 * Local Variables:
 * eval: (c-set-style "gnu")
 * End:
 */
