We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
The current analysis cannot catch a buffer overflow in a structure.
For instance:
#include <ikos/analyzer/intrinsic.h> typedef struct { int tab[10]; int x; } Struct; int main() { Struct s; s.tab[10] = 1; // overflow on tab, writes on x __ikos_assert(s.x == 1); return 0; }
The analyzer only checks that the memory write is within the structure, so it is considered safe.
The analyzer will actually know that s.x is 1, so we could say that the analysis is somewhat sound regarding the memory model.
s.x
To fix this, we should investigate the inbounds flag of the LLVM getelementptr instruction.
inbounds
getelementptr
See:
The text was updated successfully, but these errors were encountered:
Is this a bug or a feature request?
Sorry, something went wrong.
My understanding is that this is not a bug. I'm switching labels accordingly. If you disagree, please revert the change.
No branches or pull requests
The current analysis cannot catch a buffer overflow in a structure.
For instance:
The analyzer only checks that the memory write is within the structure, so it is considered safe.
The analyzer will actually know that
s.x
is 1, so we could say that the analysis is somewhat sound regarding the memory model.To fix this, we should investigate the
inbounds
flag of the LLVMgetelementptr
instruction.See:
The text was updated successfully, but these errors were encountered: