Skip to content
cloud security pen testingcloud penetration testingAWS pen testing

Cloud Security Pen Testing: AWS, Azure and GCP Rules

Cloud Security Pen Testing: AWS, Azure and GCP Rules

You've got an AWS access key pasted into a text file, three Azure subscriptions you've never signed into, and a GCP project that someone on the platform team stood up last year and then left. The client wants findings by Friday. The first thing you need to know isn't what's misconfigured. It's what you're allowed to touch, from which starting position, and how you'll prove what you reached.

That gap between permission and proof is where most cloud work falls apart. The technical testing is often the easy half. Scope, provider rules, evidence standards and retesting are where engagements get renegotiated, delayed or refunded. The sections below are the order I'd handle it in, from why a scan can't answer the client's real question to the scope document you should write before the next test is booked.

Table of Contents

What Cloud Pen Testing Is and Why Scanners Fall Short

A vulnerability scanner is a building inspector with a clipboard. It walks the halls, notes every open window and every door propped open, and hands you a list. A penetration test climbs through one of those windows and finds out whether it opens onto a supply closet or the room with the safe.

A professional drawing illustrating the difference between vulnerability scanning and penetration testing of a building structure.

Cloud security pen testing is an authorized attempt to exploit weaknesses across identities, workloads, APIs, storage and management planes, then verify what an attacker could reach from a defined starting position. The deliverable is a demonstrated path with a consequence attached: data read, a role assumed, a control plane changed.

The case for that work keeps getting stronger. Breach investigations keep tracking the same pattern: exploitation of known vulnerabilities is climbing as an initial access method, and mass scanning now starts within days of public disclosure while remediation inside large organizations drags for weeks or months. Discovery alone cannot close that gap. Knowing a flaw exists is cheap. Knowing whether it is reachable from a real starting position is what changes the priority order.

That difference shows up in how findings read. A scan result saying a bucket policy is permissive tells a platform team nothing about who can read it, from where, or what else that identity can reach afterward. A finding that shows a specific low-privilege principal reading customer records through a chain of three permissions tells them exactly what to close, and in what order.

What separates the two: a scan tells you a window is open. A test tells you what's behind it and who can carry it out.

Cloud estates don't hold still long enough for an annual photograph to mean much. Terraform applies on Tuesday, a data pipeline picks up a new role on Thursday, an engineer widens a policy on Friday to make a deadline. Point-in-time testing of a system that changes weekly leaves gaps measured in months.

Permission is part of the target as well. Every major provider draws a line between what customers may test and what stays off limits, and that line functions as a technical control boundary rather than paperwork. Findings only count when the path that produced them sits inside what the provider permits.

A useful test produces three things and nothing else: confirmed reachability from a stated starting position, the privileges or data exposed at the end of that path, and evidence precise enough that a fix can be verified rather than assumed. If the report can't support a retest, it isn't finished.

Provider Testing Rules and Shared-Boundary Decisions

Before a single packet leaves your laptop, answer one question. Does this provider let you test, and under what conditions? Getting this wrong is the fastest way to have a valid exploit attempt flagged as abuse, and it's the one part of scoping that no amount of technical skill compensates for.

Provider Prior approval needed Key restrictions Scoping note
AWS No, for listed services such as EC2, RDS, Lambda, API Gateway, CloudFront and Fargate Prior approval for command-and-control or simulated events; denial-of-service testing prohibited List accounts, regions, services and identities before execution
Azure No pre-approval or notice to Microsoft since June 15, 2017 Third-party testers need written authorization from the resource owner; no testing of Microsoft or other customers' assets Covers Virtual Machines, App Service, Azure Functions and API endpoints
Google Cloud No contact with Google required Must follow Acceptable Use Policy and Terms of Service; effects limited to your own projects Supplier assessments add stricter rules, including manual testing

Where each provider draws the line

AWS permits customer testing without prior approval for specified services, including EC2, WAF, NAT Gateway, Elastic Load Balancing, RDS, CloudFront, API Gateway, Lambda, ECS, Fargate and Transit Gateway, according to the AWS penetration testing policy. The same policy requires prior approval for activities involving command-and-control or simulated events and prohibits denial-of-service testing outright. Read that as a design constraint, because the C2 listener you'd normally stand up on an internal engagement is exactly the thing you can't run here.

Azure has required no pre-approval or advance notice to Microsoft since June 15, 2017, per Microsoft's Azure penetration testing guidance, and testing may cover Virtual Machines, App Service web and API applications, Azure Functions and API endpoints. The clause that matters for anyone selling the work sits in the same document: third-party testers, including managed security service providers and consultancies, may perform it only with explicit written authorization from the resource owner. That authorization belongs in the service agreement before testing starts, not in a chat thread the week of.

Microsoft's penetration testing rules of engagement go further, prohibiting scanning or testing of assets belonging to Microsoft or another Microsoft customer and prohibiting intentional access to data not wholly owned by your customer. Fuzzing, port scanning and vulnerability-assessment tools against the customer's own Azure Virtual Machines are allowed, and so is testing monitoring by generating anomalous security logs or dropping the EICAR test file.

The shared-container stop rule

The breakout case is the one teams forget to write into the rules of engagement. If you successfully break out of a shared service container such as Azure Websites or Azure Functions, you must report the issue to Microsoft immediately and stop further exploration. No pivoting, no "just to confirm", no screenshot tour of someone else's tenant.

Pause at the boundary, write down where it sits, and get approval in writing before you cross it. A path that dead-ends at a shared component is still a finding worth reporting.

Google Cloud doesn't require you to contact Google before testing your own infrastructure, per Google Cloud's penetration testing guidance, but the test must comply with the Acceptable Use Policy and Terms of Service and its effects must stay inside your own projects. Supplier assessments tighten considerably: the test must have occurred within the previous 12 months, cover all infrastructure used to provide the service and its relevant security dependencies, use manual vulnerability identification rather than automated results alone, and include both unauthenticated and authenticated testing where authentication exists.

Our own terms carry the same obligation, so it's worth repeating to clients who assume an authorization letter covers everything: customers may not test third-party infrastructure or services such as cloud, hosting, telecom or SaaS providers without complying with those providers' testing policies and obtaining any required authorization.

Scope by accounts, regions, services, identities and source addresses, plus traffic limits and prohibited techniques. An IP range can't express an IAM path, and cloud attack chains routinely cross roles, functions, storage and control-plane permissions in a way a CIDR block never captures. If you need the wider control context a test should map back to, the reference material on standards for security in cloud computing pairs well with a scope document.

The Five-Phase Cloud Pen Test Workflow

A defensible cloud test follows the lifecycle set out in NIST SP 800-115, which frames testing as planning, execution, analysis and mitigation rather than a one-shot scan. NIST also emphasizes analyzing findings and developing mitigation strategies, which is why retesting sits inside the method instead of being sold as a follow-on engagement.

Here's the sequence in motion before you commit an account to it.

Five phases from authorization to retest

  1. Define scope by account, region, service and identity. Name the accounts, subscriptions and projects, the regions, the services and every identity you've been handed. The reason is simple: an IP-based scope can't describe a single IAM edge. Scoping by address range is the most common slip, and it drops serverless and cross-account paths.

  2. Confirm authorization and access boundaries. Establish the authorized foothold, whether that's an external endpoint, a test credential, a leaked-key simulation or a compromised workload, and match it to the provider rules above. Starting from a credential nobody wrote into the rules of engagement is how otherwise clean tests turn into disputes.

  3. Execute controlled attacks against services. Enumerate assets and trust relationships, mapping IAM roles, network paths, functions and buckets, then chain them one hop at a time and stop at proof. Testers who keep going after proof are collecting risk, not evidence.

  4. Analyze findings and rank real risk. Capture the exact principal, policy statement, resource ARN or equivalent identifier, API calls, timestamps, response data and the privilege boundary reached. A single setting reported without its chain gives the defending team nothing to reproduce.

  5. Mitigate, remediate and re-test. Report by blast radius and business impact, then retest after fixes to confirm the path itself is closed. Skipping the retest leaves you guessing whether the access route was removed or just one node of it.

The cause-and-effect chain does more work than any individual finding. "Public bucket" is a configuration note. "This developer principal assumed the deployment role, which read the secrets store holding a production database credential, at 14:22 on the test date" is something a platform team can act on and an auditor can verify.

Assembling the toolchain is the smaller problem. If you're mapping identities and permissions rather than just enumerating resources, this overview of cloud computing testing tools covers the enumeration and graph side.

A five-phase infographic outlining the workflow for conducting cloud penetration testing based on NIST standards.

Identity Attack Paths That Matter Most

The findings list is the least valuable artifact a cloud test produces. Ask the teams who respond to cloud incidents what opens the door and the answer keeps coming back to identity: stolen keys, abused trust relationships, over-permissioned roles chained one into the next. Misconfigurations supply the raw material. The damage arrives through a principal that was allowed to do too much.

That ordering kills the checklist approach. A report listing forty public buckets and twelve broad roles measures cleanup effort. It says nothing about danger. The question worth answering is narrower: which of those roles is reachable from an identity an attacker can realistically obtain this quarter, and what sits at the end of the chain.

Layer What to prove Evidence to capture
Identity and roles A low-privilege principal can assume a higher-privilege role Principal, policy statement, role identifier, API call timestamps
Service-to-service trust A compromised workload can call a storage or database service it should not reach Source identity, request log, scope of returned data
Serverless and APIs A function or API route exposes data or credentials through its execution role Function configuration, invocation response, role permissions
Storage and data plane An identity reads sensitive objects beyond its need Access policy, object metadata, access log entry
Control plane Permissions allow changing IAM or network settings Read-only proof of the permission, audit trail, no production change made

What a chain looks like in practice

Say a developer identity holds a modest set of permissions but sits in a trust policy that lets it assume the deployment role. That role reads from a secrets store, and the store holds a production database credential. Three hops, none of them dramatic on its own, and the last one is a full data breach.

The permission that matters isn't the developer's and it isn't the deployment role's in isolation. It's the combination, and it only exists as a fact once someone demonstrates it in sequence.

Provider policy draws part of the map too, and it works as a control boundary rather than a paperwork detail. A path whose final hop requires a call the provider's testing rules forbid, or a write to infrastructure you are not authorized to touch, can only be proven up to the permission boundary. Capture the permission itself, mark the last hop as demonstrated by policy rather than by execution, and let the client decide whether the residual risk justifies seeking an authorized exception.

Excessive permission is not the same as an exploitable path. A role with wildcard access to a bucket holding marketing assets is a cleanup item. The same role, reachable from a CI identity whose key sits in a public repository, on a bucket holding customer exports, is an incident waiting for a date. Order the backlog by what sits at the end of each path and by how exposed the starting identity is, because that second factor is what separates a theoretical graph from a priority.

The reporting standard I hold to: if a finding can't name the starting principal, the steps in order and the resource reached, it isn't a finding yet. It's a hypothesis.

Ranking also has to survive provider differences, because an escalation route in AWS rarely has a direct equivalent in Azure or GCP. Cross-account role assumption, managed identity abuse and service account impersonation behave differently enough that a template carried between them will miss the paths that matter most. If you're building a backlog of the weakness classes to test for, this material on common cloud security vulnerabilities is a reasonable starting taxonomy.

Running Repeatable Tests Without Breaking Production

A scheduled scan that trips production autoscaling ends a testing program faster than any missed finding. The appetite for testing exists regardless: SANS reported in 2026 that only 40% of organizations considered their cloud security program mature even though 93% already operated production workloads in the cloud, with misconfiguration behind 45% of critical cloud incidents against 22% for credential theft, per the SANS announcement. Repeatability depends on restraint, and the rules that keep a program safe are boring and specific.

  • Rate limits per target: cap requests per second per endpoint and per identity, so an aggressive enumeration pass never trips autoscaling or a WAF rule the business depends on. Traffic that looks like an attack to the provider's own controls can also breach the testing policy the engagement was scoped under, so the limit protects the authorization as well as the workload.
  • Read-only proof wherever possible: demonstrate reachability with a list call, a metadata read or a permission check. Where a write is the only convincing proof, agree in advance which non-production resource it lands on. My rule of thumb is that any proof step requiring a write needs sign-off, every time.
  • Rollback written before each run: every state change gets a revert step in the test plan, decided while the change is still hypothetical rather than during the incident call.
  • Fixed evidence retention: screenshots, API responses and logs often contain live data, so decide how long they live and who can reach them before the first run produces them.

Programs most often fail at change awareness. A Terraform merge, a CI/CD pipeline update, an IAM policy edit or a new AI service wiring an agent to a broad role each invalidates prior results, because in cloud environments the configuration is the attack surface and it moves continuously. Trigger a targeted retest on the change itself instead of waiting for the calendar.

Separate a genuine regression from transient state by confirming the finding persists across two checks separated by a stabilization window. Infrastructure caught mid-deploy produces ghost findings, and reporting ghosts erodes client trust faster than missing real ones.

Repeated findings should roll up into the control frameworks the client already reports against: SOC 2, PCI-DSS and ISO 27001. For teams building that roll-up for the first time, this walkthrough on mapping controls to compliance frameworks shows how the exercise is typically structured. A mapped control still isn't proof of security, and a report that implies otherwise sets up the next audit for a nasty surprise.

The same honesty applies to coverage. Testing terms, ours included, state the limit plainly: the service is provided "as is" and "as available", and no security test identifies every vulnerability. Record what was tested and what sat outside scope, because an absent finding means nothing without that context. Providers running tests across tenants should isolate each customer's scope, credentials and evidence from the next.

Pre-Test Scope Checklist and Next Step

Confirm scope and authorization before anyone books a cloud test. Work through this in order, and don't compress steps because the client is in a hurry.

  1. Name the provider and the exact accounts, regions and services. Ambiguity here becomes a renegotiation later.
  2. Confirm approval status per service under that provider's policy. On AWS that includes prior approval for command-and-control or simulated events.
  3. Get written authorization from the resource owner, which is mandatory for third-party testers operating under Azure rules.
  4. List prohibited techniques, including denial-of-service testing and any shared or provider-owned component the path must not enter.
  5. Agree the starting foothold and the evidence standard, meaning principal, policy, resource identifier, timestamps and the privilege boundary reached.
  6. Schedule the retest now, while the remediation owner is in the room.

Then set expectations on volume. In 2025, cloud security assessments produced an average of 14.40 vulnerabilities per project across 660 penetration tests, according to Blaze Information Security's State of Penetration Testing Report 2025. Plan remediation capacity before the report arrives rather than discovering it afterward, because a findings backlog nobody can clear is how programs lose their budget.

If you want to see the shape of the output before committing, you can create a free account on the ThreatExploit AI portal, explore the platform and run a test pentest to see results firsthand. That's the cheapest way to pressure-test your own evidence standard.

The single next step is this: write the scope document this week, before the first test is scheduled. Provider rules, named accounts and services, written authorization, excluded techniques, foothold, evidence format and retest date, all in one page. Everything downstream gets easier once that exists.


ThreatExploit AI automates cloud pen testing across AWS, Azure and GCP, running reconnaissance, exploitation, verification and evidence collection on dedicated infrastructure so partner teams can deliver tested results without adding headcount. Findings arrive with screenshots and control references already mapped to SOC 2, PCI-DSS and ISO 27001, which is the part clients and auditors ask for first. Take a scoped cloud test through ThreatExploit AI and compare the evidence against your current scope document.