Skip to content

Instantly share code, notes, and snippets.

@zhangyoufu
Last active August 29, 2015 14:26
Show Gist options
  • Save zhangyoufu/02488c58eeb89b396990 to your computer and use it in GitHub Desktop.
Save zhangyoufu/02488c58eeb89b396990 to your computer and use it in GitHub Desktop.
ARM d-cache
#include <stdio.h>
unsigned char shellcode[] = {
0x4f, 0xf0, 0x00, 0x00,
0xf0, 0x47,
};
int main()
{
shellcode[2] = 0x01;
// __clear_cache( &shellcode[2], &shellcode[2] );
printf( "%d\n", ((int(*)())(shellcode+1))() );
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment