← blog
AWS ConfigConformance PacksAdvanced QueriesCompliance

AWS Config Beyond Rules: Conformance Packs and Advanced Queries

Most of us stop at adding a rule and reading Compliant or Noncompliant. The two features next to it answer a hundred IAM questions at once, and found eight buckets with versioning off in seconds.

01Where most of us stop

Almost everyone who opens AWS Config does the same thing: add a managed rule, wait, read a list split into Compliant and Noncompliant. That works, and for a handful of rules it is all you need.

Two features sit right next to it that I had never properly used:

I spent an afternoon on both in my own account. Here is where each one earns its place, including the part where I misread my own compliance score.

02The problem this solves

Say an account has a hundred IAM users. How do you know how many have access keys older than ninety days, how many have keys that stopped being used months ago but are still active, who can sign in without MFA, whether the password policy is still what somebody set two years ago, or whether root still has access keys on it?

You can answer all of that by hand — credential report, a few CLI calls, a spreadsheet, an afternoon. Then it is stale by Friday, because someone created three users.

Every question on that list is a managed Config rule, and AWS has already bundled them into Operational Best Practices for AWS Identity And Access Management. Deploy it once and it keeps re-evaluating. You stop running the audit and start reading it.

Advanced queries cover the other half: not "am I compliant against a standard," but "which buckets have versioning off, name them." No rule to deploy, no waiting.

03Deploying the pack

A conformance pack is a collection of Config rules and remediation actions deployed as one entity, from a YAML template. Under the hood it is a CloudFormation stack in a service-managed account, which is why you get a single deployment status instead of seventeen rule creations to watch.

The AWS Config conformance packs page in a fresh account, reading "You have no conformance packs deployed in your account."
Starting point. Both buttons lead to the same three-step wizard.
Step 1 "Specify template" with "Use sample template" selected and an empty template dropdown.
Three steps. The wizard is short; the dropdown is not.

Open that dropdown before committing to anything. It tells you how AWS thinks about the feature — regulatory frameworks and single-service packs in one alphabetical list.

The sample template dropdown open, showing Cyber Resilience for S3 EBS and DynamoDB, NIST 800 181, ABS CCIGv2, ACSC Essential 8 and ISM, API Gateway, APRA CPG 234, AWS Backup, Control Tower Detective Guardrails, IAM and the Well-Architected Reliability Pillar.
Frameworks and service packs, interleaved.
Dropdown showing CISA Cyber Essentials, CIS AWS Foundations Benchmark v1.3 and v1.4 at Level 1 and 2, CIS Critical Security Controls v8 IG1 to IG3, CIS Top 20, CMMC Levels 1 and 2, Compute Services, Data Resiliency and Database Services.
If an auditor named a framework and a level, it is probably already here.
Dropdown continuing through DevOps, EC2, ENISA Cybersecurity Guide, Encryption and Key Management, FDA Title 21 CFR Part 11, FFIEC, FedRAMP High Part 1 and Part 2, FedRAMP Low and Moderate, GLBA, GxP EU Annex 11 and HIPAA Security.
FedRAMP High ships as two parts — a template size limit, not a taxonomy.
Dropdown showing Security Best Practices for OpenSearch, AutoScaling, CloudFront, CloudTrail, CodeBuild, ECS, EFS, EKS, Lambda, Network Firewall, RDS, Redshift and Secrets Manager, with "custom conformance pack" last.
The narrow per-service packs. Easiest to hand to a service owner.

I picked the IAM pack and named it iam-conformance.

Step 1 with "Operational Best Practices for AWS Identity And Access Management" selected.
Account-level checks, so it evaluates the same way in any Region.

The other branch matters even if you start with samples, because it is where you end up. Uploads cap at 50 KB — which is why FedRAMP High is split in two — and the middle option is underrated: store templates as SSM documents and deploy by document name, no bucket policy conversation.

"Template is ready" offering three sources: upload a template file, Amazon SSM Document, or Amazon S3 bucket, with a note that templates over 50 KB must go to S3.
Upload for a first draft, SSM or S3 once it lives in a repo.

04Parameters are the whole game

This is the step people skip. It is labelled optional, it is pre-filled, and it looks like a formality. These values are what compliant means in your account.

The Parameters - optional section with eleven key/value pairs including AccessKeysRotatedParamMaxAccessKeyAge 90, MinimumPasswordLength 14, PasswordReusePrevention 24 and the KMS blocked action patterns, each with a Remove button.
Eleven parameters, all editable at deploy time only.
ParameterDefault
AccessKeysRotatedParamMaxAccessKeyAge90
IamPasswordPolicyParamMinimumPasswordLength14
IamPasswordPolicyParamMaxPasswordAge90
IamPasswordPolicyParamPasswordReusePrevention24
IamUserUnusedCredentialsCheckParamMaxCredentialUsageAge90
Iam{Customer,Inline}PolicyBlockedKmsActionsParamBlockedActionsPatternskms:Decrypt,kms:ReEncryptFrom
Require lowercase / uppercase / numbers / symbolstrue

Fourteen characters, twenty-four passwords of reuse prevention, ninety-day rotation — that is CIS, not an AWS opinion. If your standard differs, change it here, not in a ticket six weeks later when someone notices the dashboard is green against the wrong number.

Worth remembering

Removing a parameter is not the same as blanking it. Remove it and the managed rule falls back to its default, which may not be what you were just looking at. If a threshold matters, set it explicitly.

Step 3 "Review and deploy" showing the IAM sample template, Region United States (N. Virginia), pack name iam-conformance and the parameter list.
One Region per deployment. Organization packs are the answer to that, not repeating this wizard.

05The score, and why 25% is fine

The iam-conformance detail page: Deployment Completed, Compliance score 25%.
25%, and the gauge makes it look worse than it is.

Seventeen rules, twenty-five percent. Before reading that as a failing grade, look at the rule table — the compliance column has three states, not two.

The Rules (17) table listing iam-password-policy, root-account-mfa-enabled, iam-root-access-key-check, root-account-hardware-mfa-enabled, account-part-of-organizations, access-keys-rotated and others, with "Not set" in every Remediation action cell and a mix of Noncompliant, Compliant and dash in Compliance.
Three Noncompliant, two Compliant, five with a dash — and "Not set" all the way down.

What I got wrong

I read 25% as "this account is a mess" and started writing it up that way. A dash means nothing was in scope to evaluate — no IAM users, no customer-managed policies, so five rules had nothing to grade. The score only counts rules that returned a verdict, so in a small account the number is mostly a statement about sample size. Three real findings, two of them root-account hygiene. Never report a compliance score without the unevaluated count beside it.

The other thing that table shows: Remediation action: Not set, on every row. Packs are detective by default. Remediation only happens if the template carries AWS::Config::RemediationConfiguration blocks pointing at SSM Automation documents — and that belongs in phase two, not day one.

The rule detail page for iam-password-policy, showing Behavior Detective, alias CONFIG.IAM.DT.1, Deployable Regions 29 of 34, a controlcatalog API identifier, and a Frameworks list including FedRAMP r4 and r5, ISO 27001 Annex A, NIST SP 800-53 r5, CIS AWS Benchmark v1.2 and v1.3, CRI Profile v2.2, CCCS Medium and ACSC ISM.
One rule, ten framework citations. This is the control-mapping spreadsheet you were about to build by hand.

That Frameworks list is the part I did not expect. When an auditor asks which control covers password policy, this page answers it and you do not maintain it.

The rule's Parameters table showing MinimumPasswordLength 14, MaxPasswordAge 90 and PasswordReusePrevention 24, above a Resources in scope table filtered to Noncompliant with one row of type Account and a greyed-out Remediate button.
These are the parameters it was deployed with — the place to verify the wizard did what you meant.

06Advanced queries: ask, get a table

Packs answer "am I compliant against a standard." They do not answer "which buckets, right now." That is the other half of the console.

This is the feature I expect to use most, and the reason is time. The questions that eat an afternoon are not hard, just tedious — which instances are still t2.micro, which sit in the subnet somebody wants to decommission, which EBS volumes are detached and still billing, which buckets have no encryption. Normally a script, a paginator and some jq. Here it is a SELECT against data Config already recorded.

The Advanced queries page listing 58 sample queries including Active DynamoDB tables, Compliance status of Config rules of a conformance pack, Conformance packs compliance status, Count by compliant and Count EC2 Instances, with the Aggregators section in the left nav.
58 samples. Page one is Config querying itself — including your pack results.

Those pack-status samples matter: your conformance pack results are queryable data, not just a gauge, so you can build your own reporting instead of screenshotting a dial.

Advanced queries page 2 listing EC2 Instances attached to Volume, by AMI, by Network Interface, by Security Group, by Subnet, by type, and with private or public DNS names.
The EC2 block. Most are one edit away from the question you actually have.
Advanced queries page 6 listing RDS with database engine, S3 Buckets by versioning state, S3 buckets with no SSE, Security group supporting protocol, Subnets for Load Balancer, Tagged with CostCenter and Unused EBS.
"S3 buckets with no SSE" and "Unused EBS" are the two I have reached for most.

