Andrewmwells/python missing extrinsic handling#393
Open
andrewmwells-amazon wants to merge 8 commits intomainfrom
Open
Andrewmwells/python missing extrinsic handling#393andrewmwells-amazon wants to merge 8 commits intomainfrom
andrewmwells-amazon wants to merge 8 commits intomainfrom
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add initial implementation for handling unmodeled functions
Suppose we need to analyze Python code that looks like this:
What we should do for modeled_fun seems clear— we use the model we have. The question is what we should do for unmodeled_fun.
We propose dividing unmodeled functions into three categories (for now we ignore aliasing):
Category A (
havocAll)An unmodeled function in Category A is assumed to havoc all globals. This is the safest option, but will let us prove the least about the code. In our example, at line 5 we would havoc a, l and b.
Category B (
havocArgsAndRet)An unmodeled function in Category B is assumed to havoc only it’s parameters. This strikes a balance between safety and expressive power. In our example, at line 5 we would havoc a and l[0].
Category C (
havocRet)An unmodeled function in Category C is assumed to havoc neither it’s parameters nor other variables. This is the least safe option, but lets us prove the most. In our example, at line 5 we would havoc a.
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.