-
Notifications
You must be signed in to change notification settings - Fork 112
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
Instrumentation fails for the "calendar" module from the standard library #30
Comments
Oh, thanks for the heads-up, we'll look into it. |
Looks like this is specific to the 3.10 upgrade |
I believe I've identified the issue. After instrumenting code, Atheris needs to fix-up instruction offsets. In one code path in
Calling
This wasn't detected during testing because this particular code path is only triggered in the unlikely event that (1) the argument is an offset for an absolute jump instruction, and (2) the argument was previously <256 but is now >=256. Here's a minimum reproducer of this issue:
|
We'll validate that this fix is indeed correct, and if so cut a release, most likely tomorrow. |
In one rare code path, adjust() adjusts jump instruction offsets with `self.arg += size`. Calling self.arg += size in 3.10 is incorrect, because the argument to jump instructions changed from a byte offset to an instruction offset. This change calls the correct function to handle both 3.10 and pre-3.10 indexing. See #30 for more details.
Issue fixed and released as 2.0.11. |
Code:
Output:
The text was updated successfully, but these errors were encountered: