turbot/steampipe-mod-aws-insights

Dashboard: AWS SQS Queue Dashboard

This dashboard answers the following questions:

  • How many queues are in each account and region?
  • How many FIFO queues are there?
  • How many unencrypted queues are there?
  • How many queues are publicly accessible?
  • How many queues have DLQ configured?
  • How much do my queues cost each month?
This dashboard contains 5 cards and 1 table.

Usage

Install the mod:

mkdir dashboards
cd dashboards
powerpipe mod init
powerpipe mod install github.com/turbot/steampipe-mod-aws-insights

Start the Powerpipe server:

steampipe service start
powerpipe server

Open http://localhost:9033 in your browser and select AWS SQS Queue Dashboard dashboard.

You could also snapshot and share results via Turbot Pipes:

powerpipe login
powerpipe dashboard run aws_insights.dashboard.sqs_queue_dashboard --share

Queries

This dashboard uses the the following queries:
select
count(*) as value,
'Publicly Accessible' as label,
case count(*) when 0 then 'ok' else 'alert' end as "type"
from
aws_sqs_queue,
jsonb_array_elements(policy_std -> 'Statement') as s,
jsonb_array_elements_text(s -> 'Principal' -> 'AWS') as p,
string_to_array(p, ':') as pa,
jsonb_array_elements_text(s -> 'Action') as a
where
s ->> 'Effect' = 'Allow'
and (
pa[5] != account_id
or p = '*'
);

Tags