* Extend fuzzing to other map types
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* Limit fuzzing process memory
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* PR feedback
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
Co-authored-by: saxena-anurag <43585259+saxena-anurag@users.noreply.github.com>
* Update test scripts
* Make KM runner execute bpftool tests
* Make the run_tests.bat script also execute bpftool tests
* Make deploy-ebpf.ps1 -t copy all files needed for testing
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Fix test
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Fix merge error
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
Co-authored-by: saxena-anurag <43585259+saxena-anurag@users.noreply.github.com>
* Add diagrams and discussion of native driver execution type
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* PR feedback
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
Co-authored-by: saxena-anurag <43585259+saxena-anurag@users.noreply.github.com>
* Add initial bpftool tests and another libbpf test
And fix various bugs hit by the tests.
This PR only adds a couple of initial tests.
A future PR will add many more tests.
bpftool_tests.exe is meant to be run on a machine with the drivers
installed. A future PR will add it to the KM test runner in CI/CD.
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Fix release build
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Fix test
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Fix test
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Send stderr to bpf2c_tests log
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Update expected bpf2c output for map.o
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Fix bpf2c map output
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
Co-authored-by: Alan Jowett <alanjo@microsoft.com>
Co-authored-by: saxena-anurag <43585259+saxena-anurag@users.noreply.github.com>
* Switch from verbose success logging to just duration
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* Enable verification on supported file and disable for map.o
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* Encode all program info types
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* Expand hard coded program types and helper functions
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* Fix tail_call_map verification failure
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* Fix tail_call_map verification failure
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* Call ebpf_verifier prior to code gen
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* Resovle failures after merge
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* PR feedback
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* Revert rollback of catch2
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
Co-authored-by: Dave Thaler <dthaler@microsoft.com>
* Fix reply id/length on failure in KM
And make UM and KM more closely follow the same logic to catch this sort
of bug in the future. Before this, UM would succeed and KM would fail,
and there were only UM tests for this case.
Fixes#946
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Fix device_helper.hpp
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Fix reply length
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Cleanup
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* PR feedback
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
Co-authored-by: Alan Jowett <alanjo@microsoft.com>
* Gather code coverage from within self-hosted runner
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* PR feedback
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
The problem is that every bug report showed up as having "tasks" to be
done as can be seen at
https://github.com/microsoft/ebpf-for-windows/issues where a number of
bugs show "6 tasks". The checkboxes involved are not tasks, and indeed
they weren't providing us any value at present, so removed them.
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* remove dependabot from the fork.
* Revert "remove dependabot from the fork."
This reverts commit c542c6cd44.
* add sock_ops program and attach types.
* PR Feedback.
* Add short haul stress test
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* Don't log success assertions in stress test
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
Co-authored-by: Dave Thaler <dthaler@microsoft.com>
Several fields were missing descriptions in the generated docs.
This PR fixes the docs to actually show the relevant descriptions.
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
Co-authored-by: Alan Jowett <alanjo@microsoft.com>
* Put back permission security-events: write to permit codeql to run
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* CodeQL build takes > 30 minutes
Fixes#860
This PR will conflict with PR #891 which should be merged before this
one and conflicts resolved.
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
Co-authored-by: Alan Jowett <alanjo@microsoft.com>
* Cancel workflows if PR is updated with a new commit
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Fix typos
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
Co-authored-by: Alan Jowett <alanjo@microsoft.com>
* Add some header file names included by typical eBPF programs
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* PR feedback
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Fix test
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Remove unneeded include
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Add _MSC_VER checks around pragma warnings in ebpf program headers
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
* Use full path to avoid requiring an include path
Signed-off-by: Dave Thaler <dthaler@microsoft.com>
Co-authored-by: Alan Jowett <alanjo@microsoft.com>
* Only run code coverage related tests on each push
Signed-off-by: Alan Jowett <alanjo@microsoft.com>
* Update cicd.yml
Co-authored-by: saxena-anurag <43585259+saxena-anurag@users.noreply.github.com>