google / google/grr

startup.DropPrivileges does not work properly.

Open
#491 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
5.1k
Forks
796
PR merge metrics
No merged PRs in 30d

Description

In GRR 3.1.0.2, when I set `Server.username` to a non-root user, the UID is dropped, but they keep GID=0. Fixing that is easy, (just call `os.setgid` before `os.setuid`), but this opens up an even bigger mess: Some files created by the SQLite backend now get the wrong permissions (root:root). because those files are opened before DropPrivileges is called.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.