diff options
| author | Ophestra Umiker <cat@ophivana.moe> | 2024-11-04 03:15:39 +0900 |
|---|---|---|
| committer | Ophestra Umiker <cat@ophivana.moe> | 2024-11-04 03:15:39 +0900 |
| commit | af15b1c048e97c092f7a5eeb30f20d13cd972486 (patch) | |
| tree | c2d9e82655844cbf7130651f3a918b8c8a256f13 /internal/app/system.go | |
| parent | 7962681f4a9ea0614fe788ca2cda2c697cfff162 (diff) | |
app: support mapping target uid as privileged uid in sandbox
Chromium's D-Bus client implementation refuses to work when its getuid call returns a different value than what the D-Bus server is running as. The reason behind this is not fully understood, but this workaround is implemented to support chromium and electron apps. This is not used by default since it has many side effects that break many other programs, like SSH on NixOS.
Signed-off-by: Ophestra Umiker <cat@ophivana.moe>
Diffstat (limited to 'internal/app/system.go')
| -rw-r--r-- | internal/app/system.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/internal/app/system.go b/internal/app/system.go index 3c17cf41..47bbd7ed 100644 --- a/internal/app/system.go +++ b/internal/app/system.go @@ -20,6 +20,11 @@ type appSealSys struct { // target user sealed from config user *user.User + // mapped uid and gid in user namespace + mappedID int + // string representation of mappedID + mappedIDString string + needRevert bool saveState bool *system.I |
