[Merge] ~gunnarhj/ubuntu-release-upgrader:temp-font into ubuntu-release-upgrader:ubuntu/main
Nick Rosbrook
mp+451815 at code.launchpad.net
Fri Sep 22 21:27:33 UTC 2023
> I have struggled a bit more with this. Tried a quick and dirty way to drop
> privileges, but it proved to not be sufficient.
>
> The trick is to make it both read from and write to the right dconf database
> ($HOME/.config/dconf/user), and when I only changed setresgid and setresuid,
> it still interacted with /root/.cache/dconf/user. Changing HOME made me come
> closer, but it insists to create $HOME/.cache/dconf/user instead of updating
> $HOME/.config/dconf/user.
>
> So I'm stuck. Again.
There is a function in DistUpgradeController.py that should work. I think you just need to do this in both of your functions:
try:
self.controller._setNonRootEUID()
// existing code
finally:
os.seteuid(os.getuid())
--
https://code.launchpad.net/~gunnarhj/ubuntu-release-upgrader/+git/ubuntu-release-upgrader/+merge/451815
Your team Ubuntu Core Development Team is requested to review the proposed merge of ~gunnarhj/ubuntu-release-upgrader:temp-font into ubuntu-release-upgrader:ubuntu/main.
More information about the Ubuntu-reviews
mailing list