diff --git a/Makefile b/Makefile index c4b1d54..3a1ec37 100644 --- a/Makefile +++ b/Makefile @@ -38,9 +38,12 @@ users: -sudo useradd -M djumbaiq -sudo useradd -M djumbaid -sudo groupadd djumbai_queue + -sudo groupadd djumbai -sudo groupadd djumbai_send -sudo usermod -aG djumbai_queue djumbaiq -sudo usermod -aG djumbai_queue djumbaid + -sudo usermod -aG djumbai djumbaiq + -sudo usermod -aG djumbai djumbaid -sudo usermod -aG djumbai_send djumbaid -sudo usermod -aG djumbai_send root diff --git a/src/djumbai_send/djumbai_send.c b/src/djumbai_send/djumbai_send.c index 33b0f90..8815628 100644 --- a/src/djumbai_send/djumbai_send.c +++ b/src/djumbai_send/djumbai_send.c @@ -99,16 +99,16 @@ int main() { exit(EXIT_FAILURE); } - struct passwd *pw = getpwuid(msg.header.receiver); - if (pw == NULL) { - fprintf(stderr, "User with uid %d not found\n", msg.header.receiver); - exit(EXIT_FAILURE); - } + //struct passwd *pw = getpwuid(msg.header.receiver); + //if (pw == NULL) { + // fprintf(stderr, "User with uid %d not found\n", msg.header.receiver); + // exit(EXIT_FAILURE); + //} - if (setegid(pw->pw_gid) == -1) { - perror("setgid"); - exit(EXIT_FAILURE); - } + //if (setegid(pw->pw_gid) == -1) { + // perror("setgid"); + // exit(EXIT_FAILURE); + //} } // Redirect stdin to read from pipe_to_child