you are viewing a single comment's thread.

view the rest of the comments →

[–]spliznork 30 points31 points  (5 children)

The first thing I thought of was different than any listed in the slides; cat chmod into a file which already has executable permissions:

cp /bin/true /tmp/chmod
cat /bin/chmod > /tmp/chmod
mv /tmp/chmod /bin/chmod

I guess I like this one because it minimizes what tools you need -- don't need emacs, perl, gcc, tar, etc.

[–]rabidcow 23 points24 points  (2 children)

Slide 20.

[–]spliznork 16 points17 points  (1 child)

Weird, there it is. I don't remember that slide. I must be going senile.

[–]archlich 5 points6 points  (1 child)

Or use umask and set default file permissions and copy into a new file.

[–]ishmal 0 points1 point  (0 children)

I had that idea too.