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/vulkan-tools-1.2.154.0+dfsg1/common/android_util.cpp
Examining data/vulkan-tools-1.2.154.0+dfsg1/common/android_util.h
Examining data/vulkan-tools-1.2.154.0+dfsg1/common/vulkan_wrapper.cpp
Examining data/vulkan-tools-1.2.154.0+dfsg1/common/vulkan_wrapper.h
Examining data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c
Examining data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp
Examining data/vulkan-tools-1.2.154.0+dfsg1/cube/gettime.h
Examining data/vulkan-tools-1.2.154.0+dfsg1/cube/linmath.h
Examining data/vulkan-tools-1.2.154.0+dfsg1/cube/lunarg.ppm.h
Examining data/vulkan-tools-1.2.154.0+dfsg1/cube/object_type_string_helper.h
Examining data/vulkan-tools-1.2.154.0+dfsg1/icd/generated/mock_icd.cpp
Examining data/vulkan-tools-1.2.154.0+dfsg1/icd/generated/mock_icd.h
Examining data/vulkan-tools-1.2.154.0+dfsg1/icd/generated/vk_typemap_helper.h
Examining data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/generated/vulkaninfo.hpp
Examining data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/macOS/vulkaninfo/metal_view.h
Examining data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/outputprinter.h
Examining data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/vulkaninfo.cpp
Examining data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/vulkaninfo.h

FINAL RESULTS:

data/vulkan-tools-1.2.154.0+dfsg1/common/android_util.cpp:74: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(vector[0], appName);
data/vulkan-tools-1.2.154.0+dfsg1/common/android_util.cpp:78:9:  [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(vector[i + 1], args[i].c_str());
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:95:5:  [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, va);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:130:5:  [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, va);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:499:5:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
    sprintf(message, "%s - Message Id Number: %d | Message Id Name: %s\n\t%s\n", prefix, pCallbackData->messageIdNumber,
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:504:9:  [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(message, tmp_message);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:507:17:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
                sprintf(tmp_message, "\t\tObject[%d] - %s, Handle %p, Name \"%s\"\n", object,
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:511:17:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
                sprintf(tmp_message, "\t\tObject[%d] - %s, Handle %p\n", object,
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:515:13:  [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(message, tmp_message);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:521:9:  [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(message, tmp_message);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:523:13:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
            sprintf(tmp_message, "\t\tLabel[%d] - %s { %f, %f, %f, %f}\n", cmd_buf_label,
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:527:13:  [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(message, tmp_message);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:3880:22:  [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.
        int length = snprintf(NULL, 0, message, APP_SHORT_NAME, VK_PRESENT_MODE_IMMEDIATE_KHR, VK_PRESENT_MODE_MAILBOX_KHR,
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:3886: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.
        snprintf(usage, length + 1, message, APP_SHORT_NAME, VK_PRESENT_MODE_IMMEDIATE_KHR, VK_PRESENT_MODE_MAILBOX_KHR,
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp:969:13:  [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. If the scanf format is influenceable by an
  attacker, it's exploitable.
            sscanf(argv[i + 1], "%" SCNu32, &frameCount) == 1) {
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:2558:33:  [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 *display_envar = getenv("DISPLAY");
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:3771:33:  [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 *display_envar = getenv("DISPLAY");
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp:1028:33:  [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 *display_envar = getenv("DISPLAY");
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp:2522:33:  [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 *display_envar = getenv("DISPLAY");
data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/vulkaninfo.h:269:19:  [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.
        library = LoadLibrary(TEXT("vulkan-1.dll"));
data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/vulkaninfo.h:1076:31:  [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 *display_var = getenv("DISPLAY");
data/vulkan-tools-1.2.154.0+dfsg1/common/android_util.cpp:77:26:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        vector[i + 1] = (char *)malloc(strlen(args[i].c_str()) * sizeof(char));
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:309: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 name[APP_NAME_STR_LEN];  // Name to put on the window/icon
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:376: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 *extension_names[64];
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:377: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 *enabled_layers[64];
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:461: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 prefix[64] = "";
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:475:9:  [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(prefix, "VERBOSE : ");
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:477:9:  [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(prefix, "INFO : ");
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:479:9:  [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(prefix, "WARNING : ");
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:481:9:  [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(prefix, "ERROR : ");
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:485:9:  [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(prefix, "GENERAL");
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:488:13:  [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(prefix, "VALIDATION");
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:495:13:  [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(prefix, "PERFORMANCE");
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:502:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        char tmp_message[500];
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:503: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.
        sprintf(tmp_message, "\n\tObjects - %d\n", pCallbackData->objectCount);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:519:9:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
        char tmp_message[500];
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:520: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.
        sprintf(tmp_message, "\n\tCommand Buffer Labels - %d\n", pCallbackData->cmdBufLabelCount);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:888: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(demo->swapchain_image_resources[demo->current_buffer].uniform_memory_ptr, (const void *)&MVP[0][0], matrixSize);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:1497:13:  [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(rowPtr, cPtr, 3);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:1763: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(data.mvp, MVP, sizeof(MVP));
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:1805:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(demo->swapchain_image_resources[i].uniform_memory_ptr, &data, sizeof data);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:3822: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).
            demo->presentMode = atoi(argv[i + 1]);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:3861: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).
            demo->gpu_number = atoi(argv[i + 1]);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp:281: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 name[APP_NAME_STR_LEN];  // Name to put on the window/icon
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp:332: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 const *extension_names[64];
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp:333: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 const *enabled_layers[64];
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp:952:47:  [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).
            presentMode = (vk::PresentModeKHR)atoi(argv[i + 1]);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp:978: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).
            gpu_number = atoi(argv[i + 1]);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp:1724: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(data.mvp, MVP, sizeof(MVP));
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp:1761:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(swapchain_image_resources[i].uniform_memory_ptr, &data, sizeof data);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp:2397: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(swapchain_image_resources[current_buffer].uniform_memory_ptr, (const void *)&MVP[0][0], sizeof(MVP));
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp:2425:13:  [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(rowPtr, cPtr, 3);
data/vulkan-tools-1.2.154.0+dfsg1/icd/generated/mock_icd.cpp:286:5:  [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(pProperties->deviceName, "Vulkan Mock Device");
data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/vulkaninfo.cpp:408: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 buf[kBufferSize];
data/vulkan-tools-1.2.154.0+dfsg1/common/android_util.cpp:73: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).
    vector[0] = (char *)malloc(strlen(appName) * sizeof(char));
data/vulkan-tools-1.2.154.0+dfsg1/common/android_util.cpp:77:40:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        vector[i + 1] = (char *)malloc(strlen(args[i].c_str()) * sizeof(char));
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:462: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).
    char *message = (char *)malloc(strlen(pCallbackData->pMessage) + 5000);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:493:17:  [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(prefix, "|");
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:506:72:  [1] (buffer) strlen:
  Does not handle 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 (NULL != pCallbackData->pObjects[object].pObjectName && strlen(pCallbackData->pObjects[object].pObjectName) > 0) {
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:3947:38:  [1] (buffer) wcslen:
  Does not handle 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 wideCharLen = wcslen(commandLineArgs[iii]);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.c:3973:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
    strncpy(demo.name, "Vulkan Cube", APP_NAME_STR_LEN);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp:3062:38:  [1] (buffer) wcslen:
  Does not handle 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 wideCharLen = wcslen(commandLineArgs[iii]);
data/vulkan-tools-1.2.154.0+dfsg1/cube/cube.cpp:3088:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
    strncpy(demo.name, "Vulkan Cube", APP_NAME_STR_LEN);
data/vulkan-tools-1.2.154.0+dfsg1/icd/generated/mock_icd.cpp:400:22:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                std::strncpy(pProperties[i].extensionName, name_ver_pair.first.c_str(), sizeof(pProperties[i].extensionName));
data/vulkan-tools-1.2.154.0+dfsg1/icd/generated/mock_icd.cpp:431:22:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
                std::strncpy(pProperties[i].extensionName, name_ver_pair.first.c_str(), sizeof(pProperties[i].extensionName));
data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/vulkaninfo.cpp:53: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).
        max_length = std::max(max_length, std::strlen(ext.extensionName));
data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/vulkaninfo.cpp:725:51:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        layer_name_max = std::max(layer_name_max, strlen(props.layerName));
data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/vulkaninfo.cpp:726:51:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        layer_desc_max = std::max(layer_desc_max, strlen(props.description));
data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/vulkaninfo.cpp:733:58:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        auto name_padding = std::string(layer_name_max - strlen(props.layerName), ' ');
data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/vulkaninfo.cpp:734:58:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
        auto desc_padding = std::string(layer_desc_max - strlen(props.description), ' ');
data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/vulkaninfo.cpp:879: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).
            if (strlen(argv[i]) > 7 && strncmp("--json=", argv[i], 7) == 0) {
data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/vulkaninfo.cpp:887: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).
            if (strlen(argv[i]) > 14 && strncmp("--portability=", argv[i], 14) == 0) {
data/vulkan-tools-1.2.154.0+dfsg1/vulkaninfo/vulkaninfo.h:1077:35:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
    if (display_var == nullptr || strlen(display_var) == 0) {

ANALYSIS SUMMARY:

Hits = 73
Lines analyzed = 38196 in approximately 2.20 seconds (17360 lines/second)
Physical Source Lines of Code (SLOC) = 32345
Hits@level = [0]  63 [1]  19 [2]  33 [3]   6 [4]  15 [5]   0
Hits@level+ = [0+] 136 [1+]  73 [2+]  54 [3+]  21 [4+]  15 [5+]   0
Hits/KSLOC@level+ = [0+] 4.20467 [1+] 2.25692 [2+] 1.6695 [3+] 0.64925 [4+] 0.46375 [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.