History log of /openbsd-current/gnu/usr.bin/binutils-2.17/binutils/rename.c
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: OPENBSD_5_9_BASE OPENBSD_6_0_BASE OPENBSD_6_1_BASE OPENBSD_6_2_BASE
# 1.3 15-Nov-2015 jca

In smart_rename, restore at least the regular permissions bits.

But don't try to chown or set special bits. This fixes several ports.

ok deraadt@


# 1.2 15-Nov-2015 deraadt

Using #ifndef __OpenBSD__, disable the really dangerous and silly
setuid-preserving code in the so-called smart_rename() function. I
don't want my tools (ar, ranlib, objcopy, strip) going through the
effort to preserve setuid bits on ``build-directory'' files when they
sense a symbolic link, thank you very much. The modern way is to build
code, then set such modes at install-time.

Our kernel goes through the effort to clear setuid flags, and this was
neutering that attempt. Also has atrocious error handling.

(Identified as an issue of concern while doing the audit for pledge)
ok guenther


# 1.1 24-Apr-2011 miod

branches: 1.1.1;
Initial revision