1

Ubunbu 20.04

fifo pipe is created via a bash script from user A with: [[ ! -p $fifopath ]] && mkfifo $fifopath -m0777

This creates: prwxrwxrwx 1 A A 0 May 25 00:40 /tmp/somefifo

Then, if user B attempts to write to the fifo, permission will be denied. If i change the group of the fifo to user B's group, permission will still be denied. Only if i change the owner to be B or root, then B can write to the fifo.

Problem manifested after an update from 18.04

Any ideas how to solve this thing?

1 Answer 1

2

This patch (maybe introduced in Ubuntu 19.10?):

Disallows open of FIFOs or regular files not owned by the user in world writable sticky directories, unless the owner is the same as that of the directory or the file is opened without the O_CREAT flag.

I took these steps to disable it as detailed here:

create /etc/sysctl.d/protect-links.conf with the contents:

fs.protected_fifos = 0 

Then restart procps:

sudo systemctl restart procps.service 

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.