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/vstream-client-1.2/crc.c
Examining data/vstream-client-1.2/io.c
Examining data/vstream-client-1.2/mfs.c
Examining data/vstream-client-1.2/mfs.h
Examining data/vstream-client-1.2/object.c
Examining data/vstream-client-1.2/partition.c
Examining data/vstream-client-1.2/preload_schema.h
Examining data/vstream-client-1.2/proto.h
Examining data/vstream-client-1.2/query.c
Examining data/vstream-client-1.2/schema.c
Examining data/vstream-client-1.2/test-client.c
Examining data/vstream-client-1.2/util.c
Examining data/vstream-client-1.2/vstream-client.h
Examining data/vstream-client-1.2/vstream.c

FINAL RESULTS:

data/vstream-client-1.2/schema.c:136:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(path, "/ObjectType/%s", vstream_schema_type(type));
data/vstream-client-1.2/test-client.c:17:9:  [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( stdout, format, va );
data/vstream-client-1.2/vstream.c:77:7:  [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( myfsid, fsid );
data/vstream-client-1.2/vstream.c:149:10:  [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( lastFsid, fsid );
data/vstream-client-1.2/io.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 tmp[SECTOR_SIZE];
data/vstream-client-1.2/io.c:112: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, tmp, size);
data/vstream-client-1.2/mfs.c:23: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[100*SECTOR_SIZE];
data/vstream-client-1.2/mfs.c:179: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, inode.u.data, ret);
data/vstream-client-1.2/mfs.c:210: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, buf2, n2);
data/vstream-client-1.2/mfs.c:307: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(meta_dir+meta_size, d2, n2*sizeof(ret[0]));
data/vstream-client-1.2/mfs.c:340: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).
		return atoi(path);
data/vstream-client-1.2/mfs.h: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 devlist[128];
data/vstream-client-1.2/mfs.h: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 junk[512];		/* ppchacker: hack, pad to avoid over-read */
data/vstream-client-1.2/mfs.h:140: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 data[452];
data/vstream-client-1.2/partition.c:18: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	name[32];	/* partition name */
data/vstream-client-1.2/partition.c:19: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[32];	/* string type description */
data/vstream-client-1.2/partition.c:30: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	processor[16];	/* identifies ISA of boot */
data/vstream-client-1.2/partition.c:45: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[SECTOR_SIZE];
data/vstream-client-1.2/query.c:82: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).
			subobj = atoi(tok);
data/vstream-client-1.2/schema.c:15: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 *types[MAX_TYPES];
data/vstream-client-1.2/schema.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 path[100];
data/vstream-client-1.2/test-client.c:10:17:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
#define fopen64 fopen
data/vstream-client-1.2/test-client.c:42: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 buffer[ CHUNK ];
data/vstream-client-1.2/test-client.c:67:23:  [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).
			offset = ((int64_t)atol(argv[0])) << 20;
data/vstream-client-1.2/util.c:64: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[255];
data/vstream-client-1.2/util.c:113: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( our_s_addr, (void*)hp->h_addr, hp->h_length );
data/vstream-client-1.2/util.c:118: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( our_s_addr, (void*)&addr, sizeof(addr) );
data/vstream-client-1.2/vstream.c:33: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 dirName[ 80 ];
data/vstream-client-1.2/vstream.c:34: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 blankTitle[ 80 ];
data/vstream-client-1.2/vstream.c:54:1:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
char lastFsid[ 80 ] = "";
data/vstream-client-1.2/vstream.c:66: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                calcFsid[ 80 ];
data/vstream-client-1.2/vstream.c:71: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                myfsid[ 80 ];
data/vstream-client-1.2/vstream.c:83:21:  [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).
         filePart = atoi( mypart );
data/vstream-client-1.2/vstream.c:93:13:  [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( calcFsid, "Part/%d/File", obj[ index ].subobj );
data/vstream-client-1.2/test-client.c:102: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 len = strlen(fsid) + 4;
data/vstream-client-1.2/util.c:22:11:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		int n = read(fd, buf, size);
data/vstream-client-1.2/util.c:141:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy( buf, inet_ntoa( *((struct in_addr*)our_s_addr) ), 255);
data/vstream-client-1.2/vstream.c:236: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).
   while( strlen( dirList[ h ].dirName ) > 0 )

ANALYSIS SUMMARY:

Hits = 38
Lines analyzed = 4326 in approximately 0.21 seconds (20363 lines/second)
Physical Source Lines of Code (SLOC) = 3883
Hits@level = [0]  22 [1]   4 [2]  30 [3]   0 [4]   4 [5]   0
Hits@level+ = [0+]  60 [1+]  38 [2+]  34 [3+]   4 [4+]   4 [5+]   0
Hits/KSLOC@level+ = [0+] 15.452 [1+] 9.78625 [2+] 8.75612 [3+] 1.03013 [4+] 1.03013 [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.