Skip to content

Commit

Permalink
Fix issue with ::new() ctor on 2012 server
Browse files Browse the repository at this point in the history
  • Loading branch information
dpaulson45 committed Aug 8, 2023
1 parent 5d268ec commit 86fdaa4
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ function Get-ExchangeAES256CBCDetails {
# Translates to: "NetworkService", "FullControl", "ContainerInherit, ObjectInherit", "None", "Allow"
# See: https://learn.microsoft.com/dotnet/api/system.security.accesscontrol.registryaccessrule.-ctor?view=net-7.0#system-security-accesscontrol-registryaccessrule-ctor(system-security-principal-identityreference-system-security-accesscontrol-registryrights-system-security-accesscontrol-inheritanceflags-system-security-accesscontrol-propagationflags-system-security-accesscontrol-accesscontroltype)
$networkServiceAcl = New-Object System.Security.AccessControl.RegistryAccessRule(
[System.Security.Principal.SecurityIdentifier]::new("S-1-5-20"), 983103, 3, 0, 0
(New-Object System.Security.Principal.SecurityIdentifier("S-1-5-20")), 983103, 3, 0, 0
)
} process {
# First, check if the build running on the server supports AES256-CBC
Expand Down

0 comments on commit 86fdaa4

Please sign in to comment.