Skip to content

Instantly share code, notes, and snippets.

@viktorbenei
Forked from mtauraso/add_launchd_to_tcc.sh
Last active August 29, 2015 14:27
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save viktorbenei/ca1e013ddfa5675bc07d to your computer and use it in GitHub Desktop.
Save viktorbenei/ca1e013ddfa5675bc07d to your computer and use it in GitHub Desktop.
TCC Database Script
#!/bin/bash
# This will add lauchd to the list of allowed processes for accessibility access
sudo sqlite3 /Library/Application\ Support/com.apple.TCC/TCC.db "INSERT or REPLACE INTO access VALUES('kTCCServiceAccessibility','/sbin/osascript',1,1,1,NULL)"
# This outputs the rows in the TCC database
sudo sqlite3 /Library/Application\ Support/com.apple.TCC/TCC.db 'select * from access'
echo "Restart is required for these changes to take effect"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment