This documentation is archived and is not being maintained.

PipeSecurity Class

Represents the access control and audit security for a pipe.

Namespace:  System.IO.Pipes
Assembly:  System.Core (in System.Core.dll)

[HostProtectionAttribute(SecurityAction.LinkDemand, MayLeakOnAbort = true)]
public class PipeSecurity : NativeObjectSecurity

NoteNote:

The HostProtectionAttribute attribute applied to this type or member has the following Resources property value: MayLeakOnAbort. The HostProtectionAttribute does not affect desktop applications (which are typically started by double-clicking an icon, typing a command, or entering a URL in a browser). For more information, see the HostProtectionAttribute class or SQL Server Programming and Host Protection Attributes.

The PipeSecurity class specifies the access rights for a pipe and how access attempts are audited. This class represents access and audit rights as a set of rules. Each access rule is represented by a PipeAccessRule object, while each audit rule is represented by a PipeAuditRule object.

The PipeSecurity class is an abstraction of the underlying Microsoft Windows file security system. In this system, each pipe has a discretionary access control list (DACL), which controls access to the pipe, and a system access control list (SACL), which specifies the access control attempts that are audited. The PipeAccessRule and PipeAuditRule classes are abstractions of the access control entries (ACEs) that comprise DACLs and SACLs.

The PipeSecurity class hides many of the details of DACLs and SACLs; you do not have to worry about ACE ordering or null DACLS.

Use the PipeSecurity class to retrieve, add, or change the access rules that represent the DACL and SACL of a pipe.

To persist new or changed access or audit rules to a pipe, use the SetAccessControl method. To retrieve access or audit rules from an existing file, use the GetAccessControl method.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Windows 7, Windows Vista, Windows XP SP2, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5
Show: