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/monit-5.27.1/libmonit/test/ConvertTest.c
Examining data/monit-5.27.1/libmonit/test/OutputStreamTest.c
Examining data/monit-5.27.1/libmonit/test/InputStreamTest.c
Examining data/monit-5.27.1/libmonit/test/ExceptionTest.c
Examining data/monit-5.27.1/libmonit/test/FileTest.c
Examining data/monit-5.27.1/libmonit/test/ListTest.c
Examining data/monit-5.27.1/libmonit/test/TimeTest.c
Examining data/monit-5.27.1/libmonit/test/DirTest.c
Examining data/monit-5.27.1/libmonit/test/StrTest.c
Examining data/monit-5.27.1/libmonit/test/SystemTest.c
Examining data/monit-5.27.1/libmonit/test/CommandTest.c
Examining data/monit-5.27.1/libmonit/test/NetTest.c
Examining data/monit-5.27.1/libmonit/test/StringBufferTest.c
Examining data/monit-5.27.1/libmonit/src/util/StringBuffer.h
Examining data/monit-5.27.1/libmonit/src/util/StringBuffer.c
Examining data/monit-5.27.1/libmonit/src/util/Str.h
Examining data/monit-5.27.1/libmonit/src/util/Convert.c
Examining data/monit-5.27.1/libmonit/src/util/List.c
Examining data/monit-5.27.1/libmonit/src/util/Convert.h
Examining data/monit-5.27.1/libmonit/src/util/Str.c
Examining data/monit-5.27.1/libmonit/src/util/List.h
Examining data/monit-5.27.1/libmonit/src/system/Time.h
Examining data/monit-5.27.1/libmonit/src/system/Command.c
Examining data/monit-5.27.1/libmonit/src/system/Process.h
Examining data/monit-5.27.1/libmonit/src/system/Net.c
Examining data/monit-5.27.1/libmonit/src/system/Net.h
Examining data/monit-5.27.1/libmonit/src/system/Command.h
Examining data/monit-5.27.1/libmonit/src/system/System.c
Examining data/monit-5.27.1/libmonit/src/system/Mem.h
Examining data/monit-5.27.1/libmonit/src/system/Time.c
Examining data/monit-5.27.1/libmonit/src/system/System.h
Examining data/monit-5.27.1/libmonit/src/system/Mem.c
Examining data/monit-5.27.1/libmonit/src/thread/Thread.c
Examining data/monit-5.27.1/libmonit/src/thread/Thread.h
Examining data/monit-5.27.1/libmonit/src/Bootstrap.c
Examining data/monit-5.27.1/libmonit/src/exceptions/ProtocolException.h
Examining data/monit-5.27.1/libmonit/src/exceptions/MemoryException.h
Examining data/monit-5.27.1/libmonit/src/exceptions/assert.c
Examining data/monit-5.27.1/libmonit/src/exceptions/Exception.c
Examining data/monit-5.27.1/libmonit/src/exceptions/NumberFormatException.h
Examining data/monit-5.27.1/libmonit/src/exceptions/IOException.h
Examining data/monit-5.27.1/libmonit/src/exceptions/AssertException.h
Examining data/monit-5.27.1/libmonit/src/exceptions/Exception.h
Examining data/monit-5.27.1/libmonit/src/exceptions/assert.h
Examining data/monit-5.27.1/libmonit/src/Bootstrap.h
Examining data/monit-5.27.1/libmonit/src/io/InputStream.h
Examining data/monit-5.27.1/libmonit/src/io/File.c
Examining data/monit-5.27.1/libmonit/src/io/OutputStream.c
Examining data/monit-5.27.1/libmonit/src/io/OutputStream.h
Examining data/monit-5.27.1/libmonit/src/io/Dir.c
Examining data/monit-5.27.1/libmonit/src/io/File.h
Examining data/monit-5.27.1/libmonit/src/io/Dir.h
Examining data/monit-5.27.1/libmonit/src/io/InputStream.c
Examining data/monit-5.27.1/libmonit/src/Config.h
Examining data/monit-5.27.1/src/gc.c
Examining data/monit-5.27.1/src/spawn.c
Examining data/monit-5.27.1/src/util.c
Examining data/monit-5.27.1/src/env.c
Examining data/monit-5.27.1/src/state.h
Examining data/monit-5.27.1/src/util.h
Examining data/monit-5.27.1/src/event.h
Examining data/monit-5.27.1/src/alert.h
Examining data/monit-5.27.1/src/http/engine.c
Examining data/monit-5.27.1/src/http/httpstatus.h
Examining data/monit-5.27.1/src/http/processor.c
Examining data/monit-5.27.1/src/http/client.c
Examining data/monit-5.27.1/src/http/engine.h
Examining data/monit-5.27.1/src/http/xml.c
Examining data/monit-5.27.1/src/http/processor.h
Examining data/monit-5.27.1/src/http/cervlet.h
Examining data/monit-5.27.1/src/http/cervlet.c
Examining data/monit-5.27.1/src/http/base64.c
Examining data/monit-5.27.1/src/http/client.h
Examining data/monit-5.27.1/src/http/base64.h
Examining data/monit-5.27.1/src/y.tab.c
Examining data/monit-5.27.1/src/file.c
Examining data/monit-5.27.1/src/md5.h
Examining data/monit-5.27.1/src/control.c
Examining data/monit-5.27.1/src/log.c
Examining data/monit-5.27.1/src/terminal/Color.h
Examining data/monit-5.27.1/src/terminal/Box.c
Examining data/monit-5.27.1/src/terminal/Color.c
Examining data/monit-5.27.1/src/terminal/Box.h
Examining data/monit-5.27.1/src/signal.c
Examining data/monit-5.27.1/src/monit.c
Examining data/monit-5.27.1/src/protocols/imap.c
Examining data/monit-5.27.1/src/protocols/lmtp.c
Examining data/monit-5.27.1/src/protocols/dns.c
Examining data/monit-5.27.1/src/protocols/protocol.h
Examining data/monit-5.27.1/src/protocols/default.c
Examining data/monit-5.27.1/src/protocols/dwp.c
Examining data/monit-5.27.1/src/protocols/rsync.c
Examining data/monit-5.27.1/src/protocols/sip.c
Examining data/monit-5.27.1/src/protocols/ntp3.c
Examining data/monit-5.27.1/src/protocols/nntp.c
Examining data/monit-5.27.1/src/protocols/ldap3.c
Examining data/monit-5.27.1/src/protocols/clamav.c
Examining data/monit-5.27.1/src/protocols/mysql.c
Examining data/monit-5.27.1/src/protocols/ftp.c
Examining data/monit-5.27.1/src/protocols/postfix_policy.c
Examining data/monit-5.27.1/src/protocols/pgsql.c
Examining data/monit-5.27.1/src/protocols/protocol.c
Examining data/monit-5.27.1/src/protocols/websocket.c
Examining data/monit-5.27.1/src/protocols/radius.c
Examining data/monit-5.27.1/src/protocols/smtp.c
Examining data/monit-5.27.1/src/protocols/memcache.c
Examining data/monit-5.27.1/src/protocols/rdate.c
Examining data/monit-5.27.1/src/protocols/redis.c
Examining data/monit-5.27.1/src/protocols/fail2ban.c
Examining data/monit-5.27.1/src/protocols/mongodb.c
Examining data/monit-5.27.1/src/protocols/ssh.c
Examining data/monit-5.27.1/src/protocols/apache_status.c
Examining data/monit-5.27.1/src/protocols/mqtt.c
Examining data/monit-5.27.1/src/protocols/generic.c
Examining data/monit-5.27.1/src/protocols/ldap2.c
Examining data/monit-5.27.1/src/protocols/pop.c
Examining data/monit-5.27.1/src/protocols/http.c
Examining data/monit-5.27.1/src/protocols/sieve.c
Examining data/monit-5.27.1/src/protocols/spamassassin.c
Examining data/monit-5.27.1/src/protocols/tns.c
Examining data/monit-5.27.1/src/protocols/gps.c
Examining data/monit-5.27.1/src/md5_crypt.h
Examining data/monit-5.27.1/src/net/socket.h
Examining data/monit-5.27.1/src/net/socket.c
Examining data/monit-5.27.1/src/net/Link.h
Examining data/monit-5.27.1/src/net/net.c
Examining data/monit-5.27.1/src/net/net.h
Examining data/monit-5.27.1/src/net/Link.c
Examining data/monit-5.27.1/src/event.c
Examining data/monit-5.27.1/src/checksum.h
Examining data/monit-5.27.1/src/daemonize.c
Examining data/monit-5.27.1/src/checksum.c
Examining data/monit-5.27.1/src/statistics/Statistics.h
Examining data/monit-5.27.1/src/statistics/Statistics.c
Examining data/monit-5.27.1/src/notification/MMonit.c
Examining data/monit-5.27.1/src/notification/MMonit.h
Examining data/monit-5.27.1/src/notification/Address.h
Examining data/monit-5.27.1/src/notification/SMTP.c
Examining data/monit-5.27.1/src/notification/SMTP.h
Examining data/monit-5.27.1/src/notification/Address.c
Examining data/monit-5.27.1/src/file.h
Examining data/monit-5.27.1/src/lex.yy.c
Examining data/monit-5.27.1/src/state.c
Examining data/monit-5.27.1/src/validate.c
Examining data/monit-5.27.1/src/ssl/Ssl.c
Examining data/monit-5.27.1/src/ssl/Ssl.h
Examining data/monit-5.27.1/src/ssl/SslServer.h
Examining data/monit-5.27.1/src/http.c
Examining data/monit-5.27.1/src/alert.c
Examining data/monit-5.27.1/src/y.tab.h
Examining data/monit-5.27.1/src/device/sysdep_LINUX.c
Examining data/monit-5.27.1/src/device/sysdep_NETBSD.c
Examining data/monit-5.27.1/src/device/sysdep_DARWIN.c
Examining data/monit-5.27.1/src/device/device_common.c
Examining data/monit-5.27.1/src/device/sysdep_FREEBSD.c
Examining data/monit-5.27.1/src/device/sysdep_DRAGONFLY.c
Examining data/monit-5.27.1/src/device/sysdep_AIX.c
Examining data/monit-5.27.1/src/device/sysdep_UNKNOWN.c
Examining data/monit-5.27.1/src/device/device.h
Examining data/monit-5.27.1/src/device/sysdep_SOLARIS.c
Examining data/monit-5.27.1/src/device/sysdep_OPENBSD.c
Examining data/monit-5.27.1/src/device/sysdep_HURD.c
Examining data/monit-5.27.1/src/md5_crypt.c
Examining data/monit-5.27.1/src/process/sysdep_NETBSD.c
Examining data/monit-5.27.1/src/process/sysdep_DARWIN.c
Examining data/monit-5.27.1/src/process/sysdep_FREEBSD.c
Examining data/monit-5.27.1/src/process/process_sysdep.h
Examining data/monit-5.27.1/src/process/sysdep_DRAGONFLY.c
Examining data/monit-5.27.1/src/process/sysdep_AIX.c
Examining data/monit-5.27.1/src/process/sysdep_UNKNOWN.c
Examining data/monit-5.27.1/src/process/ProcessTree.h
Examining data/monit-5.27.1/src/process/sysdep_SOLARIS.c
Examining data/monit-5.27.1/src/process/ProcessTree.c
Examining data/monit-5.27.1/src/process/sysdep_OPENBSD.c
Examining data/monit-5.27.1/src/process/sysdep_HURD.c
Examining data/monit-5.27.1/src/process/sysdep_LINUX.c
Examining data/monit-5.27.1/src/md5.c
Examining data/monit-5.27.1/src/sha1.h
Examining data/monit-5.27.1/src/sha1.c
Examining data/monit-5.27.1/src/monit.h

FINAL RESULTS:

data/monit-5.27.1/libmonit/src/io/File.c:203:25:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
                return (chmod(file, mode) == 0);
