Skip to content

Commit

Permalink
Disable user switching for macOS. (#638)
Browse files Browse the repository at this point in the history
  • Loading branch information
bcipriano committed Mar 4, 2020
1 parent 42139e9 commit 1f93b4d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions rqd/rqd/rqutil.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def permissionsHigh():
def permissionsLow():
"""Sets the effective gid/uid to one with less permissions:
RQD_GID and RQD_UID"""
if platform.system() == 'Windows':
if platform.system() in ('Windows', 'Darwin'):
return
if os.getegid() != rqd.rqconstants.RQD_GID or os.geteuid() != rqd.rqconstants.RQD_UID:
__becomeRoot()
Expand All @@ -99,7 +99,7 @@ def permissionsLow():

def permissionsUser(uid, gid):
"""Sets the effective gid/uid to supplied values"""
if platform.system() == 'Windows':
if platform.system() in ('Windows', 'Darwin'):
return
PERMISSIONS.acquire()
__becomeRoot()
Expand Down

0 comments on commit 1f93b4d

Please sign in to comment.