You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The bounds_check function in ubpf_vm.c has two checks that are susceptible to buffer overflow if addr value is to high. This could lead to incorrect memory access and possibly cause a segmentation fault and a crash.
Here is an example of a payload that would trigger the overflow and try to write 0 to the 0xFFFFFFFFFFF address:
To address this issue, I propose adding a check to ensure that the value of addr + size does not cause an integer overflow before performing the bounds check. If the check fails, the function will print an error message and return false.
Here is the updated code for the bounds_check function:
With this change, the bounds_check function will check for integer overflow before performing the bounds check, ensuring that the function is protected against buffer overflow.
The text was updated successfully, but these errors were encountered:
The bounds_check function in ubpf_vm.c has two checks that are susceptible to buffer overflow if addr value is to high. This could lead to incorrect memory access and possibly cause a segmentation fault and a crash.
Here is an example of a payload that would trigger the overflow and try to write 0 to the 0xFFFFFFFFFFF address:
To address this issue, I propose adding a check to ensure that the value of addr + size does not cause an integer overflow before performing the bounds check. If the check fails, the function will print an error message and return false.
Here is the updated code for the bounds_check function:
ubpf_vm.c:995
With this change, the bounds_check function will check for integer overflow before performing the bounds check, ensuring that the function is protected against buffer overflow.
The text was updated successfully, but these errors were encountered: