Skip to content

Instantly share code, notes, and snippets.

@adison
Created September 9, 2014 08:51
Show Gist options
  • Save adison/dbd810ebcc71cd33bf5a to your computer and use it in GitHub Desktop.
Save adison/dbd810ebcc71cd33bf5a to your computer and use it in GitHub Desktop.
isJailBroken
+ (BOOL)isJailbroken {
FILE *f = fopen("/bin/bash", "r");
BOOL isJailbroken = NO;
if (f != NULL)
// Device is jailbroken
isJailbroken = YES;
else
// Device isn't jailbroken
isJailbroken = NO;
fclose(f);
return isJailbroken;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment