Open System Services System Calls Reference Manual (G06.29+, H06.08+, J06.03+)
setfilepriv(2) OSS System Calls Reference Manual
If the main executable of a process has a file privilege, then all user libraries and ordinary DLLs
loaded into the process must also have that file privilege. Public DLLs and implicit DLLs do not
need file privileges to be loaded into a process.
NFS client processes are not allowed to write to a file that has file privileges.
RETURN VALUES
Upon successful completion, the setfilepriv() function If the setfilepriv() function call fails, the
value -1 is returned and errno is set to indicate the error.
ERRORS
If any of these conditions occurs, the setfilepriv() function sets errno to the corresponding
value:
[EACCES] One of these conditions occured:
• Search permission was denied on a component of the pathname prefix
• The file does not exist
• The process attempted to access a Guardian subvolume with a reserved
filename beginning with ZYQ or a file within such a subvolume
[EPERM] One of these conditions occured:
• The effective user ID was not a member of the Safeguard SECURITY-
PRV-ADMINISTRATOR (SPA) group.
• The process attempted to set file privileges on an OSS file where the
set-user-ID or set-group-ID bit of the file mode was already set.
• The process attempted to set file privileges on a Guardian file where the
PROGID bit was already set.
• The process attempted to set file privileges on a file already opened for
writing.
[EINVAL] The value specified for fileprivs is not valid.
[EIO] A physical input or output error occurred. The device where the file is stored
might be in the down state, or both processors that provide access to the device
might have failed.
[ENOSUP] The file specified by path either resides in a fileset that does not support file
privileges, or is a file type that does not support file privileges (such as a direc-
tory or an AF_UNIX socket).
[EROFS] The file resides on a read-only fileset.
RELATED INFORMATION
Commands: getfilepriv(1), initfilepriv(1), setfilepriv(1).
Functions: chmod(2), chown(2), exec(2), fork(2), open(2), stat(2).
STANDARDS CONFORMANCE
This function is an HP extension.
7−58 Hewlett-Packard Company 527186-023