Monday, August 26, 2019

#1 2018-10-05 05:07:21 am

Titanium
Member
From:: ~/Desktop
Registered: 2005-08-22
Posts: 54
Website

Full Disk Access

Hello,

Is it possible to check if my application can access to the disk or not (System Preferences > Security & Privacy > Privacy > Full Disk Access)?

Nothing in the TCC.db...

Thanks.


iMac 27" 3,4 Ghz - MacOS Mojave
https://www.titanium-software.fr

Offline

 

#2 2018-10-05 07:50:13 am

Shane Stanley
Member
From:: Australia
Registered: 2002-12-07
Posts: 5837

Re: Full Disk Access

No, other than trying it.


Shane Stanley <sstanley@myriad-com.com.au>
www.macosxautomation.com/applescript/apps/
latenightsw.com

Offline

 

#3 2018-10-05 09:59:23 pm

Titanium
Member
From:: ~/Desktop
Registered: 2005-08-22
Posts: 54
Website

Re: Full Disk Access

A solution... It's necessary to copy the TCC.db file (on the Desktop, for example) and it's possible to check with this command:

Applescript:

try
set checkAccessApp to do shell script "sqlite3 /Users/myaccount/Desktop/TCC.db 'SELECT * FROM access' | grep kTCCServiceSystemPolicyAllFiles"

if checkAccessApp contains "com.xxxxxx.myApp|0|1|1|" then
display alert "OK"
end if
on error
display alert "Not OK"
end try

Problem: It's possible to copy the TCC.db file from the Finder but not with a command (operation not permitted)

Applescript:

do shell script "cp /Library/'Application Support'/com.apple.TCC/TCC.db /Users/myaccount/Desktop/TCC.db" with administrator privileges

Last edited by Titanium (2018-10-05 10:52:09 pm)


iMac 27" 3,4 Ghz - MacOS Mojave
https://www.titanium-software.fr

Offline

 

#4 2018-10-09 12:00:29 pm

bentoms
Member
Registered: 2008-10-21
Posts: 73
Website

Re: Full Disk Access

Offline

 

Board footer

Powered by FluxBB

RSS (new topics) RSS (active topics)