HomeFreeBSD

Call crextend() before copying old credentials to the new credentials

Description

Call crextend() before copying old credentials to the new credentials
and replace crcopysafe by crcopy as crcopysafe is is not intended to be
safe in a threaded environment, it drops PROC_LOCK() in while() that
can lead to unexpected results, such as overwrite kernel memory.

In my POV crcopysafe() needs special attention. For now I do not see
any problems with this function, but who knows.

Submitted by: dchagin
Found by: trinity
Security: SA-16:04.linux

Details

Provenance
glebiusAuthored on
Parents
rS293908: Regen after r293907.
Branches
Unknown
Tags
Unknown