Created
August 14, 2018 16:46
-
-
Save erikng/6475a89c60303d1e16c0c1d982346267 to your computer and use it in GitHub Desktop.
allowed_tcc_binaries.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
# In order for this to work, you will need to go to System Preferences in Mojave -> Security & Privacy -> Privacy -> Full Disk Access and grant Terminal.app permissions | |
import sqlite3 | |
conn = sqlite3.connect('/Library/Application Support/com.apple.TCC/TCC.db') | |
c = conn.cursor() | |
query = 'SELECT * FROM access' | |
c.execute(query) | |
allowed_binaries = c.fetchall() | |
for binary in allowed_binaries: | |
print binary |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment