Re:RFC-0082: Runnning unmodified Linux programs on Fuchsia
by trasz on Wednesday September 01, 2021 @04:56AM
(#28377638)
It cannot be forced to enter, no. It could be executed in capability mode, though, except you would have to give up dynamic linking, for obvious reasons.
As for granting new capabilities - you can pass capabilities from the outside; otherwise the whole mechanism would make no sense :-) In Capsicum case, capabilities are file descriptors, and you pass them the usual way, over Unix sockets.
Can it be forced to?
> it loses all permissions normally associated with its controlling user, with the exception of "capabilities" it already has in the form of file descriptors.
What if we want to grant an app already running a new capability on the fly? E.g. I imagine a case of user opening a file in a GUI app as an OS-level file selection dialog getting invoked (provided the app already has a capability to invoke it, as by the manifest) and producing a capability for the app to access the file the user choosse in an explicitly specified (RO or R/W) mode.