Flawfinder version 2.0.10, (C) 2001-2019 David A. Wheeler.
Number of rules (primarily dangerous function names) in C/C++ ruleset: 223
Examining data/wal2json-2.3/wal2json.c

FINAL RESULTS:

data/wal2json-2.3/wal2json.c:92:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char		ht[2];				/* horizontal tab, if pretty print */
data/wal2json-2.3/wal2json.c:93:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char		nl[2];				/* new line, if pretty print */
data/wal2json-2.3/wal2json.c:94:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char		sp[2];				/* space, if pretty print */
data/wal2json-2.3/wal2json.c:966:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char				comma[3] = "";
data/wal2json-2.3/wal2json.c:1385:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char				comma[3] = "";
data/wal2json-2.3/wal2json.c:3171:20:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		originid = (Oid) atoi(tok);
data/wal2json-2.3/wal2json.c:287:2:  [1] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant character.
	strcpy(data->ht, "");
data/wal2json-2.3/wal2json.c:288:2:  [1] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant character.
	strcpy(data->nl, "");
data/wal2json-2.3/wal2json.c:289:2:  [1] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant character.
	strcpy(data->sp, "");
data/wal2json-2.3/wal2json.c:492:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant character.
				strncpy(data->ht, "\t", 1);
data/wal2json-2.3/wal2json.c:493:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant character.
				strncpy(data->nl, "\n", 1);
data/wal2json-2.3/wal2json.c:494:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant character.
				strncpy(data->sp, " ", 1);
data/wal2json-2.3/wal2json.c:1270:55:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
					else if (strspn(outputstr, "0123456789+-eE.") == strlen(outputstr))
data/wal2json-2.3/wal2json.c:1926:50:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			else if (strspn(outstr, "0123456789+-eE.") == strlen(outstr))
data/wal2json-2.3/wal2json.c:2608:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(content_str, content, content_size);
data/wal2json-2.3/wal2json.c:2688:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(content_str, content, content_size);
data/wal2json-2.3/wal2json.c:2937:31:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
				memmove(nextp, nextp + 1, strlen(nextp));
data/wal2json-2.3/wal2json.c:2952:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(t->schemaname, startp, len);
data/wal2json-2.3/wal2json.c:2971:32:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
					memmove(nextp, nextp + 1, strlen(nextp));
data/wal2json-2.3/wal2json.c:2978:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(t->tablename, startp, len);

ANALYSIS SUMMARY:

Hits = 20
Lines analyzed = 3178 in approximately 0.09 seconds (34547 lines/second)
Physical Source Lines of Code (SLOC) = 2431
Hits@level = [0]   2 [1]  14 [2]   6 [3]   0 [4]   0 [5]   0
Hits@level+ = [0+]  22 [1+]  20 [2+]   6 [3+]   0 [4+]   0 [5+]   0
Hits/KSLOC@level+ = [0+] 9.04977 [1+] 8.22707 [2+] 2.46812 [3+]   0 [4+]   0 [5+]   0
Dot directories skipped = 1 (--followdotdir overrides)
Minimum risk level = 1
Not every hit is necessarily a security vulnerability.
There may be other security vulnerabilities; review your code!
See 'Secure Programming HOWTO'
(https://dwheeler.com/secure-programs) for more information.