Skip to content

Commit 1d7d9e0

Browse files
authored
Merge pull request #701 from ossf/xref_compiler_flags
Add cross-link from concise guide to C/C++ compiler options
2 parents 154b75a + 9cad319 commit 1d7d9e0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/Concise-Guide-for-Developing-More-Secure-Software.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ Here is a concise guide for all software developers for secure software developm
3232
23. **Complete a third-party security code review/audit**. Expect this to be USD$50K or more.
3333
24. **Continuously improve**. Improve scores, look for tips, & apply as appropriate.
3434
25. **Manage succession**. Have clear governance & work to add active, trustworthy maintainer(s).
35-
26. **Prefer memory-safe languages**. Many vulnerabilities involve memory safety. Where practical, use memory-safe programming languages (most are) and keep memory safety enabled. Otherwise, use mechanisms like extra tools and peer review to reduce risk.
35+
26. **Prefer memory-safe languages**. Many vulnerabilities involve memory safety. Where practical, use memory-safe programming languages (most are) and keep memory safety enabled. Otherwise, use mechanisms like compiler flags, extra tools, and peer review to reduce risk; see [Compiler Options Hardening Guide for C and C++](https://best.openssf.org/Compiler-Hardening-Guides/Compiler-Options-Hardening-Guide-for-C-and-C++).
3636
27. **If a source code (unbuilt) package is released, it should only include content from the version control system (VCS), and source package users should rebuild, if needed, to create production (built) package(s)**. E.g., if autotools is used, if a source package is released it should _not_ include a generated `configure` file, while recipients should ignore pre-generated files like `configure` and instead rebuild from source (e.g., with `autoreconf`). This eliminates a malware-hiding mechanism, as illustrated by an attack on [xz utils](https://access.redhat.com/security/cve/CVE-2024-3094).
3737
28. **Ensure production websites only load assets from your own domains**. _Linking_ to other domains is fine, but where practical, don't directly load assets such as JavaScript, CSS, and media (including images) from domains you do not control. If you do, your site might be subverted if that other domain is subverted, so investigate the risks before doing so. See the [subverted polyfill.io revelation in 2024](https://blog.qualys.com/vulnerabilities-threat-research/2024/06/28/polyfill-io-supply-chain-attack).
3838

0 commit comments

Comments
 (0)