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/libpam-krb5-4.9/module/account.c
Examining data/libpam-krb5-4.9/module/alt-auth.c
Examining data/libpam-krb5-4.9/module/auth.c
Examining data/libpam-krb5-4.9/module/cache.c
Examining data/libpam-krb5-4.9/module/context.c
Examining data/libpam-krb5-4.9/module/fast.c
Examining data/libpam-krb5-4.9/module/internal.h
Examining data/libpam-krb5-4.9/module/options.c
Examining data/libpam-krb5-4.9/module/password.c
Examining data/libpam-krb5-4.9/module/prompting.c
Examining data/libpam-krb5-4.9/module/public.c
Examining data/libpam-krb5-4.9/module/setcred.c
Examining data/libpam-krb5-4.9/module/support.c
Examining data/libpam-krb5-4.9/pam-util/args.c
Examining data/libpam-krb5-4.9/pam-util/args.h
Examining data/libpam-krb5-4.9/pam-util/logging.c
Examining data/libpam-krb5-4.9/pam-util/logging.h
Examining data/libpam-krb5-4.9/pam-util/options.c
Examining data/libpam-krb5-4.9/pam-util/options.h
Examining data/libpam-krb5-4.9/pam-util/vector.c
Examining data/libpam-krb5-4.9/pam-util/vector.h
Examining data/libpam-krb5-4.9/portable/asprintf.c
Examining data/libpam-krb5-4.9/portable/issetugid.c
Examining data/libpam-krb5-4.9/portable/krb5-extra.c
Examining data/libpam-krb5-4.9/portable/krb5-profile.c
Examining data/libpam-krb5-4.9/portable/mkstemp.c
Examining data/libpam-krb5-4.9/portable/pam_syslog.c
Examining data/libpam-krb5-4.9/portable/pam_vsyslog.c
Examining data/libpam-krb5-4.9/portable/reallocarray.c
Examining data/libpam-krb5-4.9/portable/snprintf.c
Examining data/libpam-krb5-4.9/portable/strndup.c
Examining data/libpam-krb5-4.9/portable/dummy.c
Examining data/libpam-krb5-4.9/portable/kadmin.h
Examining data/libpam-krb5-4.9/portable/krb5.h
Examining data/libpam-krb5-4.9/portable/macros.h
Examining data/libpam-krb5-4.9/portable/pam.h
Examining data/libpam-krb5-4.9/portable/stdbool.h
Examining data/libpam-krb5-4.9/portable/system.h
Examining data/libpam-krb5-4.9/tests/fakepam/config.c
Examining data/libpam-krb5-4.9/tests/fakepam/data.c
Examining data/libpam-krb5-4.9/tests/fakepam/general.c
Examining data/libpam-krb5-4.9/tests/fakepam/internal.h
Examining data/libpam-krb5-4.9/tests/fakepam/kuserok.c
Examining data/libpam-krb5-4.9/tests/fakepam/logging.c
Examining data/libpam-krb5-4.9/tests/fakepam/pam.h
Examining data/libpam-krb5-4.9/tests/fakepam/script.c
Examining data/libpam-krb5-4.9/tests/fakepam/script.h
Examining data/libpam-krb5-4.9/tests/module/alt-auth-t.c
Examining data/libpam-krb5-4.9/tests/module/bad-authtok-t.c
Examining data/libpam-krb5-4.9/tests/module/basic-t.c
Examining data/libpam-krb5-4.9/tests/module/cache-cleanup-t.c
Examining data/libpam-krb5-4.9/tests/module/cache-t.c
Examining data/libpam-krb5-4.9/tests/module/expired-t.c
Examining data/libpam-krb5-4.9/tests/module/fast-anon-t.c
Examining data/libpam-krb5-4.9/tests/module/fast-t.c
Examining data/libpam-krb5-4.9/tests/module/long-t.c
Examining data/libpam-krb5-4.9/tests/module/no-cache-t.c
Examining data/libpam-krb5-4.9/tests/module/pam-user-t.c
Examining data/libpam-krb5-4.9/tests/module/password-t.c
Examining data/libpam-krb5-4.9/tests/module/pkinit-t.c
Examining data/libpam-krb5-4.9/tests/module/realm-t.c
Examining data/libpam-krb5-4.9/tests/module/stacked-t.c
Examining data/libpam-krb5-4.9/tests/module/trace-t.c
Examining data/libpam-krb5-4.9/tests/pam-util/args-t.c
Examining data/libpam-krb5-4.9/tests/pam-util/fakepam-t.c
Examining data/libpam-krb5-4.9/tests/pam-util/logging-t.c
Examining data/libpam-krb5-4.9/tests/pam-util/options-t.c
Examining data/libpam-krb5-4.9/tests/pam-util/vector-t.c
Examining data/libpam-krb5-4.9/tests/portable/asprintf-t.c
Examining data/libpam-krb5-4.9/tests/portable/asprintf.c
Examining data/libpam-krb5-4.9/tests/portable/mkstemp-t.c
Examining data/libpam-krb5-4.9/tests/portable/mkstemp.c
Examining data/libpam-krb5-4.9/tests/portable/snprintf-t.c
Examining data/libpam-krb5-4.9/tests/portable/snprintf.c
Examining data/libpam-krb5-4.9/tests/portable/strndup-t.c
Examining data/libpam-krb5-4.9/tests/portable/strndup.c
Examining data/libpam-krb5-4.9/tests/tap/basic.c
Examining data/libpam-krb5-4.9/tests/tap/basic.h
Examining data/libpam-krb5-4.9/tests/tap/kadmin.c
Examining data/libpam-krb5-4.9/tests/tap/kadmin.h
Examining data/libpam-krb5-4.9/tests/tap/kerberos.c
Examining data/libpam-krb5-4.9/tests/tap/kerberos.h
Examining data/libpam-krb5-4.9/tests/tap/macros.h
Examining data/libpam-krb5-4.9/tests/tap/process.c
Examining data/libpam-krb5-4.9/tests/tap/process.h
Examining data/libpam-krb5-4.9/tests/tap/string.c
Examining data/libpam-krb5-4.9/tests/tap/string.h
Examining data/libpam-krb5-4.9/tests/runtests.c

FINAL RESULTS:

data/libpam-krb5-4.9/module/setcred.c:424:18:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
        status = chown(cache_name + strlen("FILE:"), uid, gid);
data/libpam-krb5-4.9/module/setcred.c:426:18:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
        status = chown(cache_name, uid, gid);
data/libpam-krb5-4.9/module/auth.c:425:44:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
    if (pwd == NULL || filename == NULL || access(filename, R_OK) != 0) {
data/libpam-krb5-4.9/pam-util/logging.c:82:40:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
static char *__attribute__((__format__(printf, 1, 0)))
data/libpam-krb5-4.9/pam-util/logging.c:100:39:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
static void __attribute__((__format__(printf, 3, 0)))
data/libpam-krb5-4.9/pam-util/logging.c:128:39:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
static void __attribute__((__format__(printf, 3, 4)))
data/libpam-krb5-4.9/pam-util/logging.c:146:39:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
static void __attribute__((__format__(printf, 4, 0)))
data/libpam-krb5-4.9/pam-util/logging.c:175:36:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    void __attribute__((__format__(printf, 2, 3)))                \
data/libpam-krb5-4.9/pam-util/logging.c:184:36:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    void __attribute__((__format__(printf, 3, 4)))                \
data/libpam-krb5-4.9/pam-util/logging.c:251:32:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void __attribute__((__format__(printf, 2, 3)))
data/libpam-krb5-4.9/pam-util/logging.c:299:27:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
__attribute__((__format__(printf, 4, 0))) static void
data/libpam-krb5-4.9/pam-util/logging.c:329:36:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    void __attribute__((__format__(printf, 3, 4)))                      \
data/libpam-krb5-4.9/pam-util/logging.h:61:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 2, 3)));
data/libpam-krb5-4.9/pam-util/logging.h:63:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 4)));
data/libpam-krb5-4.9/pam-util/logging.h:65:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 2, 3)));
data/libpam-krb5-4.9/pam-util/logging.h:67:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 4)));
data/libpam-krb5-4.9/pam-util/logging.h:69:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 2, 3)));
data/libpam-krb5-4.9/pam-util/logging.h:71:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 4)));
data/libpam-krb5-4.9/pam-util/logging.h:73:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 2, 3)));
data/libpam-krb5-4.9/pam-util/logging.h:75:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 4)));
data/libpam-krb5-4.9/pam-util/logging.h:84:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 4)));
data/libpam-krb5-4.9/pam-util/logging.h:86:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 4)));
data/libpam-krb5-4.9/pam-util/logging.h:88:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 4)));
data/libpam-krb5-4.9/pam-util/logging.h:90:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 4)));
data/libpam-krb5-4.9/pam-util/logging.h:99:44:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__nonnull__, __format__(printf, 2, 3)));
data/libpam-krb5-4.9/pam-util/vector.c:270:12:  [4] (shell) execv:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
    return execv(path, (char *const *) vector->strings);
data/libpam-krb5-4.9/portable/asprintf.c:39:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 2, 3)));
data/libpam-krb5-4.9/portable/asprintf.c:41:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 2, 0)));
data/libpam-krb5-4.9/portable/asprintf.c:65:14:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
    needed = vsnprintf(NULL, 0, fmt, args_copy);
data/libpam-krb5-4.9/portable/asprintf.c:74:14:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
    status = vsnprintf(*strp, needed + 1, fmt, args);
data/libpam-krb5-4.9/portable/krb5-extra.c:83:5:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
    sprintf(*out, "%s:%s", type, name);
data/libpam-krb5-4.9/portable/pam_vsyslog.c:57:5:  [4] (format) syslog:
  If syslog's format strings can be influenced by an attacker, they can be
  exploited (CWE-134). Use a constant format string for syslog.
    syslog(priority | LOG_AUTHPRIV, MODULE_NAME "%s%s%s: %s",
data/libpam-krb5-4.9/portable/snprintf.c:22:9:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
# undef snprintf
data/libpam-krb5-4.9/portable/snprintf.c:23:9:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
# undef vsnprintf
data/libpam-krb5-4.9/portable/snprintf.c:24:10:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
# define snprintf test_snprintf
data/libpam-krb5-4.9/portable/snprintf.c:25:10:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
# define vsnprintf test_vsnprintf
data/libpam-krb5-4.9/portable/snprintf.c:153:5:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
int snprintf (char *str, size_t count, const char *fmt, ...);
data/libpam-krb5-4.9/portable/snprintf.c:154:5:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
int vsnprintf (char *str, size_t count, const char *fmt, va_list arg);
data/libpam-krb5-4.9/portable/snprintf.c:885:5:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
int vsnprintf (char *str, size_t count, const char *fmt, va_list args)
data/libpam-krb5-4.9/portable/snprintf.c:892:5:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
int snprintf (char *str, size_t count, const char *fmt,...)
data/libpam-krb5-4.9/portable/snprintf.c:898:11:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
  total = vsnprintf(str, count, fmt, ap);
data/libpam-krb5-4.9/portable/snprintf.c:951:7:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
      snprintf (buf1, sizeof (buf1), fp_fmt[x], fp_nums[y]);
data/libpam-krb5-4.9/portable/snprintf.c:952:7:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
      sprintf (buf2, fp_fmt[x], fp_nums[y]);
data/libpam-krb5-4.9/portable/snprintf.c:965:7:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
      snprintf (buf1, sizeof (buf1), int_fmt[x], int_nums[y]);
data/libpam-krb5-4.9/portable/snprintf.c:966:7:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
      sprintf (buf2, int_fmt[x], int_nums[y]);
data/libpam-krb5-4.9/portable/system.h:80:13:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
#    define snprintf _snprintf
data/libpam-krb5-4.9/portable/system.h:80:22:  [4] (format) _snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
#    define snprintf _snprintf
data/libpam-krb5-4.9/portable/system.h:132:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 2, 3)));
data/libpam-krb5-4.9/portable/system.h:134:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 2, 0)));
data/libpam-krb5-4.9/portable/system.h:137:12:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
extern int snprintf(char *, size_t, const char *, ...)
data/libpam-krb5-4.9/portable/system.h:138:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 4)));
data/libpam-krb5-4.9/portable/system.h:141:12:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
extern int vsnprintf(char *, size_t, const char *, va_list)
data/libpam-krb5-4.9/portable/system.h:142:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 0)));
data/libpam-krb5-4.9/tests/fakepam/kuserok.c:93:9:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
    if (access(path, R_OK) < 0) {
data/libpam-krb5-4.9/tests/fakepam/script.c:63:39:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
static void __attribute__((__format__(printf, 3, 4)))
data/libpam-krb5-4.9/tests/fakepam/script.c:123:39:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
static void __attribute__((__format__(printf, 3, 4)))
data/libpam-krb5-4.9/tests/fakepam/script.c:278:9:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
    if (access(file, R_OK) == 0)
data/libpam-krb5-4.9/tests/fakepam/script.c:390:9:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
    if (access(dir, R_OK) == 0)
data/libpam-krb5-4.9/tests/module/trace-t.c:38:15:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
    is_int(0, access(trace, F_OK), "Trace file was created");
data/libpam-krb5-4.9/tests/module/trace-t.c:42:16:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
    is_int(-1, access(trace, F_OK), "Trace file does not exist");
data/libpam-krb5-4.9/tests/portable/asprintf-t.c:27:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 2, 3)));
data/libpam-krb5-4.9/tests/portable/asprintf-t.c:29:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 2, 0)));
data/libpam-krb5-4.9/tests/portable/asprintf-t.c:31:38:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
static int __attribute__((__format__(printf, 2, 3)))
data/libpam-krb5-4.9/tests/portable/mkstemp-t.c:63:8:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
    ok(access(template, F_OK) == 0, "...and the file exists");
data/libpam-krb5-4.9/tests/portable/snprintf-t.c:162:21:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            count = sprintf(lgbuf, fp_formats[i], fp_nums[j]);
data/libpam-krb5-4.9/tests/portable/snprintf-t.c:167:21:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            count = sprintf(lgbuf, int_formats[i], int_nums[j]);
data/libpam-krb5-4.9/tests/portable/snprintf-t.c:172:21:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            count = sprintf(lgbuf, uint_formats[i], uint_nums[j]);
data/libpam-krb5-4.9/tests/portable/snprintf-t.c:177:21:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            count = sprintf(lgbuf, llong_formats[i], llong_nums[j]);
data/libpam-krb5-4.9/tests/portable/snprintf-t.c:182:21:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
            count = sprintf(lgbuf, ullong_formats[i], ullong_nums[j]);
data/libpam-krb5-4.9/tests/runtests.c:287:58:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__nonnull__, __noreturn__, __format__(printf, 1, 2)));
data/libpam-krb5-4.9/tests/runtests.c:289:58:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__nonnull__, __noreturn__, __format__(printf, 1, 2)));
data/libpam-krb5-4.9/tests/runtests.c:313:5:  [4] (format) vfprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    vfprintf(stderr, format, args);
data/libpam-krb5-4.9/tests/runtests.c:333:5:  [4] (format) vfprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    vfprintf(stderr, format, args);
data/libpam-krb5-4.9/tests/runtests.c:611:13:  [4] (shell) execv:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
        if (execv(command[0], command) == -1)
data/libpam-krb5-4.9/tests/runtests.c:1226:9:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
    if (access(path, X_OK) < 0)
data/libpam-krb5-4.9/tests/runtests.c:1648:9:  [4] (shell) execl:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
    if (execl(path, path, (char *) 0) == -1)
data/libpam-krb5-4.9/tests/runtests.c:1683:13:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
            printf(usage_message, program, program, program, usage_extra);
data/libpam-krb5-4.9/tests/runtests.c:1704:9:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
        fprintf(stderr, usage_message, program, program, program, usage_extra);
data/libpam-krb5-4.9/tests/runtests.c:1746:9:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
        printf(banner, shortlist);
data/libpam-krb5-4.9/tests/tap/basic.c:137:13:  [4] (format) vprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
            vprintf(format, args);  \
data/libpam-krb5-4.9/tests/tap/basic.c:458:9:  [4] (format) vprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
        vprintf(format, args);
data/libpam-krb5-4.9/tests/tap/basic.c:677:5:  [4] (format) vprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    vprintf(format, args);
data/libpam-krb5-4.9/tests/tap/basic.c:699:5:  [4] (format) vprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    vprintf(format, args);
data/libpam-krb5-4.9/tests/tap/basic.c:720:5:  [4] (format) vprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    vprintf(format, args);
data/libpam-krb5-4.9/tests/tap/basic.c:742:5:  [4] (format) vprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    vprintf(format, args);
data/libpam-krb5-4.9/tests/tap/basic.c:933:13:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
        if (access(path, R_OK) == 0)
data/libpam-krb5-4.9/tests/tap/basic.c:974:9:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
    if (access(path, X_OK) < 0)
data/libpam-krb5-4.9/tests/tap/basic.h:68:45:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__noreturn__, __format__(printf, 1, 2)));
data/libpam-krb5-4.9/tests/tap/basic.h:77:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 2, 3)));
data/libpam-krb5-4.9/tests/tap/basic.h:79:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 2, 0)));
data/libpam-krb5-4.9/tests/tap/basic.h:80:62:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void skip(const char *reason, ...) __attribute__((__format__(printf, 1, 2)));
data/libpam-krb5-4.9/tests/tap/basic.h:87:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 4)));
data/libpam-krb5-4.9/tests/tap/basic.h:89:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 2, 3)));
data/libpam-krb5-4.9/tests/tap/basic.h:98:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 4)));
data/libpam-krb5-4.9/tests/tap/basic.h:100:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 4)));
data/libpam-krb5-4.9/tests/tap/basic.h:102:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 4)));
data/libpam-krb5-4.9/tests/tap/basic.h:104:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 3, 4)));
data/libpam-krb5-4.9/tests/tap/basic.h:106:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 4, 5)));
data/libpam-krb5-4.9/tests/tap/basic.h:110:58:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__noreturn__, __nonnull__, __format__(printf, 1, 2)));
data/libpam-krb5-4.9/tests/tap/basic.h:112:58:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__noreturn__, __nonnull__, __format__(printf, 1, 2)));
data/libpam-krb5-4.9/tests/tap/basic.h:116:44:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__nonnull__, __format__(printf, 1, 2)));
data/libpam-krb5-4.9/tests/tap/basic.h:118:44:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__nonnull__, __format__(printf, 1, 2)));
data/libpam-krb5-4.9/tests/tap/kerberos.c:196:18:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
        status = system(command);
data/libpam-krb5-4.9/tests/tap/kerberos.h:116:61:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__noreturn__, __nonnull__(3), __format__(printf, 3, 4)));
data/libpam-krb5-4.9/tests/tap/kerberos.h:120:47:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__nonnull__(3), __format__(printf, 3, 4)));
data/libpam-krb5-4.9/tests/tap/process.c:199:5:  [4] (shell) execvp:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
    execvp(argv[0], argv);
data/libpam-krb5-4.9/tests/tap/process.c:458:13:  [4] (shell) execv:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
        if (execv(argv[0], (char *const *) argv) < 0)
data/libpam-krb5-4.9/tests/tap/process.c:468:42:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
    for (i = 0; i < PROCESS_WAIT * 10 && access(pidfile, F_OK) != 0; i++) {
data/libpam-krb5-4.9/tests/tap/process.c:478:9:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
    if (access(pidfile, F_OK) != 0) {
data/libpam-krb5-4.9/tests/tap/process.h:56:31:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__format__(printf, 5, 6), __nonnull__(1)));
data/libpam-krb5-4.9/tests/tap/string.h:45:44:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__nonnull__, __format__(printf, 2, 3)));
data/libpam-krb5-4.9/tests/tap/string.h:47:44:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
    __attribute__((__nonnull__, __format__(printf, 2, 0)));
