fix(compliance/ens): remap resilience VPC checks out of mp.com.4#11372
Merged
danibarranqueroo merged 3 commits intoMay 27, 2026
Merged
Conversation
`vpc_different_regions` and `vpc_subnet_different_az` have
`Categories: ["resilience"]` and measure multi-region/multi-AZ
availability, not network segregation.
- Remove `vpc_different_regions` from `mp.com.4.r1.aws.vpc.1`
(Segmentación lógica avanzada).
- Remove `vpc_subnet_different_az` and `vpc_different_regions`
from `mp.com.4.r3.aws.vpc.1` (Segmentación física). MP.COM.4 in
RD 311/2022, Anexo II, covers network segregation by criticality
and function (DMZ, trust zones, management traffic), not
geographic redundancy.
- Add a new requirement `op.cont.2.aws.vpc.1` (Plan de
continuidad, `ModoEjecucion: automático`) with both checks,
matching `op.cont.2.aws.az.1`'s control description
("distribución de servicios según regiones y zonas de
disponibilidad").
Refs: RD 311/2022 Anexo II (BOE-A-2022-7191).
Contributor
|
✅ Conflict Markers Resolved All conflict markers have been successfully resolved in this pull request. |
danibarranqueroo
approved these changes
May 27, 2026
Member
danibarranqueroo
left a comment
There was a problem hiding this comment.
Thanks for this! We decided to maintain both checks under the mp.com.4 requirement since we consider that those checks cover that requirement.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #11372 +/- ##
==========================================
- Coverage 93.96% 90.08% -3.88%
==========================================
Files 237 859 +622
Lines 34901 25027 -9874
==========================================
- Hits 32793 22545 -10248
- Misses 2108 2482 +374
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
3252f9c
into
prowler-cloud:master
24 of 25 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Context
The ENS RD 311/2022 (AWS) compliance framework shipped in
prowler/compliance/aws/ens_rd2022_aws.jsonmaps two resilience checks (vpc_different_regionsandvpc_subnet_different_az) under themp.com.4family (Network segregation, Anexo II of RD 311/2022), but those checks measure multi-region/multi-AZ availability, not network segmentation. This causes ENS reports to incorrectly grade the MP.COM.4 — "Segregación de redes" control based on geographic distribution of VPCs rather than on actual traffic/trust-zone segmentation.Fix #11371
Description
This PR corrects the mismapping by:
vpc_different_regionsfrommp.com.4.r1.aws.vpc.1(Segmentación lógica avanzada). The remaining check,vpc_subnet_separate_private_public(Categories: ["trust-boundaries"]), is correctly aligned with the control and is preserved.vpc_different_regionsandvpc_subnet_different_azfrommp.com.4.r3.aws.vpc.1(Segmentación física). The requirement is left withChecks: [], matching the existing pattern in the file for refinements that do not yet have an automated check (see e.g.op.cont.2.aws.az.1,op.mon.1.aws.gd.4,mp.com.2.aws.vpn.1).op.cont.2.aws.vpc.1(Plan de continuidad,ModoEjecucion: automático,Dimensiones: ["disponibilidad"],Checks: ["vpc_different_regions", "vpc_subnet_different_az"]). It coexists with the pre-existingop.cont.2.aws.az.1under the sameIdGrupoControl: op.cont.2, following the same<ENS_id>.aws.<service>.<seq>pattern used elsewhere in this file (e.g.op.acc.1.aws.iam.2). The existingop.cont.2.aws.az.1requirement is left untouched.The new requirement's
DescripcionControlis: "Distribución de las VPCs entre múltiples regiones y zonas de disponibilidad de AWS para garantizar la continuidad del servicio ante fallos regionales o zonales."Why this is the right mapping
prowler/providers/aws/services/vpc/vpc_different_regions/vpc_different_regions.metadata.json):"Categories": ["resilience"]"CheckType"includes"Effects/Denial of Service"Riskfield reads: "Single-region VPC deployment weakens availability and resilience [...] hinder recovery, and increase the blast radius of incidents impacting business continuity."vpc_subnet_different_az(Categories: ["resilience"], multi-AZ HA).op.cont.2.aws.az.1requirement already states its control description verbatim: "Deberá implementarse correctamente la distribución de servicios según regiones y zonas de disponibilidad para limitar al máximo los riesgos asociados a una única ubicación."References
Steps to review
prowler/compliance/aws/ens_rd2022_aws.json. Three localized blocks change:mp.com.4.r1.aws.vpc.1,mp.com.4.r3.aws.vpc.1, and the newly insertedop.cont.2.aws.vpc.1(placed afterop.cont.2.aws.az.1).op.cont.2.aws.az.1: sameIdGrupoControl,Marco,Categoria,Nivel,Dimensiones.ModoEjecucionisautomáticohere because the new requirement does carry automated checks.mp.com.4.r1.aws.vpc.1still containsvpc_subnet_separate_private_public(the correctly-mapped trust-boundary check) and only that one.mp.com.4.r3.aws.vpc.1is left withChecks: [], mirroring the empty-checks pattern used by other manual or yet-uncovered requirements.prowler/lib/check/compliance_models.py); the change preserves the schema.prowler/CHANGELOG.mdentry under[5.29.0] (Prowler UNRELEASED) → 🐞 Fixed. Reminder: before merge, replace the placeholder#PRNUMwith the actual PR number once GitHub assigns one.Checklist
Community Checklist
prowler/lib/check/compliance_models.py) already validates the schema at load time.)masterfor several minor releases and is also present on the active LTS branches that shipens_rd2022_aws.json. A backport to the current supportedv5.xbranches would benefit ENS-compliant customers; deferring the decision to the release owner.)README.mddoes not list individual mappings inside compliance frameworks.)[5.29.0] (Prowler UNRELEASED) → 🐞 Fixed. Contains a#PRNUMplaceholder that must be replaced with the PR number after opening.)SDK/CLI
UI
API
License
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.