Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 1 addition & 7 deletions docs/Plugins.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,9 @@ E.g., a plugin could filter traffic before it is processed by a worker, i.e., co
In LF, to enable a plugin, add its name to the colon-separated list of the CMake variable `LF_PLUGINS`. E.g.:

```
cmake -D LF_PLUGINS=\"bypass:wg_ratelimiter\"
cmake -D LF_PLUGINS=\"dst_ratelimiter:wg_ratelimiter\"
```

## Bypass (name: bypass)

The bypass plugin forwards network control packets directly without going through the other processing steps. Currently, the following packets are considered network control packets:
- ARP
- IPv6 ICMP Neighbor Discovery

## Host Ratelimiter (name: dst_ratelimiter)

The host ratelimiter plugin allows to define rate limits for destination addresses.
Expand Down
8 changes: 0 additions & 8 deletions src/plugins/CMakePlugins.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,6 @@ add_compile_definitions(LF_PLUGINS="${LF_PLUGINS_STRING}")

message( STATUS ${LF_PLUGINS_STRING})

if ("bypass" IN_LIST LF_PLUGINS)
message( STATUS "Plugin Bypass enabled")
add_compile_definitions(LF_PLUGIN_BYPASS=1)
target_sources(${EXEC} PRIVATE plugins/bypass.c)
else()
add_compile_definitions(LF_PLUGIN_BYPASS=0)
endif()

if ("wg_ratelimiter" IN_LIST LF_PLUGINS)
message( STATUS "Plugin WireGuard Ratelimiter enabled")
add_compile_definitions(LF_PLUGIN_WG_RATELIMITER=1)
Expand Down
109 changes: 0 additions & 109 deletions src/plugins/bypass.c

This file was deleted.

3 changes: 0 additions & 3 deletions src/plugins/plugins.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,6 @@ lf_plugins_pre(struct lf_worker_context *worker_context, struct rte_mbuf *m,
enum lf_pkt_action pkt_action)
{
enum lf_pkt_action pkt_action_res = pkt_action;
#if LF_PLUGIN_BYPASS
pkt_action = lf_bp_pre(worker_context, m, pkt_action);
#endif

(void)worker_context;
(void)m;
Expand Down
2 changes: 1 addition & 1 deletion tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ fi

test_label="lf_fw_plugins"
make_artifacts_dir
cmake_args="-D LF_WORKER=IPV4 -D LF_DRKEY_FETCHER=MOCK -D LF_PLUGINS=\"bypass:dst_ratelimiter:wg_ratelimiter\""
cmake_args="-D LF_WORKER=IPV4 -D LF_DRKEY_FETCHER=MOCK -D LF_PLUGINS=\"dst_ratelimiter:wg_ratelimiter\""
build_test

test_label="lf_scion_drkey_scion"
Expand Down