AWS ec2 documentation change
Summary
Added PowerShell V5 examples for DescribeSnapshots API including tag filtering and owner filtering
Security assessment
The change demonstrates snapshot querying capabilities but doesn't address encryption status verification or access control issues. While snapshots can contain sensitive data, these examples focus on basic API usage rather than security hardening or vulnerability mitigation.
Diff
diff --git a/ec2/latest/devguide/example_ec2_DescribeSnapshots_section.md b/ec2/latest/devguide/example_ec2_DescribeSnapshots_section.md index a46e91571..5cb339985 100644 --- a//ec2/latest/devguide/example_ec2_DescribeSnapshots_section.md +++ b//ec2/latest/devguide/example_ec2_DescribeSnapshots_section.md @@ -209,0 +210,50 @@ PowerShell +**Tools for PowerShell V5** + + +**Example 1: This example describes the specified snapshot.** + + + Get-EC2Snapshot -SnapshotId snap-12345678 + + +**Output:** + + + DataEncryptionKeyId : + Description : Created by CreateImage(i-1a2b3c4d) for ami-12345678 from vol-12345678 + Encrypted : False + KmsKeyId : + OwnerAlias : + OwnerId : 123456789012 + Progress : 100% + SnapshotId : snap-12345678 + StartTime : 10/23/2014 6:01:28 AM + State : completed + StateMessage : + Tags : {} + VolumeId : vol-12345678 + VolumeSize : 8 + +**Example 2: This example describes the snapshots that have a 'Name' tag.** + + + Get-EC2Snapshot | ? { $_.Tags.Count -gt 0 -and $_.Tags.Key -eq "Name" } + + +**Example 3: This example describes the snapshots that have a 'Name' tag with the value 'TestValue'.** + + + Get-EC2Snapshot | ? { $_.Tags.Count -gt 0 -and $_.Tags.Key -eq "Name" -and $_.Tags.Value -eq "TestValue" } + + +**Example 4: This example describes all your snapshots.** + + + Get-EC2Snapshot -Owner self + + + * For API details, see [DescribeSnapshots](https://docs.aws.amazon.com/powershell/v5/reference) in _AWS Tools for PowerShell Cmdlet Reference (V5)_. + + + +