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

Helper reallocate packet #3110

Merged
merged 4 commits into from
Dec 11, 2023

Conversation

shankarseal
Copy link
Collaborator

Description

This fixes #3090. A reallocate_packet flag is added to the helper function prototype metadata, to pass onto the PREVAIL verifier, to validate programs that uses any helper function that may change the packet pointers such as xdp_adjust_head.

Testing

A new netsh tests is added that tries to load an unsafe XDP program and fails.

Documentation

Updated extension documentation.

Installation

No changes to installation.

@shankarseal shankarseal force-pushed the helper_reallocate_packet branch from 1db057d to dfc180a Compare December 11, 2023 07:42
@shankarseal shankarseal force-pushed the helper_reallocate_packet branch from dfc180a to b043234 Compare December 11, 2023 10:29
@shankarseal shankarseal marked this pull request as ready for review December 11, 2023 11:15
@Alan-Jowett Alan-Jowett added this pull request to the merge queue Dec 11, 2023
Merged via the queue into microsoft:main with commit 13eed74 Dec 11, 2023
shankarseal added a commit to shankarseal/ebpf-for-windows that referenced this pull request Feb 14, 2024
github-merge-queue bot pushed a commit that referenced this pull request Feb 15, 2024
@shpalani shpalani mentioned this pull request Feb 15, 2024
shpalani pushed a commit to shpalani/ebpf-for-windows that referenced this pull request Feb 15, 2024
shpalani pushed a commit to shpalani/ebpf-for-windows that referenced this pull request Feb 15, 2024
shpalani added a commit that referenced this pull request Feb 16, 2024
* fix check for static initialization of hash-of-maps key length. (#3260)

* fix check for static initialization of hash-of-maps key length.

* Delete tests/bpf2c_tests/expected/xdp_adjust_head_unsafe_dll.c

* Delete tests/bpf2c_tests/expected/xdp_adjust_head_unsafe_raw.c

* Delete tests/bpf2c_tests/expected/xdp_adjust_head_unsafe_sys.c

* fix build failure

---------

Co-authored-by: Anurag Saxena <anusa@microsoft.com>

* Revert "Helper reallocate packet (#3110)" (#3263)

This reverts commit 13eed74.

* bump version to 0.14.1

* fix test

---------

Co-authored-by: Shankar Seal <74580197+shankarseal@users.noreply.github.com>
Co-authored-by: Anurag Saxena <anusa@microsoft.com>
@shankarseal shankarseal deleted the helper_reallocate_packet branch April 23, 2024 07:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

eBPF does not support helper functions that modify direct packet data
5 participants