Carbon 2.3.0 is out. You can download Carbon as a .ZIP archive, NuGet package, Chocolatey package, or from the PowerShell Gallery. It may take a week or two for the package to show up at chocolatey.org.
Enhancements
Protect-Stringcan now encrypt with a key, password, or passphrase (i.e. it can now encrypt with symmetric encryption).Unprotect-Stringcan now decrypt with a key, password, or passphrase (i.e. it can now decrypt using symmetric encryption).Set-HostsEntrynow supports IPv6 addresses (fixes issue).Grant-Permissionnow supports creatingDenyaccess rules. Use the newTypeparameter. Fixes issue #152.Set-EnvironmentVariable:- Added
-Forceswitch to make all variable modifications immediately visible in the current PowerShell process’senv:drive. Restarts are no longer required. - You can now set an environment variable for other users. Use the
Credentialparameter to specify the user’s credentials. Fixes issue #151.
- Added
Remove-EnvironmentVariable:- Added
-Forceswitch to make all variable removals immediately visible in the current PowerShell process’senv:drive. Restarts are no longer required. - You can now remove variables from multiple targets/scopes at once.
- You can now remove an environment variable for other users. Use the
Credentialparameter to specify the user’s credentials.
- Added
Invoke-PowerShell:- It now runs PowerShell commands. Pass a string of PowerShell code with the
Commandparameter. - It now runs encoded PowerShell commands. Pass the string of PowerShell code with the
Commandparameter and use the-Encodeswitch. - It now runs scripts and commands as another user. Use the
Credentialparameter to pass the user’s credentials along with theFilePathandCommandparameters to run scripts and commands, respectively.
- It now runs PowerShell commands. Pass a string of PowerShell code with the
Bug Fixes
- Fixed:
Set-RegistryKeyValuefails when-Stringparameter’s value is$nullor empty (fixes issue #211). - Fixed: Can’t import Carbon in a 32-bit PowerShell 4 session on a 64-bit operating system (fixes issue #199).
- Fixed: Documentation for the
Install-ScheduledTaskfunction’sHighestAvailableRunLevelis lying (fixes issue #205). - Fixed:
Carbon_FirewallRulefails whenProfileproperty set to multiple values (fixes issue #209). - Fixed:
Install-IisAppPoolcan’t set .NET framework version toNo Managed Code(fixes issue #210). - Fixed:
Get-SslCertificateBindingfails if the operating system’s culture is noten-US(fixes issue #171). - Fixed:
Install-ScheduledTaskfails when creating a task that runs during a specific week of the month on Sundays. (You’re going to love this: the underlying int value for[DayOfWeek]::Sundayis0, so when testing if aDayOfWeektyped variable set toSundayhas a value, it returns$false. This madeInstall-ScheduledTaskadd the/Dparameter without a value.