Skip to content

Commit

Permalink
fix privilege dropping
Browse files Browse the repository at this point in the history
  • Loading branch information
zardus committed Dec 4, 2024
1 parent e1d3a08 commit 150aea3
Show file tree
Hide file tree
Showing 32 changed files with 16 additions and 16 deletions.
Binary file modified integrated-security/web-overflow-client/_0/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_0/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_1/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_1/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_10/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_10/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_11/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_11/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_12/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_12/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_13/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_13/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_14/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_14/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_15/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_15/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_2/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_2/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_3/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_3/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_4/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_4/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_5/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_5/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_6/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_6/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_7/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_7/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_8/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_8/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down
Binary file modified integrated-security/web-overflow-client/_9/server
Binary file not shown.
2 changes: 1 addition & 1 deletion integrated-security/web-overflow-client/_9/server.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ int challenge(int argc, char **argv, char **envp)
assert(bind(server_fd, (struct sockaddr *)&server_addr, sizeof(server_addr)) >= 0);
assert(listen(server_fd, 10) >= 0);

if (geteuid() != getuid())
if (getuid())
{
assert(setresgid(65534, 65534, 65534) == 0);
assert(setresuid(65534, 65534, 65534) == 0);
Expand Down

0 comments on commit 150aea3

Please sign in to comment.