You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(auth): unify caller authentication to isTrustedSender and remove binary path identification
Replace binary path-based caller identification (getExecutablePathAndCmdline,
mapMethodCaller, checkInvokePermission, checkSenderNsMntValid) with
isTrustedSender + polkit authentication across all protected interfaces
(InstallPackage, RemovePackage, DistUpgradePartly, PrepareDistUpgradePartly,
PrepareFullScreenUpgrade, PowerOff, SetUpdateSources, UpdateMode,
CheckUpdateModeWrite). Remove hardcoded executable path constants and
whitelists (allowInstallPackageExecPaths, allowRemovePackageExecPaths).
Consolidate duplicated isTrustedSender + polkit check blocks into the
existing checkInvokePermission method, eliminating inline authentication
logic in InstallPackage, RemovePackage, DistUpgradePartly,
PrepareFullScreenUpgrade and PrepareDistUpgradePartly.
Introduce manager_auth.go with allow-caller registration, lightdm trusted
UID support, and persistent runtime state under /run/lastore. Export
SetAllowCaller D-Bus method for deepin-security-loader integration.
Add D-Bus access rules: deny SetAllowCaller/PowerOff for default policy,
allow deepin-daemon and lightdm groups. Configure RuntimeDirectoryMode
to 0700 with RuntimeDirectoryPreserve=yes. Add appstore_intranet.list
to trusted source list. Remove deprecated deny-exec-whitelist and
install-package-support-auth config items. Add isInstallLikeJobType
helper. Refactor PrepareFullScreenUpgrade to use terminate() closure
and remove dead lastore-upgrader.service fallback path.
Add unit tests for manager_auth (isTrustedSender, SetAllowCaller
persistence, runtime state load/remove, bus restart cleanup) and
isInstallLikeJobType. Fix appinfo_test to use t.TempDir() instead
of hardcoded /tmp path.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
0 commit comments