Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add transient mode #13

Merged
merged 4 commits into from
Aug 30, 2023
Merged

Conversation

qdeslandes
Copy link
Contributor

Transient mode ensure bpfilter won't load /run/bpfilter.blob at startup, nor will it save its runtime context into /run/bpfilter.blob. Additionally, all the generated BPF program will be detached and unloaded when bpfilter stops.

Use argp.h to define command line arguments and parse them. Arguments
are stored within main.c and are not accessible from other translation
unit for now.

Add --transient argument to the list of supported arguments, it will be
used in a later commit.

Signed-off-by: Quentin Deslandes <[email protected]>
--transient will prevent bpfilter from loading its context from
bpfilter.blob, nor will it allow to save its runtime context into
bpfilter.blob. Additionally, all the BPF programs will be unloaded when
bpfilter stops.

To summarise, --transient prevent bpfilter's system modifications to
remain after its stopped.

Signed-off-by: Quentin Deslandes <[email protected]>
@qdeslandes qdeslandes merged commit 3d48ff8 into facebook:main Aug 30, 2023
3 checks passed
@qdeslandes qdeslandes deleted the add_transient_mode branch August 30, 2023 14:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants