Strange strace and setuid behaviour: permission denied under strace, but not running normally.
- by Autopulated
This is related to this question.
I have a script (fix-permissions.sh) that fixes some file permissions:
#! /bin/bash
sudo chown -R person:group /path/
sudo chmod -R g+rw /path/
And a small c program to run this, which is setuided:
#include "sys/types.h"
#include "unistd.h"
int main(){
setuid(geteuid());
return…