Skip to content

Instantly share code, notes, and snippets.

@upbeta01
Created October 13, 2016 13:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save upbeta01/435e260457f3bc55e300a1364a3ebe8c to your computer and use it in GitHub Desktop.
Save upbeta01/435e260457f3bc55e300a1364a3ebe8c to your computer and use it in GitHub Desktop.
AWSCLI Query
aws ec2 describe-security-groups --filters Name=ip-permission.from-port,Values=22 Name=ip-permission.to-port,Values=22 --query 'SecurityGroups[*].IpPermissions[*].{IP:IpRanges}'
@upbeta01
Copy link
Author

I only wanted to see records specifically related to port 22

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment