polkit (formerly PolicyKit) is a toolkit for defining and handling authorizations. It is used for allowing unprivileged processes to speak to privileged processes.
Other
68
stars
32
forks
source link
polkit uses signed int for uid_t, while linux uses unsigned #191
In gitlab.freedesktop.org by jrybar on Mar 1, 2023, 12:34
Link to the original issue: https://gitlab.freedesktop.org/polkit/polkit/-/issues/190
Despite posix which doesn't state whether uid_t should be signed,
usual linux configuration uses U32 (`grep -rn "UID_T_TYPE" /usr/include/bits/`).
Proposed fix:
Use preprocessor branch detecting the platform and change definition in struct PolkitUnixProcess accordingly, along with rest of associated code.
This will preserve multiplatformness and also allow high UIDs on linux (where it seems to be more and more required and used).
In gitlab.freedesktop.org by jrybar on Mar 1, 2023, 12:34
Link to the original issue: https://gitlab.freedesktop.org/polkit/polkit/-/issues/190 Despite posix which doesn't state whether uid_t should be signed, usual linux configuration uses U32 (`grep -rn "UID_T_TYPE" /usr/include/bits/`).
Proposed fix: Use preprocessor branch detecting the platform and change definition in
struct PolkitUnixProcess
accordingly, along with rest of associated code.This will preserve multiplatformness and also allow high UIDs on linux (where it seems to be more and more required and used).