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/obexpushd-0.11.2/src/action.h
Examining data/obexpushd-0.11.2/src/action/connect.c
Examining data/obexpushd-0.11.2/src/action/core.c
Examining data/obexpushd-0.11.2/src/action/core.h
Examining data/obexpushd-0.11.2/src/action/disconnect.c
Examining data/obexpushd-0.11.2/src/action/get.c
Examining data/obexpushd-0.11.2/src/action/put.c
Examining data/obexpushd-0.11.2/src/action/setpath.c
Examining data/obexpushd-0.11.2/src/auth.h
Examining data/obexpushd-0.11.2/src/auth/core.c
Examining data/obexpushd-0.11.2/src/auth/file.c
Examining data/obexpushd-0.11.2/src/checks.c
Examining data/obexpushd-0.11.2/src/checks.h
Examining data/obexpushd-0.11.2/src/closexec.h
Examining data/obexpushd-0.11.2/src/compiler.h
Examining data/obexpushd-0.11.2/src/fork.c
Examining data/obexpushd-0.11.2/src/io.h
Examining data/obexpushd-0.11.2/src/io/core.c
Examining data/obexpushd-0.11.2/src/io/internal/caps.c
Examining data/obexpushd-0.11.2/src/io/internal/caps.h
Examining data/obexpushd-0.11.2/src/io/internal/common.c
Examining data/obexpushd-0.11.2/src/io/internal/common.h
Examining data/obexpushd-0.11.2/src/io/internal/dir.c
Examining data/obexpushd-0.11.2/src/io/internal/dir.h
Examining data/obexpushd-0.11.2/src/io/internal/file.h
Examining data/obexpushd-0.11.2/src/io/internal/file.c
Examining data/obexpushd-0.11.2/src/io/script.c
Examining data/obexpushd-0.11.2/src/net.h
Examining data/obexpushd-0.11.2/src/net/btobex.c
Examining data/obexpushd-0.11.2/src/net/core.c
Examining data/obexpushd-0.11.2/src/net/core.h
Examining data/obexpushd-0.11.2/src/net/fdobex.c
Examining data/obexpushd-0.11.2/src/net/fdobex.h
Examining data/obexpushd-0.11.2/src/net/fdobex_ctrans.c
Examining data/obexpushd-0.11.2/src/net/inobex.c
Examining data/obexpushd-0.11.2/src/net/irobex.c
Examining data/obexpushd-0.11.2/src/net/publish/sdp.c
Examining data/obexpushd-0.11.2/src/net/publish/sdp.h
Examining data/obexpushd-0.11.2/src/net/tcpobex.c
Examining data/obexpushd-0.11.2/src/net/usbgobex.c
Examining data/obexpushd-0.11.2/src/net/usbgobex.h
Examining data/obexpushd-0.11.2/src/net/usbgobex_ctrans.c
Examining data/obexpushd-0.11.2/src/obex_auth.h
Examining data/obexpushd-0.11.2/src/obex_auth/core.c
Examining data/obexpushd-0.11.2/src/obex_auth/md5.c
Examining data/obexpushd-0.11.2/src/obex_auth/md5.h
Examining data/obexpushd-0.11.2/src/obex_auth/obex_auth.c
Examining data/obexpushd-0.11.2/src/obex_auth/obex_auth.h
Examining data/obexpushd-0.11.2/src/obexpush_atd.c
Examining data/obexpushd-0.11.2/src/obexpushd.c
Examining data/obexpushd-0.11.2/src/obexpushd.h
Examining data/obexpushd-0.11.2/src/pipe.c
Examining data/obexpushd-0.11.2/src/pipe.h
Examining data/obexpushd-0.11.2/src/pthreads.c
Examining data/obexpushd-0.11.2/src/utf.c
Examining data/obexpushd-0.11.2/src/utf.h
Examining data/obexpushd-0.11.2/src/x-obex/obex-capability-app.c
Examining data/obexpushd-0.11.2/src/x-obex/obex-capability.c
Examining data/obexpushd-0.11.2/src/x-obex/obex-capability.h
Examining data/obexpushd-0.11.2/src/x-obex/obex-folder-listing-app.c
Examining data/obexpushd-0.11.2/src/x-obex/obex-folder-listing.c
Examining data/obexpushd-0.11.2/src/x-obex/obex-folder-listing.h
Examining data/obexpushd-0.11.2/src/x-obex/xml_simple.h

