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/sjaakii-1.4.1/include/aligned_malloc.h Examining data/sjaakii-1.4.1/include/ansi.h Examining data/sjaakii-1.4.1/include/assert.h Examining data/sjaakii-1.4.1/include/betza_string.h Examining data/sjaakii-1.4.1/include/bitboard.h Examining data/sjaakii-1.4.1/include/bits.h Examining data/sjaakii-1.4.1/include/bits128.h Examining data/sjaakii-1.4.1/include/bits32.h Examining data/sjaakii-1.4.1/include/bits64.h Examining data/sjaakii-1.4.1/include/board.h Examining data/sjaakii-1.4.1/include/board_rules.h Examining data/sjaakii-1.4.1/include/bool.h Examining data/sjaakii-1.4.1/include/cfgpath.h Examining data/sjaakii-1.4.1/include/chase.h Examining data/sjaakii-1.4.1/include/compilerdef.h Examining data/sjaakii-1.4.1/include/eval_param.h Examining data/sjaakii-1.4.1/include/eval_types.h Examining data/sjaakii-1.4.1/include/evalhash.h Examining data/sjaakii-1.4.1/include/evaluate.h Examining data/sjaakii-1.4.1/include/fen.h Examining data/sjaakii-1.4.1/include/game.h Examining data/sjaakii-1.4.1/include/genrand.h Examining data/sjaakii-1.4.1/include/hashkey.h Examining data/sjaakii-1.4.1/include/hashpath.h Examining data/sjaakii-1.4.1/include/hashtable.h Examining data/sjaakii-1.4.1/include/history.h Examining data/sjaakii-1.4.1/include/keypressed.h Examining data/sjaakii-1.4.1/include/killer.h Examining data/sjaakii-1.4.1/include/mate.h Examining data/sjaakii-1.4.1/include/move.h Examining data/sjaakii-1.4.1/include/moveflag.h Examining data/sjaakii-1.4.1/include/movegen.h Examining data/sjaakii-1.4.1/include/movelist.h Examining data/sjaakii-1.4.1/include/movestring.h Examining data/sjaakii-1.4.1/include/movetype.h Examining data/sjaakii-1.4.1/include/piece_rules.h Examining data/sjaakii-1.4.1/include/piece_types.h Examining data/sjaakii-1.4.1/include/pieces.h Examining data/sjaakii-1.4.1/include/pipe2.h Examining data/sjaakii-1.4.1/include/prefetch.h Examining data/sjaakii-1.4.1/include/pst.h Examining data/sjaakii-1.4.1/include/san.h Examining data/sjaakii-1.4.1/include/score.h Examining data/sjaakii-1.4.1/include/search.h Examining data/sjaakii-1.4.1/include/see.h Examining data/sjaakii-1.4.1/include/sjaak.h Examining data/sjaakii-1.4.1/include/softexp.h Examining data/sjaakii-1.4.1/include/sprt.h Examining data/sjaakii-1.4.1/include/squares.h Examining data/sjaakii-1.4.1/include/test_suite.h Examining data/sjaakii-1.4.1/include/timer.h Examining data/sjaakii-1.4.1/include/variants.h Examining data/sjaakii-1.4.1/include/xstring.h Examining data/sjaakii-1.4.1/src/chess.cc Examining data/sjaakii-1.4.1/src/eval/pst.cc Examining data/sjaakii-1.4.1/src/hash/evalhash.c Examining data/sjaakii-1.4.1/src/hash/hashkey.c Examining data/sjaakii-1.4.1/src/hash/hashtable.c Examining data/sjaakii-1.4.1/src/misc/aligned_malloc.c Examining data/sjaakii-1.4.1/src/misc/ansi.c Examining data/sjaakii-1.4.1/src/misc/cfgpath.c Examining data/sjaakii-1.4.1/src/misc/genrand.c Examining data/sjaakii-1.4.1/src/misc/keypressed.c Examining data/sjaakii-1.4.1/src/misc/pipe2.c Examining data/sjaakii-1.4.1/src/misc/snprintf.c Examining data/sjaakii-1.4.1/src/misc/softexp.c Examining data/sjaakii-1.4.1/src/misc/sprt.c Examining data/sjaakii-1.4.1/src/rules/bitboard.cc Examining data/sjaakii-1.4.1/src/rules/game.cc Examining data/sjaakii-1.4.1/src/rules/move.cc Examining data/sjaakii-1.4.1/src/rules/san.cc Examining data/sjaakii-1.4.1/src/rules/squares.cc Examining data/sjaakii-1.4.1/src/sjef.c Examining data/sjaakii-1.4.1/src/test.cc Examining data/sjaakii-1.4.1/src/timer/timer.c Examining data/sjaakii-1.4.1/src/xboard.cc FINAL RESULTS: data/sjaakii-1.4.1/include/compilerdef.h:47: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 *buf, size_t size, const char *fmt, ...); data/sjaakii-1.4.1/include/compilerdef.h:61:57: [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. # define ATTRIBUTE_FORMAT_PRINTF __attribute__((format(printf, 1, 2))) data/sjaakii-1.4.1/src/hash/hashtable.c:55:13: [4] (crypto) crypt: The crypt functions use a poor one-way hashing algorithm; since they only accept passwords of 8 characters or fewer and only a two-byte salt, they are excessively vulnerable to dictionary attacks given today's faster computing equipment (CWE-327). Use a different algorithm, such as SHA-256, with a larger, non-repeating salt. static void crypt(hash_table_entry_t *hash) data/sjaakii-1.4.1/src/hash/hashtable.c:85:7: [4] (crypto) crypt: The crypt functions use a poor one-way hashing algorithm; since they only accept passwords of 8 characters or fewer and only a two-byte salt, they are excessively vulnerable to dictionary attacks given today's faster computing equipment (CWE-327). Use a different algorithm, such as SHA-256, with a larger, non-repeating salt. crypt(&hash); data/sjaakii-1.4.1/src/hash/hashtable.c:105:4: [4] (crypto) crypt: The crypt functions use a poor one-way hashing algorithm; since they only accept passwords of 8 characters or fewer and only a two-byte salt, they are excessively vulnerable to dictionary attacks given today's faster computing equipment (CWE-327). Use a different algorithm, such as SHA-256, with a larger, non-repeating salt. crypt(data); data/sjaakii-1.4.1/src/hash/hashtable.c:128:7: [4] (crypto) crypt: The crypt functions use a poor one-way hashing algorithm; since they only accept passwords of 8 characters or fewer and only a two-byte salt, they are excessively vulnerable to dictionary attacks given today's faster computing equipment (CWE-327). Use a different algorithm, such as SHA-256, with a larger, non-repeating salt. crypt(&hash); data/sjaakii-1.4.1/src/misc/cfgpath.c:142:2: [4] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). strcat(out, appname); data/sjaakii-1.4.1/src/misc/cfgpath.c:236:2: [4] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). strcat(out, appname); data/sjaakii-1.4.1/src/misc/cfgpath.c:422:2: [4] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). strcat(out, appname); data/sjaakii-1.4.1/src/misc/pipe2.c:76:7: [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(cmd, argv); data/sjaakii-1.4.1/src/misc/snprintf.c:25: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 *buf, size_t size, const char *fmt, ...) data/sjaakii-1.4.1/src/misc/snprintf.c:30:8: [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. res = vsnprintf(buf, size, fmt, ap); data/sjaakii-1.4.1/src/rules/game.cc:11:4: [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. vsnprintf(buf, sizeof buf, msg, ap); data/sjaakii-1.4.1/src/sjef.c:160:4: [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. vsnprintf(buf, BUF_SIZE-1, msg, ap); data/sjaakii-1.4.1/src/xboard.cc:539:4: [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. vsnprintf(buf, 65535, msg, ap); data/sjaakii-1.4.1/src/xboard.cc:553:4: [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. vsnprintf(buf, 65535, msg, ap); data/sjaakii-1.4.1/src/xboard.cc:3816:14: [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(input+1) == -1) data/sjaakii-1.4.1/src/misc/cfgpath.c:88:15: [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. char *home = getenv("XDG_CONFIG_HOME"); data/sjaakii-1.4.1/src/misc/cfgpath.c:91:10: [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. home = getenv("HOME"); data/sjaakii-1.4.1/src/misc/cfgpath.c:179:15: [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. char *home = getenv("XDG_CONFIG_HOME"); data/sjaakii-1.4.1/src/misc/cfgpath.c:182:10: [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. home = getenv("HOME"); data/sjaakii-1.4.1/src/misc/cfgpath.c:280:15: [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. char *home = getenv("XDG_DATA_HOME"); data/sjaakii-1.4.1/src/misc/cfgpath.c:283:10: [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. home = getenv("HOME"); data/sjaakii-1.4.1/src/misc/cfgpath.c:365:15: [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. char *home = getenv("XDG_CACHE_HOME"); data/sjaakii-1.4.1/src/misc/cfgpath.c:368:10: [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. home = getenv("HOME"); data/sjaakii-1.4.1/include/betza_string.h:65:10: [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 *sym4txt[NUM_SYM4]; data/sjaakii-1.4.1/include/betza_string.h:67:10: [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 *sym8txt[NUM_SYM8]; data/sjaakii-1.4.1/include/betza_string.h:299:10: [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 *sym4txt[NUM_SYM4]; data/sjaakii-1.4.1/include/betza_string.h:362: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. const char *atom[2] = { "W", "F" }; data/sjaakii-1.4.1/include/betza_string.h:363:7: [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 countstr[10]; data/sjaakii-1.4.1/include/betza_string.h:384:10: [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 s[64]; data/sjaakii-1.4.1/include/betza_string.h:467: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. static char static_buffer[256] = { 0 }; data/sjaakii-1.4.1/include/betza_string.h:508:4: [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 s_string[256] = { 0 }; data/sjaakii-1.4.1/include/betza_string.h:509:4: [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 m_string[256] = { 0 }; data/sjaakii-1.4.1/include/betza_string.h:510:4: [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 c_string[256] = { 0 }; data/sjaakii-1.4.1/include/betza_string.h:511:4: [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 i_string[256] = { 0 }; data/sjaakii-1.4.1/include/betza_string.h:512:4: [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 b_string[256] = { 0 }; data/sjaakii-1.4.1/include/betza_string.h:513: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. static char static_buffer[768] = { 0 }; data/sjaakii-1.4.1/include/bitboard.h:248:17: [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 char static_buffer[256]; data/sjaakii-1.4.1/include/board.h:470:7: [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 mark[256]; data/sjaakii-1.4.1/include/eval_types.h:139:21: [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). bitboard_t<kind> open; data/sjaakii-1.4.1/include/evaluate.h:19:21: [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). bitboard_t<kind> open; data/sjaakii-1.4.1/include/evaluate.h:32:21: [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). bitboard_t<kind> open; data/sjaakii-1.4.1/include/evaluate.h:82:10: [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). open &= ~bitboard_t<kind>::board_file[unpack_file(square)]; data/sjaakii-1.4.1/include/evaluate.h:90: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). ps->open = open; data/sjaakii-1.4.1/include/evaluate.h:293:66: [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 ((pt.piece_move_flags[piece] & MF_SLIDER_V) && ps.open.test(square)) { data/sjaakii-1.4.1/include/fen.h:329: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. static char static_buffer[4096]; data/sjaakii-1.4.1/include/game.h:1694:7: [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[4096]; data/sjaakii-1.4.1/include/game.h:2078:7: [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(backup_repetition_hash_table, repetition_hash_table, sizeof repetition_hash_table); data/sjaakii-1.4.1/include/game.h:2079:7: [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(backup_board_repetition_hash_table, board_repetition_hash_table, sizeof board_repetition_hash_table); data/sjaakii-1.4.1/include/game.h:2261:10: [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 fen[4096] = { 0 }; data/sjaakii-1.4.1/include/game.h:2406: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 fen[4096] = { 0 }; data/sjaakii-1.4.1/include/game.h:2481:7: [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(repetition_hash_table, backup_repetition_hash_table, sizeof repetition_hash_table); data/sjaakii-1.4.1/include/game.h:2482:7: [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(board_repetition_hash_table, backup_board_repetition_hash_table, sizeof board_repetition_hash_table); data/sjaakii-1.4.1/include/game.h:2489:7: [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(backup_repetition_hash_table, repetition_hash_table, sizeof repetition_hash_table); data/sjaakii-1.4.1/include/game.h:2490:7: [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(backup_board_repetition_hash_table, board_repetition_hash_table, sizeof board_repetition_hash_table); data/sjaakii-1.4.1/include/game.h:2761:7: [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(repetition_hash_table, backup_repetition_hash_table, sizeof repetition_hash_table); data/sjaakii-1.4.1/include/game.h:2762:7: [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(board_repetition_hash_table, backup_board_repetition_hash_table, sizeof board_repetition_hash_table); data/sjaakii-1.4.1/include/move.h:102:8: [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. extern char piece_symbol_string[MAX_PIECE_TYPES+1]; data/sjaakii-1.4.1/include/move.h:103:8: [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. extern char piece_psymbol_string[MAX_PIECE_TYPES+1]; data/sjaakii-1.4.1/include/move.h:104:8: [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. extern char piece_drop_string[MAX_PIECE_TYPES+1]; data/sjaakii-1.4.1/include/movestring.h:18:4: [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 ms[16]; data/sjaakii-1.4.1/include/movestring.h:30:7: [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[128]; data/sjaakii-1.4.1/include/piece_rules.h:201:4: [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/sjaakii-1.4.1/include/piece_types.h:149:4: [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 * piece_name[MAX_PIECE_TYPES]; data/sjaakii-1.4.1/include/piece_types.h:150:4: [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 * piece_abbreviation[MAX_PIECE_TYPES][NUM_SIDES]; data/sjaakii-1.4.1/include/piece_types.h:151:4: [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 * piece_notation[MAX_PIECE_TYPES]; data/sjaakii-1.4.1/include/piece_types.h:152:4: [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 * demotion_string[MAX_PIECE_TYPES]; data/sjaakii-1.4.1/include/piece_types.h:153:4: [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 * allowed_victim[MAX_PIECE_TYPES]; data/sjaakii-1.4.1/include/piece_types.h:197:7: [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 ss[32]; data/sjaakii-1.4.1/include/squares.h:6:8: [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. extern char *square_names[128]; data/sjaakii-1.4.1/include/squares.h:7:8: [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. extern char *file_names[16]; data/sjaakii-1.4.1/include/squares.h:8:8: [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. extern char *rank_names[16]; data/sjaakii-1.4.1/include/variants.h:1775:4: [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 *promotion[MAX_PZ]; data/sjaakii-1.4.1/include/variants.h:1879:4: [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[4096]; data/sjaakii-1.4.1/include/variants.h:2689:8: [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). f = fopen(filename, "r"); data/sjaakii-1.4.1/include/variants.h:2691:4: [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[4096]; data/sjaakii-1.4.1/include/variants.h:2731: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 msg[256]; data/sjaakii-1.4.1/src/misc/cfgpath.c:110:2: [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, home, home_len); data/sjaakii-1.4.1/src/misc/cfgpath.c:115:3: [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/", config_len); data/sjaakii-1.4.1/src/misc/cfgpath.c:120:2: [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, appname, appname_len); data/sjaakii-1.4.1/src/misc/cfgpath.c:122:2: [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, ".conf", ext_len); data/sjaakii-1.4.1/src/misc/cfgpath.c:143:2: [2] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). Risk is low because the source is a constant string. strcat(out, ".ini"); data/sjaakii-1.4.1/src/misc/cfgpath.c:200:2: [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, home, home_len); data/sjaakii-1.4.1/src/misc/cfgpath.c:205:3: [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/", config_len); data/sjaakii-1.4.1/src/misc/cfgpath.c:211:2: [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, appname, appname_len); data/sjaakii-1.4.1/src/misc/cfgpath.c:301:2: [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, home, home_len); data/sjaakii-1.4.1/src/misc/cfgpath.c:306:3: [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, ".local/share/", config_len); data/sjaakii-1.4.1/src/misc/cfgpath.c:312:2: [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, appname, appname_len); data/sjaakii-1.4.1/src/misc/cfgpath.c:386:2: [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, home, home_len); data/sjaakii-1.4.1/src/misc/cfgpath.c:391:3: [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, ".cache/", config_len); data/sjaakii-1.4.1/src/misc/cfgpath.c:397:2: [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, appname, appname_len); data/sjaakii-1.4.1/src/misc/pipe2.c:87:4: [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[10]; data/sjaakii-1.4.1/src/rules/game.cc:7: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. static char buf[65536]; data/sjaakii-1.4.1/src/rules/move.cc:24:1: [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 piece_symbol_string[MAX_PIECE_TYPES+1]; data/sjaakii-1.4.1/src/rules/move.cc:25:1: [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 piece_psymbol_string[MAX_PIECE_TYPES+1]; data/sjaakii-1.4.1/src/rules/move.cc:26:1: [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 piece_drop_string[MAX_PIECE_TYPES+1]; data/sjaakii-1.4.1/src/rules/move.cc:30: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. static char static_buffer[64]; data/sjaakii-1.4.1/src/rules/move.cc:132: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. static char static_buffer[256]; data/sjaakii-1.4.1/src/rules/san.cc:8: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. static char static_buffer[256]; data/sjaakii-1.4.1/src/rules/squares.cc:8:1: [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 *square_names[128] = { NULL }; data/sjaakii-1.4.1/src/rules/squares.cc:9:1: [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 *file_names[16] = { NULL }; data/sjaakii-1.4.1/src/rules/squares.cc:10:1: [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_names[16] = { NULL }; data/sjaakii-1.4.1/src/rules/squares.cc:108:4: [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 s[128]; data/sjaakii-1.4.1/src/sjef.c:566:4: [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 finit[65536]; data/sjaakii-1.4.1/src/sjef.c:567:4: [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 sinit[65536]; data/sjaakii-1.4.1/src/sjef.c:570:4: [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 host[255]; data/sjaakii-1.4.1/src/sjef.c:726:20: [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). pgnf = fopen(argv[n], "a"); data/sjaakii-1.4.1/src/sjef.c:785:17: [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 *f = fopen(epdfile, "r"); data/sjaakii-1.4.1/src/sjef.c:798:17: [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). logfile = fopen(logfilename, "w"); data/sjaakii-1.4.1/src/sjef.c:985:4: [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 tc_string[256]; data/sjaakii-1.4.1/src/sjef.c:1033:20: [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 *f = fopen(epdfile, "r"); data/sjaakii-1.4.1/src/sjef.c:1056:10: [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 s[4096]; data/sjaakii-1.4.1/src/sjef.c:1106:22: [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 *side_string[4] = { "1-0", "0-1", "draw", "-" }; data/sjaakii-1.4.1/src/sjef.c:1240: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 s[128]; data/sjaakii-1.4.1/src/xboard.cc:465:8: [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 char configfile[1024] = { 0 }; data/sjaakii-1.4.1/src/xboard.cc:468:8: [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 char deferred[256]; data/sjaakii-1.4.1/src/xboard.cc:628: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). FILE *f = fopen(filename, "r"); data/sjaakii-1.4.1/src/xboard.cc:632:4: [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[4096]; data/sjaakii-1.4.1/src/xboard.cc:752:8: [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 char fairy_alias[512] = { 0 }; data/sjaakii-1.4.1/src/xboard.cc:753:8: [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 char normal_alias[512] = { 0 }; data/sjaakii-1.4.1/src/xboard.cc:848:4: [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 fen[4096]; data/sjaakii-1.4.1/src/xboard.cc:986:7: [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 move_str[10] = { 0 }; data/sjaakii-1.4.1/src/xboard.cc:1066: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. static char ponder_input[65536]; data/sjaakii-1.4.1/src/xboard.cc:1135: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. static char ponder_input[65536]; data/sjaakii-1.4.1/src/xboard.cc:1164: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. static char ponder_input[65536]; data/sjaakii-1.4.1/src/xboard.cc:1207:10: [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 choice_str[256]; data/sjaakii-1.4.1/src/xboard.cc:1464: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 move_str[32] = { 0 }; data/sjaakii-1.4.1/src/xboard.cc:1484: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 move_str[32] = { 0 }; data/sjaakii-1.4.1/src/xboard.cc:1737: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. static char buf[65536]; data/sjaakii-1.4.1/src/xboard.cc:1871: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). FILE *cf = fopen(configfile, "w"); data/sjaakii-1.4.1/src/xboard.cc:2046: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. static char buffer[1024]; data/sjaakii-1.4.1/src/xboard.cc:2150:4: [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 fairy_size_string[1024] = { 0 }; data/sjaakii-1.4.1/src/xboard.cc:2152:7: [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 s[32]; data/sjaakii-1.4.1/src/xboard.cc:2206:19: [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 *inf = fopen(fname, "r"); data/sjaakii-1.4.1/src/xboard.cc:2225:4: [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 input[65536]; data/sjaakii-1.4.1/src/xboard.cc:2226:4: [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 prompt_str[256]; data/sjaakii-1.4.1/src/xboard.cc:2268: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). if (!f) f = fopen(logfile, mode); data/sjaakii-1.4.1/src/xboard.cc:2351: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). FILE *cf = fopen(configfile, "r"); data/sjaakii-1.4.1/src/xboard.cc:2683: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 fen[256] = { 0 }; data/sjaakii-1.4.1/src/xboard.cc:3749: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 choice_str[256]; data/sjaakii-1.4.1/src/xboard.cc:3765:10: [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 choice_str[256]; data/sjaakii-1.4.1/src/xboard.cc:3802:20: [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 *f = fopen(input+8, "r"); data/sjaakii-1.4.1/src/xboard.cc:3804: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 s[4096]; data/sjaakii-1.4.1/include/betza_string.h:411: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 (ai == 1 && strlen(sym4txt[best]) == 2 && k == 1) data/sjaakii-1.4.1/include/betza_string.h:534: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). size_t n1 = strlen(m_string); data/sjaakii-1.4.1/include/betza_string.h:535: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). size_t n2 = strlen(i_string); data/sjaakii-1.4.1/include/betza_string.h:545: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). size_t n1 = strlen(m_string); data/sjaakii-1.4.1/include/betza_string.h:546: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). size_t n2 = strlen(b_string); data/sjaakii-1.4.1/include/betza_string.h:557:7: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(s_string, m_string, sizeof s_string); data/sjaakii-1.4.1/include/betza_string.h:564:10: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(s_string, m_string, sizeof s_string); data/sjaakii-1.4.1/include/betza_string.h:567: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 n1 = strlen(s_string); data/sjaakii-1.4.1/include/betza_string.h:568: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 n2 = strlen(c_string); data/sjaakii-1.4.1/include/betza_string.h:581:10: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(s_string, c_string, sizeof s_string); data/sjaakii-1.4.1/include/betza_string.h:584: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 n1 = strlen(s_string); data/sjaakii-1.4.1/include/betza_string.h:585: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 n2 = strlen(m_string); data/sjaakii-1.4.1/include/betza_string.h:607: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). size_t l = strlen(m_string); data/sjaakii-1.4.1/include/betza_string.h:620:8: [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). l = strlen(c_string); data/sjaakii-1.4.1/include/betza_string.h:639: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 l = strlen(i_string); data/sjaakii-1.4.1/include/betza_string.h:654: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 l = strlen(b_string); data/sjaakii-1.4.1/include/betza_string.h:719:8: [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(buffer) == 0) { data/sjaakii-1.4.1/include/fen.h:196: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). int len = (int)strlen(pt.piece_abbreviation[n][match_side]); data/sjaakii-1.4.1/include/fen.h:212: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). s += strlen(pt.piece_abbreviation[piece][side])-1; data/sjaakii-1.4.1/include/game.h:1714: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). s = line+strlen(line)-1; data/sjaakii-1.4.1/include/game.h:2101: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). const char lc = pt.piece_name[n][strlen(pt.piece_name[n])-1]; data/sjaakii-1.4.1/include/game.h:2180: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). const char lc = pt.piece_name[n][strlen(pt.piece_name[n])-1]; data/sjaakii-1.4.1/include/game.h:2368: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). const char lc = pt.piece_name[n][strlen(pt.piece_name[n])-1]; data/sjaakii-1.4.1/include/game.h:2525: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). const char lc = pt.piece_name[n][strlen(pt.piece_name[n])-1]; data/sjaakii-1.4.1/include/movestring.h:56:12: [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 l = strlen(ms); data/sjaakii-1.4.1/include/piece_rules.h:82: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). p = pt.piece_abbreviation[n][WHITE] + strlen(pt.piece_abbreviation[n][WHITE]); data/sjaakii-1.4.1/include/variants.h:1901: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). s = line+strlen(line)-1; data/sjaakii-1.4.1/include/variants.h:2707: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). s = line+strlen(line)-1; data/sjaakii-1.4.1/include/xstring.h:12:29: [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 (size_t n = 0; n<=strlen(p); n++) data/sjaakii-1.4.1/src/misc/cfgpath.c:97: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). config_len = strlen(".config/"); data/sjaakii-1.4.1/src/misc/cfgpath.c:100: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). unsigned int home_len = strlen(home); data/sjaakii-1.4.1/src/misc/cfgpath.c:101:29: [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). unsigned int appname_len = strlen(appname); data/sjaakii-1.4.1/src/misc/cfgpath.c:102: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). const int ext_len = strlen(".conf"); data/sjaakii-1.4.1/src/misc/cfgpath.c:136: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). appname_len = (unsigned int)strlen(appname); data/sjaakii-1.4.1/src/misc/cfgpath.c:137:6: [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(out) + 1 + appname_len + strlen(".ini") + 1 > maxlen) { data/sjaakii-1.4.1/src/misc/cfgpath.c:137: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 (strlen(out) + 1 + appname_len + strlen(".ini") + 1 > maxlen) { data/sjaakii-1.4.1/src/misc/cfgpath.c:141:2: [1] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). Risk is low because the source is a constant character. strcat(out, "\\"); data/sjaakii-1.4.1/src/misc/cfgpath.c:188: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). config_len = strlen(".config/"); data/sjaakii-1.4.1/src/misc/cfgpath.c:191: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). unsigned int home_len = strlen(home); data/sjaakii-1.4.1/src/misc/cfgpath.c:192:29: [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). unsigned int appname_len = strlen(appname); data/sjaakii-1.4.1/src/misc/cfgpath.c:230: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). appname_len = (unsigned int)strlen(appname); data/sjaakii-1.4.1/src/misc/cfgpath.c:231:6: [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(out) + 1 + appname_len + 1 + 1 > maxlen) { data/sjaakii-1.4.1/src/misc/cfgpath.c:235:2: [1] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). Risk is low because the source is a constant character. strcat(out, "\\"); data/sjaakii-1.4.1/src/misc/cfgpath.c:239:2: [1] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). Risk is low because the source is a constant character. strcat(out, "\\"); data/sjaakii-1.4.1/src/misc/cfgpath.c:289: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). config_len = strlen(".local/share/"); data/sjaakii-1.4.1/src/misc/cfgpath.c:292: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). unsigned int home_len = strlen(home); data/sjaakii-1.4.1/src/misc/cfgpath.c:293:29: [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). unsigned int appname_len = strlen(appname); data/sjaakii-1.4.1/src/misc/cfgpath.c:374: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). config_len = strlen(".cache/"); data/sjaakii-1.4.1/src/misc/cfgpath.c:377: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). unsigned int home_len = strlen(home); data/sjaakii-1.4.1/src/misc/cfgpath.c:378:29: [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). unsigned int appname_len = strlen(appname); data/sjaakii-1.4.1/src/misc/cfgpath.c:416: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). appname_len = (unsigned int)strlen(appname); data/sjaakii-1.4.1/src/misc/cfgpath.c:417:6: [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(out) + 1 + appname_len + 1 + 1 > maxlen) { data/sjaakii-1.4.1/src/misc/cfgpath.c:421:2: [1] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). Risk is low because the source is a constant character. strcat(out, "\\"); data/sjaakii-1.4.1/src/misc/cfgpath.c:425:2: [1] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). Risk is low because the source is a constant character. strcat(out, "\\"); data/sjaakii-1.4.1/src/misc/pipe2.c:88:18: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). ssize_t res = read(lifeline[0], buf, 10); data/sjaakii-1.4.1/src/rules/move.cc:153: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). snprintf(s + strlen(s), 256-strlen(s), "/%c%s", piece_symbol_string[get_move_promotion_piece(move)], square_names[get_move_drop_square(move)]); data/sjaakii-1.4.1/src/rules/move.cc:153: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). snprintf(s + strlen(s), 256-strlen(s), "/%c%s", piece_symbol_string[get_move_promotion_piece(move)], square_names[get_move_drop_square(move)]); data/sjaakii-1.4.1/src/rules/move.cc:228: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). snprintf(s + strlen(s), 256-strlen(s), "/%c", piece_symbol_string[get_move_promotion_piece(move)]); data/sjaakii-1.4.1/src/rules/move.cc:228: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). snprintf(s + strlen(s), 256-strlen(s), "/%c", piece_symbol_string[get_move_promotion_piece(move)]); data/sjaakii-1.4.1/src/rules/san.cc:36: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). snprintf(s + strlen(s), 256-strlen(s), "/%c%s", piece_symbol_string[get_move_promotion_piece(move)], square_names[get_move_drop_square(move)]); data/sjaakii-1.4.1/src/rules/san.cc:36: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). snprintf(s + strlen(s), 256-strlen(s), "/%c%s", piece_symbol_string[get_move_promotion_piece(move)], square_names[get_move_drop_square(move)]); data/sjaakii-1.4.1/src/sjef.c:174:8: [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(buf)) { data/sjaakii-1.4.1/src/sjef.c:175: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). ssize_t res = p2write(prog->f, buf, strlen(buf)); data/sjaakii-1.4.1/src/sjef.c:318: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). token = line+strlen(line); data/sjaakii-1.4.1/src/sjef.c:454: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). int len = strlen(value); data/sjaakii-1.4.1/src/sjef.c:652: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). finit_str = finit + strlen(finit); data/sjaakii-1.4.1/src/sjef.c:660: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). sinit_str = sinit + strlen(sinit); data/sjaakii-1.4.1/src/sjef.c:1245: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). k = strlen(s); data/sjaakii-1.4.1/src/sjef.c:1253: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). if ( (l + strlen(s)) >= 80) { data/sjaakii-1.4.1/src/sjef.c:1257: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). l += strlen(s); data/sjaakii-1.4.1/src/sjef.c:1261: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). if ( (l + strlen(s)) >= 80) { data/sjaakii-1.4.1/src/sjef.c:1265: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). l += strlen(s); data/sjaakii-1.4.1/src/xboard.cc:646: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). s = line+strlen(line)-1; data/sjaakii-1.4.1/src/xboard.cc:1537:8: [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(topic)) topic = "help"; data/sjaakii-1.4.1/src/xboard.cc:1875: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). if (user_alias && strlen(user_alias)) data/sjaakii-1.4.1/src/xboard.cc:1878: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). if (fairy_file && strlen(fairy_file)) data/sjaakii-1.4.1/src/xboard.cc:1881: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). if (eval_file && strlen(eval_file) && remember_eval_file) data/sjaakii-1.4.1/src/xboard.cc:1923: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). len = strlen (text); data/sjaakii-1.4.1/src/xboard.cc:1959: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). len = strlen (text); data/sjaakii-1.4.1/src/xboard.cc:2008: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). len = strlen (text); data/sjaakii-1.4.1/src/xboard.cc:2155: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). size_t l = strlen(fairy_size_string); data/sjaakii-1.4.1/src/xboard.cc:2450: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). if (readline_input && strlen(readline_input)) data/sjaakii-1.4.1/src/xboard.cc:2462:25: [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). char *e = input + strlen(input)-1; data/sjaakii-1.4.1/src/xboard.cc:2609: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). char *p = s + strlen(s)-1; data/sjaakii-1.4.1/src/xboard.cc:2855: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). size_t l = strlen(standard_variants[n].name); data/sjaakii-1.4.1/src/xboard.cc:2859: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). size_t l = strlen(custom_variants[n].shortname); data/sjaakii-1.4.1/src/xboard.cc:2864: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). int c = (int)(max_len - strlen(standard_variants[n].name)); data/sjaakii-1.4.1/src/xboard.cc:2872: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). int c = (int)(max_len - strlen(custom_variants[n].shortname)); data/sjaakii-1.4.1/src/xboard.cc:2882: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). p = s + strlen(s)-1; data/sjaakii-1.4.1/src/xboard.cc:2897: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). p = s + strlen(s)-1; data/sjaakii-1.4.1/src/xboard.cc:2910: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). char *p = s + strlen(s)-1; data/sjaakii-1.4.1/src/xboard.cc:2928:50: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). snprintf((char *)variant_name, strlen(variant_name), "fairy"); data/sjaakii-1.4.1/src/xboard.cc:2966:56: [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 (game->xb_setup && game->xb_setup[strlen(game->xb_setup)-1] == ')') { data/sjaakii-1.4.1/src/xboard.cc:2999: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). char *eol = input + strlen(input)-1; data/sjaakii-1.4.1/src/xboard.cc:3020: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). char *eol = input + strlen(input)-1; data/sjaakii-1.4.1/src/xboard.cc:3178: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). char *eol = input + strlen(input)-1; data/sjaakii-1.4.1/src/xboard.cc:3199: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). char *eol = input + strlen(input)-1; data/sjaakii-1.4.1/src/xboard.cc:3592: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). const char *fname = input + strlen("lep"); ANALYSIS SUMMARY: Hits = 242 Lines analyzed = 27085 in approximately 1.00 seconds (27105 lines/second) Physical Source Lines of Code (SLOC) = 20830 Hits@level = [0] 844 [1] 98 [2] 119 [3] 8 [4] 17 [5] 0 Hits@level+ = [0+] 1086 [1+] 242 [2+] 144 [3+] 25 [4+] 17 [5+] 0 Hits/KSLOC@level+ = [0+] 52.1363 [1+] 11.6179 [2+] 6.91311 [3+] 1.20019 [4+] 0.816131 [5+] 0 Dot directories skipped = 1 (--followdotdir overrides) Minimum risk level = 1 Not every hit is necessarily a security vulnerability. There may be other security vulnerabilities; review your code! See 'Secure Programming HOWTO' (https://dwheeler.com/secure-programs) for more information.