-
- Downloads
Use tor_getpw{nam,uid} wrappers to fix bug 11946
When running with User set, we frequently try to look up our information in the user database (e.g., /etc/passwd). The seccomp2 sandbox setup doesn't let us open /etc/passwd, and probably shouldn't. To fix this, we have a pair of wrappers for getpwnam and getpwuid. When a real call to getpwnam or getpwuid fails, they fall back to a cached value, if the uid/gid matches. (Granting access to /etc/passwd isn't possible with the way we handle opening files through the sandbox. It's not desirable either.)
Showing
- changes/bug11946 5 additions, 0 deletionschanges/bug11946
- src/common/compat.c 4 additions, 4 deletionssrc/common/compat.c
- src/common/util.c 5 additions, 5 deletionssrc/common/util.c
- src/or/connection.c 2 additions, 2 deletionssrc/or/connection.c
- src/or/control.c 1 addition, 1 deletionsrc/or/control.c
Loading
Please register or sign in to comment