FINAL RESULTS:

data/obexpushd-0.11.2/src/action/setpath.c:81: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(transfer->path, (char*)n);
data/obexpushd-0.11.2/src/io/internal/common.c:60:4:  [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(name, basedir);
data/obexpushd-0.11.2/src/io/internal/common.c:65:4:  [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(name, subdir);
data/obexpushd-0.11.2/src/io/internal/common.c:70:4:  [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(name, (char*)namebase);
data/obexpushd-0.11.2/src/io/internal/common.c:73:4:  [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(name, basedir);
data/obexpushd-0.11.2/src/obexpush_atd.c:71:32:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
#define debug_print(line, ...) fprintf(stderr, line, ##__VA_ARGS__)
data/obexpushd-0.11.2/src/obexpush_atd.c:227:3:  [4] (shell) execvp:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
		execvp(cmd, args);
data/obexpushd-0.11.2/src/obexpushd.c:69:3:  [4] (format) vfprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		vfprintf(stderr, format, ap);
data/obexpushd-0.11.2/src/obexpushd.c:293:2:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	fprintf(stderr,
data/obexpushd-0.11.2/src/obexpushd.h:63:84:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void dbg_printf (file_data_t *data, const char *format, ...) __attribute__((format(printf,2,3)));
data/obexpushd-0.11.2/src/pipe.c:96:3:  [4] (shell) execvp:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
		execvp(command, args);
data/obexpushd-0.11.2/src/x-obex/obex-capability-app.c:31:2:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	fprintf(stderr,
data/obexpushd-0.11.2/src/x-obex/obex-capability.c:65:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(s, "%sSize", prefix);
data/obexpushd-0.11.2/src/x-obex/obex-capability.c:70:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(s, "%sNLen", prefix);
data/obexpushd-0.11.2/src/x-obex/obex-capability.c:250:12:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	if (caps->access)
data/obexpushd-0.11.2/src/x-obex/obex-capability.c:251:34:  [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.
		obex_caps_access(fd, 2, *caps->access);
data/obexpushd-0.11.2/src/x-obex/obex-capability.h:91:28:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
	struct obex_caps_access** access;
data/obexpushd-0.11.2/src/x-obex/obex-folder-listing-app.c:30:2:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	fprintf(stderr,
data/obexpushd-0.11.2/src/x-obex/obex-folder-listing.c:224:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(filename,"%s%s%s",dir,seperator,entry->d_name);
data/obexpushd-0.11.2/src/x-obex/xml_simple.h:22:3:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		fprintf(fd, a, __VA_ARGS__);\
data/obexpushd-0.11.2/src/x-obex/xml_simple.h:43:17:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
                fprintf(fd,f, __VA_ARGS__ );\
data/obexpushd-0.11.2/src/obexpush_atd.c:517: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, argv, "S:dX:hv");
data/obexpushd-0.11.2/src/obexpushd.c:443: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,argv,"B::I::N::G:SAa:dhnp:r:o:s:t:v");
data/obexpushd-0.11.2/src/x-obex/obex-capability-app.c:64: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,"V:M:h")) != -1) {
data/obexpushd-0.11.2/src/x-obex/obex-folder-listing-app.c:62: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,"PHtpogh")) != -1) {
data/obexpushd-0.11.2/src/action/core.c:24: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(transfer->name, value->bs, vsize);
data/obexpushd-0.11.2/src/action/core.c:50: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(transfer->type, value->bs, vsize);
data/obexpushd-0.11.2/src/action/core.c:71: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(tmp, value->bs, vsize);
data/obexpushd-0.11.2/src/action/core.c:94: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 tmp[17];
data/obexpushd-0.11.2/src/action/get.c:86: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 header[16+19+3];
data/obexpushd-0.11.2/src/action/get.c:102: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 bs[17];
data/obexpushd-0.11.2/src/action/setpath.c:136: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(name, value.bs, vsize);
data/obexpushd-0.11.2/src/auth/core.c:50: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(hnew, h, sizeof(*h));
data/obexpushd-0.11.2/src/auth/core.c:74:11:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	int fd = open(RANDOM_FILE, O_RDONLY);
data/obexpushd-0.11.2/src/auth/core.c:116: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(chal[i].nonce, self->session[i].nonce, sizeof(chal->nonce));
data/obexpushd-0.11.2/src/closexec.h:13:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	int err = open(pathname, (flags | O_CLOEXEC), mode);
data/obexpushd-0.11.2/src/io.h:31: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).
	int (*open)(struct io_handler *self, struct io_transfer_data *transfer, enum io_type t);
data/obexpushd-0.11.2/src/io/core.c:39: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(hnew, h, sizeof(*hnew));
data/obexpushd-0.11.2/src/io/core.c:72:30:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	if (self->ops && self->ops->open)
data/obexpushd-0.11.2/src/io/core.c:73:21:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		return self->ops->open(self, transfer, t);
data/obexpushd-0.11.2/src/io/internal/caps.c:22:13:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
	data->in = tmpfile();
data/obexpushd-0.11.2/src/io/internal/dir.c:20:13:  [2] (tmpfile) tmpfile:
  Function tmpfile() has a security flaw on some systems (e.g., older System
  V systems) (CWE-377).
	data->in = tmpfile();
data/obexpushd-0.11.2/src/io/internal/file.c:34: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[256];
data/obexpushd-0.11.2/src/io/script.c:118: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 ret[4+1];
data/obexpushd-0.11.2/src/io/script.c:141: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 buffer[512+1];
data/obexpushd-0.11.2/src/io/script.c:287:4:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
			char tmp[17];
data/obexpushd-0.11.2/src/net/btobex.c:29: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 device[18];
data/obexpushd-0.11.2/src/net/btobex.c:127: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 addrstr[128];
data/obexpushd-0.11.2/src/net/btobex.c:128: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[256];
data/obexpushd-0.11.2/src/net/inobex.c:82: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 addrstr[INET6_ADDRSTRLEN];
data/obexpushd-0.11.2/src/net/inobex.c:84: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[256];
data/obexpushd-0.11.2/src/net/irobex.c:46: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[256];
data/obexpushd-0.11.2/src/net/tcpobex.c:133: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 addrstr[INET6_ADDRSTRLEN];
data/obexpushd-0.11.2/src/net/tcpobex.c:134: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[256];
data/obexpushd-0.11.2/src/obex_auth/md5.c:186: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((uint8_t *)ctx->in + 64 - t, buf, len);
data/obexpushd-0.11.2/src/obex_auth/md5.c:190: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((uint8_t *)ctx->in + 64 - t, buf, t);
data/obexpushd-0.11.2/src/obex_auth/md5.c:198: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(ctx->in, buf, 64);
data/obexpushd-0.11.2/src/obex_auth/md5.c:206: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(ctx->in, buf, len);
data/obexpushd-0.11.2/src/obex_auth/md5.c:240: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(digest, ctx->buf, 16);
data/obexpushd-0.11.2/src/obex_auth/obex_auth.c:81: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(ptr, chal[0].nonce, sizeof(chal[0].nonce));
data/obexpushd-0.11.2/src/obex_auth/obex_auth.c:98: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(ptr, chal[i].realm.data, chal[i].realm.len);
data/obexpushd-0.11.2/src/obex_auth/obex_auth.c:144: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(user,hdata,hlen);
data/obexpushd-0.11.2/src/obex_auth/obex_auth.c:202: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(chal[k].nonce, hdata, 16);
data/obexpushd-0.11.2/src/obex_auth/obex_auth.c:219: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(r, hdata, hlen);
data/obexpushd-0.11.2/src/obex_auth/obex_auth.c:248: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(u, user, ulen);
data/obexpushd-0.11.2/src/obex_auth/obex_auth.c:275: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,resp->digest,sizeof(resp->digest));
data/obexpushd-0.11.2/src/obex_auth/obex_auth.c:282: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(ptr,resp->user,resp->ulen);
data/obexpushd-0.11.2/src/obex_auth/obex_auth.c:289: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,resp->nonce,sizeof(resp->nonce));
data/obexpushd-0.11.2/src/obexpush_atd.c:51: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 buffer[2048];
data/obexpushd-0.11.2/src/obexpush_atd.c:126: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 line[4];
data/obexpushd-0.11.2/src/obexpush_atd.c:378: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 buf[128];
data/obexpushd-0.11.2/src/obexpush_atd.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(device, O_RDWR | O_NOCTTY, 0);
data/obexpushd-0.11.2/src/obexpushd.c:195:4:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
			char buffer[256];
