Skip to content

Instantly share code, notes, and snippets.

@dreness
Created October 23, 2019 18:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dreness/4e0c100dbcaf2d6333a6d3d1e67e1794 to your computer and use it in GitHub Desktop.
Save dreness/4e0c100dbcaf2d6333a6d3d1e67e1794 to your computer and use it in GitHub Desktop.
Show recent #TCC entries
#!/bin/sh
# ** NOTE: probably requires that SIP is disabled **
# To show all entries, remove "limit 10" from the queries.
echo "Recent user TCC entries:"
sqlite3 -line ~/Library/Application\ Support/com.apple.TCC/TCC.db "SELECT service, client, allowed, prompt_count, Datetime(last_modified, 'unixepoch') as modified FROM access order by modified desc limit 10;"
echo "\n-----------------------------------------\n"
echo "Recent system TCC entries:"
sqlite3 -line /Library/Application\ Support/com.apple.TCC/TCC.db "SELECT service, client, allowed, prompt_count, Datetime(last_modified, 'unixepoch') as modified FROM access order by modified desc limit 10;"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment