BinToss / Intern

A small library for elevated tasks.
GNU General Public License v3.0
0 stars 0 forks source link

Pass parameters to interns via temporary files... #1

Open BinToss opened 3 years ago

BinToss commented 3 years ago

...and pass the file paths to the process via startup argument. Paths will be kept unique via GUID file/directory names. Those GUIDs will be passed as startup parameters to the process hosting the Intern.

Potential problems:

Unauthorized file modification could abuse the intern's elevated authorization.

The temporary files will need to be written, then locked to read-only either by file attributes or FileMode/FileAccess.

BinToss commented 3 years ago

An INI, JSON, or XML formatted-file would be easy to parse. Especially the latter.

BinToss commented 3 years ago

For permissions, there are a few ways to do them.

image

The most important sections per-principal is the principal's identity (user/group name) and the permissions that are granted and denied. The former is always a string, but the latter could be a Dictionary<string PermName, bool Grant/Allow>.