Commit d8eea85e authored by Robert Ricci's avatar Robert Ricci

Remove hardcoded group "flux" from calls to suexec. Use the TBADMIN

group from the defs file instead.
parent 36f805a2
...@@ -208,7 +208,7 @@ elseif (strcmp($approval, "approve") == 0) { ...@@ -208,7 +208,7 @@ elseif (strcmp($approval, "approve") == 0) {
# Invoke the script. This does it all. If it fails, we will find out # Invoke the script. This does it all. If it fails, we will find out
# about it. # about it.
# #
SUEXEC($uid, "flux", "webmkproj $pid", 0); SUEXEC($uid, $TBADMINGROUP, "webmkproj $pid", 0);
echo "<h3><p> echo "<h3><p>
Project $pid (User: $headuid) has been approved. Project $pid (User: $headuid) has been approved.
......
...@@ -497,8 +497,8 @@ while (list ($header, $value) = each ($HTTP_POST_VARS)) { ...@@ -497,8 +497,8 @@ while (list ($header, $value) = each ($HTTP_POST_VARS)) {
# #
# Create user account on control node. # Create user account on control node.
# #
SUEXEC($uid, "flux", "webmkacct -a $user", 0); SUEXEC($uid, $TBADMINGROUP, "webmkacct -a $user", 0);
SUEXEC($uid, "flux", "websetgroups $user", 0); SUEXEC($uid, $TBADMINGROUP, "websetgroups $user", 0);
continue; continue;
} }
......
...@@ -6,6 +6,7 @@ $TBDIR = "@prefix@/"; ...@@ -6,6 +6,7 @@ $TBDIR = "@prefix@/";
$WWWDEFS = "@WWWDEFS@"; $WWWDEFS = "@WWWDEFS@";
$OURDOMAIN = "@OURDOMAIN@"; $OURDOMAIN = "@OURDOMAIN@";
$BOSSNODE = "@BOSSNODE@"; $BOSSNODE = "@BOSSNODE@";
$TBADMINGROUP = "@TBADMINGROUP@";
# Overridden by the defs file! # Overridden by the defs file!
$TBMAINSITE = 0; $TBMAINSITE = 0;
......
...@@ -124,7 +124,7 @@ $query_result = ...@@ -124,7 +124,7 @@ $query_result =
# #
# Remove the project directory and the group. # Remove the project directory and the group.
# #
SUEXEC($uid, "flux", "rmproj $pid", 0); SUEXEC($uid, $TBADMINGROUP, "rmproj $pid", 0);
# #
# Then the project table itself. # Then the project table itself.
......
...@@ -139,7 +139,7 @@ DBQueryFatal("update users set usr_modified=now() ". ...@@ -139,7 +139,7 @@ DBQueryFatal("update users set usr_modified=now() ".
# #
# mkacct updates the user pubkeys. # mkacct updates the user pubkeys.
# #
SUEXEC($uid, "flux", "webmkacct -a $target_uid", 0); SUEXEC($uid, $TBADMINGROUP, "webmkacct -a $target_uid", 0);
header("Location: showpubkeys.php3?target_uid=$target_uid"); header("Location: showpubkeys.php3?target_uid=$target_uid");
......
...@@ -102,7 +102,7 @@ $query_result = ...@@ -102,7 +102,7 @@ $query_result =
# #
# Remove the user account before killing the user entry. # Remove the user account before killing the user entry.
# #
SUEXEC($uid, "flux", "rmacct-ctrl $target_uid", 0); SUEXEC($uid, $TBADMINGROUP, "rmacct-ctrl $target_uid", 0);
# #
# Then the users table, # Then the users table,
......
...@@ -492,7 +492,7 @@ TBMAIL("$usr_name <$usr_email>", ...@@ -492,7 +492,7 @@ TBMAIL("$usr_name <$usr_email>",
# #
# mkacct updates the user gecos and password. # mkacct updates the user gecos and password.
# #
SUEXEC($uid, "flux", "webmkacct -a $target_uid", 0); SUEXEC($uid, $TBADMINGROUP, "webmkacct -a $target_uid", 0);
# #
# Spit out a redirect so that the history does not include a post # Spit out a redirect so that the history does not include a post
......
...@@ -64,7 +64,7 @@ $log_entry = addslashes($log_entry); ...@@ -64,7 +64,7 @@ $log_entry = addslashes($log_entry);
# #
# Run the external script. # Run the external script.
# #
SUEXEC($uid, "flux", "webnodelog -t $log_type -m \"$log_entry\" $node_id", 1); SUEXEC($uid, $TBADMINGROUP, "webnodelog -t $log_type -m \"$log_entry\" $node_id", 1);
# #
# Show result. # Show result.
......
...@@ -92,7 +92,8 @@ $output = array(); ...@@ -92,7 +92,8 @@ $output = array();
$retval = 0; $retval = 0;
$result = $result =
exec("$TBSUEXEC_PATH $uid flux webnscheck $nsfile", $output, $retval); exec("$TBSUEXEC_PATH $uid $TBADMINGROUP webnscheck $nsfile", $output,
$retval);
echo "<center>"; echo "<center>";
echo "<h1>Syntax Check Results</h1>"; echo "<h1>Syntax Check Results</h1>";
......
...@@ -111,7 +111,7 @@ if ($isadmin) { ...@@ -111,7 +111,7 @@ if ($isadmin) {
if ($idle) { if ($idle) {
# Run idlecheck and get the info # Run idlecheck and get the info
#print "<pre>Running idlecheck\n"; #print "<pre>Running idlecheck\n";
$x=exec("$TBSUEXEC_PATH $uid flux webidlecheck -s -u", $x=exec("$TBSUEXEC_PATH $uid $TBADMINGROUP webidlecheck -s -u",
$l, $rv); $l, $rv);
reset($l); reset($l);
while(list($index,$i) = each ($l)) { while(list($index,$i) = each ($l)) {
......
...@@ -139,7 +139,7 @@ else { ...@@ -139,7 +139,7 @@ else {
$flags = "-b"; $flags = "-b";
} }
$result = exec("$TBSUEXEC_PATH $uid flux webreport $flags $pid $eid", $result = exec("$TBSUEXEC_PATH $uid $TBADMINGROUP webreport $flags $pid $eid",
$output, $retval); $output, $retval);
echo "<XMP>\n"; echo "<XMP>\n";
......
...@@ -337,7 +337,7 @@ if (isset($usr_key)) { ...@@ -337,7 +337,7 @@ if (isset($usr_key)) {
# #
# mkacct updates the user pubkeys. # mkacct updates the user pubkeys.
# #
SUEXEC($uid, "flux", "webmkacct -a $target_uid", 0); SUEXEC($uid, $TBADMINGROUP, "webmkacct -a $target_uid", 0);
} }
header("Location: showpubkeys.php3?target_uid=$target_uid&finished=1"); header("Location: showpubkeys.php3?target_uid=$target_uid&finished=1");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment