Mono Class Library: Mono.Unix.UnixEnvironment Overview | Members

Mono.Unix.UnixEnvironment.SetSupplementaryGroups Method

Set the group access list of the current process.

public static void SetSupplementaryGroups (UnixGroupInfo[] groups)

See Also

Mono.Unix.Native.Syscall.setgroups

Parameters

groups
A Mono.Unix.UnixGroupInfo array containing the new group access list.

Exceptions

TypeReason
InvalidOperationException The caller is not the super-user. [Mono.Unix.Native.Errno.EPERM]

Remarks

Only the super-user may set new groups.

The group access list is a list of groups which the current process belongs to. These groups are used for file access checks when the UnixEnvironment.RealUser is not the file's UnixFileSystemInfo.OwnerUser; each of the supplementary groups is checked against UnixFileSystemInfo.OwnerGroup to see if group access applies, before using the "other" UnixFileSystemInfo.FileAccessPermissions.

Requirements

Namespace: Mono.Unix
Assembly: Mono.Posix (in Mono.Posix.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0