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/trace-cmd-2.9.1/include/linux/time64.h
Examining data/trace-cmd-2.9.1/include/trace-cmd/trace-cmd.h
Examining data/trace-cmd-2.9.1/include/trace-cmd/trace-filter-hash.h
Examining data/trace-cmd-2.9.1/include/trace-cmd/trace-hash.h
Examining data/trace-cmd-2.9.1/include/trace-cmd/trace-msg.h
Examining data/trace-cmd-2.9.1/include/traceevent/event-parse.h
Examining data/trace-cmd-2.9.1/include/traceevent/kbuffer.h
Examining data/trace-cmd-2.9.1/include/traceevent/trace-seq.h
Examining data/trace-cmd-2.9.1/include/tracefs/tracefs.h
Examining data/trace-cmd-2.9.1/include/version.h
Examining data/trace-cmd-2.9.1/kernel-shark/examples/cmd_split.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/examples/configio.c
Examining data/trace-cmd-2.9.1/kernel-shark/examples/datafilter.c
Examining data/trace-cmd-2.9.1/kernel-shark/examples/datahisto.c
Examining data/trace-cmd-2.9.1/kernel-shark/examples/dataload.c
Examining data/trace-cmd-2.9.1/kernel-shark/examples/dataplot.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/examples/widgetdemo.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsAdvFilteringDialog.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsAdvFilteringDialog.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsCaptureDialog.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsCaptureDialog.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsDualMarker.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsDualMarker.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsGLWidget.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsGLWidget.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsMainWindow.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsMainWindow.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsModels.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsModels.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsPlotTools.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsPlotTools.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsPlugins.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsQuickContextMenu.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsQuickContextMenu.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsSearchFSM.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsSearchFSM.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsSession.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsSession.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsTraceGraph.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsTraceGraph.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsTraceViewer.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsTraceViewer.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsUtils.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsUtils.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsWidgetsLib.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/KsWidgetsLib.hpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/kernelshark.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/kshark-record.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/libkshark-collection.c
Examining data/trace-cmd-2.9.1/kernel-shark/src/libkshark-configio.c
Examining data/trace-cmd-2.9.1/kernel-shark/src/libkshark-model.c
Examining data/trace-cmd-2.9.1/kernel-shark/src/libkshark-model.h
Examining data/trace-cmd-2.9.1/kernel-shark/src/libkshark-plot.c
Examining data/trace-cmd-2.9.1/kernel-shark/src/libkshark-plot.h
Examining data/trace-cmd-2.9.1/kernel-shark/src/libkshark-plugin.c
Examining data/trace-cmd-2.9.1/kernel-shark/src/libkshark-plugin.h
Examining data/trace-cmd-2.9.1/kernel-shark/src/libkshark.c
Examining data/trace-cmd-2.9.1/kernel-shark/src/libkshark.h
Examining data/trace-cmd-2.9.1/kernel-shark/src/plugins/MissedEvents.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/plugins/SchedEvents.cpp
Examining data/trace-cmd-2.9.1/kernel-shark/src/plugins/missed_events.c
Examining data/trace-cmd-2.9.1/kernel-shark/src/plugins/missed_events.h
Examining data/trace-cmd-2.9.1/kernel-shark/src/plugins/sched_events.c
Examining data/trace-cmd-2.9.1/kernel-shark/src/plugins/sched_events.h
Examining data/trace-cmd-2.9.1/lib/trace-cmd/include/trace-cmd-local.h
Examining data/trace-cmd-2.9.1/lib/trace-cmd/include/trace-hash-local.h
Examining data/trace-cmd-2.9.1/lib/trace-cmd/include/trace-tsync-local.h
Examining data/trace-cmd-2.9.1/lib/trace-cmd/include/trace-write-local.h
Examining data/trace-cmd-2.9.1/lib/trace-cmd/trace-blk-hack.c
Examining data/trace-cmd-2.9.1/lib/trace-cmd/trace-filter-hash.c
Examining data/trace-cmd-2.9.1/lib/trace-cmd/trace-ftrace.c
Examining data/trace-cmd-2.9.1/lib/trace-cmd/trace-hash.c
Examining data/trace-cmd-2.9.1/lib/trace-cmd/trace-hooks.c
Examining data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c
Examining data/trace-cmd-2.9.1/lib/trace-cmd/trace-msg.c
Examining data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c
Examining data/trace-cmd-2.9.1/lib/trace-cmd/trace-plugin.c
Examining data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c
Examining data/trace-cmd-2.9.1/lib/trace-cmd/trace-timesync.c
Examining data/trace-cmd-2.9.1/lib/trace-cmd/trace-util.c
Examining data/trace-cmd-2.9.1/lib/traceevent/event-parse-api.c
Examining data/trace-cmd-2.9.1/lib/traceevent/event-parse-local.h
Examining data/trace-cmd-2.9.1/lib/traceevent/event-parse.c
Examining data/trace-cmd-2.9.1/lib/traceevent/event-plugin.c
Examining data/trace-cmd-2.9.1/lib/traceevent/include/event-utils.h
Examining data/trace-cmd-2.9.1/lib/traceevent/kbuffer-parse.c
Examining data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c
Examining data/trace-cmd-2.9.1/lib/traceevent/parse-utils.c
Examining data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_blk.c
Examining data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_cfg80211.c
Examining data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_function.c
Examining data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_futex.c
Examining data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_hrtimer.c
Examining data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_jbd2.c
Examining data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_kmem.c
Examining data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_kvm.c
Examining data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_mac80211.c
Examining data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_python_loader.c
Examining data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_sched_switch.c
Examining data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_scsi.c
Examining data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_tlb.c
Examining data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_xen.c
Examining data/trace-cmd-2.9.1/lib/traceevent/tep_strerror.c
Examining data/trace-cmd-2.9.1/lib/traceevent/trace-seq.c
Examining data/trace-cmd-2.9.1/lib/tracefs/include/tracefs-local.h
Examining data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c
Examining data/trace-cmd-2.9.1/lib/tracefs/tracefs-instance.c
Examining data/trace-cmd-2.9.1/lib/tracefs/tracefs-utils.c
Examining data/trace-cmd-2.9.1/tracecmd/include/bug.h
Examining data/trace-cmd-2.9.1/tracecmd/include/list.h
Examining data/trace-cmd-2.9.1/tracecmd/include/trace-local.h
Examining data/trace-cmd-2.9.1/tracecmd/trace-agent.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-check-events.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-cmd.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-dump.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-hist.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-list.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-listen.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-mem.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-profile.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-read.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-record.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-restore.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-show.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-snapshot.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-split.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-stack.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-stat.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-stream.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-tsync.c
Examining data/trace-cmd-2.9.1/tracecmd/trace-usage.c
Examining data/trace-cmd-2.9.1/utest/trace-utest.c
Examining data/trace-cmd-2.9.1/utest/trace-utest.h
Examining data/trace-cmd-2.9.1/utest/tracefs-utest.c

FINAL RESULTS:

data/trace-cmd-2.9.1/lib/trace-cmd/trace-plugin.c:198:8:  [5] (race) readlink:
  This accepts filename arguments; if an attacker can move those files or
  change the link content, a race condition results. Also, it does not
  terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach.
	ret = readlink("/proc/self/exe", path, PATH_MAX);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-util.c:268:8:  [5] (race) readlink:
  This accepts filename arguments; if an attacker can move those files or
  change the link content, a race condition results. Also, it does not
  terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach.
	ret = readlink("/proc/self/exe", path, PATH_MAX);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1101:8:  [5] (race) readlink:
  This accepts filename arguments; if an attacker can move those files or
  change the link content, a race condition results. Also, it does not
  terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach.
	ret = readlink(fname, mapname, PATH_MAX);