I opened the S3 versioning sample and ran it unmodified.

The query editor showing "S3 Buckets by versioning state", query scope "This account and region only", and a SELECT over resourceId, resourceType and supplementaryConfiguration.BucketVersioningConfiguration.status filtered to AWS::S3::Bucket with status Off.
Note the scope line under the title. It matters more than the SQL.
SELECT
  resourceId,
  resourceType,
  supplementaryConfiguration.BucketVersioningConfiguration.status
WHERE
  resourceType = 'AWS::S3::Bucket'
  AND supplementaryConfiguration.BucketVersioningConfiguration.status = 'Off'
Query output listing eight buckets, all AWS::S3::Bucket with versioning status Off, including two aws-cloudtrail-logs buckets, a config-bucket, a cf-templates bucket and an elasticbeanstalk bucket.
Eight buckets. Two of them are CloudTrail log buckets.

Two audit log buckets with no versioning, and the Config delivery bucket next to them. I wrote none of that SQL — clicked a sample, hit Run, had the answer before I finished reading the query. By hand it is list-buckets, then get-bucket-versioning in a loop, then remembering that an unversioned bucket returns an empty response rather than the word "Off". Every bucket in that list was created by an AWS console flow, which is a useful reminder that service-created is not the same as compliant.

Worth remembering

supplementaryConfiguration is where the interesting S3 state lives — versioning, encryption, logging, lifecycle — not the top-level configuration block. If a query comes back empty, check the nesting before concluding you are clean. An empty result and a clean account look identical.

07Four things that will bite you

Scope is one account and one Region. The editor says so under the query title. In a landing zone that means you just answered a question about one account and may not notice. Org-wide answers run against an aggregator — that parallel set of Aggregators entries in the left nav. Set it up before you go looking for answers.

Export caps at 500 rows. Fine for exploring, wrong for inventory. aws configservice select-resource-config paginates properly and is what belongs in a script.

Packs bill per evaluation, per account, per Region. Deploying to twelve Regions because the wizard is quick is a decision with a monthly cost on it.

Rule names carry a random pack suffix. Mine are all <rule>-conformance-pack-4vyxkuk7v, and that suffix changes on redeployment — so dashboards, automation rules and suppressions keyed on rule names break quietly. Key on the pack name.

The same flow works for everything else in the catalog. Point it at S3 and those eight versioning findings arrive as a tracked rule instead of a one-off query, which is the shape you want them in long term.

Step 1 of the deploy wizard with "Operational Best Practices for Amazon S3" selected in the sample template dropdown.
Same three steps — and now those buckets are a rule, not a query I have to remember to re-run.
The S3 pack's Parameters - optional section, showing four S3AccountLevelPublicAccessBlocksPeriodic parameters set to True and S3BucketBlacklistedActionsProhibited listing s3:DeleteBucketPolicy, s3:PutBucketAcl and more, with an Add parameter button.
Different pack, same lesson — and note "Add parameter", which is how you feed a custom rule its own thresholds.

08How I would run this

  1. Start with one narrow pack, not a framework. A service owner can read a fifteen-rule pack and argue with it. Nobody argues productively with FedRAMP High Part 2 on day one.
  2. Set every parameter deliberately, in the template. The defaults are CIS values. If your standard differs, the template is where that decision gets recorded and reviewed.
  3. Move to organization packs early. Deployed from a delegated administrator, immutable in member accounts, re-applied centrally — one template to change instead of a hundred accounts. Every non-excluded account needs a working Configuration Recorder first, or it fails on the accounts you forgot.
  4. Keep the YAML in the repo. aws_config_organization_conformance_pack exists. It encodes a policy decision, so it deserves a reviewer.
  5. Add remediation only after the detection has been quiet. Manual first, one rule at a time.
  6. Report unevaluated counts next to the score. Always.
  7. Queries for today's ticket, packs for the trend. If you run the same query every month, it should be a rule in a pack.

Worth knowing where this is heading, too: AWS shipped close to three hundred new managed rules this year, and every announcement points at conformance packs as the way to deploy them. Since June, Security Hub CSPM runs its own service-linked Config rules independently of yours — so "we have Security Hub, we do not need Config rules" stopped being a coherent position. Its rules are its own; your standard is your pack.