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/soapysdr-0.7.2/ExampleDriver/MyDeviceSupport.cpp
Examining data/soapysdr-0.7.2/apps/SoapyRateTest.cpp
Examining data/soapysdr-0.7.2/apps/SoapySDRProbe.cpp
Examining data/soapysdr-0.7.2/apps/SoapySDRUtil.cpp
Examining data/soapysdr-0.7.2/apps/msvc/getopt.h
Examining data/soapysdr-0.7.2/include/SoapySDR/Config.h
Examining data/soapysdr-0.7.2/include/SoapySDR/Config.hpp
Examining data/soapysdr-0.7.2/include/SoapySDR/Constants.h
Examining data/soapysdr-0.7.2/include/SoapySDR/ConverterPrimitives.hpp
Examining data/soapysdr-0.7.2/include/SoapySDR/ConverterRegistry.hpp
Examining data/soapysdr-0.7.2/include/SoapySDR/Device.h
Examining data/soapysdr-0.7.2/include/SoapySDR/Device.hpp
Examining data/soapysdr-0.7.2/include/SoapySDR/Errors.h
Examining data/soapysdr-0.7.2/include/SoapySDR/Errors.hpp
Examining data/soapysdr-0.7.2/include/SoapySDR/Formats.h
Examining data/soapysdr-0.7.2/include/SoapySDR/Formats.hpp
Examining data/soapysdr-0.7.2/include/SoapySDR/Logger.h
Examining data/soapysdr-0.7.2/include/SoapySDR/Logger.hpp
Examining data/soapysdr-0.7.2/include/SoapySDR/Modules.h
Examining data/soapysdr-0.7.2/include/SoapySDR/Modules.hpp
Examining data/soapysdr-0.7.2/include/SoapySDR/Registry.hpp
Examining data/soapysdr-0.7.2/include/SoapySDR/Time.h
Examining data/soapysdr-0.7.2/include/SoapySDR/Time.hpp
Examining data/soapysdr-0.7.2/include/SoapySDR/Types.h
Examining data/soapysdr-0.7.2/include/SoapySDR/Types.hpp
Examining data/soapysdr-0.7.2/include/SoapySDR/Version.h
Examining data/soapysdr-0.7.2/include/SoapySDR/Version.hpp
Examining data/soapysdr-0.7.2/lib/ConverterRegistry.cpp
Examining data/soapysdr-0.7.2/lib/DefaultConverters.cpp
Examining data/soapysdr-0.7.2/lib/Device.cpp
Examining data/soapysdr-0.7.2/lib/DeviceC.cpp
Examining data/soapysdr-0.7.2/lib/ErrorHelpers.hpp
Examining data/soapysdr-0.7.2/lib/Errors.cpp
Examining data/soapysdr-0.7.2/lib/ErrorsC.cpp
Examining data/soapysdr-0.7.2/lib/Factory.cpp
Examining data/soapysdr-0.7.2/lib/FactoryC.cpp
Examining data/soapysdr-0.7.2/lib/Formats.cpp
Examining data/soapysdr-0.7.2/lib/FormatsC.cpp
Examining data/soapysdr-0.7.2/lib/Logger.cpp
Examining data/soapysdr-0.7.2/lib/LoggerC.cpp
Examining data/soapysdr-0.7.2/lib/Modules.in.cpp
Examining data/soapysdr-0.7.2/lib/ModulesC.cpp
Examining data/soapysdr-0.7.2/lib/NullDevice.cpp
Examining data/soapysdr-0.7.2/lib/Registry.cpp
Examining data/soapysdr-0.7.2/lib/TimeC.cpp
Examining data/soapysdr-0.7.2/lib/TypeHelpers.hpp
Examining data/soapysdr-0.7.2/lib/Types.cpp
Examining data/soapysdr-0.7.2/lib/TypesC.cpp
Examining data/soapysdr-0.7.2/lib/Version.in.cpp
Examining data/soapysdr-0.7.2/lib/VersionC.cpp
Examining data/soapysdr-0.7.2/tests/TestFormatParser.cpp
Examining data/soapysdr-0.7.2/tests/TestKwargsMarkup.cpp
Examining data/soapysdr-0.7.2/tests/TestTimeConversion.cpp

FINAL RESULTS:

data/soapysdr-0.7.2/apps/msvc/getopt.h:98:11:  [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.
    (void)vfprintf(stderr,fmt,ap);
data/soapysdr-0.7.2/lib/LoggerC.cpp:72:30:  [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.
    case SOAPY_SDR_FATAL:    fprintf(stderr, ANSI_COLOR_BOLD ANSI_COLOR_RED "[FATAL] %s" ANSI_COLOR_RESET "\n", message); break;
data/soapysdr-0.7.2/lib/LoggerC.cpp:73:30:  [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.
    case SOAPY_SDR_CRITICAL: fprintf(stderr, ANSI_COLOR_BOLD ANSI_COLOR_RED "[CRITICAL] %s" ANSI_COLOR_RESET "\n", message); break;
data/soapysdr-0.7.2/lib/LoggerC.cpp:74:30:  [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.
    case SOAPY_SDR_ERROR:    fprintf(stderr, ANSI_COLOR_BOLD ANSI_COLOR_RED "[ERROR] %s" ANSI_COLOR_RESET "\n", message); break;
data/soapysdr-0.7.2/lib/LoggerC.cpp:75:30:  [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.
    case SOAPY_SDR_WARNING:  fprintf(stderr, ANSI_COLOR_BOLD ANSI_COLOR_YELLOW "[WARNING] %s" ANSI_COLOR_RESET "\n", message); break;
data/soapysdr-0.7.2/lib/LoggerC.cpp:76:30:  [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.
    case SOAPY_SDR_NOTICE:   fprintf(stderr, ANSI_COLOR_GREEN "[NOTICE] %s" ANSI_COLOR_RESET "\n", message); break;
data/soapysdr-0.7.2/apps/msvc/getopt.h:174:1:  [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.
getopt(int nargc, char * const *nargv, const char *options)
data/soapysdr-0.7.2/apps/msvc/getopt.h:396:22:  [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.
		posixly_correct = (getenv("POSIXLY_CORRECT") != NULL);
data/soapysdr-0.7.2/apps/msvc/getopt.h:568:1:  [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.
getopt_long(int nargc, char * const *nargv, const char *options,
data/soapysdr-0.7.2/lib/Modules.in.cpp:41:26:  [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.
    const char *result = getenv(name);
data/soapysdr-0.7.2/lib/Modules.in.cpp:253:22:  [3] (misc) LoadLibrary:
  Ensure that the full path to the library is specified, or current directory
  may be used (CWE-829, CWE-20). Use registry entry or GetWindowsDirectory to
  find library path, if you aren't already.
    HMODULE handle = LoadLibrary(path.c_str());
data/soapysdr-0.7.2/apps/msvc/getopt.h:159:6:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
			((char **) nargv)[pos] = nargv[cstart];
data/soapysdr-0.7.2/apps/msvc/getopt.h:161:6:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
			((char **)nargv)[cstart] = swap;
data/soapysdr-0.7.2/lib/DefaultConverters.cpp:25:12:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      std::memcpy(dstBuff, srcBuff, numElems*elemDepth*sampleSize);
data/soapysdr-0.7.2/lib/DefaultConverters.cpp:46:12:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      std::memcpy(dstBuff, srcBuff, numElems*elemDepth*sampleSize);
data/soapysdr-0.7.2/lib/DefaultConverters.cpp:67:12:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      std::memcpy(dstBuff, srcBuff, numElems*elemDepth*sampleSize);
data/soapysdr-0.7.2/lib/DefaultConverters.cpp:88:12:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      std::memcpy(dstBuff, srcBuff, numElems*elemDepth*sampleSize);
data/soapysdr-0.7.2/lib/DefaultConverters.cpp:341:12:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      std::memcpy(dstBuff, srcBuff, numElems*elemDepth*sampleSize);
data/soapysdr-0.7.2/lib/DefaultConverters.cpp:362:12:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      std::memcpy(dstBuff, srcBuff, numElems*elemDepth*sampleSize);
data/soapysdr-0.7.2/lib/DefaultConverters.cpp:383:12:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      std::memcpy(dstBuff, srcBuff, numElems*elemDepth*sampleSize);
data/soapysdr-0.7.2/lib/DefaultConverters.cpp:404:12:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      std::memcpy(dstBuff, srcBuff, numElems*elemDepth*sampleSize);
data/soapysdr-0.7.2/lib/DeviceC.cpp:23:17:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
static __thread char lastErrorMsg[1024];
data/soapysdr-0.7.2/lib/LoggerC.cpp:33:34:  [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).
    const int logLevelInt = std::atoi(logLevelEnvStr.c_str());
data/soapysdr-0.7.2/lib/Modules.in.cpp:56:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-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[MAX_PATH];
data/soapysdr-0.7.2/apps/msvc/getopt.h:266: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).
		current_argv_len = strlen(current_argv);
data/soapysdr-0.7.2/apps/msvc/getopt.h:274: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(long_options[i].name) == current_argv_len) {
data/soapysdr-0.7.2/lib/DeviceC.cpp:38:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
    strncpy(lastErrorMsg, msg, sizeof(lastErrorMsg));

ANALYSIS SUMMARY:

Hits = 27
Lines analyzed = 10343 in approximately 0.30 seconds (34283 lines/second)
Physical Source Lines of Code (SLOC) = 5312
Hits@level = [0]  29 [1]   3 [2]  13 [3]   5 [4]   6 [5]   0
Hits@level+ = [0+]  56 [1+]  27 [2+]  24 [3+]  11 [4+]   6 [5+]   0
Hits/KSLOC@level+ = [0+] 10.5422 [1+] 5.08283 [2+] 4.51807 [3+] 2.07078 [4+] 1.12952 [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.