Secure Development Guide
Version 0.9
This is our practical SSDLC guide for everyday development. The goal is to make secure-by-default changes without having to read the full SSDLC for each ticket.
This is a distilled view of our SSDLC and the underlying TR-03187 requirements. It does not replace the full document; it focuses on what we need to do in our daily dev work. The full document lives here.
This document itself includes only information and prescriptions for the entire CIVITAS/CORE team.
This document is meant to be used in conjunction with the following team specific guidelines:
- Security Architecture Principles: This document needs to be followed by everyone creating a ticket. It includes architecture-wide/overarching design principles that need to be incorporated into requirements and designs; they affect the coding phase only via the specifications from the ticket.
- Backend-Style Guide: This document is intended for Team 1 and the backend developers of Team 2 (including Model Atlas)
- Frontend-Style Guide: This document is intended for the Frontend developers of Team 2
- DevOps Deployment Standards: This document contains prescriptions for Team 3.
- Open Source Standards: This policy is to followed whenever new open source components are selected
1. Scope & Roles (developer view)
Developer responsibilities
You are responsible for:
- writing secure code and avoiding unnecessary increases of attack surface,
- keeping defaults safe,
- shipping only the necessary artifacts (no debugging tools, no unused dependencies)
- ensuring the CI pipeline is green and security findings are addressed (we enforce this anyway), and
- escalating high sensitivity changes for dedicated security review.
What you do not need to handle manually
CI and release tooling already:
- run SAST and linters on each change,
- run dependency and license scans and enforce policies,
- perform secret scanning on commits and images,
- generate SBOMs and attach them to releases, and
- build and sign release artifacts.
You do not need to:
- Run these tools locally (unless it speeds you up, e.g. by shortening the feedback cycle when you’re trying to fix it),
- manually construct SBOMs or signatures, or
- maintain separate spreadsheets / lists of dependencies.
You do need to:
- keep the pipeline green, and
- investigate and fix or explicitly document exceptions for any security findings.
Operators are responsible for hosting, monitoring, backups, incident response, and their local ISMS. We are responsible for enabling them through documentation and guidance.
2. Working with the MR checklists
When merging from your feature branch to the dev branch, you SHOULD fill in the non functional requirement checklist. As this may not be feasible in early stages of work on a feature, it is not mandatory. Before closing a ticket, you MUST refer to the MR (e.g. using the Closes functionality in Gitlab) and the checklist MUST be filled out.
3. Requirements you need to fulfill
Keep defaults secure
- New feature flags default to the safest mode (least privilege, minimal exposure).
- New configuration options have a documented “secure default” and reasoning.
- If the feature employs Authentication or Authorization, default to a "block all" setting
Interfaces
For each externally reachable interface:
- Enforce input validation and authentication at the first entry point.
Dependencies
- Before adding a dependency, consider if it actually adds value considering the risk of adding a component. As a rule of thumb, anything that's less than 50 lines of code should not be added through a dependency, but instead added in code.
- When adding a new dependency:
- Ensure it is pinned in the lockfile
- Add a short rationale to the MR (why did you choose this particular library over others? Why do you think this component is secure enough?)
- For high risk/widely used components, note the risk as calculated from the scheme in the Open Source Standards. For these components, the MR reviewer must also comment on the reasoning.
- Make reasonable effort to minimize dependencies/shipped binaries
Dependency analysis and SBOM generation are handled in CI, but you are responsible for choosing appropriate dependencies. If you need help choosing, ping your team mates or the security team.