Skip to main content

Mapping Threats to Security Requirements

🌟 Objective​

To establish a systematic approach for mapping the threats identified in threat modelling to the security requirements defined in Chapter 2 of the SbD-ToE Manual, ensuring that:

  • Each threat gives rise to at least one technical or organisational requirement;
  • The derivation of requirements is traceable, auditable and documented;
  • The link threat → requirement → control is explicit.

🧭 How to map threats to requirements​

The mapping must be based on unique identifiers and consistent formats:

Threat IDThreat descriptionGenerated requirementCh. 2 categoryState
TM-001JWT with alg: none allows session forgeryEX-AUT-003: Mandatory JWT signatureAuthentication and SessionsMitigated
TM-002/admin/config endpoint accessible to everyoneEX-AC-010: Mandatory RBAC per endpointAccess ControlUnder validation
TM-003Excessive claims in the JWT expose sensitive dataEX-DAT-005: Minimise claims per contextPrivacy and DataJustified
TM-004Missing logging of administrative actionsEX-LOG-001: Mandatory structured loggingLogging and AuditingIn progress

Illustrative identifiers (EX-…); they do not correspond to the Ch. 02 Requirements Catalogue.

⚠️ Each row of the mapping must be documented in the repository or in the mitigations.md file.


✅ Examples of derived requirements​

Requirement category (Ch. 2)Typical threat typeExample of derived requirement
Authentication and SessionsReuse of unexpired JWTsEX-AUT-004: Maximum token TTL of 15 min
Access ControlUncontrolled access to administrative functionsEX-AC-012: Explicit verification of role in the backend
Privacy and DataUnnecessary claims in tokensEX-DAT-006: Dynamic scoping of claims per operation
Logging and AuditingActions without structured loggingEX-LOG-002: Logging of all sensitive actions with user ID
Protection against DoSAbuse of public endpoints (e.g. /login)EX-DOS-001: Rate limiting + CAPTCHA

Illustrative identifiers (EX-…); they do not correspond to the Ch. 02 Requirements Catalogue.


🔗 Integration with the validation process​

During the security validation phase of each project, this mapping must be used to:

  • Confirm that each identified threat has a response (requirement or justification);
  • Verify whether the requirement is implemented, tested or under a formal exception;
  • Trace the origin of the requirement (where the real need came from).

📁 Suggested organisation​

📁 threat-model/
├── threats.yaml # Lista de ameaças com threat_id, descrição, requisito associado
├── requisitos.yaml # Requisitos com id, descrição, categoria, estado
└── mitigations.md # Estado e histórico das decisões de segurança

✅ Good practices​

  • Always use unique, traceable identifiers (e.g. TM-001, EX-AC-010 — illustrative identifiers; they do not correspond to the Ch. 02 Requirements Catalogue);
  • Ensure consistency between the threats.yaml, requisitos.yaml and mitigations.md files;
  • Update the mapping whenever new threats are introduced or requirements change;
  • Use the mapping as mandatory input for security validations and technical audits;
  • Integrate this process with ALM, CI/CD or GRC tools whenever possible.

📎 Cross-references​

DocumentRelation to this file
threat-modeling-ciAutomated validation of the model in CI/CD pipelines
base methodGeneral principles of threat modelling in SbD-ToE

This mapping consolidates the link between threat analysis and formal security requirements, making the process verifiable, justifiable and auditable.