data/monit-5.27.1/src/http/engine.c:452:29:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
                        if (chmod(Run.httpd.socket.unix.path, Run.httpd.socket.unix.permission) != 0) {
data/monit-5.27.1/src/http/engine.c:458:29:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
                        if (chown(Run.httpd.socket.unix.path, Run.httpd.socket.unix.uid, -1) != 0) {
data/monit-5.27.1/src/http/engine.c:464:29:  [5] (race) chown:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchown( ) instead.
                        if (chown(Run.httpd.socket.unix.path, -1, Run.httpd.socket.unix.gid) != 0) {
data/monit-5.27.1/libmonit/src/exceptions/Exception.c:94:25:  [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(p->message, EXCEPTION_MESSAGE_LENGTH, cause, ap);
data/monit-5.27.1/libmonit/src/exceptions/Exception.c:102:17:  [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(message, EXCEPTION_MESSAGE_LENGTH, cause, ap);
data/monit-5.27.1/libmonit/src/io/File.c:234:25:  [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(file, R_OK) == 0);
data/monit-5.27.1/libmonit/src/io/File.c:241:25:  [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(file, W_OK) == 0);
data/monit-5.27.1/libmonit/src/io/File.c:248:25:  [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(file, X_OK) == 0);
data/monit-5.27.1/libmonit/src/io/OutputStream.c:313:17:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
                snprintf(buf, sizeof(buf), fmt, va_arg(box->ap, double));
data/monit-5.27.1/libmonit/src/io/OutputStream.h:149:72:  [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.
int OutputStream_print(T S, const char *s, ...) __attribute__((format (printf, 2, 3)));
data/monit-5.27.1/libmonit/src/system/Command.h:183:92:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Command_vSetEnv(T C, const char *name, const char *value, ...) __attribute__((format (printf, 3, 4)));
data/monit-5.27.1/libmonit/src/system/System.c:80:17:  [4] (format) vfprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
                vfprintf(stderr, e, ap);
data/monit-5.27.1/libmonit/src/system/System.c:93:17:  [4] (format) vfprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
                vfprintf(stderr, e, ap);
data/monit-5.27.1/libmonit/src/system/System.h:60:62:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void System_abort(const char *e, ...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/libmonit/src/system/System.h:68:62:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void System_error(const char *e, ...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/libmonit/src/util/Convert.c:58:13:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
            snprintf(s, 10, _isInt(bytes) ? "%s%.0lf %s" : "%s%.1lf %s", sign, bytes, kNotation[i]);
data/monit-5.27.1/libmonit/src/util/Convert.c:87:13:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
            snprintf(s, 11, _isInt(milli) ? "%s%.0lf %s" : "%s%.3lf %s", sign, milli, conversion[i].suffix);
data/monit-5.27.1/libmonit/src/util/Str.c:345:28:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
                int size = vsnprintf(t, 0, s, ap_copy) + 1;
data/monit-5.27.1/libmonit/src/util/Str.c:349:17:  [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(t, size, s, ap_copy);
data/monit-5.27.1/libmonit/src/util/Str.h:325:58:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
char *Str_cat(const char *s, ...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/libmonit/src/util/Str.h:336:66:  [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.
char *Str_vcat(const char *s, va_list ap) __attribute__((format (printf, 1, 0)));
data/monit-5.27.1/libmonit/src/util/StringBuffer.c:64:24:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
__attribute__((format (printf, 2, 0)))
data/monit-5.27.1/libmonit/src/util/StringBuffer.c:69:25:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
                int n = vsnprintf((char *)(S->buffer + S->used), S->length - S->used, s, ap_copy);
data/monit-5.27.1/libmonit/src/util/StringBuffer.h:84:71:  [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.
T StringBuffer_append(T S, const char *s, ...) __attribute__((format (printf, 2, 3)));
data/monit-5.27.1/libmonit/src/util/StringBuffer.h:97:79:  [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.
T StringBuffer_vappend(T S, const char *s, va_list ap) __attribute__((format (printf, 2, 0)));
data/monit-5.27.1/libmonit/test/StringBufferTest.c:18:24:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
__attribute__((format (printf, 2, 3)))
data/monit-5.27.1/libmonit/test/SystemTest.c:29:9:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
        vsnprintf(buf, sizeof(buf), s, ap);
data/monit-5.27.1/src/event.h:105:128:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Event_post(Service_T service, long id, State_Type state, EventAction_T action, const char *s, ...) __attribute__((format (printf, 5, 6)));
data/monit-5.27.1/src/http/cervlet.c:236:24:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
__attribute__((format (printf, 7, 8))) static void _formatStatus(const char *name, Event_Type errorType, Output_Type type, HttpResponse res, Service_T s, bool validValue, const char *value, ...) {
data/monit-5.27.1/src/http/cervlet.c:315:108:  [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.
                                                StringBuffer_append(sb, "%.1f%%sys ", systeminfo.cpu.usage.system > 0. ? systeminfo.cpu.usage.system : 0.);
data/monit-5.27.1/src/http/cervlet.c:315:143:  [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.
                                                StringBuffer_append(sb, "%.1f%%sys ", systeminfo.cpu.usage.system > 0. ? systeminfo.cpu.usage.system : 0.);
data/monit-5.27.1/src/http/cervlet.c:350:121:  [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.
                                _formatStatus("access timestamp", Event_Timestamp, type, res, s, s->inf.file->timestamp.access > 0, "%s", Time_string(s->inf.file->timestamp.access, (char[32]){}));
data/monit-5.27.1/src/http/cervlet.c:350:174:  [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.
                                _formatStatus("access timestamp", Event_Timestamp, type, res, s, s->inf.file->timestamp.access > 0, "%s", Time_string(s->inf.file->timestamp.access, (char[32]){}));
data/monit-5.27.1/src/http/cervlet.c:363:126:  [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.
                                _formatStatus("access timestamp", Event_Timestamp, type, res, s, s->inf.directory->timestamp.access > 0, "%s", Time_string(s->inf.directory->timestamp.access, (char[32]){}));
data/monit-5.27.1/src/http/cervlet.c:363:184:  [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.
                                _formatStatus("access timestamp", Event_Timestamp, type, res, s, s->inf.directory->timestamp.access > 0, "%s", Time_string(s->inf.directory->timestamp.access, (char[32]){}));
data/monit-5.27.1/src/http/cervlet.c:372:121:  [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.
                                _formatStatus("access timestamp", Event_Timestamp, type, res, s, s->inf.fifo->timestamp.access > 0, "%s", Time_string(s->inf.fifo->timestamp.access, (char[32]){}));
data/monit-5.27.1/src/http/cervlet.c:372:174:  [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.
                                _formatStatus("access timestamp", Event_Timestamp, type, res, s, s->inf.fifo->timestamp.access > 0, "%s", Time_string(s->inf.fifo->timestamp.access, (char[32]){}));
data/monit-5.27.1/src/http/cervlet.c:507:24:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
__attribute__((format (printf, 5, 6))) static void _displayTableRow(HttpResponse res, bool escape, const char *class, const char *key, const char *value, ...) {
data/monit-5.27.1/src/http/cervlet.c:1190:27:  [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.
        Service_T s = Run.system;
data/monit-5.27.1/src/http/cervlet.c:1214:95:  [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.
                StringBuffer_append(res->outputbuffer, "%.1f%%sy ", systeminfo.cpu.usage.system > 0. ? systeminfo.cpu.usage.system : 0.);
data/monit-5.27.1/src/http/cervlet.c:1214:130:  [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.
                StringBuffer_append(res->outputbuffer, "%.1f%%sy ", systeminfo.cpu.usage.system > 0. ? systeminfo.cpu.usage.system : 0.);
data/monit-5.27.1/src/http/cervlet.c:2635:25:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
                        snprintf(buf, buflen, Color_lightYellow("Not monitored"));
data/monit-5.27.1/src/http/cervlet.c:2640:25:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
                        snprintf(buf, buflen, Color_white("Waiting"));
data/monit-5.27.1/src/http/cervlet.c:2645:25:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
                        snprintf(buf, buflen, Color_lightBlue("Initializing"));
data/monit-5.27.1/src/http/cervlet.c:2662:17:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
                snprintf(buf, buflen, type == HTML ? "<span class='green-text'>OK</span>" : Color_lightGreen("OK"));
data/monit-5.27.1/src/http/cervlet.c:2675:54:  [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.
                                                p += snprintf(p, buflen - (p - buf), Color_lightYellow("%s", (*et).description_changed));
data/monit-5.27.1/src/http/cervlet.c:2680:54:  [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.
                                                p += snprintf(p, buflen - (p - buf), Color_lightRed("%s", (*et).description_failed));
data/monit-5.27.1/src/http/processor.h:104:105:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void send_error(HttpRequest, HttpResponse, int status, const char *message, ...) __attribute__((format (printf, 4, 5)));
data/monit-5.27.1/src/http/processor.h:106:100:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void set_header(HttpResponse res, const char *name, const char *value, ...) __attribute__((format (printf, 3, 4)));
data/monit-5.27.1/src/http/xml.c:256:64:  [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.
                                        S->inf.file->timestamp.access,
data/monit-5.27.1/src/http/xml.c:277:69:  [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.
                                        S->inf.directory->timestamp.access,
data/monit-5.27.1/src/http/xml.c:295:64:  [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.
                                        S->inf.fifo->timestamp.access,
data/monit-5.27.1/src/http/xml.c:518:102:  [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.
                                StringBuffer_append(B, "<system>%.1f</system>", systeminfo.cpu.usage.system > 0. ? systeminfo.cpu.usage.system : 0.);
data/monit-5.27.1/src/http/xml.c:518:137:  [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.
                                StringBuffer_append(B, "<system>%.1f</system>", systeminfo.cpu.usage.system > 0. ? systeminfo.cpu.usage.system : 0.);
data/monit-5.27.1/src/log.c:154:24:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
__attribute__((format (printf, 2, 0)))
data/monit-5.27.1/src/log.c:163:17:  [4] (format) vfprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
                vfprintf(output, s, ap_copy);
data/monit-5.27.1/src/log.c:174:33:  [4] (format) vfprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
                                vfprintf(_LOG, s, ap_copy);
data/monit-5.27.1/src/log.c:209:9:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
        vsnprintf(msg, STRLEN, format, arglist);
data/monit-5.27.1/src/monit.c:399:24:  [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.
        Event_post(Run.system, Event_Instance, State_Changed, Run.system->action_MONIT_START, "Monit reloaded");
data/monit-5.27.1/src/monit.c:514:32:  [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.
                Event_post(Run.system, Event_Instance, State_Changed, Run.system->action_MONIT_STOP, "Monit %s stopped", VERSION);
data/monit-5.27.1/src/monit.c:580:32:  [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.
                Event_post(Run.system, Event_Instance, State_Changed, Run.system->action_MONIT_START, "Monit %s started", VERSION);
data/monit-5.27.1/src/monit.h:585:31:  [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.
                        float system;     /**< Time in kernel space [%] */
data/monit-5.27.1/src/monit.h:1056:28:  [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.
        unsigned long long access;
data/monit-5.27.1/src/monit.h:1311: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.
        Service_T system;                          /**< The general system service */
data/monit-5.27.1/src/monit.h:1397:62:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_emergency(const char *, ...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/src/monit.h:1398:58:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_alert(const char *, ...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/src/monit.h:1399:61:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_critical(const char *, ...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/src/monit.h:1400:58:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_error(const char *, ...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/src/monit.h:1401:60:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_warning(const char *, ...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/src/monit.h:1402:59:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_notice(const char *, ...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/src/monit.h:1403: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.
void Log_info(const char *, ...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/src/monit.h:1404:58:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_debug(const char *, ...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/src/monit.h:1405:70:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_vemergency(const char *, va_list ap) __attribute__((format (printf, 1, 0)));
data/monit-5.27.1/src/monit.h:1406:66:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_valert(const char *, va_list ap) __attribute__((format (printf, 1, 0)));
data/monit-5.27.1/src/monit.h:1407:69:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_vcritical(const char *, va_list ap) __attribute__((format (printf, 1, 0)));
data/monit-5.27.1/src/monit.h:1408:66:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_verror(const char *, va_list ap) __attribute__((format (printf, 1, 0)));
data/monit-5.27.1/src/monit.h:1409:67:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_vwarning(const char *,va_list ap) __attribute__((format (printf, 1, 0)));
data/monit-5.27.1/src/monit.h:1410:67:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_vnotice(const char *, va_list ap) __attribute__((format (printf, 1, 0)));
data/monit-5.27.1/src/monit.h:1411:65:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_vinfo(const char *, va_list ap) __attribute__((format (printf, 1, 0)));
data/monit-5.27.1/src/monit.h:1412:66:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_vdebug(const char *, va_list ap) __attribute__((format (printf, 1, 0)));
data/monit-5.27.1/src/monit.h:1413:74:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Log_abort_handler(const char *s, va_list ap) __attribute__((format (printf, 1, 0))) __attribute__((noreturn));
data/monit-5.27.1/src/net/net.c:181:24:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
__attribute__((format (printf, 3, 4))) static void _log_warningOrError(int attempt, int maxAttempts, const char *s, ...) {
data/monit-5.27.1/src/net/socket.h:232:66:  [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.
int Socket_print(T S, const char *m, ...) __attribute__((format (printf, 2, 3)));
data/monit-5.27.1/src/notification/SMTP.c:134:24:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
__attribute__((format (printf, 2, 3))) static void _send(T S, const char *data, ...) {
data/monit-5.27.1/src/spawn.c:165:13:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
        if (access(C->arg[0], X_OK) != 0) {
data/monit-5.27.1/src/spawn.c:238:32:  [4] (shell) execv:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
                        (void) execv(C->arg[0], C->arg);
data/monit-5.27.1/src/state.c:546:124:  [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.
                                        state.priv.directory.atime = (unsigned long long)service->inf.directory->timestamp.access;
data/monit-5.27.1/src/state.c:553:114:  [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.
                                        state.priv.fifo.atime = (unsigned long long)service->inf.fifo->timestamp.access;
data/monit-5.27.1/src/state.c:563:114:  [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.
                                        state.priv.file.atime = (unsigned long long)service->inf.file->timestamp.access;
data/monit-5.27.1/src/terminal/Box.h:88:93:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void Box_setColumn(T t, unsigned int index, const char *format, ...) __attribute__((format (printf, 3, 4)));
data/monit-5.27.1/src/util.c:466:25:  [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(buf, q);
data/monit-5.27.1/src/util.c:467:25:  [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(buf, new);
data/monit-5.27.1/src/util.c:471:17:  [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(buf, q);
data/monit-5.27.1/src/util.c:1557:32:  [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.
                        temp = crypt(outside, salt);
data/monit-5.27.1/src/util.h:303:119:  [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.
StringBuffer_T Util_printRule(StringBuffer_T buf, EventAction_T action, const char *rule, ...) __attribute__((format (printf, 3, 4)));
data/monit-5.27.1/src/validate.c:460:63:  [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.
                                        (systeminfo.cpu.usage.system > 0. ? systeminfo.cpu.usage.system : 0.) +
data/monit-5.27.1/src/validate.c:460:98:  [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.
                                        (systeminfo.cpu.usage.system > 0. ? systeminfo.cpu.usage.system : 0.) +
data/monit-5.27.1/src/validate.c:487:50:  [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 (systeminfo.cpu.usage.system < 0.) {
data/monit-5.27.1/src/validate.c:490:97:  [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.
                        } else if (Util_evalDoubleQExpression(r->operator, systeminfo.cpu.usage.system, r->limit)) {
data/monit-5.27.1/src/validate.c:492:161:  [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.
                                snprintf(report, STRLEN, "cpu system usage of %.1f%% matches resource limit [cpu system usage %s %.1f%%]", systeminfo.cpu.usage.system, operatorshortnames[r->operator], r->limit);
data/monit-5.27.1/src/validate.c:494:151:  [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.
                                snprintf(report, STRLEN, "cpu system usage check succeeded [current cpu system usage = %.1f%%]", systeminfo.cpu.usage.system);
data/monit-5.27.1/src/validate.c:1706:56:  [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 (_checkTimestamps(s, s->inf.file->timestamp.access, s->inf.file->timestamp.change, s->inf.file->timestamp.modify) == State_Failed)
data/monit-5.27.1/src/validate.c:1758:61:  [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 (_checkTimestamps(s, s->inf.directory->timestamp.access, s->inf.directory->timestamp.change, s->inf.directory->timestamp.modify) == State_Failed)
data/monit-5.27.1/src/validate.c:1808:56:  [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 (_checkTimestamps(s, s->inf.fifo->timestamp.access, s->inf.fifo->timestamp.change, s->inf.fifo->timestamp.modify) == State_Failed)
data/monit-5.27.1/src/y.tab.c:197:56:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void  yyerror(const char *,...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/src/y.tab.c:198: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.
void  yyerror2(const char *,...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/src/y.tab.c:199:58:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void  yywarning(const char *,...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/src/y.tab.c:200:59:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void  yywarning2(const char *,...) __attribute__((format (printf, 1, 2)));
data/monit-5.27.1/src/y.tab.c:2723:21:  [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.
#  define YYFPRINTF fprintf
data/monit-5.27.1/src/y.tab.c:8073: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.
        if (! Run.system) {
data/monit-5.27.1/src/y.tab.c:8084:32:  [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.
                addservice(Run.system);
data/monit-5.27.1/src/y.tab.c:8660:25:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
                        snprintf(cs->hash, sizeof(cs->hash), cs->type == Hash_Md5 ? "00000000000000000000000000000000" : "0000000000000000000000000000000000000000");
data/monit-5.27.1/libmonit/src/io/File.c:315: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.
                return realpath(path, resolved);
data/monit-5.27.1/libmonit/src/system/System.c:126:27:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
                _buf[i] = random() % 256;
data/monit-5.27.1/libmonit/src/system/System.c:134:28:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
        unsigned long long random;
data/monit-5.27.1/libmonit/src/system/System.c:135:24:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
        System_random(&random, sizeof(random));
data/monit-5.27.1/libmonit/src/system/System.c:135:39:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
        System_random(&random, sizeof(random));
data/monit-5.27.1/libmonit/src/system/System.c:136:16:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
        return random;
data/monit-5.27.1/libmonit/test/CommandTest.c:84:18:  [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.
        assert(! getenv("SULT"));
data/monit-5.27.1/libmonit/test/SystemTest.c:62:17:  [3] (random) srandom:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
                srandom((unsigned)(Time_now() + getpid()));
data/monit-5.27.1/src/device/device_common.c:75:31:  [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.
                        if (! realpath(s->path, buf)) {
data/monit-5.27.1/src/device/device_common.c:96:21:  [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.
                if (realpath(s->path, buf)) {
data/monit-5.27.1/src/device/sysdep_LINUX.c:374:58:  [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 (Str_isEqual(device, mnt->mnt_fsname) || (realpath(mnt->mnt_fsname, target) && Str_isEqual(device, target)));
data/monit-5.27.1/src/device/sysdep_LINUX.c:418:37:  [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.
                                if (realpath(mnt->mnt_fsname, inf->filesystem->object.key)) {
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:189:50:  [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 (IS(device, mnt->mnt_special) || (realpath(mnt->mnt_special, target) && IS(device, target)));
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:229:39:  [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.
                                if (! realpath(mnt.mnt_special, special)) {
data/monit-5.27.1/src/monit.c:261:9:  [3] (random) srandom:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
        srandom((unsigned)(Time_now() + getpid()));
data/monit-5.27.1/src/monit.c:643:28:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
                if ((opt = getopt_long(argc, argv, shortopts, longopts, NULL)) != -1)
data/monit-5.27.1/src/monit.c:645:28:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
                if ((opt = getopt(argc, argv, shortopts)) != -1)
data/monit-5.27.1/src/monit.c:652:46:  [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 realpath[PATH_MAX] = {};
data/monit-5.27.1/src/monit.c:654:78:  [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.
                                                f = File_getRealPath(optarg, realpath);
data/monit-5.27.1/src/terminal/Color.c:57:21:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
                if (getenv("COLORTERM")) {
data/monit-5.27.1/src/terminal/Color.c:60:38:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
                        char *term = getenv("TERM");
data/monit-5.27.1/libmonit/src/exceptions/Exception.c:100: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.
                char message[EXCEPTION_MESSAGE_LENGTH + 1] = "?";
data/monit-5.27.1/libmonit/src/exceptions/Exception.h:190: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 message[EXCEPTION_MESSAGE_LENGTH + 1];
data/monit-5.27.1/libmonit/src/io/File.c:72:58:  [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).
                                        case '+': return open(file, O_RDWR|O_NONBLOCK);
data/monit-5.27.1/libmonit/src/io/File.c:73:58:  [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).
                                        default:  return open(file, O_RDONLY|O_NONBLOCK);
data/monit-5.27.1/libmonit/src/io/File.c:77:58:  [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).
                                        case '+': return open(file, O_CREAT|O_RDWR|O_TRUNC|O_NONBLOCK, DEFAULT_PERM);
data/monit-5.27.1/libmonit/src/io/File.c:78:58:  [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).
                                        default:  return open(file, O_CREAT|O_WRONLY|O_TRUNC|O_NONBLOCK, DEFAULT_PERM);
data/monit-5.27.1/libmonit/src/io/File.c:82:58:  [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).
                                        case '+': return open(file, O_CREAT|O_RDWR|O_APPEND|O_NONBLOCK, DEFAULT_PERM);
data/monit-5.27.1/libmonit/src/io/File.c:83:58:  [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).
                                        default:  return open(file, O_CREAT|O_WRONLY|O_APPEND|O_NONBLOCK, DEFAULT_PERM);
data/monit-5.27.1/libmonit/src/io/OutputStream.c:77:65:  [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.
typedef void (*fmt_t)(T S, int code, va_list_box *box, unsigned char flags[256], int width, int precision);
data/monit-5.27.1/libmonit/src/io/OutputStream.c:204: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 buf[43];
data/monit-5.27.1/libmonit/src/io/OutputStream.c:224: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 buf[43];
data/monit-5.27.1/libmonit/src/io/OutputStream.c:243: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 buf[43];
data/monit-5.27.1/libmonit/src/io/OutputStream.c:254: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 buf[43];
data/monit-5.27.1/libmonit/src/io/OutputStream.c:265: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 buf[43];
data/monit-5.27.1/libmonit/src/io/OutputStream.c:276: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 buf[43];
data/monit-5.27.1/libmonit/src/io/OutputStream.c:302: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 buf[DBL_MAX_10_EXP+1+1+99+1];
data/monit-5.27.1/libmonit/src/system/Command.c:342: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.
                char t[STRLEN];
data/monit-5.27.1/libmonit/src/system/Command.c:596:23:  [2] (race) vfork:
  On some old systems, vfork() permits race conditions, and it's very
  difficult to use correctly (CWE-362). Use fork() instead.
        if ((P->pid = vfork()) < 0) {
data/monit-5.27.1/libmonit/src/system/System.c:115:18:  [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).
        int fd = open("/dev/urandom", O_RDONLY);
data/monit-5.27.1/libmonit/src/system/Time.c:163: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 inline int _m2i(const char m[static 3]) {
data/monit-5.27.1/libmonit/src/system/Time.c:164: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 month[3] = {[0] = tolower(m[0]), [1] = tolower(m[1]), [2] = tolower(m[2])};
data/monit-5.27.1/libmonit/src/system/Time.c:1348: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.
                char x[2];
data/monit-5.27.1/libmonit/src/system/Time.c:1351:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(result, "aaa, xx aaa xxxx xx:xx:xx\0", 26);
data/monit-5.27.1/libmonit/src/system/Time.c:1353:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(result, days + 3 * ts.tm_wday, 3);
data/monit-5.27.1/libmonit/src/system/Time.c:1357:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(result + 8, months + 3 * ts.tm_mon, 3);
data/monit-5.27.1/libmonit/src/system/Time.c:1380: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.
                char x[2];
data/monit-5.27.1/libmonit/src/system/Time.c:1383:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(result, "aaa, xx aaa xxxx xx:xx:xx GMT\0", 30);
data/monit-5.27.1/libmonit/src/system/Time.c:1385:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(result, days + 3 * ts.tm_wday, 3);
data/monit-5.27.1/libmonit/src/system/Time.c:1389:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(result + 8, months + 3 * ts.tm_mon, 3);
data/monit-5.27.1/libmonit/src/system/Time.h:205: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 *Time_string(time_t time, char result[static 26]);
data/monit-5.27.1/libmonit/src/system/Time.h:205:32:  [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_string(time_t time, char result[static 26]);
data/monit-5.27.1/libmonit/src/system/Time.h:219: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 *Time_gmtstring(time_t time, char result[static 30]);
data/monit-5.27.1/libmonit/src/system/Time.h:219:35:  [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_gmtstring(time_t time, char result[static 30]);
data/monit-5.27.1/libmonit/src/system/Time.h:251: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 *Time_uptime(time_t sec, char result[static 24]);
data/monit-5.27.1/libmonit/src/system/Time.h:251:31:  [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_uptime(time_t sec, char result[static 24]);
data/monit-5.27.1/libmonit/src/util/Convert.c:47: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 *Convert_bytes2str(double bytes, char s[static 10]) {
data/monit-5.27.1/libmonit/src/util/Convert.c:47:39:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
char *Convert_bytes2str(double bytes, char s[static 10]) {
data/monit-5.27.1/libmonit/src/util/Convert.c:66: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 *Convert_time2str(double milli, char s[static 11]) {
data/monit-5.27.1/libmonit/src/util/Convert.c:66:38:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
char *Convert_time2str(double milli, char s[static 11]) {
data/monit-5.27.1/libmonit/src/util/Convert.h:45: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 *Convert_bytes2str(double bytes, char s[static 10]);
data/monit-5.27.1/libmonit/src/util/Convert.h:45:39:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
char *Convert_bytes2str(double bytes, char s[static 10]);
data/monit-5.27.1/libmonit/src/util/Convert.h:54: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 *Convert_time2str(double milli, char s[static 11]);
data/monit-5.27.1/libmonit/src/util/Convert.h:54:38:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
char *Convert_time2str(double milli, char s[static 11]);
data/monit-5.27.1/libmonit/src/util/Str.c:295:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(t, s, n);
data/monit-5.27.1/libmonit/src/util/Str.c:308:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(t, s, n);
data/monit-5.27.1/libmonit/src/util/Str.c:394:25:  [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 e[STRLEN];
data/monit-5.27.1/libmonit/src/util/Str.c:429: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 _x[Str_compareConstantTimeStringLength + 1] = {};
data/monit-5.27.1/libmonit/src/util/Str.c:430: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 _y[Str_compareConstantTimeStringLength + 1] = {};
data/monit-5.27.1/libmonit/src/util/StringBuffer.c:169:57:  [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->buffer + i, b, bl); 
data/monit-5.27.1/libmonit/test/CommandTest.c:28: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 buf[STRLEN];
data/monit-5.27.1/libmonit/test/CommandTest.c:79: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 buf[STRLEN];
data/monit-5.27.1/libmonit/test/ConvertTest.c:26: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.
                char str[10];
data/monit-5.27.1/libmonit/test/ConvertTest.c:48: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.
                char str[13];
data/monit-5.27.1/libmonit/test/DirTest.c:52: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.
                char cwd[STRLEN];
data/monit-5.27.1/libmonit/test/FileTest.c:22: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[STRLEN];
data/monit-5.27.1/libmonit/test/FileTest.c:138: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.
                char s[STRLEN];
data/monit-5.27.1/libmonit/test/FileTest.c:153: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.
                char s[PATH_MAX];
data/monit-5.27.1/libmonit/test/InputStreamTest.c:75: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.
                char line[STRLEN];
data/monit-5.27.1/libmonit/test/InputStreamTest.c:91: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.
                char array[STRLEN];
data/monit-5.27.1/libmonit/test/InputStreamTest.c:107:25:  [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 array[2][STRLEN + 1] = {};
data/monit-5.27.1/libmonit/test/OutputStreamTest.c:176: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.
                char a[1024];
data/monit-5.27.1/libmonit/test/OutputStreamTest.c:184: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.
                char b[2048];
data/monit-5.27.1/libmonit/test/StrTest.c:25: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.
                char s3[STRLEN];
data/monit-5.27.1/libmonit/test/StrTest.c:152: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.
                char i[STRLEN] = "   -2812 bla";
data/monit-5.27.1/libmonit/test/StrTest.c:153: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.
                char ll[STRLEN] = "  2147483642 blabla";
data/monit-5.27.1/libmonit/test/StrTest.c:154: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.
                char d[STRLEN] = "  2.718281828 this is e";
data/monit-5.27.1/libmonit/test/StrTest.c:155: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.
                char de[STRLEN] = "1.495E+08 kilometer = An Astronomical Unit";
data/monit-5.27.1/libmonit/test/StrTest.c:156: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.
                char ie[STRLEN] = " 9999999999999999999999999999999999999999";
data/monit-5.27.1/libmonit/test/StrTest.c:458: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.
                char dest[10+1] = "xxxxxxxxx";
data/monit-5.27.1/libmonit/test/SystemTest.c:26: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 buf[STRLEN];
data/monit-5.27.1/libmonit/test/SystemTest.c:67: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.
                char buf0[1];
data/monit-5.27.1/libmonit/test/SystemTest.c:75: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.
                char buf1[4];
data/monit-5.27.1/libmonit/test/SystemTest.c:83: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.
                char buf2[16];
data/monit-5.27.1/libmonit/test/TimeTest.c:33: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.
                char result[STRLEN];
data/monit-5.27.1/libmonit/test/TimeTest.c:78: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.
                char result[24];
data/monit-5.27.1/libmonit/test/TimeTest.c:92: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.
                char b[STRLEN];
data/monit-5.27.1/src/alert.c:73: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 *_getFQDNhostname(char host[256]) {
data/monit-5.27.1/src/alert.c:73:31:  [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 *_getFQDNhostname(char host[256]) {
data/monit-5.27.1/src/alert.c:114: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 timestamp[26];
data/monit-5.27.1/src/alert.c:221:25:  [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 now[STRLEN];
data/monit-5.27.1/src/alert.c:300: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.
                char host[256] = {};
data/monit-5.27.1/src/checksum.c:144:18:  [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.
        unsigned char buffer[HASHBLOCKSIZE + 72];
data/monit-5.27.1/src/checksum.c:203:18:  [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.
        unsigned char sha1[STRLEN], md5[STRLEN];
data/monit-5.27.1/src/checksum.c:206:33:  [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 (! (fhandle = file ? fopen(file, "r") : stdin) || ! Checksum_getStreamDigests(fhandle, sha1, md5) || (file && fclose(fhandle))) {
data/monit-5.27.1/src/checksum.c:235:27:  [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(file, "r");
data/monit-5.27.1/src/checksum.c:273:18:  [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.
        unsigned char k_ipad[65] = {};
data/monit-5.27.1/src/checksum.c:274:18:  [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.
        unsigned char k_opad[65] = {};
data/monit-5.27.1/src/checksum.c:275:18:  [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.
        unsigned char tk[16];
data/monit-5.27.1/src/checksum.c:287: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(k_ipad, key, keylen);
data/monit-5.27.1/src/checksum.c:288: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(k_opad, key, keylen);
data/monit-5.27.1/src/control.c:147:25:  [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[STRLEN];
data/monit-5.27.1/src/control.c:243: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.
                                char msg[1024];
data/monit-5.27.1/src/control.c:293:25:  [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[1024];
data/monit-5.27.1/src/control.c:331: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.
                char msg[1024];
data/monit-5.27.1/src/device/device_common.c:74:25:  [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[PATH_MAX] = {};
data/monit-5.27.1/src/device/device_common.c:95: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.
                char buf[PATH_MAX] = {};
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:128: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.
                char buf[len + 1];
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:135: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.
                char disk[PATH_MAX] = {};
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:143: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.
                                char type[64] = {};
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:144: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.
                                char name[PATH_MAX] = {};
data/monit-5.27.1/src/device/sysdep_LINUX.c:130: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 *f = fopen(CIFSSTAT, "r");
data/monit-5.27.1/src/device/sysdep_LINUX.c:136: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 line[PATH_MAX];
data/monit-5.27.1/src/device/sysdep_LINUX.c:141:25:  [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 name[4096];
data/monit-5.27.1/src/device/sysdep_LINUX.c:146:25:  [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 label1[256];
data/monit-5.27.1/src/device/sysdep_LINUX.c:147:25:  [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 label2[256];
data/monit-5.27.1/src/device/sysdep_LINUX.c:169: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 *f = fopen(NFSSTAT, "r");
data/monit-5.27.1/src/device/sysdep_LINUX.c:175: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 line[PATH_MAX];
data/monit-5.27.1/src/device/sysdep_LINUX.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 pattern[2 * PATH_MAX];
data/monit-5.27.1/src/device/sysdep_LINUX.c:183:25:  [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 name[256];
data/monit-5.27.1/src/device/sysdep_LINUX.c:209: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[2 * PATH_MAX];
data/monit-5.27.1/src/device/sysdep_LINUX.c:211: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 *f = fopen(path, "r");
data/monit-5.27.1/src/device/sysdep_LINUX.c:213: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.
                char line[STRLEN];
data/monit-5.27.1/src/device/sysdep_LINUX.c:252: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[PATH_MAX];
data/monit-5.27.1/src/device/sysdep_LINUX.c:254: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 *f = fopen(path, "r");
data/monit-5.27.1/src/device/sysdep_LINUX.c:277:13:  [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(DISKSTAT, "r");
data/monit-5.27.1/src/device/sysdep_LINUX.c:282: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.
                char line[PATH_MAX];
data/monit-5.27.1/src/device/sysdep_LINUX.c:284:25:  [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 name[256] = {};
data/monit-5.27.1/src/device/sysdep_LINUX.c:311: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[2 * PATH_MAX];
data/monit-5.27.1/src/device/sysdep_LINUX.c:313: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 *f = fopen(path, "r");
data/monit-5.27.1/src/device/sysdep_LINUX.c:339: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 *f = fopen(DISKSTAT, "r");
data/monit-5.27.1/src/device/sysdep_LINUX.c:344: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.
                char line[PATH_MAX];
data/monit-5.27.1/src/device/sysdep_LINUX.c:346:25:  [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 name[256] = {};
data/monit-5.27.1/src/device/sysdep_LINUX.c:372: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 target[PATH_MAX] = {};
data/monit-5.27.1/src/device/sysdep_LINUX.c:387: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 flags[STRLEN];
data/monit-5.27.1/src/device/sysdep_LINUX.c:453:34:  [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).
                _statistics.fd = open(MOUNTS, O_RDONLY);
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:188: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 target[PATH_MAX] = {};
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:194: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 *f = fopen(MNTTAB, "r");
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:228: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.
                                char special[PATH_MAX];
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:243:41:  [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[PATH_MAX] = {};
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:244:53:  [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 *pti = fopen(PATHTOINST, "r");
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:249:57:  [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[1024] = {};
data/monit-5.27.1/src/env.c:87:23:  [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).
        int devnull = open("/dev/null", O_RDWR);
data/monit-5.27.1/src/env.c:102: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 buf[4096];
data/monit-5.27.1/src/env.c:109: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 t[PATH_MAX];
data/monit-5.27.1/src/event.c:190: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 file_name[PATH_MAX];
data/monit-5.27.1/src/event.c:195: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 *file = fopen(file_name, "w");
data/monit-5.27.1/src/event.c:260: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 *file = fopen(file_name, "w");
data/monit-5.27.1/src/event.c:572: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.
                char file_name[PATH_MAX];
data/monit-5.27.1/src/event.c:578:38:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
                        FILE *file = fopen(file_name, "r");
data/monit-5.27.1/src/file.c:84: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 pidfile[STRLEN];
data/monit-5.27.1/src/file.c:85: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 buf[STRLEN];
data/monit-5.27.1/src/file.c:146: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 *F = fopen(pidfile, "w");
data/monit-5.27.1/src/file.c:201:25:  [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[PATH_MAX];
data/monit-5.27.1/src/file.c:272: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 filename[STRLEN];
data/monit-5.27.1/src/file.c:278:18:  [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).
        int fd = open(filename, O_RDONLY);
data/monit-5.27.1/src/http/cervlet.c:209: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 *_getUptime(time_t delta, char s[256]) {
data/monit-5.27.1/src/http/cervlet.c:209:39:  [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 *_getUptime(time_t delta, char s[256]) {
data/monit-5.27.1/src/http/cervlet.c:286: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 header[STRLEN] = {};
data/monit-5.27.1/src/http/cervlet.c:459:144:  [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).
                                                _formatStatus("filedescriptors", Event_Resource, type, res, s, s->inf.process->filedescriptors.open != -1LL, "%lld [%.1f%% of %lld limit]", s->inf.process->filedescriptors.open, (float)100 * (float)s->inf.process->filedescriptors.open / (float)limit, limit);
data/monit-5.27.1/src/http/cervlet.c:459:221:  [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).
                                                _formatStatus("filedescriptors", Event_Resource, type, res, s, s->inf.process->filedescriptors.open != -1LL, "%lld [%.1f%% of %lld limit]", s->inf.process->filedescriptors.open, (float)100 * (float)s->inf.process->filedescriptors.open / (float)limit, limit);
data/monit-5.27.1/src/http/cervlet.c:459:279:  [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).
                                                _formatStatus("filedescriptors", Event_Resource, type, res, s, s->inf.process->filedescriptors.open != -1LL, "%lld [%.1f%% of %lld limit]", s->inf.process->filedescriptors.open, (float)100 * (float)s->inf.process->filedescriptors.open / (float)limit, limit);
data/monit-5.27.1/src/http/cervlet.c:461:144:  [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).
                                                _formatStatus("filedescriptors", Event_Resource, type, res, s, s->inf.process->filedescriptors.open != -1LL, "N/A");
data/monit-5.27.1/src/http/cervlet.c:489: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.
                                char buf[STRLEN] = {};
data/monit-5.27.1/src/http/cervlet.c:527: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[STRLEN] = {};
data/monit-5.27.1/src/http/cervlet.c:542: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[STRLEN] = {};
data/monit-5.27.1/src/http/cervlet.c:788: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 buf[STRLEN];
data/monit-5.27.1/src/http/cervlet.c:817: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.
                char opt[STRLEN] = {};
data/monit-5.27.1/src/http/cervlet.c:857: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.
                                char opt[STRLEN] = {};
data/monit-5.27.1/src/http/cervlet.c:954:27:  [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(Run.files.log, "r");
data/monit-5.27.1/src/http/cervlet.c:957:25:  [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/monit-5.27.1/src/http/cervlet.c:1103: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 buf[STRLEN] = {};
data/monit-5.27.1/src/http/cervlet.c:1191: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 buf[STRLEN];
data/monit-5.27.1/src/http/cervlet.c:1234: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      buf[STRLEN];
data/monit-5.27.1/src/http/cervlet.c:1304: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 buf[STRLEN];
data/monit-5.27.1/src/http/cervlet.c:1374: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 buf[STRLEN];
data/monit-5.27.1/src/http/cervlet.c:1415: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 buf[STRLEN];
data/monit-5.27.1/src/http/cervlet.c:1481: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 buf[STRLEN];
data/monit-5.27.1/src/http/cervlet.c:1534: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 buf[STRLEN];
data/monit-5.27.1/src/http/cervlet.c:1581: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 buf[STRLEN];
data/monit-5.27.1/src/http/cervlet.c:1628: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 buf[STRLEN];
data/monit-5.27.1/src/http/cervlet.c:1995: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.
                char key[STRLEN];
data/monit-5.27.1/src/http/cervlet.c:2232: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 buf[STRLEN];
data/monit-5.27.1/src/http/cervlet.c:2432: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.
                char buf[STRLEN];
data/monit-5.27.1/src/http/cervlet.c:2608: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 buf[STRLEN];
data/monit-5.27.1/src/http/client.c:100: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 buf[1024];
data/monit-5.27.1/src/http/client.c:164: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 buf[1024];
data/monit-5.27.1/src/http/engine.c:166: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 buf[INET6_ADDRSTRLEN] = {};
data/monit-5.27.1/src/http/engine.c:208: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(copy, source, sizeof(struct HostsAllow_T));
data/monit-5.27.1/src/http/engine.c:230: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 buf[STRLEN];
data/monit-5.27.1/src/http/engine.c:272:37:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
                        shortmask = atoi(longmask);
data/monit-5.27.1/src/http/engine.c:290:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(net.address, &(addr.sin6_addr), 16);
data/monit-5.27.1/src/http/engine.c:357:33:  [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(&h->address, &(sin->sin6_addr), 16);
data/monit-5.27.1/src/http/engine.c:427:52:  [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 void _createTcpServer(Socket_Family family, char error[STRLEN]) {
data/monit-5.27.1/src/http/engine.c:448:31:  [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 void _createUnixServer(char error[STRLEN]) {
data/monit-5.27.1/src/http/engine.c:491: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 error[MAX_SERVER_SOCKETS][STRLEN] = {};
data/monit-5.27.1/src/http/processor.c:224: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 server[STRLEN];
data/monit-5.27.1/src/http/processor.c:333: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 buf[RES_STRLEN];
data/monit-5.27.1/src/http/processor.c:494: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.
                char date[STRLEN];
data/monit-5.27.1/src/http/processor.c:495: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.
                char server[STRLEN];
data/monit-5.27.1/src/http/processor.c:537: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 line[REQ_STRLEN];
data/monit-5.27.1/src/http/processor.c:543: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 method[STRLEN];
data/monit-5.27.1/src/http/processor.c:544: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 url[REQ_STRLEN];
data/monit-5.27.1/src/http/processor.c:545: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 protocol[STRLEN];
data/monit-5.27.1/src/http/processor.c:593: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 line[REQ_STRLEN] = {0};
data/monit-5.27.1/src/http/processor.c:771: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.
                                char cookieValue[STRLEN] = {};
data/monit-5.27.1/src/http/processor.c:805: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 buf[STRLEN] = {0};
data/monit-5.27.1/src/http/processor.c:807: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 uname[STRLEN] = {0};
data/monit-5.27.1/src/http/processor.c:846: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 date[STRLEN];
data/monit-5.27.1/src/http/processor.c:847: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 server[STRLEN];
data/monit-5.27.1/src/http/xml.c:447:81:  [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).
                                                S->inf.process->filedescriptors.open,
data/monit-5.27.1/src/lex.yy.c:8106:37:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
                    yylval.number = atoi(yytext);
data/monit-5.27.1/src/lex.yy.c:8489:42:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
                      yylval.url->port = atoi(++yytext);
data/monit-5.27.1/src/lex.yy.c:8615:37:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
                    yylval.number = atoi(yytext);
data/monit-5.27.1/src/lex.yy.c:9781: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 *_yyin = fopen(path, "r");
data/monit-5.27.1/src/log.c:119: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).
                _LOG = fopen(Run.files.log, "a");
data/monit-5.27.1/src/log.c:208: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 msg[STRLEN+1];
data/monit-5.27.1/src/md5.c:162:33:  [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(xbuf, data, 64);
data/monit-5.27.1/src/md5.c:332:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(pms->buf + offset, p, copy);
data/monit-5.27.1/src/md5.c:346:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(pms->buf, p, left);
data/monit-5.27.1/src/md5_crypt.c:68:18:  [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.
        unsigned char final[16];
data/monit-5.27.1/src/monit.c:652:41:  [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 realpath[PATH_MAX] = {};
data/monit-5.27.1/src/monit.h:450: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.
typedef char MD_T[MD_SIZE];
data/monit-5.27.1/src/monit.h:476: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 *arg[ARGMAX];                             /**< Program with arguments */
data/monit-5.27.1/src/monit.h:1044: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 device[PATH_MAX];
data/monit-5.27.1/src/monit.h:1045: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 mountpoint[PATH_MAX];
data/monit-5.27.1/src/monit.h:1046: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[PATH_MAX];
data/monit-5.27.1/src/monit.h:1047: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 module[256];
data/monit-5.27.1/src/monit.h:1048: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 type[64];
data/monit-5.27.1/src/monit.h:1076: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 flags[STRLEN];                              /**< Filesystem flags */
data/monit-5.27.1/src/monit.h:1139: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 secattr[STRLEN];                         /**< Security attributes */
data/monit-5.27.1/src/monit.h:1141: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).
                long long open;                        /**< number of opened files */
data/monit-5.27.1/src/net/Link.c:234: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.
                char host[NI_MAXHOST];
data/monit-5.27.1/src/net/net.c:197:36:  [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.
int create_server_socket_tcp(const char *address, int port, Socket_Family family, int backlog, char error[STRLEN]) {
data/monit-5.27.1/src/net/net.c:197:96:  [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.
int create_server_socket_tcp(const char *address, int port, Socket_Family family, int backlog, char error[STRLEN]) {
data/monit-5.27.1/src/net/net.c:219: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 _port[6];
data/monit-5.27.1/src/net/net.c:267:37:  [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.
int create_server_socket_unix(const char *path, int backlog, char error[STRLEN]) {
data/monit-5.27.1/src/net/net.c:267:62:  [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.
int create_server_socket_unix(const char *path, int backlog, char error[STRLEN]) {
data/monit-5.27.1/src/net/net.c:329: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 buf[ICMP_MAXSIZE] = {};
data/monit-5.27.1/src/net/net.c:345:25:  [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((long long *)(out_icmp4->icmp_data), &started, sizeof(long long)); // set data to timestamp
data/monit-5.27.1/src/net/net.c:359:25:  [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((long long *)(out_icmp6 + 1), &started, sizeof(long long)); // set data to timestamp
data/monit-5.27.1/src/net/net.c:394: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 buf[ICMP_MAXSIZE] = {};
data/monit-5.27.1/src/net/net.c:457:25:  [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(&started, data, sizeof(long long));
data/monit-5.27.1/src/net/net.h:54:36:  [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.
int create_server_socket_tcp(const char *address, int port, Socket_Family family, int backlog, char error[STRLEN]);
data/monit-5.27.1/src/net/net.h:54:96:  [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.
int create_server_socket_tcp(const char *address, int port, Socket_Family family, int backlog, char error[STRLEN]);
data/monit-5.27.1/src/net/net.h:65:37:  [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.
int create_server_socket_unix(const char *path, int backlog, char error[STRLEN]);
data/monit-5.27.1/src/net/net.h:65:62:  [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.
int create_server_socket_unix(const char *path, int backlog, char error[STRLEN]);
data/monit-5.27.1/src/net/socket.c:125:18:  [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.
        unsigned char buffer[RBUFFER_SIZE + 1];
data/monit-5.27.1/src/net/socket.c:178: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.
                char ip[NI_MAXHOST];
data/monit-5.27.1/src/net/socket.c:179: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.
                char port[NI_MAXSERV];
data/monit-5.27.1/src/net/socket.c:231: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 error[STRLEN];
data/monit-5.27.1/src/net/socket.c:295: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 _port[6];
data/monit-5.27.1/src/net/socket.c:321: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.
                char error[512] = {};
data/monit-5.27.1/src/net/socket.c:365:25:  [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 error[STRLEN];
data/monit-5.27.1/src/net/socket.c:572: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 error[512];
data/monit-5.27.1/src/notification/MMonit.c:114: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 buf[STRLEN];
data/monit-5.27.1/src/notification/SMTP.c:149: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 line[STRLEN];
data/monit-5.27.1/src/notification/SMTP.c:242: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 buffer[STRLEN] = {};
data/monit-5.27.1/src/process/ProcessTree.c:400: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.
                char errbuf[STRLEN];
data/monit-5.27.1/src/process/sysdep_AIX.c:223: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.
                char filename[STRLEN];
data/monit-5.27.1/src/process/sysdep_AIX.c:225:26:  [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).
                int fd = open(filename, O_RDONLY);
data/monit-5.27.1/src/process/sysdep_AIX.c:245: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.
                                char command[8192];
data/monit-5.27.1/src/process/sysdep_DARWIN.c:188: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.
                                char cmdpath[PROC_PIDPATHINFO_MAXSIZE] = {};
data/monit-5.27.1/src/process/sysdep_FREEBSD.c:143: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 errbuf[_POSIX2_LINE_MAX];
data/monit-5.27.1/src/process/sysdep_LINUX.c:137:39:  [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).
                        long long     open;
data/monit-5.27.1/src/process/sysdep_LINUX.c:143: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.
                char                secattr[STRLEN];
data/monit-5.27.1/src/process/sysdep_LINUX.c:182: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 buf[STRLEN];
data/monit-5.27.1/src/process/sysdep_LINUX.c:198: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 buf[8192];
data/monit-5.27.1/src/process/sysdep_LINUX.c:229: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 buf[4096];
data/monit-5.27.1/src/process/sysdep_LINUX.c:257: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 buf[4096];
data/monit-5.27.1/src/process/sysdep_LINUX.c:329: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.
                char filename[STRLEN];
data/monit-5.27.1/src/process/sysdep_LINUX.c:332:27:  [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/monit-5.27.1/src/process/sysdep_LINUX.c:338: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.
                char buf[STRLEN] = {};
data/monit-5.27.1/src/process/sysdep_LINUX.c:352:25:  [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[8192];
data/monit-5.27.1/src/process/sysdep_LINUX.c:386: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[PATH_MAX] = {};
data/monit-5.27.1/src/process/sysdep_LINUX.c:417: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 *f = fopen(path, "r");
data/monit-5.27.1/src/process/sysdep_LINUX.c:421: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.
                char line[STRLEN];
data/monit-5.27.1/src/process/sysdep_LINUX.c:469: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 *f = fopen("/proc/meminfo", "r");
data/monit-5.27.1/src/process/sysdep_LINUX.c:471: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.
                char line[STRLEN];
data/monit-5.27.1/src/process/sysdep_LINUX.c:486:13:  [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("/proc/stat", "r");
data/monit-5.27.1/src/process/sysdep_LINUX.c:488: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.
                char line[STRLEN];
data/monit-5.27.1/src/process/sysdep_LINUX.c:531:33:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
                proc.data.pid = atoi(globbuf.gl_pathv[i] + 6); // skip "/proc/"
data/monit-5.27.1/src/process/sysdep_LINUX.c:556:85:  [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).
                        pt[count].filedescriptors.usage = proc.data.filedescriptors.open;
data/monit-5.27.1/src/process/sysdep_LINUX.c:585: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 buf[STRLEN];
data/monit-5.27.1/src/process/sysdep_LINUX.c:606: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           buf[2048];
data/monit-5.27.1/src/process/sysdep_LINUX.c:641:27:  [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("/proc/spl/kstat/zfs/arcstats", "r");
data/monit-5.27.1/src/process/sysdep_LINUX.c:643:25:  [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[STRLEN];
data/monit-5.27.1/src/process/sysdep_LINUX.c:692: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 buf[8192];
data/monit-5.27.1/src/process/sysdep_LINUX.c:808: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 *f = fopen("/proc/sys/fs/file-nr", "r");
data/monit-5.27.1/src/process/sysdep_LINUX.c:810: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.
                char line[STRLEN];
data/monit-5.27.1/src/process/sysdep_LINUX.c:836: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 buf[8192];
data/monit-5.27.1/src/process/sysdep_NETBSD.c:167: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 buf[_POSIX2_LINE_MAX];
data/monit-5.27.1/src/process/sysdep_OPENBSD.c:146: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                      buf[_POSIX2_LINE_MAX];
data/monit-5.27.1/src/process/sysdep_SOLARIS.c:157: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 buf[4096];
data/monit-5.27.1/src/process/sysdep_SOLARIS.c:159:29:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
                pt[i].pid = atoi(globbuf.gl_pathv[i] + strlen("/proc/"));
data/monit-5.27.1/src/protocols/apache_status.c:87:111:  [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).
        int total = logging + close + dns + keepalive + reply + request + start + wait + graceful + cleanup + open;
data/monit-5.27.1/src/protocols/apache_status.c:115: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 buf[STRLEN];
data/monit-5.27.1/src/protocols/apache_status.c:135: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 buf[4096];
data/monit-5.27.1/src/protocols/clamav.c:50: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 buf[STRLEN];
data/monit-5.27.1/src/protocols/default.c:42: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.
                char token[1] = {};
data/monit-5.27.1/src/protocols/dns.c:56:18:  [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.
        unsigned char  buf[STRLEN];
data/monit-5.27.1/src/protocols/dns.c:58:18:  [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.
        unsigned char  request[19] = {
data/monit-5.27.1/src/protocols/dwp.c:54: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 buf[STRLEN];
data/monit-5.27.1/src/protocols/dwp.c:55: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 proto[STRLEN];
data/monit-5.27.1/src/protocols/fail2ban.c:58:18:  [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.
        unsigned char response[1] = {};
data/monit-5.27.1/src/protocols/ftp.c:44: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 buf[STRLEN];
data/monit-5.27.1/src/protocols/generic.c:107: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.
                                char e[STRLEN];
data/monit-5.27.1/src/protocols/generic.c:109: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.
                                char error[512];
data/monit-5.27.1/src/protocols/gps.c:43: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 buf[STRLEN];
data/monit-5.27.1/src/protocols/http.c:71: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.
                char error[512];
data/monit-5.27.1/src/protocols/http.c:79:41:  [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 errbuf[STRLEN];
data/monit-5.27.1/src/protocols/http.c:116: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 buf[9];
data/monit-5.27.1/src/protocols/http.c:166: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 crlf[2] = {};
data/monit-5.27.1/src/protocols/http.c:225: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 buf[512] = {};
data/monit-5.27.1/src/protocols/http.c:238: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 buf[512] = {};
data/monit-5.27.1/src/protocols/imap.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 buf[512];
data/monit-5.27.1/src/protocols/ldap2.c:54:18:  [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.
        unsigned char buf[STRLEN];
data/monit-5.27.1/src/protocols/ldap2.c:56:18:  [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.
        unsigned char request[14] = {
data/monit-5.27.1/src/protocols/ldap2.c:80:18:  [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.
        unsigned char response[14] = {
data/monit-5.27.1/src/protocols/ldap2.c:104:18:  [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.
        unsigned char unbind[7] = {
data/monit-5.27.1/src/protocols/ldap3.c:54:18:  [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.
        unsigned char buf[STRLEN];
data/monit-5.27.1/src/protocols/ldap3.c:56:18:  [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.
        unsigned char request[14] = {
data/monit-5.27.1/src/protocols/ldap3.c:80:18:  [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.
        unsigned char response[14] = {
data/monit-5.27.1/src/protocols/ldap3.c:104:18:  [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.
        unsigned char unbind[7] = {
data/monit-5.27.1/src/protocols/lmtp.c:48: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 buf[STRLEN];
data/monit-5.27.1/src/protocols/memcache.c:62:18:  [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.
        unsigned char response[MEMCACHELEN];
data/monit-5.27.1/src/protocols/memcache.c:65:18:  [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.
        unsigned char request[MEMCACHELEN] = {
data/monit-5.27.1/src/protocols/mongodb.c:82:18:  [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.
        unsigned char ping[58] = {
data/monit-5.27.1/src/protocols/mongodb.c:107:18:  [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.
        unsigned char buf[STRLEN + 1];
data/monit-5.27.1/src/protocols/mongodb.c:126:18:  [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.
        unsigned char ok[17] = {
data/monit-5.27.1/src/protocols/mqtt.c:109: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     data[STRLEN];
data/monit-5.27.1/src/protocols/mqtt.c:116: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           protocolName[4];
data/monit-5.27.1/src/protocols/mqtt.c:120: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           data[1024];
data/monit-5.27.1/src/protocols/mqtt.c:216: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(request->data + request->header.messageLength, &dataLengthNetworkOrder, sizeof(dataLengthNetworkOrder));
data/monit-5.27.1/src/protocols/mqtt.c:218: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(request->data + request->header.messageLength + sizeof(uint16_t), data, dataLength);
data/monit-5.27.1/src/protocols/mqtt.c:241: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 id[STRLEN] = {};
data/monit-5.27.1/src/protocols/mysql.c:130: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 buf[MYSQL_REQUEST_BUFFER];
data/monit-5.27.1/src/protocols/mysql.c:139: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 buf[MYSQL_RESPONSE_BUFFER + 4 + 1]; // reserve 4 bytes for header
data/monit-5.27.1/src/protocols/mysql.c:157:25:  [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      authdata[21];
data/monit-5.27.1/src/protocols/mysql.c:158:25:  [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      authplugin[64];
data/monit-5.27.1/src/protocols/mysql.c:167:25:  [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      sql_state[5];
data/monit-5.27.1/src/protocols/mysql.c:208: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 salt[21];
data/monit-5.27.1/src/protocols/mysql.c:209: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 publicKey[4096];
data/monit-5.27.1/src/protocols/mysql.c:307: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(request->cursor, data, length);
data/monit-5.27.1/src/protocols/mysql.c:361: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 *_getNativePassword(char result[static SHA1_DIGEST_SIZE], const char *password, const char *salt) {
data/monit-5.27.1/src/protocols/mysql.c:361: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.
static char *_getNativePassword(char result[static SHA1_DIGEST_SIZE], const char *password, const char *salt) {
data/monit-5.27.1/src/protocols/mysql.c:387: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 *_getCachingSha2Password(char result[static SHA256_DIGEST_LENGTH], const char *password, const char *salt) {
data/monit-5.27.1/src/protocols/mysql.c:387:38:  [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 *_getCachingSha2Password(char result[static SHA256_DIGEST_LENGTH], const char *password, const char *salt) {
data/monit-5.27.1/src/protocols/mysql.c:574: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.
                char password[SHA256_DIGEST_LENGTH] = {};
data/monit-5.27.1/src/protocols/mysql.c:644:18:  [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.
        unsigned char saltedPassword[STRLEN];
data/monit-5.27.1/src/protocols/mysql.c:650:18:  [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.
        unsigned char encryptedPassword[RSA_size(rsa)];
data/monit-5.27.1/src/protocols/mysql.c:742: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.
                                char password[SHA256_DIGEST_LENGTH] = {};
data/monit-5.27.1/src/protocols/nntp.c:46: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 buf[STRLEN];
data/monit-5.27.1/src/protocols/ntp3.c:63: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 ntpRequest[NTPLEN] = {};
data/monit-5.27.1/src/protocols/ntp3.c:64: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 ntpResponse[NTPLEN] = {};
data/monit-5.27.1/src/protocols/pgsql.c:46:18:  [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.
        unsigned char buf[STRLEN] = {};
data/monit-5.27.1/src/protocols/pgsql.c:48:18:  [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.
        unsigned char requestLogin[33] = {
data/monit-5.27.1/src/protocols/pgsql.c:86:18:  [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.
        unsigned char requestTerm[5] = {
data/monit-5.27.1/src/protocols/pgsql.c:95:18:  [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.
        unsigned char responseAuthOk[9] = {
data/monit-5.27.1/src/protocols/pop.c:46: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 buf[STRLEN];
data/monit-5.27.1/src/protocols/postfix_policy.c:56: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 buf[STRLEN];
data/monit-5.27.1/src/protocols/radius.c:64:18:  [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.
        unsigned char  digest[16];
data/monit-5.27.1/src/protocols/radius.c:65:18:  [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.
        unsigned char  response[STRLEN];
data/monit-5.27.1/src/protocols/radius.c:66:18:  [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.
        unsigned char  request[38] = {
data/monit-5.27.1/src/protocols/radius.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(digest, response + 4, 16);
data/monit-5.27.1/src/protocols/radius.c:179: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(response + 4, request + 4, 16);
data/monit-5.27.1/src/protocols/redis.c:50: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 buf[STRLEN];
data/monit-5.27.1/src/protocols/rsync.c:44: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  buf[64];
data/monit-5.27.1/src/protocols/rsync.c:45: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  header[11];
data/monit-5.27.1/src/protocols/sieve.c:51: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 buf[STRLEN];
data/monit-5.27.1/src/protocols/sip.c:97: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 buf[STRLEN];
data/monit-5.27.1/src/protocols/spamassassin.c:51: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 buf[STRLEN];
data/monit-5.27.1/src/protocols/ssh.c:45: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  buf[STRLEN];
data/monit-5.27.1/src/protocols/tns.c:48:18:  [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.
        unsigned char  buf[STRLEN];
data/monit-5.27.1/src/protocols/websocket.c:55: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.
                char buf[STRLEN];
data/monit-5.27.1/src/protocols/websocket.c:94: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 buf[STRLEN];
data/monit-5.27.1/src/protocols/websocket.c:122:18:  [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.
        unsigned char ping[6] = {
data/monit-5.27.1/src/protocols/websocket.c:134:18:  [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.
        unsigned char close_request[6] = {
data/monit-5.27.1/src/sha1.c:61:66:  [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 void sha1_transform(unsigned int state[5], const unsigned char buffer[64]) {
data/monit-5.27.1/src/sha1.c:64:26:  [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.
                unsigned char c[64];
data/monit-5.27.1/src/sha1.c:69: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, buffer, 64);
data/monit-5.27.1/src/sha1.c:130:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(&context->buffer[j], data, (i = 64-j));
data/monit-5.27.1/src/sha1.c:138: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(&context->buffer[j], &data[i], len - i);
data/monit-5.27.1/src/sha1.c:143:52:  [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.
void sha1_finish(sha1_context_t *context, unsigned char digest[SHA1_DIGEST_SIZE]) {
data/monit-5.27.1/src/sha1.c:145:18:  [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.
        unsigned char  finalcount[8];
data/monit-5.27.1/src/sha1.h:35:14:  [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.
    unsigned char buffer[64];
data/monit-5.27.1/src/sha1.h:40:52:  [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.
void sha1_finish(sha1_context_t *context, unsigned char digest[SHA1_DIGEST_SIZE]);
data/monit-5.27.1/src/spawn.c:160: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 date[42];
data/monit-5.27.1/src/spawn.c:211:55:  [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 (close(i) == -1 || open("/dev/null", O_RDWR) != i)
data/monit-5.27.1/src/ssl/Ssl.c:132: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 error[128];
data/monit-5.27.1/src/ssl/Ssl.c:356:26:  [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.
                unsigned char realChecksum[EVP_MAX_MD_SIZE];
data/monit-5.27.1/src/state.c:116: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               name[STRLEN];
data/monit-5.27.1/src/state.c:162: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               name[STRLEN];
data/monit-5.27.1/src/state.c:206: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               name[STRLEN];
data/monit-5.27.1/src/state.c:222: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     name[STRLEN];
data/monit-5.27.1/src/state.c:496: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).
        if ((file = open(Run.files.state, O_RDWR | O_CREAT, 0600)) == -1) {
data/monit-5.27.1/src/terminal/Box.h:56: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 _color[8];
data/monit-5.27.1/src/util.c:139:23:  [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 unsigned char urlunsafe[256] = {
data/monit-5.27.1/src/util.c:160:23:  [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 unsigned char urlunsafeparameter[256] = {
data/monit-5.27.1/src/util.c:609: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 buf[10];
data/monit-5.27.1/src/util.c:636: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.
                char slots[STRLEN];
data/monit-5.27.1/src/util.c:755: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 buffer[STRLEN];
data/monit-5.27.1/src/util.c:1313: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 ruler[STRLEN];
data/monit-5.27.1/src/util.c:1327: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 buf[STRLEN] = {};
data/monit-5.27.1/src/util.c:1343: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 = fopen(idfile, "w");
data/monit-5.27.1/src/util.c:1355:29:  [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 ((file = fopen(idfile,"r")) == (FILE *)NULL) {
data/monit-5.27.1/src/util.c:1387:21:  [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 ((file = fopen(pidfile,"r")) == (FILE *)NULL) {
data/monit-5.27.1/src/util.c:1463: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  buf[STRLEN];
data/monit-5.27.1/src/util.c:1482:39:  [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 (close(i) == -1 || open("/dev/null", O_RDWR) != i) {
data/monit-5.27.1/src/util.c:1514: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 outside_crypt[STRLEN];
data/monit-5.27.1/src/util.c:1524:25:  [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 id[STRLEN];
data/monit-5.27.1/src/util.c:1525:25:  [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 salt[STRLEN];
data/monit-5.27.1/src/util.c:1554:25:  [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 salt[3];
data/monit-5.27.1/src/util.c:1905: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 *Util_commandDescription(command_t command, char s[STRLEN]) {
data/monit-5.27.1/src/util.c:1905:50:  [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 *Util_commandDescription(command_t command, char s[STRLEN]) {
data/monit-5.27.1/src/util.h:346: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 *Util_commandDescription(command_t command, char s[STRLEN]);
data/monit-5.27.1/src/util.h:346:50:  [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 *Util_commandDescription(command_t command, char s[STRLEN]);
data/monit-5.27.1/src/validate.c:131: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 buf[STRLEN];
data/monit-5.27.1/src/validate.c:151: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 buf[STRLEN];
data/monit-5.27.1/src/validate.c:152: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 report[1024] = {};
data/monit-5.27.1/src/validate.c:244: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 report[STRLEN] = {}, buf1[10], buf2[10];
data/monit-5.27.1/src/validate.c:441:73:  [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 State_Type _checkLoadAverage(Resource_T r, double loadavg, const char *name, char report[STRLEN]) {
data/monit-5.27.1/src/validate.c:441:85:  [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 State_Type _checkLoadAverage(Resource_T r, double loadavg, const char *name, char report[STRLEN]) {
data/monit-5.27.1/src/validate.c:455: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 report[STRLEN] = {}, buf1[10], buf2[10];
data/monit-5.27.1/src/validate.c:869:103:  [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 (Util_evalQExpression(o->operator, s->inf.process->filedescriptors.open, o->limit_absolute)) {
data/monit-5.27.1/src/validate.c:871:201:  [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).
                                        Event_post(s, Event_Resource, State_Failed, o->action, "filedescriptors usage of %lld matches limit [filedescriptors %s %lld]", s->inf.process->filedescriptors.open, operatorshortnames[o->operator], o->limit_absolute);
data/monit-5.27.1/src/validate.c:873:204:  [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).
                                        Event_post(s, Event_Resource, State_Succeeded, o->action, "filedescriptors test succeeded [current filedescriptors usage = %lld]", s->inf.process->filedescriptors.open);
data/monit-5.27.1/src/validate.c:878:119:  [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).
                                        float usage = limit > 0 ? (float)100 * (float)s->inf.process->filedescriptors.open / (float)limit : 0;
data/monit-5.27.1/src/validate.c:987:25:  [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/monit-5.27.1/src/validate.c:1067:30:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
                FILE *file = fopen(s->path, "r");
data/monit-5.27.1/src/validate.c:1258:41:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
                                        char buf1[10];
data/monit-5.27.1/src/validate.c:1259:41:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
                                        char buf2[10];
data/monit-5.27.1/src/validate.c:1278:41:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
                                        char buf1[10];
data/monit-5.27.1/src/validate.c:1279:41:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
                                        char buf2[10];
data/monit-5.27.1/src/validate.c:2047: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 buf1[10], buf2[10];
data/monit-5.27.1/src/y.tab.c:2969:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
  char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
data/monit-5.27.1/src/y.tab.c:3156:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
  char yymsgbuf[128];
data/monit-5.27.1/src/y.tab.c:4484: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.
                                char hostname[STRLEN];
data/monit-5.27.1/src/y.tab.c:7936:21:  [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 ((yyin = fopen(controlfile,"r")) == (FILE *)NULL) {
data/monit-5.27.1/src/y.tab.c:8074: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.
                char hostname[STRLEN];
data/monit-5.27.1/src/y.tab.c:8126:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(&(outgoing->addr), result->ai_addr, result->ai_addrlen);
data/monit-5.27.1/src/y.tab.c:8227:25:  [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 program[PATH_MAX];
data/monit-5.27.1/src/y.tab.c:8401: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(&p->parameters, &port->parameters, sizeof(port->parameters));
data/monit-5.27.1/src/y.tab.c:8838: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.
                char errbuf[STRLEN];
data/monit-5.27.1/src/y.tab.c:8852: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 *handle = fopen(ms->match_path, "r");
data/monit-5.27.1/src/y.tab.c:8861: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.
                char buf[2048];
data/monit-5.27.1/src/y.tab.c:9051:25:  [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 errbuf[STRLEN];
data/monit-5.27.1/src/y.tab.c:9137: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.
                char errbuf[STRLEN];
data/monit-5.27.1/src/y.tab.c:9217: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 buf[4096];
data/monit-5.27.1/src/y.tab.c:9328: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 buf[STRLEN];
data/monit-5.27.1/src/y.tab.c:9334:18:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
        handle = fopen(filename, "r");
data/monit-5.27.1/src/y.tab.c:9788: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 buf[STRLEN];
data/monit-5.27.1/libmonit/src/io/File.c:220:24:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
        mode_t omask = umask(0);
data/monit-5.27.1/libmonit/src/io/File.c:221:9:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
        umask(omask);
data/monit-5.27.1/libmonit/src/io/File.c:227:24:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
        mode_t omask = umask(mask);
data/monit-5.27.1/libmonit/src/io/OutputStream.c:179: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).
        int len = (int)strlen((char*)str);
data/monit-5.27.1/libmonit/src/io/OutputStream.c:315: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).
        putd(S, buf, (int)strlen(buf), flags, width, precision);
data/monit-5.27.1/libmonit/src/system/Command.c:109:42:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                if ((strncmp(p->e, name, strlen(name)) == 0))
data/monit-5.27.1/libmonit/src/system/Command.c:110: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).
                        if (((char*)p->e)[strlen(name)] == '=') // Ensure that p->e is not just a sub-string
data/monit-5.27.1/libmonit/src/system/Net.c:111:29:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        n = read(socket, buffer, size);
data/monit-5.27.1/libmonit/src/system/Net.c:118:37:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                n = read(socket, buffer, size);
data/monit-5.27.1/libmonit/src/system/System.c:117:29:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                int bytes = read(fd, buf, nbytes);
data/monit-5.27.1/libmonit/src/system/Time.c:195: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).
        const char *limit = s + strlen(s), *marker, *token, *cursor = s;
data/monit-5.27.1/libmonit/src/system/Time.c:1460: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).
        const char *end = cron + strlen(cron);
data/monit-5.27.1/libmonit/src/system/Time.c:1591:9:  [1] (obsolete) usleep:
  This C routine is considered obsolete (as opposed to the shell command by
  the same name). The interaction of this function with SIGALRM and other
  timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is
  unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead.
        usleep((useconds_t)u);
data/monit-5.27.1/libmonit/src/util/Str.c:89: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).
                for (ssize_t j = strlen(s) - 1; j >= 0 && isspace(s[j]); j--)
data/monit-5.27.1/libmonit/src/util/Str.c:198: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).
                for (i = strlen(a), j = strlen(b); (i && j); i--, j--)
data/monit-5.27.1/libmonit/src/util/Str.c:198:41:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                for (i = strlen(a), j = strlen(b); (i && j); i--, j--)
data/monit-5.27.1/libmonit/src/util/Str.c:293: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).
                size_t n = strlen(s) + 1;
data/monit-5.27.1/libmonit/src/util/Str.c:305:32:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                long l = (long)strlen(s);
data/monit-5.27.1/libmonit/src/util/Str.c:359: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).
                size_t sl = strlen(s);
data/monit-5.27.1/libmonit/src/util/StringBuffer.c:154: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).
                        size_t bl = strlen(b);
data/monit-5.27.1/libmonit/src/util/StringBuffer.c:155:44:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                        size_t diff = bl - strlen(a);
data/monit-5.27.1/libmonit/test/OutputStreamTest.c:53: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).
                int bytes = strlen("line1\nline2\nline3\n");
data/monit-5.27.1/libmonit/test/OutputStreamTest.c:57: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).
                assert(bytes == OutputStream_write(out, data, (int)strlen(data)));
data/monit-5.27.1/libmonit/test/StrTest.c:326:54:  [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).
                assert(Str_isEqual(Str_trunc(s, (int)strlen(s)), "This string will be trailed someplace"));
data/monit-5.27.1/libmonit/test/TimeTest.c:337:17:  [1] (obsolete) usleep:
  This C routine is considered obsolete (as opposed to the shell command by
  the same name). The interaction of this function with SIGALRM and other
  timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is
  unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead.
                usleep(500000);
data/monit-5.27.1/libmonit/test/TimeTest.c:346:17:  [1] (obsolete) usleep:
  This C routine is considered obsolete (as opposed to the shell command by
  the same name). The interaction of this function with SIGALRM and other
  timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is
  unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead.
                usleep(500);
data/monit-5.27.1/src/alert.c:85:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(host, r->ai_canonname, 255);
data/monit-5.27.1/src/alert.c:95:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(host, Run.system->name, 255);
data/monit-5.27.1/src/device/device_common.c:115:55:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                Statistics_reset(&(s->inf.filesystem->read.bytes));
data/monit-5.27.1/src/device/device_common.c:116:55:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                Statistics_reset(&(s->inf.filesystem->read.operations));
data/monit-5.27.1/src/device/device_common.c:119:60:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                Statistics_reset(&(s->inf.filesystem->time.read));
data/monit-5.27.1/src/device/sysdep_AIX.c:206:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(inf->filesystem->object.device, mnt->mnt_fsname, sizeof(inf->filesystem->object.device) - 1);
data/monit-5.27.1/src/device/sysdep_AIX.c:207:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(inf->filesystem->object.mountpoint, mnt->mnt_dir, sizeof(inf->filesystem->object.mountpoint) - 1);
data/monit-5.27.1/src/device/sysdep_AIX.c:208:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(inf->filesystem->object.type, mnt->mnt_type, sizeof(inf->filesystem->object.type) - 1);
data/monit-5.27.1/src/device/sysdep_DARWIN.c:102:129:  [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).
                CFURLRef url = CFURLCreateFromFileSystemRepresentation(NULL, (const UInt8 *)inf->filesystem->object.mountpoint, strlen(inf->filesystem->object.mountpoint), true);
data/monit-5.27.1/src/device/sysdep_DARWIN.c:118:94:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                                        Statistics_update(&(inf->filesystem->read.bytes), now, value);
data/monit-5.27.1/src/device/sysdep_DARWIN.c:124:94:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                                        Statistics_update(&(inf->filesystem->read.operations), now, value);
data/monit-5.27.1/src/device/sysdep_DARWIN.c:142:99:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                                        Statistics_update(&(inf->filesystem->time.read), now, value / 1048576.); // ns -> ms
data/monit-5.27.1/src/device/sysdep_DARWIN.c:207:59:  [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(inf->filesystem->flags + strlen(inf->filesystem->flags), sizeof(inf->filesystem->flags) - strlen(inf->filesystem->flags) - 1, "%s%s", count++ ? ", " : "", t[i].description);
data/monit-5.27.1/src/device/sysdep_DARWIN.c:207:124:  [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(inf->filesystem->flags + strlen(inf->filesystem->flags), sizeof(inf->filesystem->flags) - strlen(inf->filesystem->flags) - 1, "%s%s", count++ ? ", " : "", t[i].description);
data/monit-5.27.1/src/device/sysdep_DARWIN.c:233:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.device, mntItem->f_mntfromname, sizeof(inf->filesystem->object.device) - 1);
data/monit-5.27.1/src/device/sysdep_DARWIN.c:234:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.mountpoint, mntItem->f_mntonname, sizeof(inf->filesystem->object.mountpoint) - 1);
data/monit-5.27.1/src/device/sysdep_DARWIN.c:235:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.type, mntItem->f_fstypename, sizeof(inf->filesystem->object.type) - 1);
data/monit-5.27.1/src/device/sysdep_DRAGONFLY.c:120:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(device->key, base, i < sizeof(device->key) ? i : sizeof(device->key) - 1);
data/monit-5.27.1/src/device/sysdep_DRAGONFLY.c:156:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.bytes), now, _statistics.disk.dinfo->devices[i].bytes_read);
data/monit-5.27.1/src/device/sysdep_DRAGONFLY.c:157:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.operations),  now, _statistics.disk.dinfo->devices[i].num_reads);
data/monit-5.27.1/src/device/sysdep_DRAGONFLY.c:230:59:  [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(inf->filesystem->flags + strlen(inf->filesystem->flags), sizeof(inf->filesystem->flags) - strlen(inf->filesystem->flags) - 1, "%s%s", count++ ? ", " : "", t[i].description);
data/monit-5.27.1/src/device/sysdep_DRAGONFLY.c:230:124:  [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(inf->filesystem->flags + strlen(inf->filesystem->flags), sizeof(inf->filesystem->flags) - strlen(inf->filesystem->flags) - 1, "%s%s", count++ ? ", " : "", t[i].description);
data/monit-5.27.1/src/device/sysdep_DRAGONFLY.c:262:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.device, mntItem->f_mntfromname, sizeof(inf->filesystem->object.device) - 1);
data/monit-5.27.1/src/device/sysdep_DRAGONFLY.c:263:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.mountpoint, mntItem->f_mntonname, sizeof(inf->filesystem->object.mountpoint) - 1);
data/monit-5.27.1/src/device/sysdep_DRAGONFLY.c:264:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.type, mntItem->f_fstypename, sizeof(inf->filesystem->object.type) - 1);
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:121:13:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        if (strlen(path) > 5 && Str_startsWith(path, "/dev/")) {
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:145:37:  [1] (buffer) sscanf:
  It's unclear if the %s limit in the format string is small enough
  (CWE-120). Check that the limit is sufficiently small, or use a different
  input function.
                                if (sscanf(cursor, "%d %63s %1023s ", &index, type, name) == 3) {
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:153:73:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                                                        strncpy(device->key, disk, i < sizeof(device->key) ? i : sizeof(device->key) - 1);
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:195:75:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->time.read), now, _bintimeToMilli(&(_statistics.disk.dinfo->devices[i].duration[DEVSTAT_READ])));
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:196:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.bytes), now, _statistics.disk.dinfo->devices[i].bytes[DEVSTAT_READ]);
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:197:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.operations),  now, _statistics.disk.dinfo->devices[i].operations[DEVSTAT_READ]);
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:279:59:  [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(inf->filesystem->flags + strlen(inf->filesystem->flags), sizeof(inf->filesystem->flags) - strlen(inf->filesystem->flags) - 1, "%s%s", count++ ? ", " : "", t[i].description);
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:279:124:  [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(inf->filesystem->flags + strlen(inf->filesystem->flags), sizeof(inf->filesystem->flags) - strlen(inf->filesystem->flags) - 1, "%s%s", count++ ? ", " : "", t[i].description);
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:311:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.device, mntItem->f_mntfromname, sizeof(inf->filesystem->object.device) - 1);
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:312:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.mountpoint, mntItem->f_mntonname, sizeof(inf->filesystem->object.mountpoint) - 1);
data/monit-5.27.1/src/device/sysdep_FREEBSD.c:313:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.type, mntItem->f_fstypename, sizeof(inf->filesystem->object.type) - 1);
data/monit-5.27.1/src/device/sysdep_LINUX.c:142:29:  [1] (buffer) sscanf:
  It's unclear if the %s limit in the format string is small enough
  (CWE-120). Check that the limit is sufficiently small, or use a different
  input function.
                        if (sscanf(line, "%d) %4095s", &index, name) == 2 && Str_isEqual(name, inf->filesystem->object.key)) {
data/monit-5.27.1/src/device/sysdep_LINUX.c:152:78:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                        Statistics_update(&(inf->filesystem->read.bytes), now, bytes);
data/monit-5.27.1/src/device/sysdep_LINUX.c:153:78:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                        Statistics_update(&(inf->filesystem->read.operations), now, operations);
data/monit-5.27.1/src/device/sysdep_LINUX.c:190:83:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                        Statistics_update(&(inf->filesystem->time.read), now, time / 1000.); // us -> ms
data/monit-5.27.1/src/device/sysdep_LINUX.c:191:78:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                        Statistics_update(&(inf->filesystem->read.bytes), now, bytesReceived);
data/monit-5.27.1/src/device/sysdep_LINUX.c:192:78:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                        Statistics_update(&(inf->filesystem->read.operations), now, operations);
data/monit-5.27.1/src/device/sysdep_LINUX.c:220:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.bytes), now, readBytes);
data/monit-5.27.1/src/device/sysdep_LINUX.c:221:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.operations), now, readOperations);
data/monit-5.27.1/src/device/sysdep_LINUX.c:264:59:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                Statistics_update(&(inf->filesystem->time.read), now, readTime);
data/monit-5.27.1/src/device/sysdep_LINUX.c:265:54:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                Statistics_update(&(inf->filesystem->read.bytes), now, readSectors * 512);
data/monit-5.27.1/src/device/sysdep_LINUX.c:266:54:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                Statistics_update(&(inf->filesystem->read.operations), now, readOperations);
data/monit-5.27.1/src/device/sysdep_LINUX.c:288:29:  [1] (buffer) fscanf:
  It's unclear if the %s limit in the format string is small enough
  (CWE-120). Check that the limit is sufficiently small, or use a different
  input function.
                        if (fscanf(f, "%u %u %255s %llu %*u %llu %llu %llu %*u %llu %llu %*u %*u %*u", &major, &minor, name, &readOperations, &readSectors, &readTime, &writeOperations, &writeSectors, &writeTime) == 9 && major == st_major && minor == st_minor) {
data/monit-5.27.1/src/device/sysdep_LINUX.c:289:75:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->time.read), now, readTime);
data/monit-5.27.1/src/device/sysdep_LINUX.c:290:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.bytes), now, readSectors * 512);
data/monit-5.27.1/src/device/sysdep_LINUX.c:291:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.operations), now, readOperations);
data/monit-5.27.1/src/device/sysdep_LINUX.c:323:59:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                Statistics_update(&(inf->filesystem->time.read), now, readTime);
data/monit-5.27.1/src/device/sysdep_LINUX.c:324:54:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                Statistics_update(&(inf->filesystem->read.bytes), now, readSectors * 512);
data/monit-5.27.1/src/device/sysdep_LINUX.c:325:54:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                Statistics_update(&(inf->filesystem->read.operations), now, readOperations);
data/monit-5.27.1/src/device/sysdep_LINUX.c:350:29:  [1] (buffer) fscanf:
  It's unclear if the %s limit in the format string is small enough
  (CWE-120). Check that the limit is sufficiently small, or use a different
  input function.
                        if (fscanf(f, " %*d %*d %255s %llu %llu %llu %llu", name, &readOperations, &readSectors, &writeOperations, &writeSectors) == 5 && Str_isEqual(name, inf->filesystem->object.key)) {
data/monit-5.27.1/src/device/sysdep_LINUX.c:351:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.bytes), now, readSectors * 512);
data/monit-5.27.1/src/device/sysdep_LINUX.c:352:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.operations), now, readOperations);
data/monit-5.27.1/src/device/sysdep_NETBSD.c:107: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).
        for (int len = strlen(base), i = len - 1; i >= 0; i--) {
data/monit-5.27.1/src/device/sysdep_NETBSD.c:110:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(device->key, base, index < sizeof(device->key) ? index : sizeof(device->key) - 1);
data/monit-5.27.1/src/device/sysdep_NETBSD.c:154:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.bytes), now, _statistics.disk[i].rbytes);
data/monit-5.27.1/src/device/sysdep_NETBSD.c:156:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.operations),  now, _statistics.disk[i].rxfer);
data/monit-5.27.1/src/device/sysdep_NETBSD.c:231:59:  [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(inf->filesystem->flags + strlen(inf->filesystem->flags), sizeof(inf->filesystem->flags) - strlen(inf->filesystem->flags) - 1, "%s%s", count++ ? ", " : "", t[i].description);
data/monit-5.27.1/src/device/sysdep_NETBSD.c:231:124:  [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(inf->filesystem->flags + strlen(inf->filesystem->flags), sizeof(inf->filesystem->flags) - strlen(inf->filesystem->flags) - 1, "%s%s", count++ ? ", " : "", t[i].description);
data/monit-5.27.1/src/device/sysdep_NETBSD.c:263:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.device, mntItem->f_mntfromname, sizeof(inf->filesystem->object.device) - 1);
data/monit-5.27.1/src/device/sysdep_NETBSD.c:264:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.mountpoint, mntItem->f_mntonname, sizeof(inf->filesystem->object.mountpoint) - 1);
data/monit-5.27.1/src/device/sysdep_NETBSD.c:265:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.type, mntItem->f_fstypename, sizeof(inf->filesystem->object.type) - 1);
data/monit-5.27.1/src/device/sysdep_OPENBSD.c:103: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).
        for (ssize_t len = strlen(base), i = len - 1; i >= 0; i--) {
data/monit-5.27.1/src/device/sysdep_OPENBSD.c:105:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(device->key, base, i + 1 < (ssize_t)sizeof(device->key) ? i + 1 : (ssize_t)sizeof(device->key) - 1);
data/monit-5.27.1/src/device/sysdep_OPENBSD.c:150:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.bytes), now, _statistics.disk[i].ds_rbytes);
data/monit-5.27.1/src/device/sysdep_OPENBSD.c:152:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.operations),  now, _statistics.disk[i].ds_rxfer);
data/monit-5.27.1/src/device/sysdep_OPENBSD.c:213:59:  [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(inf->filesystem->flags + strlen(inf->filesystem->flags), sizeof(inf->filesystem->flags) - strlen(inf->filesystem->flags) - 1, "%s%s", count++ ? ", " : "", t[i].description);
data/monit-5.27.1/src/device/sysdep_OPENBSD.c:213:124:  [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(inf->filesystem->flags + strlen(inf->filesystem->flags), sizeof(inf->filesystem->flags) - strlen(inf->filesystem->flags) - 1, "%s%s", count++ ? ", " : "", t[i].description);
data/monit-5.27.1/src/device/sysdep_OPENBSD.c:244:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.device, mntItem->f_mntfromname, sizeof(inf->filesystem->object.device) - 1);
data/monit-5.27.1/src/device/sysdep_OPENBSD.c:245:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.mountpoint, mntItem->f_mntonname, sizeof(inf->filesystem->object.mountpoint) - 1);
data/monit-5.27.1/src/device/sysdep_OPENBSD.c:246:41:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                        strncpy(inf->filesystem->object.type, mntItem->f_fstypename, sizeof(inf->filesystem->object.type) - 1);
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:121:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.bytes), now, zpoolStatistics->vs_bytes[ZIO_TYPE_READ]);
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:123:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                Statistics_update(&(inf->filesystem->read.operations),  now, zpoolStatistics->vs_ops[ZIO_TYPE_READ]);
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:148:78:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                        Statistics_update(&(inf->filesystem->read.bytes), now, kio.nread);
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:150:78:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                        Statistics_update(&(inf->filesystem->read.operations),  now, kio.reads);
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:205:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(inf->filesystem->object.device, mnt.mnt_special, sizeof(inf->filesystem->object.device) - 1);
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:206:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(inf->filesystem->object.mountpoint, mnt.mnt_mountp, sizeof(inf->filesystem->object.mountpoint) - 1);
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:207:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(inf->filesystem->object.type, mnt.mnt_fstype, sizeof(inf->filesystem->object.type) - 1);
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:216:33:  [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(inf->filesystem->object.module, "nfs", sizeof(inf->filesystem->object.module) - 1);
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:222:33:  [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(inf->filesystem->object.module, "zfs", sizeof(inf->filesystem->object.module) - 1);
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:224:33:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                strncpy(inf->filesystem->object.key, mnt.mnt_special, slash ? slash - mnt.mnt_special : sizeof(inf->filesystem->object.key) - 1);
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:237:55:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                                        int speclen = strlen(special);
data/monit-5.27.1/src/device/sysdep_SOLARIS.c:238:54:  [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 devlen = strlen("/devices");
data/monit-5.27.1/src/event.c:213:60:  [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 (! (rv = file_writeQueue(file, E->source->name, strlen(E->source->name) + 1)))
data/monit-5.27.1/src/event.c:217: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).
        if (! (rv = file_writeQueue(file, E->message, E->message ? strlen(E->message) + 1 : 0)))
data/monit-5.27.1/src/event.c:275:60:  [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 (! (rv = file_writeQueue(file, E->source->name, strlen(E->source->name) + 1)))
data/monit-5.27.1/src/event.c:279: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).
        if (! (rv = file_writeQueue(file, E->message, E->message ? strlen(E->message) + 1 : 0)))
data/monit-5.27.1/src/file.c:285:26:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        int bytes = (int)read(fd, buf, buf_size - 1);
data/monit-5.27.1/src/http/base64.c:107: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 = strlen((char *)src);
data/monit-5.27.1/src/http/base64.c:148:31:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                size_t k, l = strlen(src) + 1;
data/monit-5.27.1/src/http/cervlet.c:417:87:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                _printIOStatistics(type, res, s, &(s->inf.filesystem->read), "read");
data/monit-5.27.1/src/http/cervlet.c:419:101:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                bool hasReadTime = Statistics_initialized(&(s->inf.filesystem->time.read));
data/monit-5.27.1/src/http/cervlet.c:423:96:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                double deltaOperations = Statistics_delta(&(s->inf.filesystem->read.operations)) + Statistics_delta(&(s->inf.filesystem->write.operations));
data/monit-5.27.1/src/http/cervlet.c:425:134:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                        double readTime = deltaOperations > 0. ? Statistics_deltaNormalize(&(s->inf.filesystem->time.read)) / deltaOperations : 0.;
data/monit-5.27.1/src/http/cervlet.c:465:84:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                _printIOStatistics(type, res, s, &(s->inf.process->read), "read");
data/monit-5.27.1/src/http/cervlet.c:626:57:  [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).
                favicon = CALLOC(sizeof(unsigned char), strlen(FAVICON_ICO));
data/monit-5.27.1/src/http/cervlet.c:1277:78:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                bool hasReadBytes = Statistics_initialized(&(s->inf.process->read.bytes));
data/monit-5.27.1/src/http/cervlet.c:1278:83:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                bool hasReadOperations = Statistics_initialized(&(s->inf.process->read.operations));
data/monit-5.27.1/src/http/cervlet.c:1282:214:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        StringBuffer_append(res->outputbuffer, "<td class='right column%s'>%s/s</td>", (s->error & Event_Resource) ? " red-text" : "", Convert_bytes2str(Statistics_deltaNormalize(&(s->inf.process->read.bytes)), (char[10]){}));
data/monit-5.27.1/src/http/cervlet.c:1284:198:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        StringBuffer_append(res->outputbuffer, "<td class='right column%s'>%.1f/s</td>", (s->error & Event_Resource) ? " red-text" : "", Statistics_deltaNormalize(&(s->inf.process->read.operations)));
data/monit-5.27.1/src/http/cervlet.c:1468:110:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                            Convert_bytes2str(Statistics_deltaNormalize(&(s->inf.filesystem->read.bytes)), (char[10]){}),
data/monit-5.27.1/src/http/cervlet.c:2687:32:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                snprintf(buf + strlen(buf), buflen - strlen(buf) - 1, " - %s pending", actionnames[s->doaction]);
data/monit-5.27.1/src/http/cervlet.c:2687:54:  [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(buf + strlen(buf), buflen - strlen(buf) - 1, " - %s pending", actionnames[s->doaction]);
data/monit-5.27.1/src/http/client.c:121:40:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                        if (message && strlen(message) > strlen(token)) {
data/monit-5.27.1/src/http/client.c:121: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).
                        if (message && strlen(message) > strlen(token)) {
data/monit-5.27.1/src/http/client.c:122:44:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                                message += strlen(token);
data/monit-5.27.1/src/http/engine.c:231:9:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
        strncpy(buf, pattern, sizeof(buf) - 1);
data/monit-5.27.1/src/http/engine.c:433:33:  [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(error, "Could not initialize SSL engine", STRLEN - 1);
data/monit-5.27.1/src/http/processor.c:175: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).
                _httpPostLimit += strlen("&service=") + strlen(s->name);
data/monit-5.27.1/src/http/processor.c:175:57:  [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).
                _httpPostLimit += strlen("&service=") + strlen(s->name);
data/monit-5.27.1/src/http/processor.c:546:13:  [1] (buffer) sscanf:
  It's unclear if the %s limit in the format string is small enough
  (CWE-120). Check that the limit is sufficiently small, or use a different
  input function.
        if (sscanf(line, "%255s %1023s HTTP/%3[1.0]", method, url, protocol) != 3) {
data/monit-5.27.1/src/http/processor.c:550:13:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        if (strlen(url) >= MAX_URL_LENGTH) {
data/monit-5.27.1/src/http/processor.c:772:33:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                                strncpy(cookieValue, cookie + i, sizeof(cookieValue) - 1);
data/monit-5.27.1/src/http/processor.c:806:9:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
        strncpy(buf, &credentials[6], sizeof(buf) - 1);
data/monit-5.27.1/src/http/xml.c:331:79:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                _ioStatistics(B, "read", &(S->inf.filesystem->read));
data/monit-5.27.1/src/http/xml.c:333:101:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                bool hasReadTime = Statistics_initialized(&(S->inf.filesystem->time.read));
data/monit-5.27.1/src/http/xml.c:340:145:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                                StringBuffer_append(B, "<read>%.3f</read>", Statistics_deltaNormalize(&(S->inf.filesystem->time.read)));
data/monit-5.27.1/src/http/xml.c:452:76:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                _ioStatistics(B, "read", &(S->inf.process->read));
data/monit-5.27.1/src/lex.yy.c:6195:14:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
			     (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
data/monit-5.27.1/src/lex.yy.c:8098: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).
                    yylval.url = create_URL(Str_ndup(yytext, strlen(yytext)-3));
data/monit-5.27.1/src/lex.yy.c:8225:40:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                      char *p = yytext+strlen("subject:");
data/monit-5.27.1/src/lex.yy.c:8236:40:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                      char *p = yytext+strlen("message:");
data/monit-5.27.1/src/lex.yy.c:8376: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).
                    unput(yytext[strlen(yytext)-1]);
data/monit-5.27.1/src/lex.yy.c:8467:63:  [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).
                      yylval.url->password = Str_ndup(yytext, strlen(yytext)-1);
data/monit-5.27.1/src/lex.yy.c:9487: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).
	return yy_scan_bytes( yystr, (int) strlen(yystr) );
data/monit-5.27.1/src/lex.yy.c:9794: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).
                        size_t filename_length = strlen(globbuf.gl_pathv[i]);
data/monit-5.27.1/src/md5_crypt.c:69:32:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        int sl, pl, pwl = (int)strlen(pw);
data/monit-5.27.1/src/md5_crypt.c:77: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).
        if (! strncmp(salt, id, strlen(id)))
data/monit-5.27.1/src/md5_crypt.c:78: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).
                sp += strlen(id);
data/monit-5.27.1/src/md5_crypt.c:93:55:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        md5_append(&ctx, (const md5_byte_t *)id, (int)strlen(id));
data/monit-5.27.1/src/md5_crypt.c:119:9:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
        strncpy(buf, id, buflen);
data/monit-5.27.1/src/md5_crypt.c:120:9:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
        strncat(buf, (const char *)sp, sl);
data/monit-5.27.1/src/md5_crypt.c:121:9:  [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(buf, "$");
data/monit-5.27.1/src/md5_crypt.c:150: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).
        p = buf + strlen(buf);
data/monit-5.27.1/src/monit.c:791:37:  [1] (buffer) getchar:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        if (tolower(getchar()) == 'y') {
data/monit-5.27.1/src/monit.h:1078:31:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        struct IOStatistics_T read;                       /**< Read statistics */
data/monit-5.27.1/src/monit.h:1081:37:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                struct Statistics_T read;         /**< Time spend by read [ms] */
data/monit-5.27.1/src/monit.h:1137:31:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        struct IOStatistics_T read;                       /**< Read statistics */
data/monit-5.27.1/src/net/socket.c:363:17:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                strncpy(unixsocket_server.sun_path, path, sizeof(unixsocket_server.sun_path) - 1);
data/monit-5.27.1/src/net/socket.c:682: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).
        n = Socket_write(S, buf, strlen(buf));
data/monit-5.27.1/src/notification/MMonit.c:133:55:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                                char *version = buf + strlen(MMONIT_SERVER_HEADER);
data/monit-5.27.1/src/notification/SMTP.c:140: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).
        int rv = Socket_write(S->socket, msg, strlen(msg));
data/monit-5.27.1/src/notification/SMTP.c:155: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 (strlen(line) < 4 || sscanf(line, "%d", &status) != 1 || status != code)
data/monit-5.27.1/src/notification/SMTP.c:260:17:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                strncpy(buffer, username, sizeof(buffer) - 1);
data/monit-5.27.1/src/notification/SMTP.c:261: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).
                char *b64 = encode_base64(strlen(buffer), (unsigned char *)buffer);
data/monit-5.27.1/src/notification/SMTP.c:272:17:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                strncpy(buffer, password, sizeof(buffer) - 1);
data/monit-5.27.1/src/notification/SMTP.c:273: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).
                b64 = encode_base64(strlen(buffer), (unsigned char *)buffer);
data/monit-5.27.1/src/process/ProcessTree.c:331:33:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                if (ptree[leaf].read.bytes >= 0)
data/monit-5.27.1/src/process/ProcessTree.c:332:61:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        Statistics_update(&(s->inf.process->read.bytes), ptree[leaf].read.time, ptree[leaf].read.bytes);
data/monit-5.27.1/src/process/ProcessTree.c:332:86:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        Statistics_update(&(s->inf.process->read.bytes), ptree[leaf].read.time, ptree[leaf].read.bytes);
data/monit-5.27.1/src/process/ProcessTree.c:332:109:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        Statistics_update(&(s->inf.process->read.bytes), ptree[leaf].read.time, ptree[leaf].read.bytes);
data/monit-5.27.1/src/process/ProcessTree.c:333:33:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                if (ptree[leaf].read.bytesPhysical >= 0)
data/monit-5.27.1/src/process/ProcessTree.c:334:61:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        Statistics_update(&(s->inf.process->read.bytesPhysical), ptree[leaf].read.time, ptree[leaf].read.bytesPhysical);
data/monit-5.27.1/src/process/ProcessTree.c:334:94:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        Statistics_update(&(s->inf.process->read.bytesPhysical), ptree[leaf].read.time, ptree[leaf].read.bytesPhysical);
data/monit-5.27.1/src/process/ProcessTree.c:334:117:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        Statistics_update(&(s->inf.process->read.bytesPhysical), ptree[leaf].read.time, ptree[leaf].read.bytesPhysical);
data/monit-5.27.1/src/process/ProcessTree.c:335:33:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                if (ptree[leaf].read.operations >= 0)
data/monit-5.27.1/src/process/ProcessTree.c:336:61:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        Statistics_update(&(s->inf.process->read.operations), ptree[leaf].read.time, ptree[leaf].read.operations);
data/monit-5.27.1/src/process/ProcessTree.c:336:91:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        Statistics_update(&(s->inf.process->read.operations), ptree[leaf].read.time, ptree[leaf].read.operations);
data/monit-5.27.1/src/process/ProcessTree.c:336:114:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        Statistics_update(&(s->inf.process->read.operations), ptree[leaf].read.time, ptree[leaf].read.operations);
data/monit-5.27.1/src/process/ProcessTree.h:67:11:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        } read;
data/monit-5.27.1/src/process/sysdep_AIX.c:213:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.bytes          = -1;
data/monit-5.27.1/src/process/sysdep_AIX.c:214:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.bytesPhysical  = -1;
data/monit-5.27.1/src/process/sysdep_AIX.c:215:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.operations     = procs[i].pi_ru.ru_inblock;
data/monit-5.27.1/src/process/sysdep_AIX.c:216:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.time           = now;
data/monit-5.27.1/src/process/sysdep_AIX.c:231:21:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                if (read(fd, &ps, sizeof(ps)) < 0) {
data/monit-5.27.1/src/process/sysdep_DARWIN.c:175: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).
                                p += strlen(p); // skip exename
data/monit-5.27.1/src/process/sysdep_DARWIN.c:182: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).
                                        p += strlen(p);
data/monit-5.27.1/src/process/sysdep_DARWIN.c:218:39:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                pt[i].read.time = pt[i].write.time = Time_milli();
data/monit-5.27.1/src/process/sysdep_DARWIN.c:219:39:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                pt[i].read.bytes = -1;
data/monit-5.27.1/src/process/sysdep_DARWIN.c:220:39:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                pt[i].read.bytesPhysical = rusage.ri_diskio_bytesread;
data/monit-5.27.1/src/process/sysdep_DARWIN.c:221:39:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                pt[i].read.operations = -1;
data/monit-5.27.1/src/process/sysdep_DRAGONFLY.c:174:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.bytes          = -1;
data/monit-5.27.1/src/process/sysdep_DRAGONFLY.c:175:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.bytesPhysical  = -1;
data/monit-5.27.1/src/process/sysdep_DRAGONFLY.c:176:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.operations     = pinfo[i].kp_ru.ru_inblock;
data/monit-5.27.1/src/process/sysdep_DRAGONFLY.c:177:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.time           = now;
data/monit-5.27.1/src/process/sysdep_FREEBSD.c:174:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.bytes            = -1;
data/monit-5.27.1/src/process/sysdep_FREEBSD.c:175:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.bytesPhysical    = -1;
data/monit-5.27.1/src/process/sysdep_FREEBSD.c:176:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.operations       = pinfo[i].ki_rusage.ru_inblock;
data/monit-5.27.1/src/process/sysdep_FREEBSD.c:180:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.time             = pt[i].write.time = now;
data/monit-5.27.1/src/process/sysdep_LINUX.c:130:19:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                } read;
data/monit-5.27.1/src/process/sysdep_LINUX.c:266:68:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        if (sscanf(tmp + 6, "\t%llu", &(proc->data.read.bytes)) != 1) {
data/monit-5.27.1/src/process/sysdep_LINUX.c:284:68:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        if (sscanf(tmp + 6, "\t%llu", &(proc->data.read.operations)) != 1) {
data/monit-5.27.1/src/process/sysdep_LINUX.c:302:69:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        if (sscanf(tmp + 11, "\t%llu", &(proc->data.read.bytesPhysical)) != 1) {
data/monit-5.27.1/src/process/sysdep_LINUX.c:546:35:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        pt[count].read.bytes = proc.data.read.bytes;
data/monit-5.27.1/src/process/sysdep_LINUX.c:546:58:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        pt[count].read.bytes = proc.data.read.bytes;
data/monit-5.27.1/src/process/sysdep_LINUX.c:547:35:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        pt[count].read.bytesPhysical = proc.data.read.bytesPhysical;
data/monit-5.27.1/src/process/sysdep_LINUX.c:547:66:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        pt[count].read.bytesPhysical = proc.data.read.bytesPhysical;
data/monit-5.27.1/src/process/sysdep_LINUX.c:548:35:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        pt[count].read.operations = proc.data.read.operations;
data/monit-5.27.1/src/process/sysdep_LINUX.c:548:63:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        pt[count].read.operations = proc.data.read.operations;
data/monit-5.27.1/src/process/sysdep_LINUX.c:552:35:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        pt[count].read.time = pt[count].write.time = Time_milli();
data/monit-5.27.1/src/process/sysdep_NETBSD.c:191:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.bytes          = -1;
data/monit-5.27.1/src/process/sysdep_NETBSD.c:192:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.bytesPhysical  = -1;
data/monit-5.27.1/src/process/sysdep_NETBSD.c:193:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.operations     = pinfo[i].p_uru_inblock;
data/monit-5.27.1/src/process/sysdep_NETBSD.c:194:23:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                pt[i].read.time           = now;
data/monit-5.27.1/src/process/sysdep_OPENBSD.c:202:35:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        pt[index].read.bytes          = -1;
data/monit-5.27.1/src/process/sysdep_OPENBSD.c:203:35:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        pt[index].read.bytesPhysical  = -1;
data/monit-5.27.1/src/process/sysdep_OPENBSD.c:204:35:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        pt[index].read.operations     = pinfo[i].p_uru_inblock;
data/monit-5.27.1/src/process/sysdep_OPENBSD.c:208:35:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        pt[index].read.time           = pt[i].write.time = now;
data/monit-5.27.1/src/process/sysdep_SOLARIS.c:159: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).
                pt[i].pid = atoi(globbuf.gl_pathv[i] + strlen("/proc/"));
data/monit-5.27.1/src/process/sysdep_SOLARIS.c:183:39:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                pt[i].read.bytes          = -1;
data/monit-5.27.1/src/process/sysdep_SOLARIS.c:184:39:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                pt[i].read.bytesPhysical  = -1;
data/monit-5.27.1/src/process/sysdep_SOLARIS.c:185:39:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                pt[i].read.operations     = usage->pr_inblk;
data/monit-5.27.1/src/process/sysdep_SOLARIS.c:189:39:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                pt[i].read.time = pt[i].write.time = Time_milli();
data/monit-5.27.1/src/protocols/dwp.c:67:13:  [1] (buffer) sscanf:
  It's unclear if the %s limit in the format string is small enough
  (CWE-120). Check that the limit is sufficiently small, or use a different
  input function.
        n = sscanf(buf, "%255s %d", proto, &status);
data/monit-5.27.1/src/protocols/gps.c:57:45:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        if (strncasecmp(buf, ok_gps_device, strlen(ok_gps_device)) != 0)
data/monit-5.27.1/src/protocols/gps.c:58:59:  [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 (strncasecmp(buf, ok_rtcm104v2_device, strlen(ok_rtcm104v2_device)) != 0)
data/monit-5.27.1/src/protocols/gps.c:59: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).
                        if (strncasecmp(buf, ok_rtcm104_device, strlen(ok_rtcm104_device)) != 0)
data/monit-5.27.1/src/protocols/http.c:107:44:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                                if (header[strlen(name)] == ':') // Ensure that name is not just a prefix
data/monit-5.27.1/src/protocols/imap.c:84: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 (strncasecmp(buf, BYE, strlen(BYE)) != 0)
data/monit-5.27.1/src/protocols/lmtp.c:41:39:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        if (Socket_write(socket, msg, strlen(msg)) < 0)
data/monit-5.27.1/src/protocols/mqtt.c:212: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).
        size_t dataLength = strlen(data);
data/monit-5.27.1/src/protocols/mysql.c:352:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(mysql->publicKey, _getString(&mysql->response), sizeof(mysql->publicKey) - 1);
data/monit-5.27.1/src/protocols/mysql.c:366:60:  [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).
        sha1_append(&ctx, (const unsigned char *)password, strlen(password));
data/monit-5.27.1/src/protocols/mysql.c:376: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).
        sha1_append(&ctx, (const unsigned char *)salt, strlen(salt));
data/monit-5.27.1/src/protocols/mysql.c:391: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).
        SHA256((const unsigned char *)password, strlen(password), stage1);
data/monit-5.27.1/src/protocols/mysql.c:402: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).
        SHA256_Update(&ctx, salt, strlen(salt));
data/monit-5.27.1/src/protocols/mysql.c:571:83:  [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).
                _setData(&mysql->request, mysql->port->parameters.mysql.username, strlen(mysql->port->parameters.mysql.username)); // username
data/monit-5.27.1/src/protocols/mysql.c:582:86:  [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).
                _setData(&mysql->request, mysql->response.data.handshake.authplugin, strlen(mysql->response.data.handshake.authplugin) + 1); // auth plugin
data/monit-5.27.1/src/protocols/mysql.c:645: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).
        size_t saltLength = strlen(mysql->salt);
data/monit-5.27.1/src/protocols/mysql.c:646: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).
        size_t passwordLength = strlen(mysql->port->parameters.mysql.password) + 1; // Include the terminating NUL
data/monit-5.27.1/src/protocols/mysql.c:675: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).
        Checksum_append(&context, mysql->publicKey, (int)strlen(mysql->publicKey));
data/monit-5.27.1/src/protocols/mysql.c:755:116:  [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).
                                _sendPassword(&mysql, (unsigned char *)mysql.port->parameters.mysql.password, (int)strlen(mysql.port->parameters.mysql.password) + 1);
data/monit-5.27.1/src/protocols/pop.c:53:34:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        if (strncasecmp(buf, ok, strlen(ok)) != 0)
data/monit-5.27.1/src/protocols/pop.c:62:34:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        if (strncasecmp(buf, ok, strlen(ok)) != 0)
data/monit-5.27.1/src/protocols/postfix_policy.c:77:14:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        if ((strlen(buf) <= 7) || strncasecmp(buf, "action=", 7))
data/monit-5.27.1/src/protocols/radius.c:126: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).
        secret_len = (int)strlen(secret);
data/monit-5.27.1/src/protocols/rsync.c:56:14:  [1] (buffer) sscanf:
  It's unclear if the %s limit in the format string is small enough
  (CWE-120). Check that the limit is sufficiently small, or use a different
  input function.
        rc = sscanf(buf, "%10s %d.%d", header, &version_major, &version_minor);
data/monit-5.27.1/src/protocols/rsync.c:59:41:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        if (strncasecmp(header, rsyncd, strlen(rsyncd)) != 0)
data/monit-5.27.1/src/protocols/rsync.c:75: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).
        } while (strncasecmp(buf, rsyncd, strlen(rsyncd)));
data/monit-5.27.1/src/protocols/rsync.c:76: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).
        if (strncasecmp(buf, rsyncd_exit, strlen(rsyncd_exit)) != 0)
data/monit-5.27.1/src/protocols/ssh.c:56:39:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        if (Socket_write(socket, buf, strlen(buf)) <= 0)
data/monit-5.27.1/src/ssl/Ssl.c:801: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(b + strlen(b), size - strlen(b) - 1, "version: ");
data/monit-5.27.1/src/ssl/Ssl.c:801: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).
                        snprintf(b + strlen(b), size - strlen(b) - 1, "version: ");
data/monit-5.27.1/src/ssl/Ssl.c:803: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).
                                snprintf(b + strlen(b), size - strlen(b) - 1, "%sSSLv2", versions++ ? " " : "");
data/monit-5.27.1/src/ssl/Ssl.c:803:64:  [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(b + strlen(b), size - strlen(b) - 1, "%sSSLv2", versions++ ? " " : "");
data/monit-5.27.1/src/ssl/Ssl.c:805: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).
                                snprintf(b + strlen(b), size - strlen(b) - 1, "%sSSLv3", versions++ ? " " : "");
data/monit-5.27.1/src/ssl/Ssl.c:805:64:  [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(b + strlen(b), size - strlen(b) - 1, "%sSSLv3", versions++ ? " " : "");
data/monit-5.27.1/src/ssl/Ssl.c:807: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).
                                snprintf(b + strlen(b), size - strlen(b) - 1, "%sTLSv1.0", versions++ ? " " : "");
data/monit-5.27.1/src/ssl/Ssl.c:807:64:  [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(b + strlen(b), size - strlen(b) - 1, "%sTLSv1.0", versions++ ? " " : "");
data/monit-5.27.1/src/ssl/Ssl.c:809: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).
                                snprintf(b + strlen(b), size - strlen(b) - 1, "%sTLSv1.1", versions++ ? " " : "");
data/monit-5.27.1/src/ssl/Ssl.c:809:64:  [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(b + strlen(b), size - strlen(b) - 1, "%sTLSv1.1", versions++ ? " " : "");
data/monit-5.27.1/src/ssl/Ssl.c:811: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).
                                snprintf(b + strlen(b), size - strlen(b) - 1, "%sTLSv1.2", versions++ ? " " : "");
data/monit-5.27.1/src/ssl/Ssl.c:811:64:  [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(b + strlen(b), size - strlen(b) - 1, "%sTLSv1.2", versions++ ? " " : "");
data/monit-5.27.1/src/ssl/Ssl.c:813: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).
                                snprintf(b + strlen(b), size - strlen(b) - 1, "%sTLSv1.3", versions++ ? " " : "");
data/monit-5.27.1/src/ssl/Ssl.c:813:64:  [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(b + strlen(b), size - strlen(b) - 1, "%sTLSv1.3", versions++ ? " " : "");
data/monit-5.27.1/src/ssl/Ssl.c:817: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(b + strlen(b), size - strlen(b) - 1, "%sverify: enable", count++ ? ", " : "");
data/monit-5.27.1/src/ssl/Ssl.c:817: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).
                        snprintf(b + strlen(b), size - strlen(b) - 1, "%sverify: enable", count++ ? ", " : "");
data/monit-5.27.1/src/ssl/Ssl.c:819: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(b + strlen(b), size - strlen(b) - 1, "%sselfsigned: allow", count++ ? ", " : "");
data/monit-5.27.1/src/ssl/Ssl.c:819: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).
                        snprintf(b + strlen(b), size - strlen(b) - 1, "%sselfsigned: allow", count++ ? ", " : "");
data/monit-5.27.1/src/ssl/Ssl.c:821: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(b + strlen(b), size - strlen(b) - 1, "%spemfile: %s", count ++ ? ", " : "", options->pemfile);
data/monit-5.27.1/src/ssl/Ssl.c:821: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).
                        snprintf(b + strlen(b), size - strlen(b) - 1, "%spemfile: %s", count ++ ? ", " : "", options->pemfile);
data/monit-5.27.1/src/ssl/Ssl.c:823: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(b + strlen(b), size - strlen(b) - 1, "%spemchain: %s", count ++ ? ", " : "", options->pemchain);
data/monit-5.27.1/src/ssl/Ssl.c:823: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).
                        snprintf(b + strlen(b), size - strlen(b) - 1, "%spemchain: %s", count ++ ? ", " : "", options->pemchain);
data/monit-5.27.1/src/ssl/Ssl.c:825: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(b + strlen(b), size - strlen(b) - 1, "%spemkey: %s", count ++ ? ", " : "", options->pemkey);
data/monit-5.27.1/src/ssl/Ssl.c:825: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).
                        snprintf(b + strlen(b), size - strlen(b) - 1, "%spemkey: %s", count ++ ? ", " : "", options->pemkey);
data/monit-5.27.1/src/ssl/Ssl.c:827: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(b + strlen(b), size - strlen(b) - 1, "%sclientpemfile: %s", count ++ ? ", " : "", options->clientpemfile);
data/monit-5.27.1/src/ssl/Ssl.c:827: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).
                        snprintf(b + strlen(b), size - strlen(b) - 1, "%sclientpemfile: %s", count ++ ? ", " : "", options->clientpemfile);
data/monit-5.27.1/src/ssl/Ssl.c:829: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(b + strlen(b), size - strlen(b) - 1, "%sCACertificateFile: %s", count ++ ? ", " : "", options->CACertificateFile);
data/monit-5.27.1/src/ssl/Ssl.c:829: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).
                        snprintf(b + strlen(b), size - strlen(b) - 1, "%sCACertificateFile: %s", count ++ ? ", " : "", options->CACertificateFile);
data/monit-5.27.1/src/ssl/Ssl.c:831: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(b + strlen(b), size - strlen(b) - 1, "%sCACertificatePath: %s", count ++ ? ", " : "", options->CACertificatePath);
data/monit-5.27.1/src/ssl/Ssl.c:831: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).
                        snprintf(b + strlen(b), size - strlen(b) - 1, "%sCACertificatePath: %s", count ++ ? ", " : "", options->CACertificatePath);
data/monit-5.27.1/src/ssl/Ssl.c:833: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(b + strlen(b), size - strlen(b) - 1, "%sciphers: \"%s\"", count ++ ? ", " : "", options->ciphers);
data/monit-5.27.1/src/ssl/Ssl.c:833: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).
                        snprintf(b + strlen(b), size - strlen(b) - 1, "%sciphers: \"%s\"", count ++ ? ", " : "", options->ciphers);
data/monit-5.27.1/src/state.c:311:17:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                strncpy(S->checksum->hash, hash, sizeof(S->checksum->hash) - 1);
data/monit-5.27.1/src/state.c:326:13:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        if (read(file, &booted, sizeof(booted)) != sizeof(booted)) {
data/monit-5.27.1/src/state.c:331:16:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        while (read(file, &state, sizeof(state)) == sizeof(state)) {
data/monit-5.27.1/src/state.c:373:13:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        if (read(file, &booted, sizeof(booted)) != sizeof(booted)) {
data/monit-5.27.1/src/state.c:378:16:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        while (read(file, &state, sizeof(state)) == sizeof(state)) {
data/monit-5.27.1/src/state.c:420:16:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        while (read(file, &state, sizeof(state)) == sizeof(state)) {
data/monit-5.27.1/src/state.c:462:16:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        while (read(file, &state, sizeof(state)) == sizeof(state)) {
data/monit-5.27.1/src/state.c:480:21:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                if (read(file, &state, sizeof(state)) != sizeof(state))
data/monit-5.27.1/src/state.c:624:21:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                if (read(file, &magic, sizeof(magic)) != sizeof(magic)) {
data/monit-5.27.1/src/state.c:633:29:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        if (read(file, &version, sizeof(version)) != sizeof(version)) {
data/monit-5.27.1/src/terminal/Box.c:162:70:  [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 (! t->columns[i].value || t->columns[i]._cursor > strlen(t->columns[i].value) - 1) {
data/monit-5.27.1/src/terminal/Box.c:165: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).
                } else if (strlen(t->columns[i].value + t->columns[i]._cursor) > (unsigned long)t->columns[i].width) {
data/monit-5.27.1/src/terminal/Box.c:252:51:  [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).
                t->columns[_index]._valueLength = strlen(t->columns[_index].value);
data/monit-5.27.1/src/util.c:453: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).
                size_t l = strlen(old);
data/monit-5.27.1/src/util.c:454: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).
                size_t d = strlen(new) - l;
data/monit-5.27.1/src/util.c:460: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).
                char *buf = CALLOC(sizeof(char), strlen(*src) + d + 1);
data/monit-5.27.1/src/util.c:1359:21:  [1] (buffer) fscanf:
  It's unclear if the %s limit in the format string is small enough
  (CWE-120). Check that the limit is sufficiently small, or use a different
  input function.
                if (fscanf(file, "%64s", Run.id) != 1) {
data/monit-5.27.1/src/util.c:1469:36:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        if (! (b64 = encode_base64(strlen(buf), (unsigned char *)buf)) ) {
data/monit-5.27.1/src/util.c:1520:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(outside_crypt, outside, sizeof(outside_crypt) - 1);
data/monit-5.27.1/src/util.c:1532:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(id, c->passwd, sizeof(id) - 1);
data/monit-5.27.1/src/util.c:1540:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(salt, c->passwd + strlen(id), sizeof(salt) - 1);
data/monit-5.27.1/src/util.c:1540:51:  [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).
                        strncpy(salt, c->passwd + strlen(id), sizeof(salt) - 1);
data/monit-5.27.1/src/util.c:1559:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(outside_crypt, temp, sizeof(outside_crypt) - 1);
data/monit-5.27.1/src/util.c:1601:65:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        _resetIOStatistics(&(s->inf.filesystem->read));
data/monit-5.27.1/src/util.c:1603:68:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        Statistics_reset(&(s->inf.filesystem->time.read));
data/monit-5.27.1/src/util.c:1658:62:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        _resetIOStatistics(&(s->inf.process->read));
data/monit-5.27.1/src/util.c:1791: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).
        while (strlen(actionnames[i])) {
data/monit-5.27.1/src/validate.c:343:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        if (Statistics_initialized(&(s->inf.process->read.bytes))) {
data/monit-5.27.1/src/validate.c:344:92:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                double value = Statistics_deltaNormalize(&(s->inf.process->read.bytes));
data/monit-5.27.1/src/validate.c:358:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        if (Statistics_initialized(&(s->inf.process->read.bytesPhysical))) {
data/monit-5.27.1/src/validate.c:359:92:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                double value = Statistics_deltaNormalize(&(s->inf.process->read.bytesPhysical));
data/monit-5.27.1/src/validate.c:373:70:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        if (Statistics_initialized(&(s->inf.process->read.operations))) {
data/monit-5.27.1/src/validate.c:374:92:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                double value = Statistics_deltaNormalize(&(s->inf.process->read.operations));
data/monit-5.27.1/src/validate.c:1104:41:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
                        size_t length = strlen(line);
data/monit-5.27.1/src/validate.c:1117:60:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                                if ((_rv = fgetc(file)) == EOF)
data/monit-5.27.1/src/validate.c:1290:73:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        if (Statistics_initialized(&(s->inf.filesystem->read.bytes))) {
data/monit-5.27.1/src/validate.c:1291:95:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                double value = Statistics_deltaNormalize(&(s->inf.filesystem->read.bytes));
data/monit-5.27.1/src/validate.c:1303:73:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                        if (Statistics_initialized(&(s->inf.filesystem->read.operations))) {
data/monit-5.27.1/src/validate.c:1304:95:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                double value = Statistics_deltaNormalize(&(s->inf.filesystem->read.operations));
data/monit-5.27.1/src/validate.c:1344:101:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                bool hasReadTime = Statistics_initialized(&(s->inf.filesystem->time.read));
data/monit-5.27.1/src/validate.c:1354:97:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                        deltaTime += Statistics_delta(&(s->inf.filesystem->time.read));
data/monit-5.27.1/src/validate.c:1365:96:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
                                double deltaOperations = Statistics_delta(&(s->inf.filesystem->read.operations)) + Statistics_delta(&(s->inf.filesystem->write.operations));
data/monit-5.27.1/src/y.tab.c:2869: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).
#   define yystrlen strlen
data/monit-5.27.1/src/y.tab.c:8228:25:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                        strncpy(program, s->program->args->arg[0], sizeof(program) - 1);
data/monit-5.27.1/src/y.tab.c:8234:60:  [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(program + strlen(program), sizeof(program) - strlen(program) - 1, " %s", s->program->args->arg[i]);
data/monit-5.27.1/src/y.tab.c:8234:95:  [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(program + strlen(program), sizeof(program) - strlen(program) - 1, " %s", s->program->args->arg[i]);
data/monit-5.27.1/src/y.tab.c:8406: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).
                        if (strlen(p->parameters.http.checksum) == 32)
data/monit-5.27.1/src/y.tab.c:8408: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).
                        else if (strlen(p->parameters.http.checksum) == 40)
data/monit-5.27.1/src/y.tab.c:8866: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).
                size_t len = strlen(buf);
data/monit-5.27.1/src/y.tab.c:9436:13:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        if (strlen(passwd) > Str_compareConstantTimeStringLength) {

ANALYSIS SUMMARY:

Hits = 918
Lines analyzed = 68560 in approximately 2.12 seconds (32399 lines/second)
Physical Source Lines of Code (SLOC) = 48269
Hits@level = [0] 1005 [1] 343 [2] 441 [3]  21 [4] 109 [5]   4
Hits@level+ = [0+] 1923 [1+] 918 [2+] 575 [3+] 134 [4+] 113 [5+]   4
Hits/KSLOC@level+ = [0+] 39.8392 [1+] 19.0184 [2+] 11.9124 [3+] 2.77611 [4+] 2.34105 [5+] 0.0828689
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.