Skip to content

Commit

Permalink
Mac: Fix permission errors when running client as a daemon / system s…
Browse files Browse the repository at this point in the history
…ervice
  • Loading branch information
Charlie Fenton authored and lfield committed Jan 23, 2023
1 parent f5d4e1d commit 1976f02
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions client/check_security.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// This file is part of BOINC.
// http://boinc.berkeley.edu
// Copyright (C) 2022 University of California
// Copyright (C) 2023 University of California
//
// BOINC is free software; you can redistribute it and/or modify it
// under the terms of the GNU Lesser General Public License
Expand Down Expand Up @@ -432,7 +432,7 @@ int use_sandbox, int isManager, char* path_to_error, int len
if (retval)
return -1041;

if (sbuf.st_gid != boinc_project_gid)
if (sbuf.st_gid != boinc_master_gid)
return -1042;

if (sbuf.st_uid != 0) // root
Expand Down
4 changes: 2 additions & 2 deletions clientgui/mac/SetupSecurity.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// This file is part of BOINC.
// http://boinc.berkeley.edu
// Copyright (C) 2022 University of California
// Copyright (C) 2023 University of California
//
// BOINC is free software; you can redistribute it and/or modify it
// under the terms of the GNU Lesser General Public License
Expand Down Expand Up @@ -587,7 +587,7 @@ int SetBOINCDataOwnersGroupsAndPermissions() {
isDirectory = S_ISDIR(sbuf.st_mode);
if ((result == noErr) && (! isDirectory)) {
// Set owner and group of setprojectgrp application
sprintf(buf1, "root:%s", boinc_project_group_name);
sprintf(buf1, "root:%s", boinc_master_group_name);
// chown root:boinc_project "/Library/Application Support/BOINC Data/switcher/setprojectgrp"
err = DoSudoPosixSpawn(chownPath, buf1, fullpath, NULL, NULL, NULL, NULL);
if (err)
Expand Down

0 comments on commit 1976f02

Please sign in to comment.