I've searched and found traces of AppSync, here is the code to find out whether it exists on device. Yes, it's a little longer than needed but I wanted to be sure. Of course in release code you should obfuscate strings somehow, but that's it:
bool isAppSyncExist()
{
BOOL isbash = NO;
BOOL isappsync = NO;
FILE *f = fopen("/bin/bash", "r");
if (f != NULL)
{
//Device is jailbroken
isbash = YES;
fclose(f);
}
if (isbash)
{
f = fopen("/Library/MobileSubstrate/DynamicLibraries/AppSync.plist", "r");
if (f != NULL)
{
isappsync = YES;
fclose(f);
}
if (isappsync == NO)
{
NSError *err;
NSArray *files = [[NSFileManager defaultManager] contentsOfDirectoryAtPath:@"/private/var/lib/dpkg/info" error:&err];
for (int i = 0; i < files.count; i++)
{
NSString *fname = [files objectAtIndex:i];
if ([fname rangeOfString:@"appsync" options:NSCaseInsensitiveSearch].location != NSNotFound)
{
isappsync = YES;
break;
}
}
}
if (isappsync == NO)
{
NSError *err;
NSArray *files = [[NSFileManager defaultManager] contentsOfDirectoryAtPath:@"/var/lib/dpkg/info" error:&err];
for (int i = 0; i < files.count; i++)
{
NSString *fname = [files objectAtIndex:i];
if ([fname rangeOfString:@"appsync" options:NSCaseInsensitiveSearch].location != NSNotFound)
{
isappsync = YES;
break;
}
}
}
}
return isappsync == YES;
}