More summaries and tags

This commit is contained in:
2026-01-16 11:12:03 -05:00
parent 1191fd0af0
commit 0ea515752c
17 changed files with 154 additions and 8 deletions

View File

@@ -2,7 +2,15 @@
author: "Halvo (Human)"
title: "Always null Terminate (Part 2): Summations of Secure Coding in C and C++"
date: 2022-08-13
tags:
- string-concatenation
- null-termination
- c
- cpp
- secure-coding
draft: false
summary: |
The sequel to the nulltermination saga, now tackling `strcat`, `strncat`, `strlcat`, and friends—plus a quick table to keep your concatenations from turning into catastrophes.
---
## Introduction
@@ -11,7 +19,7 @@ Series on summarizing themes in "Secure Coding in C and C++" by Robert C. Seacor
This is written for an audience that has a broad overview of security concepts. Not much time is spent explaining each concept, and I encourage everyone to read the book.
The first theme to discuss is always `null` terminating `char *` or `char array` buffers (unless you have a *very* specific reason for not). This is very important to help prevent buffer overflows, reading arbitrary memory, accessing 'inaccessible' memory. This is part 2 where we will discuss string cat and length. For a brief discussion on string copy see [part 1](/posts/secure-coding-in-c-summations-null-terminate.md).
The first theme to discuss is always `null` terminating `char *` or `char array` buffers (unless you have a *very* specific reason for not). This is very important to help prevent buffer overflows, reading arbitrary memory, accessing 'inaccessible' memory. This is part 2 where we will discuss string cat and length. For a brief discussion on string copy see [part 1](posts/secure-coding-in-c-summations-null-terminate.md).
## Functions Needing null