data/obexpushd-0.11.2/src/obexpushd.c:197: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(net, data->net_data, sizeof(*net));
data/obexpushd-0.11.2/src/obexpushd.c:606:14:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
			FILE* p = fopen(pidfile,"w+");
data/obexpushd-0.11.2/src/utf.c:48: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(s2, s, len*sizeof(*s));
data/obexpushd-0.11.2/src/x-obex/obex-capability.c:196: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[37];
data/obexpushd-0.11.2/src/x-obex/obex-capability.c:201: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(tmp, caps->data, sizeof(caps->data));
data/obexpushd-0.11.2/src/x-obex/obex-capability.h:62: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 lang[2+1];
data/obexpushd-0.11.2/src/x-obex/obex-folder-listing.c:115: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[256];
data/obexpushd-0.11.2/src/x-obex/obex-folder-listing.c:117: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 create_time[17];
data/obexpushd-0.11.2/src/x-obex/obex-folder-listing.c:118: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 mod_time[17];
data/obexpushd-0.11.2/src/x-obex/obex-folder-listing.c:119: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 acc_time[17];
data/obexpushd-0.11.2/src/x-obex/xml_simple.h:11: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 i[XML_INDENT_COUNT*level+1];\
data/obexpushd-0.11.2/src/action/get.c:70: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).
				   hv, strlen((char*)hv.bs), 0);
data/obexpushd-0.11.2/src/action/get.c:92: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).
					   hv, strlen(header), 0);
data/obexpushd-0.11.2/src/action/get.c:110: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).
					   hv, strlen(bs), 0);
data/obexpushd-0.11.2/src/action/get.c:148: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).
	if (!transfer->type || strlen(transfer->type) == 0)
data/obexpushd-0.11.2/src/action/get.c:170:39:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		return (utf16len(transfer->name) && strlen(transfer->type));
data/obexpushd-0.11.2/src/action/setpath.c:80: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(transfer->path, "/");
data/obexpushd-0.11.2/src/auth/core.c:78:16:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	status = (int)read(fd, nonce, 16);
data/obexpushd-0.11.2/src/checks.c:44:15:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	size_t len = strlen((char*)type);
data/obexpushd-0.11.2/src/io.h:36:12:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	ssize_t (*read)(struct io_handler *self, void *buf, size_t bufsize);
data/obexpushd-0.11.2/src/io/core.c:142:30:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	if (self->ops && self->ops->read)
data/obexpushd-0.11.2/src/io/core.c:143:21:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		return self->ops->read(self, buf, bufsize);
data/obexpushd-0.11.2/src/io/internal/common.c:53: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).
	namesize = strlen(basedir) + 1 + utf8len((uint8_t*)subdir) + 1 + utf8len(namebase) + 1;
data/obexpushd-0.11.2/src/io/internal/common.c:64: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(name, "/");
data/obexpushd-0.11.2/src/io/internal/common.c:69: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(name, "/");
data/obexpushd-0.11.2/src/io/internal/common.c:219: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 (!basedir || strlen(basedir) == 0) {
data/obexpushd-0.11.2/src/io/internal/file.c:29:48:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	(void)lsetxattr(name, "user.mime_type", type, strlen(type)+1, 0);
data/obexpushd-0.11.2/src/io/internal/file.c:38: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).
	    strlen(type) != (size_t)status ||
data/obexpushd-0.11.2/src/io/script.c:154: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(buffer);
data/obexpushd-0.11.2/src/io/script.c:209: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(timestr) > 17 && timestr[17] == 'Z')
data/obexpushd-0.11.2/src/io/script.c:276:29:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		if (transfer->peername && strlen(transfer->peername))
data/obexpushd-0.11.2/src/net/btobex.c:146:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(buffer, tmp, bufsiz);
data/obexpushd-0.11.2/src/net/btobex.c:195: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(device) == 17) /* 11:22:33:44:55:66 */
data/obexpushd-0.11.2/src/net/fdobex_ctrans.c:46:14:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	return (int)read(args->in, buf, max);
data/obexpushd-0.11.2/src/net/fdobex_ctrans.c:100:10:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
			(void)read(args->sig_fd, &info, sizeof(info));
