This blog was co-authored by Afroz Mohammed and Jonathan Nunn, Software Developers on the AWS PowerShell team.
We’re excited to announce the general availability of the AWS Tools for PowerShell version 5, a major update that brings new features and improvements in security, along with a few breaking changes.
New Features
You can now cancel cmdlet execution by using the keyboard shortcut CTRL+C
, start an interactive session using AWS Systems Manager, and use auto-iteration in over 1,000 more cmdlets than before.
The AWS Tools for PowerShell also benefits from performance improvements introduced by the major update of the underlying AWS SDK for .NET V4 libraries.
Security Improvements
We’ve made improvements to the way tools handle and log sensitive information. These changes help prevent accidental exposure of sensitive data while maintaining robust debugging capabilities. For detailed information about these security enhancements, please consult our documentation on logging of sensitive information.
Breaking Changes
While this update brings multiple improvements, it includes breaking changes that will require updates to existing scripts. The following are some notable examples:
- The legacy, Windows-specific AWSPowerShell module will no longer work with PowerShell 5.0 or any version of .NET Framework below 4.7.2; for example, the versions that come installed on Windows Server 2012 and Windows Server 2016. Please update PowerShell and .NET Framework in these environments to continue using AWSPowerShell.
- There are over 1,000 updates to cmdlets to auto-iterate. Cmdlets that were updated to auto-iterate will return all pages of data unless it includes the
-NoAutoIteration
parameter or the session behavior was modified usingSet-AWSAutoIterationMode -IterationMode v4
. - Cmdlets that are used for Amazon S3 objects such as
Get-S3Object
andWrite-S3Object
(among others) no longer remove leading spaces, forward-slashes/
, and back-slashesfrom the
Key
andKeyPrefix
parameters. To do so, add the-EnableLegacyKeyCleaning
parameter. - The AWS Tools for PowerShell now consumes credentials from environment variables like other AWS SDKs, and the resolution order is consistent with the AWS SDK for .NET V4.
- Version 5 no longer includes the session variable
$AWSHistory
. Please use the-Select *
parameter to return entire AWS response objects when necessary.
For a comprehensive list of breaking changes and detailed migration instructions, please refer to our Migration Guide.
Support timeframe for V4
We will continue to support the AWS Tools for PowerShell V4 with the same release cadence for AWS service updates for a period of six months. After six months, V4 will enter maintenance mode in which we will address only critical bugs and security issues.
Next Steps
We encourage our AWS Tools for PowerShell community to update to V5 as soon as possible.
- Review the Migration Guide for detailed information about breaking changes.
- Check out our User Guide for instructions to Install the AWS Tools for PowerShell V5.
- Update your scripts and automation to accommodate the changes.
- Provide feedback through our GitHub repository.
About the author: