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/rmlint-2.9.0/lib/api.h
Examining data/rmlint-2.9.0/lib/cfg.c
Examining data/rmlint-2.9.0/lib/cfg.h
Examining data/rmlint-2.9.0/lib/checksum.c
Examining data/rmlint-2.9.0/lib/checksum.h
Examining data/rmlint-2.9.0/lib/checksums/blake2/blake2-impl.h
Examining data/rmlint-2.9.0/lib/checksums/blake2/blake2.h
Examining data/rmlint-2.9.0/lib/checksums/blake2/blake2b-ref.c
Examining data/rmlint-2.9.0/lib/checksums/blake2/blake2bp-ref.c
Examining data/rmlint-2.9.0/lib/checksums/blake2/blake2s-ref.c
Examining data/rmlint-2.9.0/lib/checksums/blake2/blake2sp-ref.c
Examining data/rmlint-2.9.0/lib/checksums/blake2/blake2xb-ref.c
Examining data/rmlint-2.9.0/lib/checksums/blake2/blake2xs-ref.c
Examining data/rmlint-2.9.0/lib/checksums/highwayhash.c
Examining data/rmlint-2.9.0/lib/checksums/highwayhash.h
Examining data/rmlint-2.9.0/lib/checksums/metrohash.h
Examining data/rmlint-2.9.0/lib/checksums/metrohash128.c
Examining data/rmlint-2.9.0/lib/checksums/murmur3.c
Examining data/rmlint-2.9.0/lib/checksums/murmur3.h
Examining data/rmlint-2.9.0/lib/checksums/sha3/sha3.c
Examining data/rmlint-2.9.0/lib/checksums/sha3/sha3.h
Examining data/rmlint-2.9.0/lib/checksums/xxhash/xxhash.c
Examining data/rmlint-2.9.0/lib/checksums/xxhash/xxhash.h
Examining data/rmlint-2.9.0/lib/cmdline.h
Examining data/rmlint-2.9.0/lib/file.c
Examining data/rmlint-2.9.0/lib/file.h
Examining data/rmlint-2.9.0/lib/formats/_equal.c
Examining data/rmlint-2.9.0/lib/formats/csv.c
Examining data/rmlint-2.9.0/lib/formats/fdupes.c
Examining data/rmlint-2.9.0/lib/formats/json.c
Examining data/rmlint-2.9.0/lib/formats/null.c
Examining data/rmlint-2.9.0/lib/formats/pretty.c
Examining data/rmlint-2.9.0/lib/formats/progressbar.c
Examining data/rmlint-2.9.0/lib/formats/stats.c
Examining data/rmlint-2.9.0/lib/formats/summary.c
Examining data/rmlint-2.9.0/lib/formats/timestamp.c
Examining data/rmlint-2.9.0/lib/formats/uniques.c
Examining data/rmlint-2.9.0/lib/fts/fts.c
Examining data/rmlint-2.9.0/lib/fts/fts.h
Examining data/rmlint-2.9.0/lib/hash-utility.c
Examining data/rmlint-2.9.0/lib/hash-utility.h
Examining data/rmlint-2.9.0/lib/hasher.c
Examining data/rmlint-2.9.0/lib/hasher.h
Examining data/rmlint-2.9.0/lib/md-scheduler.c
Examining data/rmlint-2.9.0/lib/md-scheduler.h
Examining data/rmlint-2.9.0/lib/pathtricia.c
Examining data/rmlint-2.9.0/lib/pathtricia.h
Examining data/rmlint-2.9.0/lib/preprocess.c
Examining data/rmlint-2.9.0/lib/preprocess.h
Examining data/rmlint-2.9.0/lib/replay.c
Examining data/rmlint-2.9.0/lib/replay.h
Examining data/rmlint-2.9.0/lib/session.c
Examining data/rmlint-2.9.0/lib/session.h
Examining data/rmlint-2.9.0/lib/shredder.c
Examining data/rmlint-2.9.0/lib/shredder.h
Examining data/rmlint-2.9.0/lib/traverse.c
Examining data/rmlint-2.9.0/lib/traverse.h
Examining data/rmlint-2.9.0/lib/treemerge.c
Examining data/rmlint-2.9.0/lib/treemerge.h
Examining data/rmlint-2.9.0/lib/xattr.h
Examining data/rmlint-2.9.0/lib/cmdline.c
Examining data/rmlint-2.9.0/lib/utilities.h
Examining data/rmlint-2.9.0/lib/xattr.c
Examining data/rmlint-2.9.0/lib/formats.c
Examining data/rmlint-2.9.0/lib/formats.h
Examining data/rmlint-2.9.0/lib/utilities.c
Examining data/rmlint-2.9.0/src/rmlint.c

