Secure Development Policy
How we design, build, test and release software that is safe to run.
The highlighted fields are filled in from your answers in the builder.
- Company: [Company]
- Policy owner: [Policy owner]
- Effective date: [Effective date]
- Version: 1.0
- Review: once a year
Purpose
This policy sets how [Company] builds software that is safe to run, and keeps security work from being left to the end.
Scope
All software we write or configure: our product, infrastructure code, scripts and mobile apps, whether written by staff or by contractors. It also covers the open-source and third-party code we use.
Roles and responsibilities
- Engineering lead: Owns the build and release process and the standards for code.
- Developers: Write, review and test code to this policy.
- Policy owner: The [Policy owner] sets security requirements and tracks findings.
One person can hold more than one role. In a small team that is normal. What matters is that each duty has a named owner.
Policy statements
1. Design
1.1For a feature that handles sensitive data or changes how people sign in or what they may do, we write down the security requirements first: who can do what, what is stored and how it is protected.
1.2We use the OWASP Application Security Verification Standard as our reference for what a secure application does, and the OWASP Top 10 as a list of the common mistakes.
1.3A short written threat model is part of the design of any feature that handles Restricted data or changes authentication, authorisation or a trust boundary.
1.4We design for least privilege, safe defaults and strict separation between customers. The system fails closed.
2. Building
2.1All code lives in version control on [Code host]. Access follows the Access Control Policy.
2.2Another person reviews code before it merges, as the Change Management Policy says. Reviewers look for input validation, missing authorisation checks, secrets in code, sensitive data in logs and unsafe error handling.
2.3We validate all input on the server, encode output, and use parameterised queries. We never build SQL, shell commands or HTML from untrusted input by joining strings.
2.4Secrets never go into code. Secret scanning runs on every push. A leaked secret is revoked at once.
2.5Developers take secure coding training every year.
2.6We use maintained libraries from trusted registries, pin versions with lockfiles, and review a new dependency before we add it. We follow the licence terms of the open-source software we use.
2.7Errors shown to users never reveal stack traces, secrets or internal details.
3. Testing
3.1Automated tests run on every pull request. A failing check blocks the merge.
3.2The pipeline also runs automated security checks: vulnerable dependencies, secret scanning, and static analysis of our code where there is tooling for our language. Findings are fixed within the times in the Vulnerability Management Policy.
3.3Before we release a feature that touches customer data, we test that one customer cannot reach another customer's data.
3.4An independent party tests our production application and infrastructure at least once a year and after major changes. We fix the findings and keep the report and the retest result.
4. Environments and data
4.1Development, test and production are kept apart (see the Change Management Policy). We use synthetic or masked data outside production. If someone must copy production data to debug a problem, the [Policy owner] approves it first, the copy is deleted when the work is done, and it keeps its original classification while it exists.
4.2Pipeline credentials have the least permission that works and are scoped to one environment. We prefer short-lived tokens to long-lived keys.
4.3We build releases in the pipeline from the repository, not on a developer's laptop.
5. Outsourced work and outside reports
5.1Outsourced development follows this policy by contract. We own the code and our own engineers review it before it merges.
5.2We publish a way for researchers to report vulnerabilities, using [security@yourcompany.com] and a security.txt file, and we fix reports under the Vulnerability Management Policy.
Exceptions
We make an exception only in writing. The request names the rule, the reason, the risk and an end date. The [Policy owner] approves it. We keep every exception in a register, review it at its end date, and let none run longer than 12 months without a fresh decision.
Enforcement
Anyone who breaks this policy on purpose, or keeps doing it carelessly, faces the disciplinary steps in our People Security Policy. For employees that can go as far as ending employment. For contractors and vendors it can mean ending the contract.
Review
The [Policy owner] reviews this policy once a year, and again after any major change to our systems, our people or the law. We record every change in the version history below. Everyone covered by the policy accepts each new version.
Control mapping
This policy is part of the evidence for these requirements.
| Framework | Reference | Topic |
|---|---|---|
| SOC 2 Trust Services Criteria (2017, revised points of focus 2022) | CC6.8 | Unauthorized or malicious software |
| SOC 2 Trust Services Criteria (2017, revised points of focus 2022) | CC7.1 | Detection of vulnerabilities and configuration changes |
| SOC 2 Trust Services Criteria (2017, revised points of focus 2022) | CC8.1 | Change management |
| ISO/IEC 27001:2022 Annex A | A.5.32 | Intellectual property rights |
| ISO/IEC 27001:2022 Annex A | A.8.4 | Access to source code |
| ISO/IEC 27001:2022 Annex A | A.8.25 | Secure development life cycle |
| ISO/IEC 27001:2022 Annex A | A.8.26 | Application security requirements |
| ISO/IEC 27001:2022 Annex A | A.8.27 | Secure system architecture and engineering principles |
| ISO/IEC 27001:2022 Annex A | A.8.28 | Secure coding |
| ISO/IEC 27001:2022 Annex A | A.8.29 | Security testing in development and acceptance |
| ISO/IEC 27001:2022 Annex A | A.8.30 | Outsourced development |
| ISO/IEC 27001:2022 Annex A | A.8.31 | Separation of development, test and production environments |
| ISO/IEC 27001:2022 Annex A | A.8.33 | Test information |
Version history
| Version | Date | Author | Change |
|---|---|---|---|
| 1.0 | [Effective date] | [Policy owner] | First release |
Make it yours
Answer a few questions and the highlighted fields fill in, sized for your team.
What it supports
SOC 2 Trust Services Criteria (2017, revised points of focus 2022)
- CC6.8Unauthorized or malicious software
- CC7.1Detection of vulnerabilities and configuration changes
- CC8.1Change management
ISO/IEC 27001:2022 Annex A
- A.5.32Intellectual property rights
- A.8.4Access to source code
- A.8.25Secure development life cycle
- A.8.26Application security requirements
- A.8.27Secure system architecture and engineering principles
- A.8.28Secure coding
- A.8.29Security testing in development and acceptance
- A.8.30Outsourced development
- A.8.31Separation of development, test and production environments
- A.8.33Test information