data/libpam-krb5-4.9/module/cache.c:45:16:  [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.
        name = getenv(key);
data/libpam-krb5-4.9/tests/module/cache-t.c:137:38:  [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.
    basprintf(&pwd.pw_dir, "%s/tmp", getenv("BUILD"));
data/libpam-krb5-4.9/tests/module/expired-t.c:66:38:  [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.
    basprintf(&pwd.pw_dir, "%s/tmp", getenv("BUILD"));
data/libpam-krb5-4.9/tests/runtests.c:1324:24:  [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.
            valgrind = getenv("C_TAP_VALGRIND");
data/libpam-krb5-4.9/tests/runtests.c:1350:23:  [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.
            libtool = getenv("C_TAP_LIBTOOL");
data/libpam-krb5-4.9/tests/runtests.c:1677: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, "b:hl:os:v")) != EOF) {
data/libpam-krb5-4.9/tests/runtests.c:1712:9:  [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 (getenv("C_TAP_VERBOSE") != NULL)
data/libpam-krb5-4.9/tests/tap/basic.c:929:16:  [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.
        base = getenv(envs[i]);
data/libpam-krb5-4.9/tests/tap/basic.c:970:13:  [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.
    build = getenv("C_TAP_BUILD");
data/libpam-krb5-4.9/module/alt-auth.c:88:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(*principal + offset, user, strlen(user));
data/libpam-krb5-4.9/module/alt-auth.c:99:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(*principal + offset, realm, strlen(realm));
data/libpam-krb5-4.9/module/auth.c:63:5:  [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 kuser[65] = ""; /* MAX_USERNAME == 65 (MIT Kerberos 1.4.1). */
data/libpam-krb5-4.9/module/auth.c:405:5:  [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 line[BUFSIZ];
data/libpam-krb5-4.9/module/auth.c:437:15:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    k5login = fopen(filename, "r");
data/libpam-krb5-4.9/module/cache.c:93:12:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
    ccfd = mkstemp(template);
data/libpam-krb5-4.9/module/prompting.c:241:15:  [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.
        free((char *) msg[i]->msg);
data/libpam-krb5-4.9/module/prompting.c:327:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(prompts[i].reply->data, resp[i].resp, len + 1);
data/libpam-krb5-4.9/module/support.c:71:5:  [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 kuser[65]; /* MAX_USERNAME == 65 (MIT Kerberos 1.4.1). */
data/libpam-krb5-4.9/pam-util/logging.c:232:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(out + offset + 1, FLAGS[i].name, length);
data/libpam-krb5-4.9/portable/krb5-profile.c:60:15:  [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.
        const char *names[5];
data/libpam-krb5-4.9/portable/mkstemp.c:38:12:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
#    undef mkstemp
data/libpam-krb5-4.9/portable/mkstemp.c:39:13:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
#    define mkstemp test_mkstemp
data/libpam-krb5-4.9/portable/mkstemp.c:51:1:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
mkstemp(char *template)
data/libpam-krb5-4.9/portable/mkstemp.c:89:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
        fd = open(template, O_RDWR | O_CREAT | O_EXCL, 0600);
data/libpam-krb5-4.9/portable/snprintf.c:545:3:  [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 convert[24];
data/libpam-krb5-4.9/portable/snprintf.c:683:3:  [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 iconvert[24];
data/libpam-krb5-4.9/portable/snprintf.c:684:3:  [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 fconvert[24];
data/libpam-krb5-4.9/portable/snprintf.c:909:3:  [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 buf1[LONG_STRING];
data/libpam-krb5-4.9/portable/snprintf.c:910:3:  [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 buf2[LONG_STRING];
data/libpam-krb5-4.9/portable/strndup.c:53:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(copy, s, length);
data/libpam-krb5-4.9/portable/system.h:106:31:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
#        define va_copy(d, s) memcpy(&(d), &(s), sizeof(va_list))
data/libpam-krb5-4.9/portable/system.h:148:12:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
extern int mkstemp(char *);
data/libpam-krb5-4.9/tests/fakepam/config.c:170:5:  [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 buffer[BUFSIZ];
data/libpam-krb5-4.9/tests/fakepam/config.c:387:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(out, uid, strlen(uid));
data/libpam-krb5-4.9/tests/fakepam/config.c:391:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(out, config->newpass, strlen(config->newpass));
data/libpam-krb5-4.9/tests/fakepam/config.c:395:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(out, config->password, strlen(config->password));
data/libpam-krb5-4.9/tests/fakepam/config.c:399:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(out, config->user, strlen(config->user));
data/libpam-krb5-4.9/tests/fakepam/config.c:413:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(out, extra, strlen(extra));
data/libpam-krb5-4.9/tests/fakepam/kuserok.c:74:5:  [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 buffer[BUFSIZ];
data/libpam-krb5-4.9/tests/fakepam/kuserok.c:98:12:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    file = fopen(path, "r");
data/libpam-krb5-4.9/tests/fakepam/script.c:68:5:  [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 err[BUFSIZ];
data/libpam-krb5-4.9/tests/fakepam/script.c:285:14:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    script = fopen(path, "r");
data/libpam-krb5-4.9/tests/fakepam/script.h:55:11:  [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.
    const char *extra[10];    /* Substituted for %0-%9 in logging. */
data/libpam-krb5-4.9/tests/module/cache-t.c:155:12:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    file = fopen(k5login, "w");
data/libpam-krb5-4.9/tests/module/realm-t.c:67:12:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    file = fopen(k5login, "w");
data/libpam-krb5-4.9/tests/pam-util/options-t.c:146:11:  [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.
    const char *argv_bool[2] = {NULL, NULL};
data/libpam-krb5-4.9/tests/pam-util/options-t.c:147:11:  [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.
    const char *argv_err[2] = {NULL, NULL};
data/libpam-krb5-4.9/tests/pam-util/vector-t.c:35:11:  [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.
    const char *env[2];
data/libpam-krb5-4.9/tests/portable/mkstemp-t.c:37:5:  [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 buffer[256];
data/libpam-krb5-4.9/tests/portable/snprintf-t.c:101:5:  [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 buf[128];
data/libpam-krb5-4.9/tests/portable/snprintf-t.c:119:5:  [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 lgbuf[128];
data/libpam-krb5-4.9/tests/portable/strndup-t.c:33:5:  [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 buffer[3];
data/libpam-krb5-4.9/tests/portable/strndup-t.c:50:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(buffer, "foo", 3);
data/libpam-krb5-4.9/tests/runtests.c:414:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(p, s, len);
data/libpam-krb5-4.9/tests/runtests.c:442:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(copy, s, len);
data/libpam-krb5-4.9/tests/runtests.c:488:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(result + offset, string, strlen(string));
data/libpam-krb5-4.9/tests/runtests.c:590:16:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
        infd = open("/dev/null", O_RDONLY);
data/libpam-krb5-4.9/tests/runtests.c:601:17:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
        errfd = open("/dev/null", O_WRONLY);
data/libpam-krb5-4.9/tests/runtests.c:1109:5:  [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 buffer[BUFSIZ];
data/libpam-krb5-4.9/tests/runtests.c:1252:11:  [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.
    const char *bases[3], *suffix, *base;
data/libpam-krb5-4.9/tests/runtests.c:1254:11:  [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.
    const char *suffixes[3] = {"-t", ".t", ""};
data/libpam-krb5-4.9/tests/runtests.c:1383:5:  [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 buffer[BUFSIZ];
data/libpam-krb5-4.9/tests/runtests.c:1395:12:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    file = fopen(filename, "r");
data/libpam-krb5-4.9/tests/tap/basic.c:180:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(result + offset, string, strlen(string));
data/libpam-krb5-4.9/tests/tap/basic.c:759:18:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    file->file = fopen(file->name, "r");
data/libpam-krb5-4.9/tests/tap/basic.c:884:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(p, s, len);
data/libpam-krb5-4.9/tests/tap/basic.c:908:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(copy, s, length);
data/libpam-krb5-4.9/tests/tap/kerberos.c:168:5:  [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 principal[BUFSIZ], *command;
data/libpam-krb5-4.9/tests/tap/kerberos.c:179:12:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    file = fopen(path, "r");
data/libpam-krb5-4.9/tests/tap/kerberos.c:294:5:  [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 buffer[BUFSIZ];
data/libpam-krb5-4.9/tests/tap/kerberos.c:326:16:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
        file = fopen(path, "r");
data/libpam-krb5-4.9/tests/tap/kerberos.c:365:16:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
        file = fopen(path, "r");
data/libpam-krb5-4.9/tests/tap/kerberos.c:434:11:  [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.
    const char *argv[3];
data/libpam-krb5-4.9/tests/tap/process.c:375:5:  [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 buffer[BUFSIZ];
data/libpam-krb5-4.9/tests/tap/process.c:378:12:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
    file = fopen(path, "r");
data/libpam-krb5-4.9/tests/tap/process.c:428:14:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
    log_fd = mkstemp(process->logfile);
data/libpam-krb5-4.9/module/alt-auth.c:73:23:  [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).
            needed += strlen(user);
data/libpam-krb5-4.9/module/alt-auth.c:80:23:  [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).
        needed += 1 + strlen(realm);
data/libpam-krb5-4.9/module/alt-auth.c:88:47:  [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).
            memcpy(*principal + offset, user, strlen(user));
data/libpam-krb5-4.9/module/alt-auth.c:89:23:  [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).
            offset += strlen(user);
data/libpam-krb5-4.9/module/alt-auth.c:99:44:  [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).
        memcpy(*principal + offset, realm, strlen(realm));
data/libpam-krb5-4.9/module/alt-auth.c:100:19:  [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).
        offset += strlen(realm);
data/libpam-krb5-4.9/module/auth.c:249:26:  [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 (*pass != NULL && strlen(*pass) > PAM_MAX_RESP_SIZE - 1) {
data/libpam-krb5-4.9/module/auth.c:295: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(password) > PAM_MAX_RESP_SIZE - 1) {
data/libpam-krb5-4.9/module/auth.c:298:34:  [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).
        explicit_bzero(password, strlen(password));
data/libpam-krb5-4.9/module/auth.c:305:30:  [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).
    explicit_bzero(password, strlen(password));
data/libpam-krb5-4.9/module/auth.c:463:15:  [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).
        len = strlen(line);
data/libpam-krb5-4.9/module/auth.c:466:23:  [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).
                len = strlen(line);
data/libpam-krb5-4.9/module/cache.c:166:52:  [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 (strncmp("FILE:", args->config->ccache_dir, strlen("FILE:")) == 0)
data/libpam-krb5-4.9/module/cache.c:167:16:  [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).
        dir += strlen("FILE:");
data/libpam-krb5-4.9/module/fast.c:67:35:  [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).
        c, &princ, (unsigned int) strlen(realm), realm,
data/libpam-krb5-4.9/module/fast.c:68: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).
        strlen(KRB5_WELLKNOWN_NAME), KRB5_WELLKNOWN_NAME,
data/libpam-krb5-4.9/module/fast.c:69: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).
        strlen(KRB5_ANON_NAME), KRB5_ANON_NAME, NULL);
data/libpam-krb5-4.9/module/options.c:114:39:  [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).
        args->realm = strdup(&argv[i][strlen("realm=")]);
data/libpam-krb5-4.9/module/password.c:50:13:  [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(tmp) > PAM_MAX_RESP_SIZE - 1) {
data/libpam-krb5-4.9/module/password.c:67:13:  [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(pass1) > PAM_MAX_RESP_SIZE - 1) {
data/libpam-krb5-4.9/module/password.c:71:35:  [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).
            explicit_bzero(pass1, strlen(pass1));
data/libpam-krb5-4.9/module/password.c:79:35:  [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).
            explicit_bzero(pass1, strlen(pass1));
data/libpam-krb5-4.9/module/password.c:86:35:  [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).
            explicit_bzero(pass1, strlen(pass1));
data/libpam-krb5-4.9/module/password.c:88:35:  [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).
            explicit_bzero(pass2, strlen(pass2));
data/libpam-krb5-4.9/module/password.c:93: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).
        explicit_bzero(pass2, strlen(pass2));
data/libpam-krb5-4.9/module/password.c:101:35:  [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).
            explicit_bzero(pass1, strlen(pass1));
data/libpam-krb5-4.9/module/password.c:109: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).
        explicit_bzero(pass1, strlen(pass1));
data/libpam-krb5-4.9/module/password.c:255:30:  [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).
        explicit_bzero(pass, strlen(pass));
data/libpam-krb5-4.9/module/password.c:383:30:  [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).
        explicit_bzero(pass, strlen(pass));
data/libpam-krb5-4.9/module/prompting.c:182:36:  [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).
        explicit_bzero(resp->resp, strlen(resp->resp));
data/libpam-krb5-4.9/module/prompting.c:260:42:  [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).
            explicit_bzero(resp[i].resp, strlen(resp[i].resp));
data/libpam-krb5-4.9/module/prompting.c:275:18:  [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).
    size_t len = strlen(prompt->prompt);
data/libpam-krb5-4.9/module/prompting.c:311:15:  [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).
        len = strlen(resp[i].resp);
data/libpam-krb5-4.9/module/setcred.c:356:36:  [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 (strncmp(name, "FILE:", strlen("FILE:")) == 0)
data/libpam-krb5-4.9/module/setcred.c:357:21:  [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).
            name += strlen("FILE:");
data/libpam-krb5-4.9/module/setcred.c:369:46:  [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 (strncmp(k5name, "FILE:", strlen("FILE:")) == 0)
data/libpam-krb5-4.9/module/setcred.c:370: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).
                    k5name += strlen("FILE:");
data/libpam-krb5-4.9/module/setcred.c:401:15:  [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).
        len = strlen(cache_name);
data/libpam-krb5-4.9/module/setcred.c:403:46:  [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 (strncmp(cache_name, "FILE:", strlen("FILE:")) == 0)
data/libpam-krb5-4.9/module/setcred.c:404:47:  [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).
                cache_name_tmp = cache_name + strlen("FILE:");
data/libpam-krb5-4.9/module/setcred.c:423:38:  [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 (strncmp(cache_name, "FILE:", strlen("FILE:")) == 0)
data/libpam-krb5-4.9/module/setcred.c:424:37:  [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).
        status = chown(cache_name + strlen("FILE:"), uid, gid);
data/libpam-krb5-4.9/pam-util/logging.c:222:26:  [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).
                length = strlen(FLAGS[i].name);
data/libpam-krb5-4.9/pam-util/logging.c:223:37:  [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).
                nout = realloc(out, strlen(out) + length + 2);
data/libpam-krb5-4.9/pam-util/logging.c:230:26:  [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).
                offset = strlen(out);
data/libpam-krb5-4.9/pam-util/options.c:223:46:  [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).
        realm_struct.length = (unsigned int) strlen(realm);
data/libpam-krb5-4.9/pam-util/options.c:262:46:  [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).
        realm_struct.length = (unsigned int) strlen(realm);
data/libpam-krb5-4.9/pam-util/options.c:305:46:  [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).
        realm_struct.length = (unsigned int) strlen(realm);
data/libpam-krb5-4.9/pam-util/options.c:349:46:  [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).
        realm_struct.length = (unsigned int) strlen(realm);
data/libpam-krb5-4.9/pam-util/options.c:500:28:  [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 (result == 0 && strlen(option->name) > length)
data/libpam-krb5-4.9/portable/krb5-extra.c:79:14:  [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).
    length = strlen(type) + 1 + strlen(name) + 1;
data/libpam-krb5-4.9/portable/krb5-extra.c:79: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).
    length = strlen(type) + 1 + strlen(name) + 1;
data/libpam-krb5-4.9/portable/mkstemp.c:65:14:  [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).
    length = strlen(template);
data/libpam-krb5-4.9/portable/snprintf.c:509:19:  [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).
    strln = (int) strlen (value);
data/libpam-krb5-4.9/tests/fakepam/config.c:180:20:  [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 (buffer[strlen(buffer) - 1] != '\n')
data/libpam-krb5-4.9/tests/fakepam/config.c:182:16:  [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).
        buffer[strlen(buffer) - 1] = '\0';
data/libpam-krb5-4.9/tests/fakepam/config.c:340:27:  [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).
                length += strlen(uid);
data/libpam-krb5-4.9/tests/fakepam/config.c:345:27:  [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).
                length += strlen(config->newpass);
data/libpam-krb5-4.9/tests/fakepam/config.c:350:27:  [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).
                length += strlen(config->password);
data/libpam-krb5-4.9/tests/fakepam/config.c:353:27:  [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).
                length += strlen(config->user);
data/libpam-krb5-4.9/tests/fakepam/config.c:367:27:  [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).
                length += strlen(config->extra[*p - '0']);
data/libpam-krb5-4.9/tests/fakepam/config.c:387:34:  [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).
                memcpy(out, uid, strlen(uid));
data/libpam-krb5-4.9/tests/fakepam/config.c:388:24:  [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).
                out += strlen(uid);
data/libpam-krb5-4.9/tests/fakepam/config.c:391:46:  [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).
                memcpy(out, config->newpass, strlen(config->newpass));
data/libpam-krb5-4.9/tests/fakepam/config.c:392:24:  [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).
                out += strlen(config->newpass);
data/libpam-krb5-4.9/tests/fakepam/config.c:395:47:  [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).
                memcpy(out, config->password, strlen(config->password));
data/libpam-krb5-4.9/tests/fakepam/config.c:396:24:  [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).
                out += strlen(config->password);
data/libpam-krb5-4.9/tests/fakepam/config.c:399:43:  [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).
                memcpy(out, config->user, strlen(config->user));
data/libpam-krb5-4.9/tests/fakepam/config.c:400:24:  [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).
                out += strlen(config->user);
data/libpam-krb5-4.9/tests/fakepam/config.c:413:36:  [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).
                memcpy(out, extra, strlen(extra));
data/libpam-krb5-4.9/tests/fakepam/config.c:414:24:  [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).
                out += strlen(extra);
data/libpam-krb5-4.9/tests/fakepam/config.c:481:18:  [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).
        length = strlen(line);
data/libpam-krb5-4.9/tests/fakepam/config.c:546:18:  [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).
        length = strlen(line);
data/libpam-krb5-4.9/tests/fakepam/config.c:638:18:  [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).
        length = strlen(line);
data/libpam-krb5-4.9/tests/fakepam/data.c:219:45:  [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 (strncmp(name, pamh->environ[i], strlen(name)) == 0
data/libpam-krb5-4.9/tests/fakepam/data.c:220: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).
            && pamh->environ[i][strlen(name)] == '=')
data/libpam-krb5-4.9/tests/fakepam/data.c:221:39:  [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 pamh->environ[i] + strlen(name) + 1;
data/libpam-krb5-4.9/tests/fakepam/data.c:291:19:  [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).
        namelen = strlen(setting);
data/libpam-krb5-4.9/tests/fakepam/kuserok.c:111:20:  [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 (buffer[strlen(buffer) - 1] == '\n')
data/libpam-krb5-4.9/tests/fakepam/kuserok.c:112:20:  [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).
            buffer[strlen(buffer) - 1] = '\0';
data/libpam-krb5-4.9/tests/fakepam/script.c:136:14:  [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).
    length = strlen(wanted);
data/libpam-krb5-4.9/tests/fakepam/script.c:171:18:  [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).
        length = strlen(message);
data/libpam-krb5-4.9/tests/module/cache-t.c:64: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).
    ok(strncmp(prefix, cache, strlen(prefix)) == 0,
data/libpam-krb5-4.9/tests/module/cache-t.c:67:20:  [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).
    file = cache + strlen("FILE:");
data/libpam-krb5-4.9/tests/module/cache-t.c:87:40:  [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).
        ctx, &tgtprinc, (unsigned int) strlen(extra->realm), extra->realm,
data/libpam-krb5-4.9/tests/module/cache-t.c:88:44:  [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).
        KRB5_TGS_NAME_SIZE, KRB5_TGS_NAME, strlen(extra->realm), extra->realm,
data/libpam-krb5-4.9/tests/module/expired-t.c:55:10:  [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).
    date[strlen(date) - 1] = '\0';
data/libpam-krb5-4.9/tests/module/fast-anon-t.c:50:37:  [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).
        ctx, &princ, (unsigned int) strlen(realm), realm,
data/libpam-krb5-4.9/tests/module/fast-anon-t.c:51: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).
        strlen(KRB5_WELLKNOWN_NAME), KRB5_WELLKNOWN_NAME,
data/libpam-krb5-4.9/tests/module/fast-anon-t.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).
        strlen(KRB5_ANON_NAME), KRB5_ANON_NAME, NULL);
data/libpam-krb5-4.9/tests/portable/mkstemp-t.c:72:14:  [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).
    length = strlen(template);
data/libpam-krb5-4.9/tests/portable/mkstemp-t.c:75:20:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    is_int(length, read(fd, buffer, length), "...and the data is there");
data/libpam-krb5-4.9/tests/runtests.c:409:11:  [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).
    len = strlen(s) + 1;
data/libpam-krb5-4.9/tests/runtests.c:474:34:  [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 (length >= UINT_MAX - strlen(string)) {
data/libpam-krb5-4.9/tests/runtests.c:478:19:  [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).
        length += strlen(string);
data/libpam-krb5-4.9/tests/runtests.c:488:41:  [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).
        memcpy(result + offset, string, strlen(string));
data/libpam-krb5-4.9/tests/runtests.c:489:19:  [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).
        offset += strlen(string);
data/libpam-krb5-4.9/tests/runtests.c:733: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).
                    ts->reason[strlen(ts->reason) - 1] = '\0';
data/libpam-krb5-4.9/tests/runtests.c:795:39:  [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).
        bail = skip_whitespace(bail + strlen("Bail out!"));
data/libpam-krb5-4.9/tests/runtests.c:799:22:  [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).
            length = strlen(bail);
data/libpam-krb5-4.9/tests/runtests.c:815:14:  [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 (line[strlen(line) - 1] != '\n')
data/libpam-krb5-4.9/tests/runtests.c:1401:18:  [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).
        length = strlen(buffer) - 1;
data/libpam-krb5-4.9/tests/runtests.c:1410:13:  [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(start) == 0)
data/libpam-krb5-4.9/tests/runtests.c:1528:18:  [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).
        length = strlen(current->ts->file);
data/libpam-krb5-4.9/tests/runtests.c:1553:22:  [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).
            for (i = strlen(ts->file); i < longest; i++)
data/libpam-krb5-4.9/tests/tap/basic.c:168:34:  [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 (length >= UINT_MAX - strlen(string))
data/libpam-krb5-4.9/tests/tap/basic.c:170:19:  [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).
        length += strlen(string);
data/libpam-krb5-4.9/tests/tap/basic.c:180:41:  [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).
        memcpy(result + offset, string, strlen(string));
data/libpam-krb5-4.9/tests/tap/basic.c:181:19:  [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).
        offset += strlen(string);
data/libpam-krb5-4.9/tests/tap/basic.c:222:14:  [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).
    length = strlen(file->buffer);
data/libpam-krb5-4.9/tests/tap/basic.c:880:11:  [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).
    len = strlen(s) + 1;
data/libpam-krb5-4.9/tests/tap/kerberos.c:188:19:  [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 (principal[strlen(principal) - 1] != '\n')
data/libpam-krb5-4.9/tests/tap/kerberos.c:190:15:  [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).
    principal[strlen(principal) - 1] = '\0';
data/libpam-krb5-4.9/tests/tap/kerberos.c:333:20:  [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 (buffer[strlen(buffer) - 1] != '\n')
data/libpam-krb5-4.9/tests/tap/kerberos.c:335:16:  [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).
        buffer[strlen(buffer) - 1] = '\0';
data/libpam-krb5-4.9/tests/tap/kerberos.c:340:20:  [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 (buffer[strlen(buffer) - 1] != '\n')
data/libpam-krb5-4.9/tests/tap/kerberos.c:342:16:  [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).
        buffer[strlen(buffer) - 1] = '\0';
data/libpam-krb5-4.9/tests/tap/kerberos.c:369:20:  [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 (buffer[strlen(buffer) - 1] != '\n')
data/libpam-krb5-4.9/tests/tap/kerberos.c:371:16:  [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).
        buffer[strlen(buffer) - 1] = '\0';
data/libpam-krb5-4.9/tests/tap/process.c:138:19:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
            ret = read(fds[0], buf + count, buflen - count - 1);

ANALYSIS SUMMARY:

Hits = 308
Lines analyzed = 18789 in approximately 0.77 seconds (24504 lines/second)
Physical Source Lines of Code (SLOC) = 11040
Hits@level = [0]  79 [1] 120 [2]  67 [3]   9 [4] 110 [5]   2
Hits@level+ = [0+] 387 [1+] 308 [2+] 188 [3+] 121 [4+] 112 [5+]   2
Hits/KSLOC@level+ = [0+] 35.0543 [1+] 27.8986 [2+] 17.029 [3+] 10.9601 [4+] 10.1449 [5+] 0.181159
Dot directories skipped = 2 (--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.