SHARE
TWEET

Untitled

a guest Oct 18th, 2019 121 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #!/bin/bash
  2.  
  3. # IMPORTANT: Don't forget to logout from your Apple ID in the settings before running it!
  4. # IMPORTANT: You will need to run this script from Recovery. In fact, macOS Catalina brings read-only filesystem which prevent this script from working from the main OS.
  5. # This script needs to be run from the volume you wish to use.
  6. # E.g. run it like this: cd /Volumes/Macintosh\ HD && sh /Volumes/Macintosh\ HD/Users/sabri/Desktop/disable.sh
  7. # WARNING: It might disable things that you may not like. Please double check the services in the TODISABLE vars.
  8.  
  9. # Get active services: launchctl list | grep -v "\-\t0"
  10. # Find a service: grep -lR [service] /System/Library/Launch* /Library/Launch* ~/Library/LaunchAgents
  11.  
  12. # Agents to disable
  13. # 'com.apple.speech.speechdatainstallerd' 'com.apple.speech.speechsynthesisd' 'com.apple.speech.synthesisserver' will freeze Edit menus
  14. # 'com.apple.bird' will prevent saving prompt from being shown
  15. TODISABLE=()
  16.  
  17. # iCloud
  18. TODISABLE+=('com.apple.security.cloudkeychainproxy3' \
  19.     'com.apple.iCloudUserNotifications' \
  20.     'com.apple.icloud.findmydeviced.findmydevice-user-agent' \
  21.     'com.apple.icloud.fmfd' \
  22.     'com.apple.icloud.searchpartyuseragent' \
  23.     'com.apple.cloudd' \
  24.     'com.apple.cloudpaird' \
  25.     'com.apple.cloudphotod' \
  26.     'com.apple.protectedcloudstorage.protectedcloudkeysyncing')
  27.  
  28. # Safari useless stuff
  29. TODISABLE+=('com.apple.SafariBookmarksSyncAgent' \
  30.     'com.apple.SafariCloudHistoryPushAgent' \
  31.     'com.apple.WebKit.PluginAgent')
  32.  
  33. # iMessage / Facetime
  34. TODISABLE+=('com.apple.imagent' \
  35.     'com.apple.imautomatichistorydeletionagent' \
  36.     'com.apple.imklaunchagent' \
  37.     'com.apple.imtransferagent' \
  38.     'com.apple.avconferenced')
  39.  
  40. # Game Center / Passbook / Apple TV / Homekit...
  41. TODISABLE+=('com.apple.gamed' \
  42.     'com.apple.passd' \
  43.     'com.apple.Maps.pushdaemon' \
  44.     'com.apple.videosubscriptionsd' \
  45.     'com.apple.CommCenter-osx' \
  46.     'com.apple.homed')
  47.  
  48. # Ad-related
  49. TODISABLE+=('com.apple.ap.adprivacyd' \
  50.     'com.apple.ap.adservicesd')
  51.  
  52. # Screensharing
  53. TODISABLE+=('com.apple.screensharing.MessagesAgent' \
  54.     'com.apple.screensharing.agent' \
  55.     'com.apple.screensharing.menuextra')
  56.  
  57. # Siri
  58. TODISABLE+=('com.apple.siriknowledged' \
  59.     'com.apple.assistant_service' \
  60.     'com.apple.assistantd' \
  61.     'com.apple.Siri.agent' \
  62.     'com.apple.parsec-fbf')
  63.  
  64. # VoiceOver / accessibility-related stuff
  65. TODISABLE+=('com.apple.VoiceOver' \
  66.     'com.apple.voicememod' \
  67.     'com.apple.accessibility.AXVisualSupportAgent' \
  68.     'com.apple.accessibility.dfrhud' \
  69.     'com.apple.accessibility.heard')
  70.  
  71. # Quicklook
  72. TODISABLE+=('com.apple.quicklook.ui.helper' \
  73.     'com.apple.quicklook.ThumbnailsAgent' \
  74.     'com.apple.quicklook')
  75.  
  76. # Sidecar
  77. TODISABLE+=('com.apple.sidecar-hid-relay' \
  78.     'com.apple.sidecar-relay')
  79.  
  80. # Debugging process
  81. TODISABLE+=('com.apple.spindump_agent' \
  82.     'com.apple.ReportCrash' \
  83.     'com.apple.ReportGPURestart' \
  84.     'com.apple.ReportPanic' \
  85.     'com.apple.DiagnosticReportCleanup' \
  86.     'com.apple.TrustEvaluationAgent')
  87.  
  88. # Others
  89. TODISABLE+=('com.apple.telephonyutilities.callservicesd' \
  90.     'com.apple.photoanalysisd' \
  91.     'com.apple.parsecd' \
  92.     'com.apple.AOSPushRelay' \
  93.     'com.apple.AOSHeartbeat' \
  94.     'com.apple.AirPlayUIAgent' \
  95.     'com.apple.AirPortBaseStationAgent' \
  96.     'com.apple.familycircled' \
  97.     'com.apple.familycontrols.useragent' \
  98.     'com.apple.familynotificationd' \
  99.     'com.apple.findmymacmessenger' \
  100.     'com.apple.sharingd' \
  101.     'com.apple.identityservicesd' \
  102.     'com.apple.java.InstallOnDemand' \
  103.     'com.apple.parentalcontrols.check' \
  104.     'com.apple.security.keychain-circle-notification' \
  105.     'com.apple.syncdefaultsd' \
  106.     'com.apple.appleseed.seedusaged' \
  107.     'com.apple.appleseed.seedusaged.postinstall' \
  108.     'com.apple.CallHistorySyncHelper' \
  109.     'com.apple.RemoteDesktop' \
  110.     'com.apple.CallHistoryPluginHelper' \
  111.     'com.apple.SocialPushAgent' \
  112.     'com.apple.touristd' \
  113.     'com.apple.macos.studentd' \
  114.     'com.apple.KeyboardAccessAgent' \
  115.     'com.apple.exchange.exchangesyncd' \
  116.     'com.apple.suggestd' \
  117.     'com.apple.AddressBook.abd' \
  118.     'com.apple.helpd' \
  119.     'com.apple.amp.mediasharingd' \
  120.     'com.apple.mediaanalysisd' \
  121.     'com.apple.mediaremoteagent' \
  122.     'com.apple.remindd')
  123.  
  124. for agent in "${TODISABLE[@]}"
  125. do
  126.     mv ./System/Library/LaunchAgents/${agent}.plist ./System/Library/LaunchAgents/${agent}.plist.bak
  127.     echo "[OK] Agent ${agent} disabled"
  128. done
  129.  
  130. # Daemons to disable
  131. TODISABLE=()
  132.  
  133. # iCloud
  134. TODISABLE+=('com.apple.analyticsd')
  135.  
  136. # Others
  137. TODISABLE+=('com.apple.netbiosd' \
  138.     'com.apple.preferences.timezone.admintool' \
  139.     'com.apple.remotepairtool' \
  140.     'com.apple.security.FDERecoveryAgent' \
  141.     'com.apple.SubmitDiagInfo' \
  142.     'com.apple.screensharing' \
  143.     'com.apple.appleseed.fbahelperd' \
  144.     'com.apple.apsd' \
  145.     'com.apple.ManagedClient.cloudconfigurationd' \
  146.     'com.apple.ManagedClient.enroll' \
  147.     'com.apple.ManagedClient' \
  148.     'com.apple.ManagedClient.startup' \
  149.     'com.apple.locate' \
  150.     'com.apple.locationd' \
  151.     'com.apple.eapolcfg_auth' \
  152.     'com.apple.RemoteDesktop.PrivilegeProxy' \
  153.     'com.apple.mediaremoted')
  154.  
  155. for daemon in "${TODISABLE[@]}"
  156. do
  157.     mv ./System/Library/LaunchDaemons/${daemon}.plist ./System/Library/LaunchDaemons/${daemon}.plist.bak
  158.     echo "[OK] Daemon ${daemon} disabled"
  159. done
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top