diff options
author | onefang | 2020-03-24 14:05:09 +1000 |
---|---|---|
committer | onefang | 2020-03-24 14:05:09 +1000 |
commit | e8442485e635aebc34c6f7e01a6be718b45ff149 (patch) | |
tree | 6d9aee3a73e2bd303bca1aa9e51f67c33044c942 /src | |
parent | Run directory has to be set group ID, so the tmux socket can be shared by tho... (diff) | |
download | opensim-SC-e8442485e635aebc34c6f7e01a6be718b45ff149.zip opensim-SC-e8442485e635aebc34c6f7e01a6be718b45ff149.tar.gz opensim-SC-e8442485e635aebc34c6f7e01a6be718b45ff149.tar.bz2 opensim-SC-e8442485e635aebc34c6f7e01a6be718b45ff149.tar.xz |
TODO--
Diffstat (limited to '')
-rw-r--r-- | src/sledjchisl/sledjchisl.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/sledjchisl/sledjchisl.c b/src/sledjchisl/sledjchisl.c index bbe5474..ba31722 100644 --- a/src/sledjchisl/sledjchisl.c +++ b/src/sledjchisl/sledjchisl.c | |||
@@ -4705,7 +4705,6 @@ jit library is loaded or the JIT compiler will not be activated. | |||
4705 | char *d; | 4705 | char *d; |
4706 | 4706 | ||
4707 | // Doing this here coz at this point we should be the correct user. | 4707 | // Doing this here coz at this point we should be the correct user. |
4708 | // TODO - things like sticky bits. | ||
4709 | if ((! qfile_exist(scBin)) && (! qfile_mkdir(scBin, S_IRUSR | S_IWUSR | S_IXUSR | S_IRGRP | S_IXGRP, true))) C("Unable to create path %s", scBin); | 4708 | if ((! qfile_exist(scBin)) && (! qfile_mkdir(scBin, S_IRUSR | S_IWUSR | S_IXUSR | S_IRGRP | S_IXGRP, true))) C("Unable to create path %s", scBin); |
4710 | if ((! qfile_exist(scEtc)) && (! qfile_mkdir(scEtc, S_IRUSR | S_IWUSR | S_IXUSR | S_IRGRP | S_IXGRP, true))) C("Unable to create path %s", scEtc); | 4709 | if ((! qfile_exist(scEtc)) && (! qfile_mkdir(scEtc, S_IRUSR | S_IWUSR | S_IXUSR | S_IRGRP | S_IXGRP, true))) C("Unable to create path %s", scEtc); |
4711 | if ((! qfile_exist(scLib)) && (! qfile_mkdir(scLib, S_IRUSR | S_IWUSR | S_IXUSR | S_IRGRP | S_IXGRP, true))) C("Unable to create path %s", scLib); | 4710 | if ((! qfile_exist(scLib)) && (! qfile_mkdir(scLib, S_IRUSR | S_IWUSR | S_IXUSR | S_IRGRP | S_IXGRP, true))) C("Unable to create path %s", scLib); |
@@ -5181,9 +5180,8 @@ fcgiDone: | |||
5181 | if (0 != WEXITSTATUS(i)) // No such sesion, create it. | 5180 | if (0 != WEXITSTATUS(i)) // No such sesion, create it. |
5182 | { | 5181 | { |
5183 | memset(toybuf, 0, sizeof(toybuf)); | 5182 | memset(toybuf, 0, sizeof(toybuf)); |
5184 | // TODO - do the sticky bit thing when we create that directory. | ||
5185 | // The sudo is only so that the session is owned by opensim, otherwise it's owned by whoever ran this script, which is a likely security hole. | 5183 | // The sudo is only so that the session is owned by opensim, otherwise it's owned by whoever ran this script, which is a likely security hole. |
5186 | // After the session is created, we rely on the caches directory to be group sticky, so that anyone in the opensim group can attach to the tmux socket. | 5184 | // After the session is created, we rely on the scRun directory to be group sticky, so that anyone in the opensim group can attach to the tmux socket. |
5187 | snprintf(toybuf, sizeof(toybuf), | 5185 | snprintf(toybuf, sizeof(toybuf), |
5188 | "sudo -Hu %s %s %s/%s new-session -d -s %s -n '%s' \\; split-window -bhp 50 -t '%s:' bash -c './sledjchisl; cd %s; bash'", | 5186 | "sudo -Hu %s %s %s/%s new-session -d -s %s -n '%s' \\; split-window -bhp 50 -t '%s:' bash -c './sledjchisl; cd %s; bash'", |
5189 | scUser, Tcmd, scRun, Tsocket, Tconsole, Ttab, Tconsole, scRoot); | 5187 | scUser, Tcmd, scRun, Tsocket, Tconsole, Ttab, Tconsole, scRoot); |