data/obexpushd-0.11.2/src/net/inobex.c:115:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(buffer, tmp, bufsiz);
data/obexpushd-0.11.2/src/net/irobex.c:60: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(addr.sir_name)? ":": ""), addr.sir_name);
data/obexpushd-0.11.2/src/net/irobex.c:63:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(buffer, tmp, bufsiz);
data/obexpushd-0.11.2/src/net/irobex.c:87:21:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		size_t slen = 5 + strlen(service) + 1;
data/obexpushd-0.11.2/src/net/tcpobex.c:154:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(buffer, tmp, bufsiz);
data/obexpushd-0.11.2/src/net/usbgobex_ctrans.c:73:14:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	return (int)read(args->fd, buf, OBEX_MAXIMUM_MTU);
data/obexpushd-0.11.2/src/net/usbgobex_ctrans.c:131:10:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
			(void)read(args->sig_fd, &info, sizeof(info));
data/obexpushd-0.11.2/src/obexpush_atd.c:190: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(cmd+cmdlen) == 0) {
data/obexpushd-0.11.2/src/obexpush_atd.c:199: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(cmd+cmdlen) == 0) {
data/obexpushd-0.11.2/src/obexpush_atd.c:208: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(cmd+cmdlen) == 0) {
data/obexpushd-0.11.2/src/obexpush_atd.c:346: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).
		size_t len = strlen(commands[i].cmd);
data/obexpushd-0.11.2/src/obexpush_atd.c:381:12:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		result = read(STDIN_FILENO, buf, sizeof(buf));
data/obexpushd-0.11.2/src/obexpush_atd.c:532: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(optarg) > 2 &&
data/obexpushd-0.11.2/src/obexpushd.c:338: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(optarg) >= 19 && optarg[0] == '[' && optarg[18] == ']') {
data/obexpushd-0.11.2/src/utf.c:33: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).
		return strlen((char*)(s));
data/obexpushd-0.11.2/src/x-obex/obex-capability.c:63: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).
	char* s = malloc(strlen(prefix)+5);
data/obexpushd-0.11.2/src/x-obex/obex-capability.c:145: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(caps->lang))
data/obexpushd-0.11.2/src/x-obex/obex-folder-listing.c:102: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(type) != (size_t)status)
data/obexpushd-0.11.2/src/x-obex/obex-folder-listing.c:212: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).
	seperator = (dir[strlen(dir)-1] == '/')? "" : "/";
data/obexpushd-0.11.2/src/x-obex/obex-folder-listing.c:214: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).
	flen = strlen(dir)+strlen(seperator)+1;
data/obexpushd-0.11.2/src/x-obex/obex-folder-listing.c:214: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).
	flen = strlen(dir)+strlen(seperator)+1;
data/obexpushd-0.11.2/src/x-obex/obex-folder-listing.c:219: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).
		tmp = realloc(filename,flen+strlen(entry->d_name));
data/obexpushd-0.11.2/src/x-obex/obex-folder-listing.c:264:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	size_t namelen = (name? strlen(name): 0);

ANALYSIS SUMMARY:

Hits = 131
Lines analyzed = 8700 in approximately 0.21 seconds (40911 lines/second)
Physical Source Lines of Code (SLOC) = 6773
Hits@level = [0] 114 [1]  47 [2]  59 [3]   4 [4]  21 [5]   0
Hits@level+ = [0+] 245 [1+] 131 [2+]  84 [3+]  25 [4+]  21 [5+]   0
Hits/KSLOC@level+ = [0+] 36.173 [1+] 19.3415 [2+] 12.4022 [3+] 3.69113 [4+] 3.10055 [5+]   0
Dot directories skipped = 1 (--followdotdir overrides)
Minimum risk level = 1
Not every hit is necessarily a security vulnerability.
There may be other security vulnerabilities; review your code!
See 'Secure Programming HOWTO'
(https://dwheeler.com/secure-programs) for more information.