
The chown function sets the owner ID and group ID of the file specified by path or referenced by the open file descriptor fildes to owner and group respectively. If owner or group is specified as -1, chown does not change the corresponding ID of the file. The operating system provides a configuration option {_POSIX_CHOWN_RESTRICTED}, to control the default behavior of processes and the behavior of the NFS server. If {_POSIX_CHOWN_RESTRICTED} is not in effect, the privilege {PRIV_FILE_CHOWN_SELF} is asserted in the inheritable set of all processes unless overridden by policy.conf or user_attr. To set this configuration option, include the following line in /etc/system:
• To enable the option to give away files, include the following line in /etc/system:
set rstchown = 1
• To disable this option, include the following line in /etc/system:
set rstchown = 0
1. Now reboot your system to update the changes.
# reboot
