Skip to content
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

No POIs in vulnerable program #66

Open
sherkat69 opened this issue Jan 3, 2024 · 2 comments
Open

No POIs in vulnerable program #66

sherkat69 opened this issue Jan 3, 2024 · 2 comments

Comments

@sherkat69
Copy link

hi

i am trying to test a code with MATE:

int main(){

	int x = 1;
	if (x=0){
	 x=3;
	 }
	int y = x/0;

	int size = 5;
	char *src = "xxxxxxxxxx";
	int *dest = malloc(size + 1);
	memcpy(dest, src, size);
	
	int* alc_mem__ptr = malloc(5);
	memcpy(alc_mem__ptr, src, 9);
	free(alc_mem__ptr);
	memcpy(alc_mem__ptr, src, 9);

	return 0;
}

this code has several issues; redundancy, use after free, overflow ...
but i am not getting any reports in POI or any other sections.

to make sure that i correctly installed MATE, i analyzed "authentication.c" file and two problems are shown in POI section.

p.s: how to delete the scanned project in build section?

@langston-barrett langston-barrett changed the title vulnerability report problem No POIs in vulnerable program Jan 3, 2024
@langston-barrett
Copy link
Collaborator

@sherkat69 MATE only checks for certain kinds of POIs (e.g., it checks for UAF but not overflow). Additionally, I wouldn't be surprised if the compiler has optimized away the straightforward UB in your program, you can check this by compiling with clang -emit-llvm and inspecting the bitcode to see if the UB is still present.

@sherkat69
Copy link
Author

is there any command to clear all previous builds?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants