aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/tcp/tcp_sdl.h
diff options
context:
space:
mode:
authorSteven Luong <sluong@cisco.com>2024-11-18 12:08:57 -0800
committerFlorin Coras <florin.coras@gmail.com>2024-12-23 21:28:08 +0000
commit6d4dbd4f29d6789cf4ea799d0b2eb9d489fa339d (patch)
tree3c1b6b1d56bd86a1d6a99e36c020a81f54a43f8b /src/vnet/tcp/tcp_sdl.h
parent755690c6c31671bdce4771db04199e151c32c5d0 (diff)
session: add auto sdl
New CLI to enable/disable auto-sdl (requires session enable rt-backend sdl) auto-sdl <enable|disable> [threshold <n>] [remove-timeout <t>] threshold is defined as the number of packets before the SDL entry is created to deny the source. remove-timeout is defined as the duration to remove the SDL entry which was created earlier. Type: feature Change-Id: I513094a59663970beae33257006c652674643764 Signed-off-by: Steven Luong <sluong@cisco.com>
Diffstat (limited to 'src/vnet/tcp/tcp_sdl.h')
-rw-r--r--src/vnet/tcp/tcp_sdl.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/src/vnet/tcp/tcp_sdl.h b/src/vnet/tcp/tcp_sdl.h
new file mode 100644
index 00000000000..482881b5b43
--- /dev/null
+++ b/src/vnet/tcp/tcp_sdl.h
@@ -0,0 +1,27 @@
+/* SPDX-License-Identifier: Apache-2.0
+ * Copyright (c) 2024 Cisco Systems, Inc.
+ */
+
+#ifndef _vnet_tcp_sdl_h_
+#define _vnet_tcp_sdl_h_
+
+typedef struct _auto_sdl_track_prefix_args
+{
+ fib_prefix_t prefix;
+ u8 *tag;
+ u32 action_index;
+ u32 fib_index;
+} auto_sdl_track_prefix_args_t;
+
+typedef int (*tcp_sdl_cb_fn_t) (auto_sdl_track_prefix_args_t *args);
+extern void tcp_sdl_enable_disable (tcp_sdl_cb_fn_t fp);
+
+#endif /* _vnet_tcp_sdl_h_ */
+
+/*
+ * fd.io coding-style-patch-verification: ON
+ *
+ * Local Variables:
+ * eval: (c-set-style "gnu")
+ * End:
+ */