Advertisement
developer

Detect Cydia / AdBlocker - Admob / iAd

Feb 12th, 2013
197
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Detect evasi0n, Cydia, AdBlocker on iOS 6.1
  2.  
  3. // Detect evasi0n
  4. NSString *filePath = @"/private/var/evasi0n/evasi0n";
  5. if ([[NSFileManager defaultManager] fileExistsAtPath:filePath])
  6. {
  7.    // evasi0n detected do something
  8. }
  9.  
  10. // Detect Cydia
  11. NSString *filePath = @"/Applications/Cydia.app";
  12. if ([[NSFileManager defaultManager] fileExistsAtPath:filePath])
  13. {
  14.    // Cydia detected do something
  15. }
  16.  
  17. or
  18. NSURL* url = [NSURL URLWithString:@"cydia://package/com.cydia.detect"];
  19.  return [[UIApplication sharedApplication] canOpenURL:url];
  20.  
  21. // Detect AdBlocker (AdBlocker blocks Google Admob, AdSense and iAds)
  22. NSString *filePath = @"/Library/MobileSubstrate/DynamicLibraries/AdBlocker.dylib";
  23. if ([[NSFileManager defaultManager] fileExistsAtPath:filePath])
  24. {
  25.    // AdBlocker (from Cydia) detected do something
  26. }
  27.  
  28.  
  29. // Detect AppCake App (Cracked Apps)
  30. NSString *filePath = @"/Applications/AppCake3.app/AppCake3";
  31. if ([[NSFileManager defaultManager] fileExistsAtPath:filePath])
  32. {
  33.    // AppCake (repo from Cydia) detected do something
  34. }
  35.  
  36. --
  37.  
  38. >find / -name "AdBlock*"
  39. /Library/MobileSubstrate/DynamicLibraries/AdBlocker.dylib
  40. /Library/MobileSubstrate/DynamicLibraries/AdBlocker.plist
  41. /Library/PreferenceLoader/Preferences/AdBlocker.plist
  42. /System/Library/PreferenceBundles/AdBlockerPreferences.bundle
  43. /System/Library/PreferenceBundles/AdBlockerPreferences.bundle/AdBlockerPreferences
  44. /System/Library/PreferenceBundles/AdBlockerPreferences.bundle/AdBlockerPreferences.plist
  45. /private/var/mobile/Library/SBSettings/Toggles/AdBlocker
  46.  
  47. >find / -name "evasi0n*"
  48. /private/var/evasi0n
  49. /private/var/evasi0n/evasi0n
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement