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/muttprint-0.73/langinfo/muttprint-langinfo.c
Examining data/muttprint-0.73/langinfo/main.c
Examining data/muttprint-0.73/langinfo/muttprint-langinfo.h

FINAL RESULTS:

data/muttprint-0.73/langinfo/main.c:26:22:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    while ((option = getopt(argc, argv, "chloa")) != EOF) {
data/muttprint-0.73/langinfo/muttprint-langinfo.c:38:31:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
    if ( strlen_null(locale = getenv("LC_ALL")) == 0 ) {
data/muttprint-0.73/langinfo/muttprint-langinfo.c:39:35:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
        if ( strlen_null(locale = getenv("LC_MESSAGES")) == 0 ) {
data/muttprint-0.73/langinfo/muttprint-langinfo.c:40:39:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
            if ( strlen_null(locale = getenv("LANG")) == 0 ) {
data/muttprint-0.73/langinfo/muttprint-langinfo.c:11:33:  [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).
    return string == NULL ? 0 : strlen(string);
data/muttprint-0.73/langinfo/muttprint-langinfo.c:52:9:  [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).
    if (strlen(locale) >= 2 && islower(locale[0]) && islower(locale[1])) {
data/muttprint-0.73/langinfo/muttprint-langinfo.c:53:9:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
        strncpy(language, locale, 2);
data/muttprint-0.73/langinfo/muttprint-langinfo.c:62:9:  [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).
    if (strlen(locale) >= 5 && isupper(locale[3]) && isupper(locale[4]) 
data/muttprint-0.73/langinfo/muttprint-langinfo.c:64:9:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
        strncpy(country, locale+3, 2);

ANALYSIS SUMMARY:

Hits = 9
Lines analyzed = 155 in approximately 0.01 seconds (10456 lines/second)
Physical Source Lines of Code (SLOC) = 121
Hits@level = [0]   1 [1]   5 [2]   0 [3]   4 [4]   0 [5]   0
Hits@level+ = [0+]  10 [1+]   9 [2+]   4 [3+]   4 [4+]   0 [5+]   0
Hits/KSLOC@level+ = [0+] 82.6446 [1+] 74.3802 [2+] 33.0579 [3+] 33.0579 [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.