bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#41554: chmod allows removing x bit on chmod without a force flag, wh


From: Will Rosecrans
Subject: bug#41554: chmod allows removing x bit on chmod without a force flag, which can be inconvenient to recover from
Date: Tue, 26 May 2020 18:30:14 -0700

Based on an inane interview question that was discussed here on Twitter:
https://twitter.com/QuinnyPig/status/1265286980859908102

"chmod a-x $(which chmod)" not a particularly likely thing for a user to
try to do directly, but it is conceivable for some sort of script to
attempt it by accident because of a bug, and it would make the system
inconvenient to recover.  Since it's almost never a desirable operation,
chmodding chmod itself could simply fail unless something like --force is
supplied.  The underlying safety logic is similar to that behind the
existing "--(no-)preserve-root"


reply via email to

[Prev in Thread] Current Thread [Next in Thread]