data/trace-cmd-2.9.1/include/traceevent/event-parse.h:277:10:  [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.
	char			*system;
data/trace-cmd-2.9.1/include/traceevent/event-parse.h:460:26:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	__attribute__ ((format (printf, 4, 5)));
data/trace-cmd-2.9.1/include/traceevent/trace-seq.h:43:26:  [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/trace-cmd-2.9.1/include/traceevent/trace-seq.h:45:26:  [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/trace-cmd-2.9.1/include/tracefs/tracefs.h:42:67:  [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.
char **tracefs_system_events(const char *tracing_dir, const char *system);
data/trace-cmd-2.9.1/kernel-shark/examples/datafilter.c:93:21:  [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 (strcmp(event->system, "sched") == 0)
data/trace-cmd-2.9.1/kernel-shark/src/KsAdvFilteringDialog.cpp:165:30:  [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.
		QString sysName(events[i]->system);
data/trace-cmd-2.9.1/kernel-shark/src/KsAdvFilteringDialog.cpp:167: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.
		while (sysName == events[i]->system) {
data/trace-cmd-2.9.1/kernel-shark/src/KsAdvFilteringDialog.cpp:219:40:  [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.
				QString("%1/%2:%3").arg(events[i]->system,
data/trace-cmd-2.9.1/kernel-shark/src/KsAdvFilteringDialog.cpp:290:29:  [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 (sysName == events[i]->system)
data/trace-cmd-2.9.1/kernel-shark/src/KsAdvFilteringDialog.cpp:334:29:  [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.
		    sysName == events[i]->system) {
data/trace-cmd-2.9.1/kernel-shark/src/KsAdvFilteringDialog.cpp:420:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy(filter, text);
data/trace-cmd-2.9.1/kernel-shark/src/KsTraceGraph.cpp:288:10:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
	pointer.sprintf("%" PRIu64 ".%06" PRIu64 "", sec, usec);
data/trace-cmd-2.9.1/kernel-shark/src/KsTraceGraph.cpp:324:10:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
	pointer.sprintf("%" PRIu64 ".%06" PRIu64 "", sec, usec);
data/trace-cmd-2.9.1/kernel-shark/src/KsTraceGraph.cpp:612:7:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
	tMin.sprintf("%" PRIu64 ".%06" PRIu64 "", sec, usec);
data/trace-cmd-2.9.1/kernel-shark/src/KsTraceGraph.cpp:618:7:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
	tMid.sprintf("%" PRIu64 ".%06" PRIu64 "", sec, usec);
data/trace-cmd-2.9.1/kernel-shark/src/KsTraceGraph.cpp:622:7:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
	tMax.sprintf("%" PRIu64 ".%06" PRIu64 "", sec, usec);
data/trace-cmd-2.9.1/kernel-shark/src/KsWidgetsLib.cpp:681: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.
		sysName = events[i]->system;
data/trace-cmd-2.9.1/kernel-shark/src/KsWidgetsLib.cpp:687: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.
		while (sysName == events[i]->system) {
data/trace-cmd-2.9.1/kernel-shark/src/libkshark-configio.c:726: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.
				temp = event->system;
data/trace-cmd-2.9.1/kernel-shark/src/libkshark-configio.c:1058:47:  [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.
		jsystem = json_object_new_string(events[i]->system);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-blk-hack.c:126:6:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
	r = sprintf(buf, blk_event_start, id);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-blk-hack.c:138:6:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
	r = sprintf(buf+l, blk_body);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-hooks.c:82:23:  [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.
	hook->start_system = system;
data/trace-cmd-2.9.1/lib/trace-cmd/trace-hooks.c:117:21:  [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.
	hook->end_system = system;
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:457:13:  [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.
			   char *system, unsigned long long size,
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:476:30:  [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.
				printf("\nsystem: %s\n", system);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:482:42:  [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 (tep_parse_event(pevent, buf, size, system))
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:490:56:  [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.
static int make_preg_files(const char *regex, regex_t *system,
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:516:16:  [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.
	ret = regcomp(system, sstr, REG_ICASE|REG_NOSUB);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:597:8:  [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.
	char *system;
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:624:8:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
		if (!system)
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:632:22:  [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 (regexec(sreg, system, 0, NULL, 0) == 0) {
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:659:34:  [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.
			ret = read_event_file(handle, system, size,
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:665:8:  [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.
		free(system);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:681:7:  [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.
	free(system);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:2382:9:  [4] (buffer) sscanf:
  The scanf() family's %s operation, without a limit specification, permits
  buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a
  different input function.
		res = sscanf(buf, "%llx %llx %s", &maps->lib_maps[i].start,
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:3471:8:  [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.
	char *system;
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:3481:8:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
		if (!system)
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:3483:28:  [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 (__do_write_check(fd, system, strlen(system) + 1)) {
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:3483:43:  [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 (__do_write_check(fd, system, strlen(system) + 1)) {
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:3484:9:  [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.
			free(system);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:3487:8:  [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.
		free(system);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-msg.c:42:2:  [4] (format) vprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	vprintf(fmt, ap);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:420: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.
				  const char *system,
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:428: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.
		if (strcmp(slist->name, system) == 0)
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:435: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.
		slist->name = strdup(system);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:495:8:  [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.
	char *system;
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:516:2:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
	strcat(path, events_path);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:518:2:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
	strcat(path, str);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:531:21:  [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.
		system = strtok_r(system, "/", &ptr);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:534:9:  [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.
			free(system);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:538:28:  [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 (!do_ftrace && strcmp(system, "ftrace") == 0) {
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:539:9:  [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.
			free(system);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:546:9:  [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.
			free(system);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:550:34:  [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.
		add_list_event_system(systems, system, event, file);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:551:8:  [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.
		free(system);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:587:2:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
	strcat(str, ptr);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:593:2:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
	strcat(str, ptr);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:1193:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy(buf + 8, name);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:251:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(file2, "%s.1", file);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-util.c:316:2:  [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, fmt, ap);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-util.c:357:6:  [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.
	r = vsnprintf(buf, LOG_BUF_SIZE, fmt, ap);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:51:35:  [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.
			warning("[%s:%s] " fmt, event->system,	\
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:994:3:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
		strcpy(newtok, buf);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:996:3:  [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(newtok, buf);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:1435:2:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
	strcat(new_buf, delim);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:1436:2:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
	strcat(new_buf, str);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:3633:39:  [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.
	    (!sys || strcmp(tep->last_event->system, sys) == 0))
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:3641:22:  [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 (strcmp(event->system, sys) == 0)
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6317:22:  [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.
	res = strcmp((*ea)->system, (*eb)->system);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6317:37:  [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.
	res = strcmp((*ea)->system, (*eb)->system);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6330:22:  [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.
	res = strcmp((*ea)->system, (*eb)->system);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6330:37:  [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.
	res = strcmp((*ea)->system, (*eb)->system);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6757:43:  [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 (sys_name && (strcmp(sys_name, event->system) != 0))
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6787:21:  [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->id, event->system, event->name);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6849:14:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	if (!event->system) {
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6915:14:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	free(event->system);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:7357:44:  [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 (sys_name && (strcmp(sys_name, event->system) != 0))
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:7402:21:  [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->id, event->system, event->name);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:7488:22:  [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->id, event->system, event->name);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:7568:14:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	free(event->system);
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:46:3:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
		strcpy(error_buf, input);
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:56:2:  [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(error_buf + len, TEP_FILTER_ERROR_BUFSZ - len, fmt, ap);
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:250: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.
		return !regexec(sreg, event->system, 0, NULL, 0) &&
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:254: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.
	return !regexec(ereg, event->system, 0, NULL, 0) ||
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:1465:28:  [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.
	sys = filter_type->event->system;
data/trace-cmd-2.9.1/lib/traceevent/parse-utils.c:23:2:  [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, fmt, ap);
data/trace-cmd-2.9.1/lib/traceevent/parse-utils.c:43:2:  [4] (format) vprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	vprintf(fmt, ap);
data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_kvm.c:367:12:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
		unsigned access:3;
data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_kvm.c:402:22:  [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.
				 access_str[role.access],
data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_python_loader.c:38:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy(full, path);
data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_python_loader.c:40:2:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
	strcat(full, name);
data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_python_loader.c:42:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy(n, name);
data/trace-cmd-2.9.1/lib/traceevent/trace-seq.c:125:8:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
	ret = vsnprintf(s->buffer + s->len, len, fmt, ap);
data/trace-cmd-2.9.1/lib/traceevent/trace-seq.c:165:8:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
	ret = vsnprintf(s->buffer + s->len, len, fmt, args);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:168:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(file, "%s/%s", path, name);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:173:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(file, "%s/%s/trace_pipe_raw", path, name);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:326:67:  [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.
char **tracefs_system_events(const char *tracing_dir, const char *system)
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:339:23:  [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 (!tracing_dir || !system)
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:342:53:  [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.
	asprintf(&system_dir, "%s/events/%s", tracing_dir, system);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:445:47:  [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.
		       const char *tracing_dir, const char *system)
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:453:46:  [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.
	events = tracefs_system_events(tracing_dir, system);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:462: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.
			       tracing_dir, system, events[i]);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:476:40:  [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.
		ret = tep_parse_event(tep, buf, len, system);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-utils.c:109:5:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
				strcpy(fspath, DEBUGFS_PATH);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-utils.c:113:4:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
			strcpy(fspath, TRACEFS_PATH);
data/trace-cmd-2.9.1/tracecmd/include/trace-local.h:157:39:  [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.
					   const char *path, const char *system);
data/trace-cmd-2.9.1/tracecmd/trace-agent.c:110:3:  [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(path, sizeof(path), VIRTIO_FIFO_FMT, i);
data/trace-cmd-2.9.1/tracecmd/trace-cmd.c:32:2:  [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, fmt, ap);
data/trace-cmd-2.9.1/tracecmd/trace-cmd.c:46:2:  [4] (format) vprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	vprintf(fmt, ap);
data/trace-cmd-2.9.1/tracecmd/trace-hist.c:835:4:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
			printf(LINE);
data/trace-cmd-2.9.1/tracecmd/trace-hist.c:837:4:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
			printf(INDENT);
data/trace-cmd-2.9.1/tracecmd/trace-hist.c:846:2:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	printf(BLANK);
data/trace-cmd-2.9.1/tracecmd/trace-hist.c:925:3:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		printf(START);
data/trace-cmd-2.9.1/tracecmd/trace-hist.c:927:4:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
			printf(TICK "*%s*\n", chain->func);
data/trace-cmd-2.9.1/tracecmd/trace-hist.c:929:4:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
			printf(TICK "%s\n", chain->func);
data/trace-cmd-2.9.1/tracecmd/trace-list.c:82:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy(str, re);
data/trace-cmd-2.9.1/tracecmd/trace-list.c:120:8:  [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.
	char *system;
data/trace-cmd-2.9.1/tracecmd/trace-list.c:130:7:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	if (!system)
data/trace-cmd-2.9.1/tracecmd/trace-list.c:138:45:  [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.
	ret = asprintf(&file, "%s/%s/%s/%s", path, system, event, type);
data/trace-cmd-2.9.1/tracecmd/trace-list.c:140:46:  [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.
		die("Failed to allocate event file %s %s", system, event);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:58:9:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
	size = snprintf(file, 0, TEMP_FILE_STR);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:62:2:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
	sprintf(file, TEMP_FILE_STR);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:87:2:  [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(file, PATH_MAX, TEMP_FILE_STR);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:124:2:  [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, PATH_MAX, VAR_RUN_DIR "/trace-cmd-net.pid");
data/trace-cmd-2.9.1/tracecmd/trace-profile.c:795:46:  [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.
add_event(struct handle_data *h, const char *system, const char *event_name,
data/trace-cmd-2.9.1/tracecmd/trace-profile.c:801:44:  [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 = tep_find_event_by_name(h->pevent, system, event_name);
data/trace-cmd-2.9.1/tracecmd/trace-profile.c:890:36:  [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.
	start = add_event(h, start_event->system, start_event->name,
data/trace-cmd-2.9.1/tracecmd/trace-profile.c:893: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.
	end = add_event(h, end_event->system, end_event->name,
data/trace-cmd-2.9.1/tracecmd/trace-profile.c:1497:40:  [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_data = add_event(h, events[i]->system, events[i]->name,
data/trace-cmd-2.9.1/tracecmd/trace-read.c:458:3:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
		sprintf(filter, ".*:" FILTER_FMT, pid, pid, pid);
data/trace-cmd-2.9.1/tracecmd/trace-read.c:466:3:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
		sprintf(filter + curr_len, "||" FILTER_FMT, pid, pid, pid);
data/trace-cmd-2.9.1/tracecmd/trace-read.c:1438:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(match, "^%s$", str->event);
data/trace-cmd-2.9.1/tracecmd/trace-read.c:1447: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.
			    !regexec(&regex, event->system, 0, NULL, 0))
data/trace-cmd-2.9.1/tracecmd/trace-read.c:1830:16:  [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 (event->system)
data/trace-cmd-2.9.1/tracecmd/trace-read.c:1831: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.
					printf("%s:", event->system);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:522:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(file, "%s.%s.cpu%d", output_file, name, cpu);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:528:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(file, "%s.cpu%d", output_file, cpu);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:616:2:  [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, fmt, ap);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:987:9:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
		len = snprintf(NULL, 0, FMT, op,
data/trace-cmd-2.9.1/tracecmd/trace-record.c:993:9:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
		len = snprintf(*filter + *curr_len, len + 1, FMT, op,
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1012:8:  [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.
	len = snprintf(NULL, 0, FMT, op,
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1019:8:  [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.
	len = snprintf(*filter + *curr_len, len + 1, FMT, op,
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1340:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(filter, "(%s==%d)", field, pid);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1348:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(filter + indx, "||(%s==%d)", field, pid);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1626:7:  [4] (shell) execvp:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
		if (execvp(argv[0], argv)) {
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2530:6:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
					sprintf(event_filter, "(%s)&&(%s||%s)",
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2540:6:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
					sprintf(event_filter, "(%s)&&(%s)",
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2555:6:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
					sprintf(event_filter, "%s||%s",
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3834:3:  [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(path, sizeof(path), GUEST_FIFO_FMT ".out", guest, i);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4111:2:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
	strcpy(p, guest->name);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4216:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(str, "%s %s %s %s", buf.sysname, buf.nodename, buf.release, buf.machine);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4759: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.
	path = append_file(path, system);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4784:8:  [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.
	char *system;
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4796:51:  [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.
	while ((type = trace_event_iter_next(iter, path, system))) {
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4819:53:  [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.
			while ((type = trace_event_iter_next(iter, path, system))) {
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4849: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.
	path = append_file(path, system);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4873:8:  [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.
	char *system;
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4885:51:  [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.
	while ((type = trace_event_iter_next(iter, path, system))) {
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5336:3:  [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(event->trigger, trigger);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5473:17:  [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.
		  const char *system, const char *event)
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5479:7:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	if (!system)
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5483:16:  [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.
	len += strlen(system) + 2;
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5487:35:  [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.
		die("Failed to allocate %s/%s", system, event);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5488:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(event_name, "%s:%s", system, event);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5488: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.
	sprintf(event_name, "%s:%s", system, event);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5948:5:  [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(last_event->filter, optarg);
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:59:2:  [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(path, sizeof(path), GUEST_DIR_FMT, guest);
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:70:3:  [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(path, sizeof(path), GUEST_FIFO_FMT "%s",
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:103:2:  [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(cmd, sizeof(cmd), cmd_fmt, guest);
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:104:6:  [4] (shell) popen:
  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.
	f = popen(cmd, "r");
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:133:3:  [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(path, sizeof(path), GUEST_FIFO_FMT, guest, i);
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:134:3:  [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(xml, sizeof(xml), xml_fmt, path, GUEST_PIPE_NAME, i);
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:137:3:  [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(cmd, sizeof(cmd), cmd_fmt, guest, tmp_path);
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:139:7:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
		if (system(cmd) != 0) {
data/trace-cmd-2.9.1/tracecmd/trace-split.c:534:4:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
			sprintf(output_file, "%s.%04d", output, c++);
data/trace-cmd-2.9.1/tracecmd/trace-split.c:536:4:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
			strcpy(output_file, output);
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:204:78:  [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.
trace_event_iter_next(struct event_iter *iter, const char *path, const char *system)
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:208:6:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	if (system && !iter->event_dir) {
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:212:29:  [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 = append_file(path, system);
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:288: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.
	file = append_file(path, system);
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:311:46:  [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.
process_event_enable(char *path, const char *system, const char *name,
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:319:6:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	if (system)
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:320:28:  [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.
		path = append_file(path, system);
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:324:6:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
	if (system)
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:337:8:  [4] (shell) system:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
		if (!system) {
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:348: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.
				printf("    %s\n", system);
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:367:8:  [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.
	char *system;
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:406:51:  [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.
	while ((type = trace_event_iter_next(iter, path, system))) {
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:443: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.
	path = append_file(path, system);
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:465:30:  [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.
	printf( "  %s:%s \"%s\"\n", system, event, cont);
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:478:8:  [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.
	char *system;
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:490:51:  [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.
	while ((type = trace_event_iter_next(iter, path, system))) {
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:516: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.
	path = append_file(path, system);
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:538:30:  [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.
	printf( "  %s:%s \"%s\"\n", system, event, cont);
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:551:8:  [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.
	char *system;
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:563:51:  [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.
	while ((type = trace_event_iter_next(iter, path, system))) {
data/trace-cmd-2.9.1/tracecmd/trace-usage.c:412:3:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		printf(help->long_help, p);
data/trace-cmd-2.9.1/utest/tracefs-utest.c:370:61:  [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.
static void test_check_events(struct tep_handle *tep, char *system, bool exist)
data/trace-cmd-2.9.1/utest/tracefs-utest.c:383:40:  [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.
	asprintf(&edir, "%s/events/%s", tdir, system);
data/trace-cmd-2.9.1/utest/tracefs-utest.c:390:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(file, "%s/%s/id", edir, dent->d_name);
data/trace-cmd-2.9.1/kernel-shark/examples/dataplot.cpp:153:14:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt(argc, argv, "hsi:")) != -1) {
data/trace-cmd-2.9.1/kernel-shark/examples/widgetdemo.cpp:63:14:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt(argc, argv, "hvi:p:u:")) != -1) {
data/trace-cmd-2.9.1/kernel-shark/src/KsMainWindow.cpp:470:8:  [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.
	dir = getenv("KS_USER_CACHE_DIR");
data/trace-cmd-2.9.1/kernel-shark/src/KsMainWindow.cpp:1082:6:  [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(fileName.toStdString().c_str(), buff)) {
data/trace-cmd-2.9.1/kernel-shark/src/kernelshark.cpp:57:14:  [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.
	while ((c = getopt_long(argc, argv, "hvi:p:u:s:l",
data/trace-cmd-2.9.1/kernel-shark/src/kshark-record.cpp:19:14:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt(argc, argv, "o:")) != -1) {
data/trace-cmd-2.9.1/lib/trace-cmd/trace-plugin.c:245:11:  [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.
	envdir = getenv("TRACECMD_PLUGIN_DIR");
data/trace-cmd-2.9.1/lib/trace-cmd/trace-plugin.c:253:9:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	home = getenv("HOME");
data/trace-cmd-2.9.1/lib/traceevent/event-plugin.c:606:11:  [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.
	envdir = getenv("TRACEEVENT_PLUGIN_DIR");
data/trace-cmd-2.9.1/lib/traceevent/event-plugin.c:614:9:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	home = getenv("HOME");
data/trace-cmd-2.9.1/tracecmd/trace-agent.c:302:7:  [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.
		c = getopt_long(argc-1, argv+1, "+hp:D",
data/trace-cmd-2.9.1/tracecmd/trace-check-events.c:21:14:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt(argc-1, argv+1, "+hN")) >= 0) {
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:664:7:  [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.
		c = getopt_long (argc-1, argv+1, "+hvai:",
data/trace-cmd-2.9.1/tracecmd/trace-hist.c:1013:7:  [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.
		c = getopt(argc-1, argv+1, "+hi:P");
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:934:7:  [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.
		c = getopt_long (argc-1, argv+1, "+hp:o:d:l:D",
data/trace-cmd-2.9.1/tracecmd/trace-mem.c:527:7:  [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.
		c = getopt(argc-1, argv+1, "+hi:");
data/trace-cmd-2.9.1/tracecmd/trace-read.c:1557:7:  [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.
		c = getopt_long (argc-1, argv+1, "+hSIi:H:feGpRr:tPNn:LlEwF:VvTqO:",
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5574:7:  [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.
		c = getopt(argc-1, argv+1, "hatB:");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5615:7:  [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.
		c = getopt(argc-1, argv+1, "hatB:");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5658:14:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt(argc-1, argv+1, "hab:B:td")) >= 0) {
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5894:7:  [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.
		c = getopt_long (argc-1, argv+1, opts, long_options, &option_index);
data/trace-cmd-2.9.1/tracecmd/trace-restore.c:46:14:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt(argc-1, argv+1, "+hco:i:t:k:")) >= 0) {
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:207:7:  [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.
		c = getopt_long(argc-1, argv+1, "+hc:p:g:a",
data/trace-cmd-2.9.1/tracecmd/trace-show.c:57:14:  [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.
	while ((c = getopt_long(argc-1, argv+1, "B:c:fsp",
data/trace-cmd-2.9.1/tracecmd/trace-snapshot.c:57:14:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt(argc-1, argv+1, "srfB:c:")) >= 0) {
data/trace-cmd-2.9.1/tracecmd/trace-split.c:430:14:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
	while ((c = getopt(argc-1, argv+1, "+ho:i:s:m:u:e:p:rcC:")) >= 0) {
data/trace-cmd-2.9.1/tracecmd/trace-stack.c:169:7:  [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.
		c = getopt_long (argc-1, argv+1, "+h?",
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:921:7:  [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.
		c = getopt(argc-1, argv+1, "tB:");
data/trace-cmd-2.9.1/utest/trace-utest.c:48:7:  [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.
		c = getopt_long (argc, argv, opts, long_options, &index);
data/trace-cmd-2.9.1/utest/tracefs-utest.c:61:19:  [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.
		test_array[i] = random();
data/trace-cmd-2.9.1/utest/tracefs-utest.c:100:2:  [3] (random) srand:
  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.
	srand(clk.tv_nsec);
data/trace-cmd-2.9.1/include/traceevent/event-parse.h:425:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&val, str, 4);
data/trace-cmd-2.9.1/include/traceevent/event-parse.h:722:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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_buffer[TEP_FILTER_ERROR_BUFSZ];
data/trace-cmd-2.9.1/kernel-shark/src/KsAdvFilteringDialog.cpp:426: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 error_str[200];
data/trace-cmd-2.9.1/kernel-shark/src/KsMainWindow.cpp:1011:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buff[FILENAME_MAX];
data/trace-cmd-2.9.1/kernel-shark/src/libkshark-configio.c:1171: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 error_str[200];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-blk-hack.c:37:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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]; /* way more than enough! */
data/trace-cmd-2.9.1/lib/trace-cmd/trace-blk-hack.c:134:7:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
		r = sprintf(buf+l, "\tfield:int common_lock_depth;\toffset:8;\tsize:4;\n");
data/trace-cmd-2.9.1/lib/trace-cmd/trace-ftrace.c:149:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char msecs_str[21];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-ftrace.c:150:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char nsecs_str[5];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-ftrace.c:154:2:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
	sprintf(msecs_str, "%lu", usecs);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.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.
	static char buf[BUFSIZ + 1];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:249:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:274:4:  [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(str + (size - BUFSIZ), buf, BUFSIZ);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:280:4:  [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(str, buf, size);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:294:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(str + (size - i), buf, i);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:301:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(str, buf, i);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:342:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:2342:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char mapname[STR_PROCMAP_LINE_MAX+1];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:2560:4:  [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(cpustats + cpustats_size, buf, size);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:2629:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:3074:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:3157:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_RDONLY);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:3198:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_RDONLY);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:3215:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_RDONLY);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-msg.c:215:13:  [2] (integer) atol:
  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).
        r = atol(s);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-msg.c:320: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 scratch_buf[MSG_MAX_LEN];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-msg.c:717:4:  [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(msg.buf, buf + count, MSG_MAX_DATA_LEN);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-msg.c:722:4:  [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(msg.buf, buf + count, n);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-msg.c:870:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(p, tsync_protos, protos_size);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-msg.c:962:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(*tsync_protos, buf, length);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-msg.c:998:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(vagrs, buf, length);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-msg.c:1184:4:  [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(*payload, msg.buf, buf_size);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-msg.c:1194:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(*payload, msg.buf, buf_size);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:172:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:191:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_RDONLY);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:205:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:226:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_RDONLY);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:284:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_WRONLY);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:325:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_RDONLY);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:353:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_RDONLY);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:519:2:  [2] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant string.
	strcat(path, "/format");
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:588:2:  [2] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant string.
	strcat(str, "/*");
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:592:2:  [2] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant string.
	strcat(str, "*/");
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:694:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_RDONLY);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:708:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_WRONLY);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:845:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:867:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(buf + 3, "tracing", 7);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:942:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(output_file, O_RDWR | O_CREAT | O_TRUNC | O_LARGEFILE, 0644);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:1007:4:  [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(data, vector[i].iov_base, vector[i].iov_len);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:1154:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(option->data, data, size);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-plugin.c:195:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char *p, path[PATH_MAX+1];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-plugin.c:211:2:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
	strcpy(p, "/lib/trace-cmd/plugins");
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:53:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[size];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:174:24:  [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).
		recorder->trace_fd = open(path, O_RDONLY);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:220:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_WRONLY | O_CREAT | O_TRUNC | O_LARGEFILE, 0644);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:253:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_RDWR | O_CREAT | O_TRUNC | O_LARGEFILE, 0644);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:257:8:  [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).
	fd2 = open(file2, O_RDWR | O_CREAT | O_TRUNC | O_LARGEFILE, 0644);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:467:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[recorder->page_size];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:520:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[recorder->page_size];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-timesync.c:239:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char inst_name[256];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-util.c:265:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char *p, path[PATH_MAX+1];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-util.c:281:2:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
	strcpy(p, "/lib/traceevent/plugins");
data/trace-cmd-2.9.1/lib/trace-cmd/trace-util.c:354:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[LOG_BUF_SIZE];
data/trace-cmd-2.9.1/lib/trace-cmd/trace-util.c:412:10:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	logfp = fopen(logfile, "w");
data/trace-cmd-2.9.1/lib/trace-cmd/trace-util.c:430:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/lib/trace-cmd/trace-util.c:441:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(PROC_STACK_FILE, O_RDONLY);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-util.c:476:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/lib/trace-cmd/trace-util.c:498:7:  [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).
	fp = fopen("/proc/cpuinfo", "r");
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:1006:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:2260:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(ref, type, len);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:2513: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.
	static char buf[24];
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:2523:3:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
		sprintf(buf, "%lld", val);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:3465:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(&val, (ptr), sizeof(unsigned long long));
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:3992:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[3];
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:4023:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(str + i, buf, 2);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:4113:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(str, data + field->offset, len);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:4730:11:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	unsigned char zerolength[8];
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:4739:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&in6, addr, sizeof(struct in6_addr));
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:5521:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char print_format[32];
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:5584:4:  [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(print_format, start, len);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:5613:4:  [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(print_format, start, len);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:5651:4:  [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(print_format, start, len);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6118:10:  [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).
		prec = atoi(format + 1);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6121:9:  [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).
		div = atoi(divstr + 1);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6143:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char format[32];
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6219:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(type->format, format, i < 32 ? i : 31);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6352:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(events, tep->events, sizeof(*events) * tep->nr_events);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6655:12:  [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).
	*offset = atoi(token);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6665:10:  [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).
	*size = atoi(token);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:7191:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char tmp[128];
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:7204:3:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
		sprintf(tmp, "0x%08llx", val);
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:85:3:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
		sprintf(*tok, "%c%c", *token, '~');
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:1299:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(this_event, filter_str, len);
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:1711:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char hex[64];
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:1730:4:  [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(arg->str.buffer, val, arg->str.field->size);
data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_blk.c:75:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char rwbs[6];
data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_blk.c:261: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.
	const char *act[2];
data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_kvm.c:59: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.
	static char out[15*3+1];
data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_kvm.c:63:3:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
		sprintf(out + i * 3, "%02x ", insn[i]);
data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_scsi.c:413: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.
	scsi_trace_parse_cdb(s, (unsigned char *) (unsigned long) args[1], args[2]);
data/trace-cmd-2.9.1/lib/traceevent/trace-seq.c:201:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(s->buffer + s->len, str, len);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:135:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[PATH_MAX];
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:167:9:  [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).
		cpu = atoi(name + 3);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:174:8:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fd = open(file, O_RDONLY | O_NONBLOCK);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-instance.c:184:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_WRONLY | O_TRUNC);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-instance.c:254:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[PATH_MAX];
data/trace-cmd-2.9.1/lib/tracefs/tracefs-utils.c:70:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char fspath[PATH_MAX+1];
data/trace-cmd-2.9.1/lib/tracefs/tracefs-utils.c:72:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[100];
data/trace-cmd-2.9.1/lib/tracefs/tracefs-utils.c:76:7:  [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).
	fp = fopen("/proc/mounts", "r");
data/trace-cmd-2.9.1/lib/tracefs/tracefs-utils.c:193:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char stbuf[BUFSIZ];
data/trace-cmd-2.9.1/lib/tracefs/tracefs-utils.c:200:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_RDONLY);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-utils.c:217:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(buf+size, stbuf, r);
data/trace-cmd-2.9.1/tracecmd/trace-agent.c:33:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open("/dev/vsock", O_RDONLY);
data/trace-cmd-2.9.1/tracecmd/trace-agent.c:106:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/tracecmd/trace-agent.c:111:8:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fd = open(path, O_WRONLY);
data/trace-cmd-2.9.1/tracecmd/trace-agent.c:311:11:  [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).
			port = atoi(optarg);
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:94:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[DUMP_SIZE];
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:112:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[8];
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:144:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[DUMP_SIZE];
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:189:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[DUMP_SIZE];
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:210:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[DUMP_SIZE];
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:252:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[DUMP_SIZE];
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:569:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/tracecmd/trace-dump.c:596:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_RDONLY);
data/trace-cmd-2.9.1/tracecmd/trace-hist.c:408:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(pending_ips, ips, sizeof(char *) * ips_idx);
data/trace-cmd-2.9.1/tracecmd/trace-list.c:16:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-list.c:20:7:  [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).
	fp = fopen(path, "r");
data/trace-cmd-2.9.1/tracecmd/trace-list.c:84:3:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
		strcpy(&str[l-1], "\n*$");
data/trace-cmd-2.9.1/tracecmd/trace-list.c:92:7:  [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).
	fp = fopen(path, "r");
data/trace-cmd-2.9.1/tracecmd/trace-list.c:194:7:  [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).
	fp = fopen(file, "r");
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:85:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[PATH_MAX];
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:129:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/tracecmd/trace-listen.c:145:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[page_size];
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:159:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(tempfile, O_WRONLY | O_TRUNC | O_CREAT, 0644);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:212:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:293:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:313:9:  [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).
	cpus = atoi(buf);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:334:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
				memcpy(last_proto, buf, n);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:373:14:  [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).
		pagesize = atoi(buf);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:385:13:  [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).
		options = atoi(buf);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:393:11:  [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).
			size = atoi(buf);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:435:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:440:8:  [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).
	ofd = open(buf, O_RDWR | O_CREAT | O_TRUNC, 0644);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:467:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:538:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:691:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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], service[NI_MAXSERV];
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:829:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/tracecmd/trace-listen.c:838:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(buf, O_WRONLY | O_CREAT | O_TRUNC, 0644);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:844:2:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
	sprintf(buf, "%d\n", getpid());
data/trace-cmd-2.9.1/tracecmd/trace-profile.c:372:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(&stack->caller, caller, size);
data/trace-cmd-2.9.1/tracecmd/trace-profile.c:545:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(task->comm, comm, field->size);
data/trace-cmd-2.9.1/tracecmd/trace-read.c:478:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char pidstr[100];
data/trace-cmd-2.9.1/tracecmd/trace-read.c:493:4:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
			sprintf(pidstr, "%d", tep_cmdline_pid(pevent, cmdline));
data/trace-cmd-2.9.1/tracecmd/trace-read.c:543:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char errstr[200];
data/trace-cmd-2.9.1/tracecmd/trace-read.c:820:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[50];
data/trace-cmd-2.9.1/tracecmd/trace-read.c:943:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ + 1];
data/trace-cmd-2.9.1/tracecmd/trace-read.c:1315:13:  [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).
	input_fd = open(file, O_RDONLY);
data/trace-cmd-2.9.1/tracecmd/trace-read.c:1387:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_RDONLY);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:461:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:474:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_RDONLY);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:562:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[PATH_MAX];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:759:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_WRONLY);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:804:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_WRONLY | O_TRUNC);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:822:7:  [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).
	fp = fopen(path, "w");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:845:7:  [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).
	fp = fopen(path, "w");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:862:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[100];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:880:31:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
	instance->len_filter_pids += sprintf(buf, "%d", pid);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:923:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_WRONLY | O_CLOEXEC | (reset ? O_TRUNC : 0));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:948:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[100];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1092:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char mapname[PATH_MAX+1];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1093:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char fname[PATH_MAX+1];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1094:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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+100];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1100:2:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
	sprintf(fname, "/proc/%d/exe", pid);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1106:2:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
	sprintf(fname, "/proc/%d/maps", pid);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1107:6:  [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(fname, "r");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1386:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[100];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1399:3:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
		sprintf(buf, "%d", child);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1655:7:  [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).
	fp = fopen(path, "w");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1679:7:  [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).
	fp = fopen(path, "w");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1683:8:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fp = fopen(path, "w");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1725:7:  [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).
	fp = fopen(path, "w");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1889:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_WRONLY);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1949:7:  [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).
	fp = fopen(path, "w");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1994:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_WRONLY);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2010:8:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fd = open(path, O_WRONLY);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2035:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char stbuf[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2042:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_RDONLY);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2057:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(buf+size, stbuf, r);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2154:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char trigger[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2205:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char filter[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2220:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_WRONLY | O_TRUNC);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2332:7:  [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).
	fp = fopen(path, "w");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2354:8:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fd = open(path, O_WRONLY | O_CLOEXEC);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2370:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, flags);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2422:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/tracecmd/trace-record.c:2436:8:  [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).
	ret = atoi(buf);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2595:9:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
		len = sprintf(str, "%d ", p->pid);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2653:3:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
		sprintf(cpumask, "%x", (1 << last) - 1);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2692:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_WRONLY | O_TRUNC);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3067:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3259:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/tracecmd/trace-record.c:3279:7:  [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(path, "r");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3304:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/tracecmd/trace-record.c:3325:15:  [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).
		guest.pid = atoi(entry->d_name);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3327:7:  [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(path, "r");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3355:17:  [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).
				guest.cid = atoi(p + 10);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3389:11:  [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).
		*port = atoi(p + 1);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3396:10:  [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).
		*cid = atoi(p + 1);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3398:10:  [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).
		*cid = atoi(guest);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3581:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3593:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3600:2:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
	sprintf(buf, "%d", local_cpu_count);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3606:2:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
	sprintf(buf, "%d", page_size);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3653:26:  [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).
		(*client_ports)[cpu] = atoi(buf);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3666:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3830:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/tracecmd/trace-record.c:3837:8:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fd = open(path, O_RDONLY | O_NONBLOCK);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3953:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_CREAT|O_WRONLY|O_TRUNC, 0644);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4043:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_WRONLY | O_CREAT | O_TRUNC, 0644);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4114:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(p, &instance->trace_id, sizeof(long long));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4117:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(p, &i, sizeof(int));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4122:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(p, &i, sizeof(int));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4124:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(p, &guest->cpu_pid[i], sizeof(int));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4286:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_RDWR);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4451:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_WRONLY | O_TRUNC);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4489:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[1] = { '#' };
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4494:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_RDONLY);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4649:8:  [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).
	tfd = open(path, O_WRONLY);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4710:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4727:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_WRONLY);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4924:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/tracecmd/trace-record.c:4928:2:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
	sprintf(buf, "%x", (unsigned int)((1ULL << bits) - 1));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4930:3:  [2] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant string.
		strcat(buf, ",ffffffff");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4977:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char sevent[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5221:12:  [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).
	overrun = atoi(p + strlen(overrun_str));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5225:20:  [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).
		commit_overrun = atoi(p + strlen(commit_overrun_str));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5355:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_WRONLY);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5375:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5378:2:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
	strcpy(buf, "events/");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5666:15:  [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).
			int size = atoi(optarg);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5947:5:  [2] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant string.
				strcat(last_event->filter, "&&(");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:6005:14:  [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).
							      atoi(pid), 0);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:6096:10:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
				fd = open(optarg, O_WRONLY | O_CREAT | O_TRUNC, 0644);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:6130:17:  [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).
			sleep_time = atoi(optarg);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:6141:14:  [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).
			rt_prio = atoi(optarg);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:6158:13:  [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).
			max_kb = atoi(optarg);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:6173: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).
			ctx->instance->buffer_size = atoi(optarg);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:6259:31:  [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).
			ctx->saved_cmdlines_size = atoi(optarg);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:6278:39:  [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).
			top_instance.tsync.loop_interval = atoi(optarg);
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:22:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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+2], *p;
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:57:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:66:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:100:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char cmd[1024];
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:123:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char tmp_path[PATH_MAX], path[PATH_MAX];
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:124:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char cmd[PATH_MAX], xml[PATH_MAX];
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:127:2:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
	strcpy(tmp_path, "/tmp/pipexmlXXXXXX");
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:128:7:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	fd = mkstemp(tmp_path);
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:216:14:  [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).
			nr_cpus = atoi(optarg);
data/trace-cmd-2.9.1/tracecmd/trace-show.c:32:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char cpu_path[128];
data/trace-cmd-2.9.1/tracecmd/trace-snapshot.c:25:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_WRONLY);
data/trace-cmd-2.9.1/tracecmd/trace-snapshot.c:43:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char cpu_path[128];
data/trace-cmd-2.9.1/tracecmd/trace-snapshot.c:83:10:  [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).
			cpu = atoi(optarg);
data/trace-cmd-2.9.1/tracecmd/trace-split.c:115:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(ptr, &time, 4);
data/trace-cmd-2.9.1/tracecmd/trace-split.c:129:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(ptr, record->data, len);
data/trace-cmd-2.9.1/tracecmd/trace-split.c:361:8:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fd = open(file, O_WRONLY | O_CREAT | O_TRUNC | O_LARGEFILE, 0644);
data/trace-cmd-2.9.1/tracecmd/trace-split.c:447:12:  [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).
			count = atoi(optarg);
data/trace-cmd-2.9.1/tracecmd/trace-split.c:463:10:  [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).
			cpu = atoi(optarg);
data/trace-cmd-2.9.1/tracecmd/trace-split.c:523:3:  [2] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant string.
		strcat(output, ".1");
data/trace-cmd-2.9.1/tracecmd/trace-stack.c:43:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[1];
data/trace-cmd-2.9.1/tracecmd/trace-stack.c:61:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(PROC_FILE, O_WRONLY);
data/trace-cmd-2.9.1/tracecmd/trace-stack.c:86:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[1];
data/trace-cmd-2.9.1/tracecmd/trace-stack.c:91:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_WRONLY);
data/trace-cmd-2.9.1/tracecmd/trace-stack.c:121:7:  [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).
	fp = fopen(path, "r");
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:35:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_RDONLY);
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:99:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_RDONLY);
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:687:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[FILE_SIZE];
data/trace-cmd-2.9.1/tracecmd/trace-stream.c:40:8:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
		fp = tmpfile();
data/trace-cmd-2.9.1/tracecmd/trace-tsync.c:143:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(file, O_RDWR);
data/trace-cmd-2.9.1/utest/tracefs-utest.c:57:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(path, O_WRONLY);
data/trace-cmd-2.9.1/utest/tracefs-utest.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.
	static char str[RAND_STR_SIZE];
data/trace-cmd-2.9.1/utest/tracefs-utest.c:145:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[BUFSIZ];
data/trace-cmd-2.9.1/utest/tracefs-utest.c:160:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	fd = open(fpath, O_RDONLY);
data/trace-cmd-2.9.1/utest/tracefs-utest.c:373:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[PATH_MAX];
data/trace-cmd-2.9.1/utest/tracefs-utest.c:374:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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/trace-cmd-2.9.1/utest/tracefs-utest.c:391:8:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fd = open(file, O_RDONLY);
data/trace-cmd-2.9.1/utest/tracefs-utest.c:396:32:  [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).
			CU_TEST(tep_find_event(tep, atoi(buf)) != NULL);
data/trace-cmd-2.9.1/utest/tracefs-utest.c:398:32:  [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).
			CU_TEST(tep_find_event(tep, atoi(buf)) == NULL);
data/trace-cmd-2.9.1/utest/tracefs-utest.c:414:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char *lsystems[3];
data/trace-cmd-2.9.1/kernel-shark/src/KsAdvFilteringDialog.cpp:414:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strlen(text) == 0) {
data/trace-cmd-2.9.1/kernel-shark/src/KsAdvFilteringDialog.cpp:419: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).
	filter = (char*) malloc(strlen(text) + 1);
data/trace-cmd-2.9.1/kernel-shark/src/KsMainWindow.cpp:1060:3:  [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(150000);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-hooks.c:60:10:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	index = strlen(tok);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-hooks.c:74:10:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	index = strlen(tok) + tok - str;
data/trace-cmd-2.9.1/lib/trace-cmd/trace-hooks.c:95:22:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	index = tok - str + strlen(tok);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-hooks.c:109:10:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	index = strlen(tok) + tok - str;
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:221:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		r = read(handle->fd, data + tot, size - tot);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:409:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(buf, file, size);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:827:9:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		ret = read(handle->cpu_data[cpu].pipe_fd, map, handle->page_size);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:847:8:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	ret = read(handle->fd, map, handle->page_size);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:2292:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	buf += strlen(guest->name) + 1;
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:2293:10:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	size -= strlen(guest->name) + 1;
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:2358:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strlen(buf) > STR_PROCMAP_LINE_MAX)
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:2380:7:  [1] (buffer) strlen:
  Does not handle 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) > STR_PROCMAP_LINE_MAX)
data/trace-cmd-2.9.1/lib/trace-cmd/trace-input.c:3483: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 (__do_write_check(fd, system, strlen(system) + 1)) {
data/trace-cmd-2.9.1/lib/trace-cmd/trace-msg.c:306:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		r = read(fd, buf + *n, size);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-msg.c:887: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).
		args_size += strlen(argv[i]) + 1;
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:176:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		r = read(fd, buf, BUFSIZ);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:209:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		r = read(fd, buf, BUFSIZ);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:509:15:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	events_len = strlen(events_path);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:511: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).
	path = malloc(events_len + strlen(str) +
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:512:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		      strlen("/format") + 2);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:517:2:  [1] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant character.
	strcat(path, "/");
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:583:15:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	str = malloc(strlen(ptr) + 3);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:667:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
				   strlen(slist->name) + 1)) {
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:701:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		if (read(fd, &buf, 1) < 0)
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:872: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).
	if (do_write_check(handle, FILE_VERSION_STRING, strlen(FILE_VERSION_STRING) + 1))
data/trace-cmd-2.9.1/lib/trace-cmd/trace-output.c:1185:17:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	int size = 8 + strlen(name) + 1;
data/trace-cmd-2.9.1/lib/trace-cmd/trace-plugin.c:184:22:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		if (strcmp(name + (strlen(name) - strlen(suffix)), suffix) != 0)
data/trace-cmd-2.9.1/lib/trace-cmd/trace-plugin.c:184: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).
		if (strcmp(name + (strlen(name) - strlen(suffix)), suffix) != 0)
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:60:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		r = read(src, buf, size);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:246:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(file);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:387:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	long read;
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:392:6:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	if (read < 0) {
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:403:8:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		     read, recorder->fd_flags);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:414:6:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	if (read)
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:430:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	long read;
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:450:6:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	if (read < 0) {
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:458:9:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	return read;
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:471:6:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	r = read(recorder->trace_fd, buf, recorder->page_size);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:536:9:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		ret = read(recorder->trace_fd, buf, recorder->page_size);
data/trace-cmd-2.9.1/lib/trace-cmd/trace-recorder.c:568:8:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		if (!read && sleep)
data/trace-cmd-2.9.1/lib/trace-cmd/trace-util.c:446:6:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	n = read(fd, buf, sizeof(buf));
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:773: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).
	p = item->printk + strlen(item->printk) - 1;
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:1182:22:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	init_input_buf(str, strlen(str));
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:1432: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).
	new_buf = realloc(*buf, strlen(*buf) + strlen(delim) + strlen(str) + 1);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:1432: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).
	new_buf = realloc(*buf, strlen(*buf) + strlen(delim) + strlen(str) + 1);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:1432: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).
	new_buf = realloc(*buf, strlen(*buf) + strlen(delim) + strlen(str) + 1);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:2246:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(type);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:4562: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).
				bptr += strlen(bptr) + 1;
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:5622:22:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
					memmove(p+1, p, strlen(p)+1);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:5728:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(format);
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6153:38:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strncmp(arg, TEP_PRINT_LATENCY, strlen(TEP_PRINT_LATENCY)) == 0) {
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6155: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).
	} else if (strncmp(arg, TEP_PRINT_COMM, strlen(TEP_PRINT_COMM)) == 0) {
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6159: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).
	} else if (strncmp(arg, TEP_PRINT_INFO_RAW, strlen(TEP_PRINT_INFO_RAW)) == 0) {
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6161: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).
	} else if (strncmp(arg, TEP_PRINT_INFO, strlen(TEP_PRINT_INFO)) == 0) {
data/trace-cmd-2.9.1/lib/traceevent/event-parse.c:6163: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).
	} else if  (strncmp(arg, TEP_PRINT_NAME, strlen(TEP_PRINT_NAME)) == 0) {
data/trace-cmd-2.9.1/lib/traceevent/event-plugin.c:542:22:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		if (strcmp(name + (strlen(name) - strlen(suffix)), suffix) != 0)
data/trace-cmd-2.9.1/lib/traceevent/event-plugin.c:542: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).
		if (strcmp(name + (strlen(name) - strlen(suffix)), suffix) != 0)
data/trace-cmd-2.9.1/lib/traceevent/include/event-utils.h:42:17:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	string = ret + strlen(ret) - 1;
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:43: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).
	len = input ? strlen(input) : 0;
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:491:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			if (strlen(arg->value.str) == 1 &&
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:1188: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).
	tep_buffer_init(filter_str, strlen(filter_str));
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:1281:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(filter_str);
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:1291:10:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			len = strlen(filter_str);
data/trace-cmd-2.9.1/lib/traceevent/parse-filter.c:1374:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strlen(filter->error_buffer) > 0) {
data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_python_loader.c:28:12:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	int len = strlen(path) + strlen(name) + 2;
data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_python_loader.c:28: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).
	int len = strlen(path) + strlen(name) + 2;
data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_python_loader.c:29:13:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	int nlen = strlen(name) + 1;
data/trace-cmd-2.9.1/lib/traceevent/plugins/plugin_python_loader.c:39:2:  [1] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant character.
	strcat(full, "/");
data/trace-cmd-2.9.1/lib/traceevent/trace-seq.c:194:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(str);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:165:7:  [1] (buffer) strlen:
  Does not handle 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(name) < 4 || strncmp(name, "cpu", 3) != 0)
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:178:8:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
			r = read(fd, page, p_size);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-events.c:421:10:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		slen = strlen(plugin);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-instance.c:189: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).
	ret = write(fd, str, strlen(str));
data/trace-cmd-2.9.1/lib/tracefs/tracefs-utils.c:82:9:  [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.
	while (fscanf(fp, "%*s %"
data/trace-cmd-2.9.1/lib/tracefs/tracefs-utils.c:101:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
				strncpy(fspath, debug_str, PATH_MAX);
data/trace-cmd-2.9.1/lib/tracefs/tracefs-utils.c:207:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		r = read(fd, stbuf, BUFSIZ);
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:58:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		r = read(fd, dst+size, 1);
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:79:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		r = read(fd, dst+size, len);
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:156: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).
	if (read_file_bytes(fd, buf, strlen(TRACING_STR)))
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:157: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).
		die("cannot read %d bytes tracing string", strlen(TRACING_STR));
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:158:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	buf[strlen(TRACING_STR)] = 0;
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:159: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).
	if (strncmp(buf, TRACING_STR, strlen(TRACING_STR)) != 0)
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:194: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).
	if (read_file_bytes(fd, buf, strlen(HEAD_PAGE_STR) + 1))
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:195: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).
		die("cannot read %d bytes header string", strlen(HEAD_PAGE_STR));
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:196:34:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strncmp(buf, HEAD_PAGE_STR, strlen(HEAD_PAGE_STR)) != 0)
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:215: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).
	if (read_file_bytes(fd, buf, strlen(HEAD_PAGE_EVENT) + 1))
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:216: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).
		die("cannot read %d bytes header string", strlen(HEAD_PAGE_EVENT));
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:217:36:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strncmp(buf, HEAD_PAGE_EVENT, strlen(HEAD_PAGE_EVENT)) != 0)
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:441:10:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	size -= strlen(buf) + 1;
data/trace-cmd-2.9.1/tracecmd/trace-dump.c:442:7:  [1] (buffer) strlen:
  Does not handle 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(buf) + 1;
data/trace-cmd-2.9.1/tracecmd/trace-list.c:70: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).
	size_t l = strlen(re);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:97:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		n = read(fd, buf+i, 1);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:178:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		r = read(sfd, buf, page_size);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:346:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		n = read(fd, buf, sizeof(V3_MAGIC));
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:407:9:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
				s = read(fd, option+s, t);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:519: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).
			write(msg_handle->fd, buf, strlen(buf));
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:543:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		n = read(ifd, buf, BUFSIZ);
data/trace-cmd-2.9.1/tracecmd/trace-listen.c:845:17:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	write(fd, buf, strlen(buf));
data/trace-cmd-2.9.1/tracecmd/trace-mem.c:205: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).
	int key = make_key(func, strlen(func)) & HASH_MASK;
data/trace-cmd-2.9.1/tracecmd/trace-mem.c:222: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).
	int key = make_key(func, strlen(func)) & HASH_MASK;
data/trace-cmd-2.9.1/tracecmd/trace-read.c:140:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(event->name);
data/trace-cmd-2.9.1/tracecmd/trace-read.c:351: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).
		item->file = file + strlen(file);
data/trace-cmd-2.9.1/tracecmd/trace-read.c:356:7:  [1] (buffer) strlen:
  Does not handle 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(item->file) > max_file_size)
data/trace-cmd-2.9.1/tracecmd/trace-read.c:357:20:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			max_file_size = strlen(item->file);
data/trace-cmd-2.9.1/tracecmd/trace-read.c:449:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(".*:" FILTER_FMT) + strlen(pid) * 3 + 1;
data/trace-cmd-2.9.1/tracecmd/trace-read.c:449: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).
	len = strlen(".*:" FILTER_FMT) + strlen(pid) * 3 + 1;
data/trace-cmd-2.9.1/tracecmd/trace-read.c:460: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).
		curr_len = strlen(curr_filter);
data/trace-cmd-2.9.1/tracecmd/trace-read.c:947:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		r = read(input_fd, buf, BUFSIZ);
data/trace-cmd-2.9.1/tracecmd/trace-read.c:1372:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		r = read(fd, dst+size, len);
data/trace-cmd-2.9.1/tracecmd/trace-read.c:1435:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		match = malloc(strlen(str->event) + 3);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:479:14:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	while ((r = read(fd, buf, BUFSIZ)) > 0)
data/trace-cmd-2.9.1/tracecmd/trace-record.c:544: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).
		base_len = strlen(file);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:807: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).
	ret = write(fd, str, strlen(str));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:928: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).
	ret = write(fd, pid, strlen(pid));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:933:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (ret < 0 && !strlen(pid))
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1342: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).
		int indx = strlen(curr_filter);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1670:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	fwrite(name, 1, strlen(name), fp);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1733:20:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	fwrite(option, 1, strlen(option), fp);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1793:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(option);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1830:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(option);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:1958: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).
	ret = fwrite(name, 1, strlen(name), fp);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2047:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		r = read(fd, stbuf, BUFSIZ);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2172:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(line);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2175:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(trigger + 1, line, len);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2241:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(line);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2245:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(filter + 1, line, len);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2432:8:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	ret = read(fd, buf, 10);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2509: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).
		common_len = strlen(instance->common_pid_filter);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2525:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
					len = common_len + strlen(event->pid_filter) +
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2526:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
						strlen(event->filter) + strlen("()&&(||)") + 1;
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2526: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).
						strlen(event->filter) + strlen("()&&(||)") + 1;
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2535:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
					len = common_len + strlen(event->filter) +
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2536:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
						strlen("()&&()") + 1;
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2550:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
					len = common_len + strlen(event->pid_filter) +
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2551:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
						strlen("||") + 1;
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2696: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).
	write(fd, instance->cpumask, strlen(instance->cpumask));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2890: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).
	path += len - strlen(name);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:2932:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(path);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3000:7:  [1] (buffer) strlen:
  Does not handle 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(ptr))
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3583:2:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	read(msg_handle->fd, buf, 8);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3603: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).
	write(msg_handle->fd, buf, strlen(buf)+1);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3609: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).
	write(msg_handle->fd, buf, strlen(buf)+1);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3644:8:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
			n = read(msg_handle->fd, buf+i, 1);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3689:6:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	n = read(fd, buf, BUFSIZ);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:3701:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		n = read(fd, buf, BUFSIZ - 1);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4102:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	size = strlen(guest->name) + 1;
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4112:7:  [1] (buffer) strlen:
  Does not handle 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(guest->name) + 1;
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4193:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(hook->hook);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4211:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(buf.sysname) + strlen(buf.nodename) +
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4211: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).
	len = strlen(buf.sysname) + strlen(buf.nodename) +
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4212:3:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		strlen(buf.release) + strlen(buf.machine) + 4;
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4212:25:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		strlen(buf.release) + strlen(buf.machine) + 4;
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4267: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).
		tracecmd_add_option(handle, type, strlen(ctx->date2ts)+1, ctx->date2ts);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4458: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).
		ret = write(fd, item->func, strlen(item->func));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4462: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).
			ret = write(fd, prefix, strlen(prefix));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4465: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).
			ret = write(fd, item->mod, strlen(item->mod));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4509:2:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	read(fd, buf, 1);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4733: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).
	ret = write(fd, buf, strlen(buf));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4995:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		len = strlen(line);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:4998:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(sevent + 1, line, len);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5221: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).
	overrun = atoi(p + strlen(overrun_str));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5225: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).
		commit_overrun = atoi(p + strlen(commit_overrun_str));
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5333:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
					 strlen(event->trigger) + strlen("\n") +
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5333: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).
					 strlen(event->trigger) + strlen("\n") +
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5334:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
					 strlen(trigger) + 1);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5335:3:  [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(event->trigger, "\n");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5379:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(buf + 7, event_str, BUFSIZ - 7);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5482:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(event);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5483:9:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len += strlen(system) + 2;
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5944:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
						strlen(last_event->filter) +
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5945:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
						strlen("&&()") +
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5946:7:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
						strlen(optarg) + 1);
data/trace-cmd-2.9.1/tracecmd/trace-record.c:5949:5:  [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(last_event->filter, ")");
data/trace-cmd-2.9.1/tracecmd/trace-record.c:6062: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).
			for (optarg += strlen(optarg) - 1;
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:24:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(buf, path, sizeof(buf));
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:85:9:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
	mask = umask(0);
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:91:2:  [1] (access) umask:
  Ensure that umask is given most restrictive possible setting (e.g., 066 or
  077) (CWE-732).
	umask(mask);
data/trace-cmd-2.9.1/tracecmd/trace-setup-guest.c:135: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).
		pwrite(fd, xml, strlen(xml), 0);
data/trace-cmd-2.9.1/tracecmd/trace-snapshot.c:29: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).
	n = write(fd, val, strlen(val));
data/trace-cmd-2.9.1/tracecmd/trace-split.c:522: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).
		output = realloc(output, strlen(output) + 3);
data/trace-cmd-2.9.1/tracecmd/trace-split.c:527: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).
	output_file = malloc(strlen(output) + 50);
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:48:12:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	s = str + strlen(str) - 1;
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:83:9:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		ret = read(fd, str + BUFSIZ * (cnt - 1), BUFSIZ);
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:603:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(str);
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:785:11:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	for (i = strlen(cont) - 1; i >= 0 && cpus > 0; i--) {
data/trace-cmd-2.9.1/tracecmd/trace-stat.c:831:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strlen(cont) == 0)
data/trace-cmd-2.9.1/utest/tracefs-utest.c:162:10:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	fsize = read(fd, buf, BUFSIZ);
data/trace-cmd-2.9.1/utest/tracefs-utest.c:244:17:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	CU_TEST(ret == strlen(tracer));
data/trace-cmd-2.9.1/utest/tracefs-utest.c:247:18:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	CU_TEST(size >= strlen(tracer));
data/trace-cmd-2.9.1/utest/tracefs-utest.c:248: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).
	CU_TEST(strncmp(file2, tracer, strlen(tracer)) == 0);
data/trace-cmd-2.9.1/utest/tracefs-utest.c:394:11:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		CU_TEST(read(fd, buf, 1024) > 0);

ANALYSIS SUMMARY:

Hits = 718
Lines analyzed = 70142 in approximately 1.46 seconds (48111 lines/second)
Physical Source Lines of Code (SLOC) = 48734
Hits@level = [0] 333 [1] 194 [2] 288 [3]  31 [4] 202 [5]   3
Hits@level+ = [0+] 1051 [1+] 718 [2+] 524 [3+] 236 [4+] 205 [5+]   3
Hits/KSLOC@level+ = [0+] 21.5661 [1+] 14.733 [2+] 10.7522 [3+] 4.84262 [4+] 4.20651 [5+] 0.0615587
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.