Skip to content

Commit e819f1e

Browse files
committed
Kestrel named pipes
1 parent c820737 commit e819f1e

File tree

1 file changed

+4
-2
lines changed
  • aspnetcore/fundamentals/servers/kestrel/endpoints/samples/KestrelNamedEP

1 file changed

+4
-2
lines changed

aspnetcore/fundamentals/servers/kestrel/endpoints/samples/KestrelNamedEP/Program.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,12 @@ static PipeSecurity CreatePipeSecurity(string pipeName)
4242
return null;
4343
// Get the current process identity.
4444
var currentIdentity = WindowsIdentity.GetCurrent();
45-
var processUser = new SecurityIdentifier(WellKnownSidType.BuiltinUsersSid, currentIdentity.User.AccountDomainSid);
45+
var processUser = new SecurityIdentifier(WellKnownSidType.BuiltinUsersSid,
46+
currentIdentity.User.AccountDomainSid);
4647

4748
// Allow only the current process read and write access to the pipe.
48-
pipeSecurity.AddAccessRule(new PipeAccessRule(processUser, PipeAccessRights.ReadWrite, AccessControlType.Allow));
49+
pipeSecurity.AddAccessRule(new PipeAccessRule(processUser,
50+
PipeAccessRights.ReadWrite, AccessControlType.Allow));
4951

5052
return pipeSecurity;
5153
}

0 commit comments

Comments
 (0)