FINAL RESULTS:

data/rmlint-2.9.0/lib/cmdline.c:1253:12:  [5] (race) readlink:
  This accepts filename arguments; if an attacker can move those files or
  change the link content, a race condition results. Also, it does not
  terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach.
        if(readlink("/proc/self/exe", exe_path, sizeof(exe_path)) != -1) {
data/rmlint-2.9.0/lib/hasher.c:146:16:  [5] (race) readlink:
  This accepts filename arguments; if an attacker can move those files or
  change the link content, a race condition results. Also, it does not
  terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach.
    gint len = readlink(path, (char *)buffer->data, hasher->buf_size);
data/rmlint-2.9.0/lib/traverse.c:181:12:  [5] (race) readlink:
  This accepts filename arguments; if an attacker can move those files or
  change the link content, a race condition results. Also, it does not
  terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach.
        if(readlink(path, new_path_buf, PATH_MAX) == -1) {
data/rmlint-2.9.0/lib/cfg.c:112:10:  [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.
    rc = access(path, R_OK);
data/rmlint-2.9.0/lib/cmdline.c:89:5:  [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, RESET "\n\n");
data/rmlint-2.9.0/lib/cmdline.c:107: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.
        if(snprintf(cmd_buf, sizeof(cmd_buf), commands[i],
data/rmlint-2.9.0/lib/cmdline.c:112:12:  [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.
        if(system(cmd_buf) == 0) {
data/rmlint-2.9.0/lib/cmdline.c:199:12:  [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.
        if(execvp(*command, (char *const *)all_argv) == -1) {
data/rmlint-2.9.0/lib/formats.c:322:12:  [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, F_OK) == 0) {
data/rmlint-2.9.0/lib/formats.c:572:12:  [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.
    return access(handler->path, W_OK) == -1;
data/rmlint-2.9.0/lib/formats/csv.c:83:5:  [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(
data/rmlint-2.9.0/lib/formats/pretty.c:118: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(out, format, self->user);
data/rmlint-2.9.0/lib/formats/pretty.c:121: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(out, format, self->group);
data/rmlint-2.9.0/lib/formats/pretty.c:124: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(out, format, self->user, self->group);
data/rmlint-2.9.0/lib/formats/summary.c:134:12:  [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) == -1) {
data/rmlint-2.9.0/lib/traverse.c:150:39:  [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.
        } else if(cfg->permissions && access(path, cfg->permissions) == -1) {
data/rmlint-2.9.0/lib/traverse.c:425:24:  [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(p->fts_path, R_OK) == -1 && errno == ENOENT) {
data/rmlint-2.9.0/lib/utilities.c:592:19:  [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.
        int res = system(cmd);
data/rmlint-2.9.0/lib/xattr.c:395:5:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
    strcpy(&key[key_len - sub_key_len], sub_key);
data/rmlint-2.9.0/lib/cfg.c:121:23:  [3] (buffer) realpath:
  This function does not protect against buffer overflows, and some
  implementations can overflow internally (CWE-120/CWE-785!). Ensure that the
  destination buffer is at least of size MAXPATHLEN, andto protect against
  implementation problems, the input argument should also be checked to
  ensure it is no larger than MAXPATHLEN.
    char *real_path = realpath(path, NULL);
data/rmlint-2.9.0/lib/cmdline.c:1258:20:  [3] (buffer) realpath:
  This function does not protect against buffer overflows, and some
  implementations can overflow internally (CWE-120/CWE-785!). Ensure that the
  destination buffer is at least of size MAXPATHLEN, andto protect against
  implementation problems, the input argument should also be checked to
  ensure it is no larger than MAXPATHLEN.
            return realpath(argv[0], NULL);
data/rmlint-2.9.0/lib/formats.c:356:27:  [3] (buffer) realpath:
  This function does not protect against buffer overflows, and some
  implementations can overflow internally (CWE-120/CWE-785!). Ensure that the
  destination buffer is at least of size MAXPATHLEN, andto protect against
  implementation problems, the input argument should also be checked to
  ensure it is no larger than MAXPATHLEN.
        char *full_path = realpath(path, NULL);
data/rmlint-2.9.0/lib/hash-utility.c:181:30:  [3] (buffer) realpath:
  This function does not protect against buffer overflows, and some
  implementations can overflow internally (CWE-120/CWE-785!). Ensure that the
  destination buffer is at least of size MAXPATHLEN, andto protect against
  implementation problems, the input argument should also be checked to
  ensure it is no larger than MAXPATHLEN.
            char *abs_path = realpath(strtok_r(path_buf, "\n", &tokbuf), NULL);
data/rmlint-2.9.0/lib/traverse.c:120:16:  [3] (buffer) realpath:
  This function does not protect against buffer overflows, and some
  implementations can overflow internally (CWE-120/CWE-785!). Ensure that the
  destination buffer is at least of size MAXPATHLEN, andto protect against
  implementation problems, the input argument should also be checked to
  ensure it is no larger than MAXPATHLEN.
        return realpath(pointing_to, NULL);
data/rmlint-2.9.0/lib/traverse.c:125:24:  [3] (buffer) realpath:
  This function does not protect against buffer overflows, and some
  implementations can overflow internally (CWE-120/CWE-785!). Ensure that the
  destination buffer is at least of size MAXPATHLEN, andto protect against
  implementation problems, the input argument should also be checked to
  ensure it is no larger than MAXPATHLEN.
    char *clean_path = realpath(full_path, NULL);
data/rmlint-2.9.0/lib/cfg.h:141: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 rank_criteria[64];
data/rmlint-2.9.0/lib/checksum.c:170: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, state, sizeof(XXH64_state_t));
data/rmlint-2.9.0/lib/checksum.c:374: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(result, state->data, state->bytes);
data/rmlint-2.9.0/lib/checksum.c:550: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(result, sha3_Finalize(copy), 256 / 8);
data/rmlint-2.9.0/lib/checksum.c:556: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(result, sha3_Finalize(copy), 384 / 8);
data/rmlint-2.9.0/lib/checksum.c:562: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(result, sha3_Finalize(copy), 512 / 8);
data/rmlint-2.9.0/lib/checksum.c:680: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(result, state->data, state->len);
data/rmlint-2.9.0/lib/checksums/blake2/blake2-impl.h:26: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(&w, src, sizeof w);
data/rmlint-2.9.0/lib/checksums/blake2/blake2-impl.h:38: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(&w, src, sizeof w);
data/rmlint-2.9.0/lib/checksums/blake2/blake2-impl.h:51: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(&w, src, sizeof w);
data/rmlint-2.9.0/lib/checksums/blake2/blake2-impl.h:61: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(dst, &w, sizeof w);
data/rmlint-2.9.0/lib/checksums/blake2/blake2-impl.h:72: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(dst, &w, sizeof w);
data/rmlint-2.9.0/lib/checksums/blake2/blake2-impl.h:84: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(dst, &w, sizeof w);
data/rmlint-2.9.0/lib/checksums/blake2/blake2b-ref.c:135: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(block, key, keylen);
data/rmlint-2.9.0/lib/checksums/blake2/blake2b-ref.c:216: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(S->buf + left, in, fill); /* Fill buffer */
data/rmlint-2.9.0/lib/checksums/blake2/blake2b-ref.c:228: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(S->buf + S->buflen, in, inlen);
data/rmlint-2.9.0/lib/checksums/blake2/blake2b-ref.c:252: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(out, buffer, S->outlen);
data/rmlint-2.9.0/lib/checksums/blake2/blake2bp-ref.c:125: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(block, key, keylen);
data/rmlint-2.9.0/lib/checksums/blake2/blake2bp-ref.c:142: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(S->buf + left, in, fill);
data/rmlint-2.9.0/lib/checksums/blake2/blake2bp-ref.c:177: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(S->buf + left, in, inlen);
data/rmlint-2.9.0/lib/checksums/blake2/blake2bp-ref.c:242: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(block, key, keylen);
data/rmlint-2.9.0/lib/checksums/blake2/blake2s-ref.c:135: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(block, key, keylen);
data/rmlint-2.9.0/lib/checksums/blake2/blake2s-ref.c:214: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(S->buf + left, in, fill); /* Fill buffer */
data/rmlint-2.9.0/lib/checksums/blake2/blake2s-ref.c:226: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(S->buf + S->buflen, in, inlen);
data/rmlint-2.9.0/lib/checksums/blake2/blake2s-ref.c:250: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(out, buffer, outlen);
data/rmlint-2.9.0/lib/checksums/blake2/blake2sp-ref.c:122: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(block, key, keylen);
data/rmlint-2.9.0/lib/checksums/blake2/blake2sp-ref.c:139: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(S->buf + left, in, fill);
data/rmlint-2.9.0/lib/checksums/blake2/blake2sp-ref.c:173: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(S->buf + left, in, inlen);
data/rmlint-2.9.0/lib/checksums/blake2/blake2sp-ref.c:238: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(block, key, keylen);
data/rmlint-2.9.0/lib/checksums/blake2/blake2xb-ref.c:65: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(block, key, keylen);
data/rmlint-2.9.0/lib/checksums/blake2/blake2xb-ref.c:106: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->P, sizeof(blake2b_param));
data/rmlint-2.9.0/lib/checksums/blake2/blake2xs-ref.c:64: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(block, key, keylen);
data/rmlint-2.9.0/lib/checksums/blake2/blake2xs-ref.c:105: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->P, sizeof(blake2s_param));
data/rmlint-2.9.0/lib/checksums/metrohash128.c:89: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(xs + xs_len, data, bytes);                                             \
data/rmlint-2.9.0/lib/checksums/metrohash128.c:140: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(state->xs, data, state->xs_len);
data/rmlint-2.9.0/lib/checksums/metrohash128.c:211: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(out, v, 16);
data/rmlint-2.9.0/lib/checksums/metrohash128.c:274: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(out, v, 16);
data/rmlint-2.9.0/lib/checksums/metrohash128.c:351: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(state->xs, data, state->xs_len);
data/rmlint-2.9.0/lib/checksums/metrohash128.c:399: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(state->xs, data, state->xs_len);
data/rmlint-2.9.0/lib/checksums/metrohash128.c:460: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(out, v, 16);
data/rmlint-2.9.0/lib/checksums/metrohash128.c:520: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(out, v, 16);
data/rmlint-2.9.0/lib/checksums/murmur3.c:131: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(xs + xs_len, data, bytes);                                             \
data/rmlint-2.9.0/lib/checksums/murmur3.c:178: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(state->xs, data, state->xs_len);
data/rmlint-2.9.0/lib/checksums/murmur3.c:295: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(state->xs, data, state->xs_len);
data/rmlint-2.9.0/lib/checksums/murmur3.c:461: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(state->xs, data, state->xs_len);
data/rmlint-2.9.0/lib/checksums/xxhash/xxhash.c:97:12:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    return memcpy(dest, src, size);
data/rmlint-2.9.0/lib/checksums/xxhash/xxhash.c:120: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(&val32, memPtr, 4);
data/rmlint-2.9.0/lib/checksums/xxhash/xxhash.c:126: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(&val64, memPtr, 8);
data/rmlint-2.9.0/lib/cmdline.c:106:9:  [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 cmd_buf[512] = {0};
data/rmlint-2.9.0/lib/cmdline.c:188: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 *all_argv[512];
data/rmlint-2.9.0/lib/cmdline.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 format_name[100];
data/rmlint-2.9.0/lib/cmdline.c:623: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 lint_sep[2] = {0, 0};
data/rmlint-2.9.0/lib/cmdline.c:698:13:  [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 time_buf[256];
data/rmlint-2.9.0/lib/cmdline.c:723:13:  [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 time_buf[256];
data/rmlint-2.9.0/lib/cmdline.c:741:24:  [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 *stamp_file = fopen(timestamp_path, "r");
data/rmlint-2.9.0/lib/cmdline.c:747:9:  [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 stamp_buf[1024];
data/rmlint-2.9.0/lib/cmdline.c:1173: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 cwd_buf[PATH_MAX + 1];
data/rmlint-2.9.0/lib/cmdline.c:1189: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_nul[argc + 1];
data/rmlint-2.9.0/lib/cmdline.c:1191: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(argv_nul, argv, argc * sizeof(const char *));
data/rmlint-2.9.0/lib/cmdline.c:1252:9:  [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 exe_path[PATH_MAX] = {0};
data/rmlint-2.9.0/lib/formats.c:329:23:  [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_handle = fopen(path, "w");
data/rmlint-2.9.0/lib/formats.c:341: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(new_handler_copy, new_handler, new_handler->size);
data/rmlint-2.9.0/lib/formats.h:118: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 *valid_keys[32];
data/rmlint-2.9.0/lib/formats/fdupes.c:52: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[512 + 32];
data/rmlint-2.9.0/lib/formats/json.c:106:9:  [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 text[20];
data/rmlint-2.9.0/lib/formats/json.c:147: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 safe_value[PATH_MAX + 4 + 1];
data/rmlint-2.9.0/lib/formats/json.c:332:21:  [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 orig_checksum_str[rm_digest_get_bytes(file->digest) * 2 + 1];
data/rmlint-2.9.0/lib/formats/progressbar.c:47: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 text_buf[1024];
data/rmlint-2.9.0/lib/formats/progressbar.c:67: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 last_eta[1024];
data/rmlint-2.9.0/lib/formats/progressbar.c:169: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 num_buf[32] = {0};
data/rmlint-2.9.0/lib/formats/progressbar.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 preproc_buf[128] = {0};
data/rmlint-2.9.0/lib/formats/progressbar.c:354:30:  [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.
                static const char *colors[3] = {
data/rmlint-2.9.0/lib/formats/stats.c:69: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 numbers[64];
data/rmlint-2.9.0/lib/formats/stats.c:109: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 eff_total[64] = "NaN";
data/rmlint-2.9.0/lib/formats/stats.c:110: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 eff_dupes[64] = "NaN";
data/rmlint-2.9.0/lib/formats/summary.c:79: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 numbers[3][512];
data/rmlint-2.9.0/lib/formats/summary.c:91: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 size_string_buf[22] = {0};
data/rmlint-2.9.0/lib/formats/timestamp.c:47:9:  [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 time_buf[256];
data/rmlint-2.9.0/lib/fts/fts.c:208:27:  [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).
        if((sp->fts_rfd = open(".", O_RDONLY | O_CLOEXEC, 0)) == -1)
data/rmlint-2.9.0/lib/fts/fts.c:357:32:  [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).
            if((p->fts_symfd = open(".", O_RDONLY | O_CLOEXEC, 0)) == -1) {
data/rmlint-2.9.0/lib/fts/fts.c:455:36:  [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).
                if((p->fts_symfd = open(".", O_RDONLY | O_CLOEXEC, 0)) == -1) {
data/rmlint-2.9.0/lib/fts/fts.c:593: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).
    if((fd = open(".", O_RDONLY | O_CLOEXEC, 0)) == -1)
data/rmlint-2.9.0/lib/fts/fts.c:1177:27:  [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).
    if(oldfd < 0 && (fd = open(path, O_RDONLY | O_CLOEXEC)) == -1)
data/rmlint-2.9.0/lib/fts/fts.h:138: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 fts_name[1];        /* file name */
data/rmlint-2.9.0/lib/hash-utility.c:64: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 checksum_str[size];
data/rmlint-2.9.0/lib/hash-utility.c:145: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 summary[4096];
data/rmlint-2.9.0/lib/hash-utility.c:176:9:  [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 path_buf[PATH_MAX];
data/rmlint-2.9.0/lib/hasher.c:171:10:  [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).
    fd = fopen(path, "rb");
data/rmlint-2.9.0/lib/pathtricia.c:97: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 path_buf[PATH_MAX];
data/rmlint-2.9.0/lib/pathtricia.c:196: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 *elements[PATH_MAX / 2 + 1] = {node->basename, NULL};
data/rmlint-2.9.0/lib/pathtricia.c:211:42:  [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.
        buf_ptr = g_stpcpy(buf_ptr + 1, (char *)elements[--n_elements]);
data/rmlint-2.9.0/lib/pathtricia.c:312: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[1024];
data/rmlint-2.9.0/lib/preprocess.c:150: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 parent_path[PATH_MAX];
data/rmlint-2.9.0/lib/traverse.c:297:33:  [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.
    FTS *ftsp = fts_open((const char *const[2]){rmpath->path, NULL}, fts_flags, NULL);
data/rmlint-2.9.0/lib/traverse.c:312: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 is_emptydir[PATH_MAX / 2 + 1];
data/rmlint-2.9.0/lib/traverse.c:313: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 is_hidden[PATH_MAX / 2 + 1];
data/rmlint-2.9.0/lib/treemerge.c:140: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 path[PATH_MAX];
data/rmlint-2.9.0/lib/treemerge.c:779:13:  [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[512];
data/rmlint-2.9.0/lib/utilities.c:505: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 sys_path[PATH_MAX + 30];
data/rmlint-2.9.0/lib/utilities.c:508:22:  [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 *sys_fdes = fopen(sys_path, "r");
data/rmlint-2.9.0/lib/utilities.c:725:9:  [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 diskname[PATH_MAX];
data/rmlint-2.9.0/lib/utilities.h:121:12:  [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).
    return open(path, mode, (S_IRUSR | S_IWUSR));
data/rmlint-2.9.0/lib/xattr.c:220: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 cksum_key[64], mtime_key[64],
data/rmlint-2.9.0/lib/xattr.c:246: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 cksum_key[64] = {0},
data/rmlint-2.9.0/lib/xattr.c:297:9:  [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 key[64] = {0};
data/rmlint-2.9.0/lib/xattr.c:320: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 prefix[13] = "user.rmlint.";
data/rmlint-2.9.0/lib/xattr.c:322: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[buf_size];
data/rmlint-2.9.0/lib/cmdline.c:413:13:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
            strncpy(format_name, pair, sizeof(format_name)-1);
data/rmlint-2.9.0/lib/cmdline.c:417:13:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
            strncpy(format_name, extension, sizeof(format_name)-1);
data/rmlint-2.9.0/lib/cmdline.c:421:9:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
        strncpy(format_name, pair, MIN((long)sizeof(format_name), separator - pair));
data/rmlint-2.9.0/lib/cmdline.c:1098:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
    strncpy(cfg->rank_criteria, criteria, sizeof(cfg->rank_criteria)-1);
data/rmlint-2.9.0/lib/cmdline.c:1320:66:  [1] (buffer) equal:
  Function does not check the second iterator for over-read conditions
  (CWE-126). This function is often discouraged by most C++ coding standards
  in favor of its safer alternatives provided since C++14. Consider using a
  form of this function that checks the second iterator before potentially
  overflowing it.
        {"equal"    ,  0 ,  EMPTY , G_OPTION_ARG_CALLBACK , FUNC(equal)    , _("Test for equality of PATHS")           , "PATHS"}           ,
data/rmlint-2.9.0/lib/formats/fdupes.c:61:13:  [1] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant character.
            strcpy(line, "\n");
data/rmlint-2.9.0/lib/formats/json.c:57: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).
        hash ^= MurmurHash3_x86_32(file_path, strlen(file_path), i);
data/rmlint-2.9.0/lib/formats/json.c:59: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).
            hash ^= MurmurHash3_x86_32(cksum, strlen(cksum), i);
data/rmlint-2.9.0/lib/formats/json.c:100: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).
    int n = strlen(string);
data/rmlint-2.9.0/lib/formats/progressbar.c:153:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
    strncpy(self->last_eta, eta_info, sizeof(self->last_eta) - 1);
data/rmlint-2.9.0/lib/fts/fts.c:151: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((len = strlen(*argv)) == 0) {
data/rmlint-2.9.0/lib/fts/fts.c:244: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(++cp);
data/rmlint-2.9.0/lib/fts/fts.c:746: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).
        dnamlen = strlen(dp->d_name);
data/rmlint-2.9.0/lib/fts/fts.c:1160: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((len = strlen(*argv)) > max)
data/rmlint-2.9.0/lib/pathtricia.c:106:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
    strncpy(iter->path_buf, path, PATH_MAX);
data/rmlint-2.9.0/lib/pathtricia.c:316: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).
        buf[strlen(buf) - 1] = 0;
data/rmlint-2.9.0/lib/preprocess.c:57:58:  [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 a_len = (ext_a) ? (ext_a - basename_a) : (int)strlen(basename_a);
data/rmlint-2.9.0/lib/preprocess.c:58:58:  [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 b_len = (ext_b) ? (ext_b - basename_b) : (int)strlen(basename_a);
data/rmlint-2.9.0/lib/preprocess.c:404:33:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        return sign * SIGN_DIFF(strlen(a->folder->basename), strlen(b->folder->basename));
data/rmlint-2.9.0/lib/preprocess.c:404:62:  [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 sign * SIGN_DIFF(strlen(a->folder->basename), strlen(b->folder->basename));
data/rmlint-2.9.0/lib/replay.c:213:68:  [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).
            rm_digest_update(file->digest, (unsigned char *)cksum, strlen(cksum));
data/rmlint-2.9.0/lib/replay.c:323: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).
        size_t path_len = strlen(rmpath->path);
data/rmlint-2.9.0/lib/shredder.c:1506:65:  [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).
        rm_digest_update(group->digest, (unsigned char *)cksum, strlen(cksum));
data/rmlint-2.9.0/lib/treemerge.c:152:17:  [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(int i = strlen(path) - 1; i >= 0; --i) {
data/rmlint-2.9.0/lib/treemerge.c:445:17:  [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(basename) + 1,  /* include the nul-byte */
data/rmlint-2.9.0/lib/treemerge.c:494:17:  [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(basename) + 1,  /* include the nul-byte */
data/rmlint-2.9.0/lib/utilities.c:736:17:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                strncpy(diskname, entry->fsname, sizeof(diskname)-1);
data/rmlint-2.9.0/lib/utilities.c:742:17:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                strncpy(diskname, entry->fsname, until_slash);
data/rmlint-2.9.0/lib/utilities.c:751:17:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
                strncpy(diskname, "unknown", sizeof(diskname));
data/rmlint-2.9.0/lib/utilities.c:765:17:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                strncpy(diskname, entry->fsname, sizeof(diskname)-1);
data/rmlint-2.9.0/lib/utilities.c:1140: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).
        int len = strlen(mountpath);
data/rmlint-2.9.0/lib/xattr.c:230:49:  [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).
       rm_xattr_set(file, mtime_key, timestamp, strlen(timestamp), follow)) {
data/rmlint-2.9.0/lib/xattr.c:385: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).
    size_t key_len = strlen(key);
data/rmlint-2.9.0/lib/xattr.c:386: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).
    size_t sub_key_len = strlen(sub_key);
data/rmlint-2.9.0/lib/xattr.c:479: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).
        result = rm_sys_setxattr(path, key, cksum, strlen(cksum), 0, follow_symlinks);

ANALYSIS SUMMARY:

Hits = 167
Lines analyzed = 23968 in approximately 0.65 seconds (37048 lines/second)
Physical Source Lines of Code (SLOC) = 15102
Hits@level = [0]  92 [1]  35 [2] 107 [3]   6 [4]  16 [5]   3
Hits@level+ = [0+] 259 [1+] 167 [2+] 132 [3+]  25 [4+]  19 [5+]   3
Hits/KSLOC@level+ = [0+] 17.15 [1+] 11.0581 [2+] 8.74056 [3+] 1.65541 [4+] 1.25811 [5+] 0.198649
Dot directories skipped = 1 (--followdotdir overrides)
Minimum risk level = 1
Not every hit is necessarily a security vulnerability.
There may be other security vulnerabilities; review your code!
See 'Secure Programming HOWTO'
(https://dwheeler.com/secure-programs) for more information.