Barney-15E wrote:
For Files & Folders, the App must request access from the user. This is accomplished using "Entitlements" set when compiled.
Entitlements are only required for accessing certain protected information like Photos or Contacts or restricted Apple services or APIs like maps. Any app can try to access protected folders. If the user grants authorization, then the app will be added to the authorized list for the requested folder. Apps do not have to be designed for this.
Full Disk Access was the original method when Apple started down this path of user data privacy. That is the only way you can add an app that wasn't designed to ask for access.
Full Disk Access is a higher level of access than items like removable folders, downloads, documents, and the desktop. All of those different locations could have personal information, but this is not guaranteed. If they did have any personal information, it would be in the form of user-created content. On one had, it could be very personal, but on the other hand, it could be in some random document. Or it might not exist at all.
Full Disk Access is designed for system folders like the "Library" folder. These locations are full of all kinds of personal information. Furthermore, the information is stored in machine-readable format. So if you were a hacker and knew what data you wanted, you could just go and get it. But if you wanted the same information in the Desktop or Downloads folders, you would first have to be really lucky and hope some interesting information actually exists. Then, you would have to download all of those documents and read through them, one-by-one, looking for something.
Full Disk Access is the only way to pre-authorize an app for access to protected folders. Otherwise, you just have to wait for an app to ask. In the case of the OP, using something poorly designed like emacs, one has to open up a huge security hole allowing any ruby script full access to the computer.
A far better choice would be any one of high-quality text editors designed for the Mac.
Interestingly, I have VLC installed and it isn't in either list, but I can open files from anywhere. Perhaps it is only when the app seeks to access user data on its own, not via the Open File Dialog.
There is a concept known as "user intent". The standard file open dialog is part of the operating system, not part of an app. If an app tries to open a file using a standard file open dialog, it will have more-or-less full access because that is a user's intent and Apple honours that. This is why these parts of the operating system can't be scripted. It is only when an app is trying to do something behind the user's back that you'll get these restrictions and/or dialogs. This includes any shell script or Terminal access. There is no way to differentiate between a malicious script and a user typing at the terminal, so all such access is considered high-risk.