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/qtcurve-1.9/gtk2/common/common.h Examining data/qtcurve-1.9/gtk2/common/config_file.cpp Examining data/qtcurve-1.9/gtk2/common/config_file.h Examining data/qtcurve-1.9/gtk2/style/animation.cpp Examining data/qtcurve-1.9/gtk2/style/animation.h Examining data/qtcurve-1.9/gtk2/style/combobox.cpp Examining data/qtcurve-1.9/gtk2/style/combobox.h Examining data/qtcurve-1.9/gtk2/style/compatability.h Examining data/qtcurve-1.9/gtk2/style/dbus.cpp Examining data/qtcurve-1.9/gtk2/style/dbus.h Examining data/qtcurve-1.9/gtk2/style/drawing.cpp Examining data/qtcurve-1.9/gtk2/style/drawing.h Examining data/qtcurve-1.9/gtk2/style/entry.cpp Examining data/qtcurve-1.9/gtk2/style/entry.h Examining data/qtcurve-1.9/gtk2/style/helpers.cpp Examining data/qtcurve-1.9/gtk2/style/helpers.h Examining data/qtcurve-1.9/gtk2/style/menu.cpp Examining data/qtcurve-1.9/gtk2/style/menu.h Examining data/qtcurve-1.9/gtk2/style/pixcache.cpp Examining data/qtcurve-1.9/gtk2/style/pixcache.h Examining data/qtcurve-1.9/gtk2/style/qt_settings.cpp Examining data/qtcurve-1.9/gtk2/style/qt_settings.h Examining data/qtcurve-1.9/gtk2/style/qtcurve.cpp Examining data/qtcurve-1.9/gtk2/style/scrollbar.cpp Examining data/qtcurve-1.9/gtk2/style/scrollbar.h Examining data/qtcurve-1.9/gtk2/style/scrolledwindow.cpp Examining data/qtcurve-1.9/gtk2/style/scrolledwindow.h Examining data/qtcurve-1.9/gtk2/style/shadowhelper.cpp Examining data/qtcurve-1.9/gtk2/style/shadowhelper.h Examining data/qtcurve-1.9/gtk2/style/tab.cpp Examining data/qtcurve-1.9/gtk2/style/tab.h Examining data/qtcurve-1.9/gtk2/style/treeview.cpp Examining data/qtcurve-1.9/gtk2/style/treeview.h Examining data/qtcurve-1.9/gtk2/style/widgetmap.cpp Examining data/qtcurve-1.9/gtk2/style/widgetmap.h Examining data/qtcurve-1.9/gtk2/style/window.cpp Examining data/qtcurve-1.9/gtk2/style/window.h Examining data/qtcurve-1.9/gtk2/style/wmmove.cpp Examining data/qtcurve-1.9/gtk2/style/wmmove.h Examining data/qtcurve-1.9/lib/cairo/draw.cpp Examining data/qtcurve-1.9/lib/cairo/draw.h Examining data/qtcurve-1.9/lib/cairo/utils.cpp Examining data/qtcurve-1.9/lib/cairo/utils.h Examining data/qtcurve-1.9/lib/cairo/utils_p.h Examining data/qtcurve-1.9/lib/utils/color.cpp Examining data/qtcurve-1.9/lib/utils/color.h Examining data/qtcurve-1.9/lib/utils/dirs.cpp Examining data/qtcurve-1.9/lib/utils/dirs.h Examining data/qtcurve-1.9/lib/utils/fd_utils.cpp Examining data/qtcurve-1.9/lib/utils/fd_utils.h Examining data/qtcurve-1.9/lib/utils/gtkutils.h Examining data/qtcurve-1.9/lib/utils/image.h Examining data/qtcurve-1.9/lib/utils/log.cpp Examining data/qtcurve-1.9/lib/utils/log.h Examining data/qtcurve-1.9/lib/utils/macros.h Examining data/qtcurve-1.9/lib/utils/map.h Examining data/qtcurve-1.9/lib/utils/number.h Examining data/qtcurve-1.9/lib/utils/options.cpp Examining data/qtcurve-1.9/lib/utils/options.h Examining data/qtcurve-1.9/lib/utils/process.cpp Examining data/qtcurve-1.9/lib/utils/process.h Examining data/qtcurve-1.9/lib/utils/qtprops.h Examining data/qtcurve-1.9/lib/utils/qtutils.h Examining data/qtcurve-1.9/lib/utils/shade.h Examining data/qtcurve-1.9/lib/utils/shadow.cpp Examining data/qtcurve-1.9/lib/utils/shadow_p.h Examining data/qtcurve-1.9/lib/utils/strs.cpp Examining data/qtcurve-1.9/lib/utils/strs.h Examining data/qtcurve-1.9/lib/utils/thread.h Examining data/qtcurve-1.9/lib/utils/timer.cpp Examining data/qtcurve-1.9/lib/utils/timer.h Examining data/qtcurve-1.9/lib/utils/utils.cpp Examining data/qtcurve-1.9/lib/utils/utils.h Examining data/qtcurve-1.9/lib/utils/x11base.h Examining data/qtcurve-1.9/lib/utils/x11blur.h Examining data/qtcurve-1.9/lib/utils/x11helpers.cpp Examining data/qtcurve-1.9/lib/utils/x11qtc.h Examining data/qtcurve-1.9/lib/utils/x11shadow.h Examining data/qtcurve-1.9/lib/utils/x11shadow_p.h Examining data/qtcurve-1.9/lib/utils/x11utils.cpp Examining data/qtcurve-1.9/lib/utils/x11utils.h Examining data/qtcurve-1.9/lib/utils/x11utils_p.h Examining data/qtcurve-1.9/lib/utils/x11wmmove.h Examining data/qtcurve-1.9/lib/utils/x11wrap.cpp Examining data/qtcurve-1.9/lib/utils/x11wrap.h Examining data/qtcurve-1.9/lib/utils/gtkprops.h Examining data/qtcurve-1.9/lib/xcb-defs/xcb/xcb.h Examining data/qtcurve-1.9/qt4/common/common.h Examining data/qtcurve-1.9/qt4/common/config_file.cpp Examining data/qtcurve-1.9/qt4/config/exportthemedialog.cpp Examining data/qtcurve-1.9/qt4/config/exportthemedialog.h Examining data/qtcurve-1.9/qt4/config/imagepropertiesdialog.cpp Examining data/qtcurve-1.9/qt4/config/imagepropertiesdialog.h Examining data/qtcurve-1.9/qt4/config/qtcurveconfig.cpp Examining data/qtcurve-1.9/qt4/config/qtcurveconfig.h Examining data/qtcurve-1.9/qt4/kwin/qtcurvebutton.cpp Examining data/qtcurve-1.9/qt4/kwin/qtcurvebutton.h Examining data/qtcurve-1.9/qt4/kwin/qtcurveclient.cpp Examining data/qtcurve-1.9/qt4/kwin/qtcurveclient.h Examining data/qtcurve-1.9/qt4/kwin/qtcurveconfig.cpp Examining data/qtcurve-1.9/qt4/kwin/qtcurveconfig.h Examining data/qtcurve-1.9/qt4/kwin/qtcurvedbus.h Examining data/qtcurve-1.9/qt4/kwin/qtcurvehandler.cpp Examining data/qtcurve-1.9/qt4/kwin/qtcurvehandler.h Examining data/qtcurve-1.9/qt4/kwin/qtcurveshadowcache.cpp Examining data/qtcurve-1.9/qt4/kwin/qtcurveshadowcache.h Examining data/qtcurve-1.9/qt4/kwin/qtcurveshadowconfiguration.cpp Examining data/qtcurve-1.9/qt4/kwin/qtcurveshadowconfiguration.h Examining data/qtcurve-1.9/qt4/kwin/qtcurvesizegrip.cpp Examining data/qtcurve-1.9/qt4/kwin/qtcurvesizegrip.h Examining data/qtcurve-1.9/qt4/kwin/qtcurvetogglebutton.cpp Examining data/qtcurve-1.9/qt4/kwin/qtcurvetogglebutton.h Examining data/qtcurve-1.9/qt4/kwin/tileset.cpp Examining data/qtcurve-1.9/qt4/kwin/tileset.h Examining data/qtcurve-1.9/qt4/kwinconfig/qtcurvekwinconfig.cpp Examining data/qtcurve-1.9/qt4/kwinconfig/qtcurvekwinconfig.h Examining data/qtcurve-1.9/qt4/style/argbhelper.cpp Examining data/qtcurve-1.9/qt4/style/argbhelper.h Examining data/qtcurve-1.9/qt4/style/blurhelper.cpp Examining data/qtcurve-1.9/qt4/style/blurhelper.h Examining data/qtcurve-1.9/qt4/style/macmenu-dbus.h Examining data/qtcurve-1.9/qt4/style/macmenu.cpp Examining data/qtcurve-1.9/qt4/style/macmenu.h Examining data/qtcurve-1.9/qt4/style/prepolish.cpp Examining data/qtcurve-1.9/qt4/style/qtcurve.cpp Examining data/qtcurve-1.9/qt4/style/qtcurve.h Examining data/qtcurve-1.9/qt4/style/qtcurve_p.h Examining data/qtcurve-1.9/qt4/style/qtcurve_plugin.cpp Examining data/qtcurve-1.9/qt4/style/qtcurve_plugin.h Examining data/qtcurve-1.9/qt4/style/shadowhelper.cpp Examining data/qtcurve-1.9/qt4/style/shadowhelper.h Examining data/qtcurve-1.9/qt4/style/shortcuthandler.cpp Examining data/qtcurve-1.9/qt4/style/shortcuthandler.h Examining data/qtcurve-1.9/qt4/style/utils.cpp Examining data/qtcurve-1.9/qt4/style/utils.h Examining data/qtcurve-1.9/qt4/style/windowmanager.cpp Examining data/qtcurve-1.9/qt4/style/windowmanager.h Examining data/qtcurve-1.9/qt5/common/common.cpp Examining data/qtcurve-1.9/qt5/common/common.h Examining data/qtcurve-1.9/qt5/common/config_file.cpp Examining data/qtcurve-1.9/qt5/common/config_file.h Examining data/qtcurve-1.9/qt5/common/kf5_utils.cpp Examining data/qtcurve-1.9/qt5/common/kf5_utils.h Examining data/qtcurve-1.9/qt5/config/exportthemedialog.cpp Examining data/qtcurve-1.9/qt5/config/exportthemedialog.h Examining data/qtcurve-1.9/qt5/config/imagepropertiesdialog.cpp Examining data/qtcurve-1.9/qt5/config/imagepropertiesdialog.h Examining data/qtcurve-1.9/qt5/config/qtcurveconfig.cpp Examining data/qtcurve-1.9/qt5/config/qtcurveconfig.h Examining data/qtcurve-1.9/qt5/kwin/qtcurvebutton.cpp Examining data/qtcurve-1.9/qt5/kwin/qtcurvebutton.h Examining data/qtcurve-1.9/qt5/kwin/qtcurveclient.cpp Examining data/qtcurve-1.9/qt5/kwin/qtcurveclient.h Examining data/qtcurve-1.9/qt5/kwin/qtcurveconfig.cpp Examining data/qtcurve-1.9/qt5/kwin/qtcurveconfig.h Examining data/qtcurve-1.9/qt5/kwin/qtcurvedbus.h Examining data/qtcurve-1.9/qt5/kwin/qtcurvehandler.cpp Examining data/qtcurve-1.9/qt5/kwin/qtcurvehandler.h Examining data/qtcurve-1.9/qt5/kwin/qtcurveshadowcache.cpp Examining data/qtcurve-1.9/qt5/kwin/qtcurveshadowcache.h Examining data/qtcurve-1.9/qt5/kwin/qtcurveshadowconfiguration.cpp Examining data/qtcurve-1.9/qt5/kwin/qtcurveshadowconfiguration.h Examining data/qtcurve-1.9/qt5/kwin/qtcurvesizegrip.cpp Examining data/qtcurve-1.9/qt5/kwin/qtcurvesizegrip.h Examining data/qtcurve-1.9/qt5/kwin/qtcurvetogglebutton.cpp Examining data/qtcurve-1.9/qt5/kwin/qtcurvetogglebutton.h Examining data/qtcurve-1.9/qt5/kwin/tileset.cpp Examining data/qtcurve-1.9/qt5/kwin/tileset.h Examining data/qtcurve-1.9/qt5/kwinconfig/qtcurvekwinconfig.cpp Examining data/qtcurve-1.9/qt5/kwinconfig/qtcurvekwinconfig.h Examining data/qtcurve-1.9/qt5/style/argbhelper.cpp Examining data/qtcurve-1.9/qt5/style/argbhelper.h Examining data/qtcurve-1.9/qt5/style/blurhelper.cpp Examining data/qtcurve-1.9/qt5/style/blurhelper.h Examining data/qtcurve-1.9/qt5/style/prepolish.cpp Examining data/qtcurve-1.9/qt5/style/qtcurve.cpp Examining data/qtcurve-1.9/qt5/style/qtcurve_api.cpp Examining data/qtcurve-1.9/qt5/style/qtcurve_p.h Examining data/qtcurve-1.9/qt5/style/qtcurve_plugin.cpp Examining data/qtcurve-1.9/qt5/style/qtcurve_plugin.h Examining data/qtcurve-1.9/qt5/style/qtcurve_primitive.cpp Examining data/qtcurve-1.9/qt5/style/qtcurve_utils.cpp Examining data/qtcurve-1.9/qt5/style/shadowhelper.cpp Examining data/qtcurve-1.9/qt5/style/shadowhelper.h Examining data/qtcurve-1.9/qt5/style/shortcuthandler.cpp Examining data/qtcurve-1.9/qt5/style/shortcuthandler.h Examining data/qtcurve-1.9/qt5/style/utils.cpp Examining data/qtcurve-1.9/qt5/style/utils.h Examining data/qtcurve-1.9/qt5/style/windowmanager.cpp Examining data/qtcurve-1.9/qt5/style/windowmanager.h Examining data/qtcurve-1.9/qt5/style/qtcurve.h Examining data/qtcurve-1.9/test/test-buff.cpp Examining data/qtcurve-1.9/test/test-call.cpp Examining data/qtcurve-1.9/test/test-color-str.cpp Examining data/qtcurve-1.9/test/test-containerof.cpp Examining data/qtcurve-1.9/test/test-default-arg.cpp Examining data/qtcurve-1.9/test/test-default.cpp Examining data/qtcurve-1.9/test/test-oneof.cpp Examining data/qtcurve-1.9/test/test-popen-buff.cpp Examining data/qtcurve-1.9/test/test-popen.cpp Examining data/qtcurve-1.9/test/test-printf.cpp Examining data/qtcurve-1.9/test/test-process.cpp Examining data/qtcurve-1.9/test/test-search.cpp Examining data/qtcurve-1.9/test/test-strlist.cpp Examining data/qtcurve-1.9/test/test-strmap.cpp Examining data/qtcurve-1.9/test/test-version.cpp Examining data/qtcurve-1.9/tools/qt_dump_png.cpp FINAL RESULTS: data/qtcurve-1.9/gtk2/style/drawing.cpp:1326:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %d %d %d %d %d ", __FUNCTION__, data/qtcurve-1.9/gtk2/style/drawing.cpp:2932:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %d %d %d %d %d %d %d %d ", __FUNCTION__, data/qtcurve-1.9/gtk2/style/drawing.cpp:3268:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %d %d %d %d %d %d %s ", data/qtcurve-1.9/gtk2/style/helpers.cpp:1434:13: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(str, format, toQtColor(col->red), toQtColor(col->green), toQtColor(col->blue), data/qtcurve-1.9/gtk2/style/qt_settings.cpp:52:34: [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. gtk_rc_parse_string(str_buff.printf(args)) data/qtcurve-1.9/gtk2/style/qt_settings.cpp:381: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(f->family, DEFAULT_KDE_FONT); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:407:13: [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(rc.family, l); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:432:13: [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(font->family, rc.family); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:456:5: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(qtSettings.fonts[f], "%s %s %s %f", font->family, data/qtcurve-1.9/gtk2/style/qt_settings.cpp:468:9: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(qtSettings.fonts[FONT_BOLD], "%s %s %s %f", font->family, data/qtcurve-1.9/gtk2/style/qt_settings.cpp:472:9: [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, DEBUG_PREFIX"Font[%d] - %s\n", f, qtSettings.fonts[f]); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:504:13: [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, DEBUG_PREFIX "Reading kwinrc\n"); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:586:13: [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, DEBUG_PREFIX"Reading kdeglobals - %s\n", rc); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:637:21: [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(qtSettings.icons, eq); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:799:17: [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(qtSettings.styleName, &line[12]); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:937: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(qtSettings.icons, defaultIcons()); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1013:9: [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, DEBUG_PREFIX "%s\n", buff.get()); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1025:13: [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 (access(fname, W_OK) != 0) { data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1249: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(stderr, DEBUG_PREFIX"Application name: \"%s\"\n", qtSettings.appName ? qtSettings.appName : "<unknown>"); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1401:17: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(version, "#%s %s %02X%02X%02X%02X%02X%02X%02X", data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1423:21: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(cmdStr, constCmdStrFmt, 4, data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1433:21: [4] (shell) system: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. system(cmdStr); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1447:38: [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. if(qtSettings.debug) fprintf(stderr, DEBUG_PREFIX "gtk-toolbar-style %d\n", qtSettings.toolbarStyle); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1450:42: [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. if(qtSettings.debug) fprintf(stderr, DEBUG_PREFIX "gtk-button-images %d\n", qtSettings.buttonIcons); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1479:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constFormat, qtSettings.fonts[FONT_GENERAL]); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1500:21: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(tmpStr, "%s%s%s%s%s%s%s", data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1508:21: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(tmpStr, "%s%s%s", constBoldPrefix, qtSettings.fonts[FONT_BOLD], constBoldSuffix); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1520:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constFormat, qtSettings.fonts[FONT_MENU]); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1530:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constFormat, qtSettings.fonts[FONT_TOOLBAR]); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1581:25: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constSbStrFormat, 1, 1, 1, 0); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1584:25: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constSbStrFormat, 1, 1, 0, 0); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1587:25: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constSbStrFormat, 0, 1, 1, 0); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1590:25: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constSbStrFormat, 1, 0, 0, 1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1593:25: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constSbStrFormat, 0, 0, 0, 0); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1607:13: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constStrFormat, data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1629:13: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constStrFormat, (opts.thin & THIN_BUTTONS) || data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1644:13: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constStrFormat, thick, thick, thick, thick); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1657:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constStrFormat, thick, thick); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1682:13: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constStrFormat, thickness, thickness); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1693:13: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constStrFormat, pthickness, pthickness); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1704:13: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constStrFormat, data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1748:13: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constStrFormat, data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1774:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constStrFormat, data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1805:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constStrFormat, data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1820:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constStrFormat, opts.sliderWidth, data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1849:13: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constStrFormat, length, width); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1878:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(tmpStr, constStrFormat, opts.crSize); data/qtcurve-1.9/gtk2/style/qtcurve.cpp:155:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %d %d %d %d %d %s ", __FUNCTION__, data/qtcurve-1.9/gtk2/style/qtcurve.cpp:450:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %d %d %d %s ", __FUNCTION__, state, shadow, data/qtcurve-1.9/gtk2/style/qtcurve.cpp:541:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %d %d %d %d %d %d %s ", __FUNCTION__, data/qtcurve-1.9/gtk2/style/qtcurve.cpp:750:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %d %d %d %d %d %d %s ", __FUNCTION__, data/qtcurve-1.9/gtk2/style/qtcurve.cpp:1769:13: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %d %d %d %d %d %s ", __FUNCTION__, data/qtcurve-1.9/gtk2/style/qtcurve.cpp:2052:13: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %s %d %d %d %d %d %s ", __FUNCTION__, data/qtcurve-1.9/gtk2/style/qtcurve.cpp:2219:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %d %s ", __FUNCTION__, state, shadow, data/qtcurve-1.9/gtk2/style/qtcurve.cpp:2292:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %d %d %d %d %d %d %s ", __FUNCTION__, state, data/qtcurve-1.9/gtk2/style/qtcurve.cpp:2323:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %d %d %d %d %d %s ", __FUNCTION__, state, data/qtcurve-1.9/gtk2/style/qtcurve.cpp:2470:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %d %d %d %s ", __FUNCTION__, state, x1, x2, data/qtcurve-1.9/gtk2/style/qtcurve.cpp:2560:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %d %d %d %s ", __FUNCTION__, state, x, y1, data/qtcurve-1.9/gtk2/style/qtcurve.cpp:2626:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %d %d %d %d %s ", __FUNCTION__, state, x, y, data/qtcurve-1.9/gtk2/style/qtcurve.cpp:2975:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d %s ", __FUNCTION__, state, _detail); data/qtcurve-1.9/gtk2/style/shadowhelper.cpp:41:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s\n", __FUNCTION__); data/qtcurve-1.9/gtk2/style/shadowhelper.cpp:50:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %p\n", __FUNCTION__, widget); data/qtcurve-1.9/gtk2/style/shadowhelper.cpp:59:17: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d\n", __FUNCTION__, (int)hint); data/qtcurve-1.9/gtk2/style/shadowhelper.cpp:77:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %p\n", __FUNCTION__, widget); data/qtcurve-1.9/gtk2/style/shadowhelper.cpp:91:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %p\n", __FUNCTION__, widget); data/qtcurve-1.9/gtk2/style/shadowhelper.cpp:119:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %p\n", __FUNCTION__, widget); data/qtcurve-1.9/gtk2/style/shadowhelper.cpp:130:9: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(DEBUG_PREFIX "%s %d\n", __FUNCTION__, qtSettings.app); data/qtcurve-1.9/lib/utils/dirs.cpp:58:17: [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 (access(opath, F_OK)) { data/qtcurve-1.9/lib/utils/dirs.cpp:64:9: [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 (access(opath, F_OK)) { data/qtcurve-1.9/lib/utils/dirs.h:103:13: [4] (race) access: This usually indicates a security flaw. If an attacker can change anything along the path between the call to access() and the file's actual use (e.g., by moving files), the attacker can exploit the race condition (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid()) and try to open the file directly. access(path, R_OK | X_OK) == 0); data/qtcurve-1.9/lib/utils/dirs.h:115:13: [4] (race) access: This usually indicates a security flaw. If an attacker can change anything along the path between the call to access() and the file's actual use (e.g., by moving files), the attacker can exploit the race condition (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid()) and try to open the file directly. access(path, R_OK) == 0); data/qtcurve-1.9/lib/utils/log.cpp:117:5: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. vfprintf(stderr, fmt, ap); data/qtcurve-1.9/lib/utils/log.h:43:23: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. __attribute__((format(printf, 5, 0))) data/qtcurve-1.9/lib/utils/log.h:47:23: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. __attribute__((format(printf, 5, 6))) data/qtcurve-1.9/lib/utils/process.cpp:103:5: [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(data->file, data->argv); data/qtcurve-1.9/lib/utils/strs.cpp:42:23: [4] (format) vsnprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. size_t new_size = vsnprintf(buff, size, fmt, ap) + 1; data/qtcurve-1.9/lib/utils/strs.cpp:51:20: [4] (format) vsnprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. new_size = vsnprintf(buff, new_size, fmt, _ap); data/qtcurve-1.9/lib/utils/strs.h:91:53: [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. template<bool allocated=true> __attribute__((format(printf, 3, 0))) data/qtcurve-1.9/lib/utils/strs.h:95:39: [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. extern template __attribute__((format(printf, 3, 0))) data/qtcurve-1.9/lib/utils/strs.h:97:39: [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. extern template __attribute__((format(printf, 3, 0))) data/qtcurve-1.9/lib/utils/strs.h:102:23: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. __attribute__((format(printf, 3, 4))) data/qtcurve-1.9/lib/utils/strs.h:152:27: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. __attribute__((format(printf, 2, 3))) data/qtcurve-1.9/lib/utils/strs.h:154:5: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(const char *fmt, ...) data/qtcurve-1.9/qt4/common/config_file.cpp:1382:25: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. gradKey.sprintf("customgradient%d", (i-APPEARANCE_CUSTOM1)+1); data/qtcurve-1.9/qt4/common/config_file.cpp:1773:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. app.sprintf("customgradient%d", (exp-APPEARANCE_CUSTOM1)+1); data/qtcurve-1.9/qt4/common/config_file.cpp:1783:14: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. colorStr.sprintf("#%02X%02X%02X", col.red(), col.green(), col.blue()); data/qtcurve-1.9/qt4/common/config_file.cpp:2379:21: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. gradKey.sprintf("customgradient%d", (i-APPEARANCE_CUSTOM1)+1); data/qtcurve-1.9/qt4/style/qtcurve.cpp:5145:25: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. key.sprintf("qtc-sel-%x-%x", r.height(), color.rgba()); data/qtcurve-1.9/qt4/style/qtcurve.cpp:10857:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. key.sprintf("qtc-%x-%x-%x-%x-%x-%x-%x-%x-%x", w, onToolbar ? 1 : 0, round, (int)realRound, pixSize.width(), pixSize.height(), data/qtcurve-1.9/qt4/style/qtcurve.cpp:11263:9: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. key.sprintf("qtc-stripes-%x", col.rgba()); data/qtcurve-1.9/qt4/style/qtcurve.cpp:11334:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. key.sprintf("qtc-bgnd-%x-%d-%d", col.rgba(), grad, app); data/qtcurve-1.9/qt4/style/qtcurve.cpp:11370:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. key.sprintf("qtc-radial-%x", size/BGND_SHINE_STEPS); data/qtcurve-1.9/qt5/common/config_file.cpp:1392:25: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. gradKey.sprintf("customgradient%d", (i-APPEARANCE_CUSTOM1)+1); data/qtcurve-1.9/qt5/common/config_file.cpp:1788:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. app.sprintf("customgradient%d", (exp-APPEARANCE_CUSTOM1)+1); data/qtcurve-1.9/qt5/common/config_file.cpp:1798:14: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. colorStr.sprintf("#%02X%02X%02X", col.red(), col.green(), col.blue()); data/qtcurve-1.9/qt5/common/config_file.cpp:2393:21: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. gradKey.sprintf("customgradient%d", (i-APPEARANCE_CUSTOM1)+1); data/qtcurve-1.9/qt5/style/qtcurve.cpp:1680:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. key.sprintf("qtc-%x-%x-%x-%x-%x-%x-%x-%x-%x", w, onToolbar ? 1 : 0, data/qtcurve-1.9/qt5/style/qtcurve.cpp:2105:9: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. key.sprintf("qtc-stripes-%x", col.rgba()); data/qtcurve-1.9/qt5/style/qtcurve.cpp:2175:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. key.sprintf("qtc-bgnd-%x-%d-%d", col.rgba(), grad, app); data/qtcurve-1.9/qt5/style/qtcurve.cpp:2215:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. key.sprintf("qtc-radial-%x", size / BGND_SHINE_STEPS); data/qtcurve-1.9/qt5/style/qtcurve_primitive.cpp:855:17: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. key.sprintf("qtc-sel-%x-%x", r.height(), color.rgba()); data/qtcurve-1.9/test/test-printf.cpp:33:5: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf(static_res, TEST_FORMAT); data/qtcurve-1.9/test/test-printf.cpp:66:26: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. char *m_res7 = buff7.printf(TEST_FORMAT); data/qtcurve-1.9/test/test-printf.cpp:73:26: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. char *m_res8 = buff8.printf(TEST_FORMAT); data/qtcurve-1.9/test/test-printf.cpp:80:26: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. char *m_res9 = buff9.printf(TEST_FORMAT); data/qtcurve-1.9/test/test-printf.cpp:87:28: [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. char *m_res10 = buff10.printf(TEST_FORMAT); data/qtcurve-1.9/gtk2/common/config_file.cpp:1141:27: [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 *env = getenv("QTCURVE_CONFIG_FILE"); data/qtcurve-1.9/gtk2/style/helpers.h:90:14: [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. !getenv("QTCURVE_MOZ_TEST")); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:67:20: [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. if ((res = getenv(getuid() ? "KDEHOME" : "KDEROOTHOME"))) { data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1080:27: [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. if (const char *dbg = getenv("QTCURVE_DEBUG")) { data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1168:35: [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. if (const char *env = getenv("QTC_STYLE")) { data/qtcurve-1.9/lib/utils/dirs.cpp:74:32: [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 *env_home = getenv("HOME"); data/qtcurve-1.9/lib/utils/dirs.cpp:93:32: [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 *env_home = getenv("XDG_CONFIG_HOME"); data/qtcurve-1.9/lib/utils/dirs.cpp:107:32: [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 *env_home = getenv("XDG_DATA_HOME"); data/qtcurve-1.9/lib/utils/dirs.cpp:132:21: [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. char *env = getenv(getuid() ? "KDEHOME" : "KDEROOTHOME"); data/qtcurve-1.9/lib/utils/dirs.cpp:149:32: [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 *env_home = getenv("QTCURVE_CONFIG_DIR"); data/qtcurve-1.9/lib/utils/dirs.cpp:182:34: [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. if (auto xdg_data_dirs = getenv("XDG_DATA_DIRS")) { data/qtcurve-1.9/lib/utils/log.cpp:51: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 *env_debug = getenv("QTCURVE_DEBUG"); data/qtcurve-1.9/lib/utils/log.cpp:62:41: [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. LogLevel res = level_map.search(getenv("QTCURVE_LEVEL"), data/qtcurve-1.9/lib/utils/log.cpp:76: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 *env_color = getenv("QTCURVE_LOG_COLOR"); data/qtcurve-1.9/qt4/common/config_file.cpp:1067:27: [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 *env = getenv("QTCURVE_CONFIG_FILE"); data/qtcurve-1.9/qt4/config/qtcurveconfig.cpp:456:21: [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 *path=getenv(env); data/qtcurve-1.9/qt4/style/qtcurve.cpp:906:23: [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 *env = getenv(QTCURVE_PREVIEW_CONFIG); data/qtcurve-1.9/qt5/common/config_file.cpp:1076:25: [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 *env=getenv("QTCURVE_CONFIG_FILE"); data/qtcurve-1.9/qt5/config/qtcurveconfig.cpp:465:21: [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 *path=getenv(env); data/qtcurve-1.9/qt5/style/qtcurve.cpp:354:23: [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 *env = getenv(QTCURVE_PREVIEW_CONFIG); data/qtcurve-1.9/qt5/style/qtcurve.cpp:706:9: [3] (buffer) getenv: Environment variables are untrustable input if they can be set by an attacker. They can have any content and length, and the same variable can be set more than once (CWE-807, CWE-20). Check environment variables carefully before using them. if (getenv("QTCURVE_DEBUG")) { data/qtcurve-1.9/test/test-popen-buff.cpp:37:23: [3] (random) random: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. buff[i] = random(); data/qtcurve-1.9/test/test-popen-buff.cpp:55:5: [3] (random) srandom: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. srandom(time(nullptr)); data/qtcurve-1.9/test/test-popen.cpp:36:23: [3] (random) random: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. buff[i] = random(); data/qtcurve-1.9/test/test-popen.cpp:54:5: [3] (random) srandom: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. srandom(time(nullptr)); data/qtcurve-1.9/test/test-process.cpp:49:5: [3] (random) srandom: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. srandom(time(nullptr)); data/qtcurve-1.9/test/test-process.cpp:50:11: [3] (random) random: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. num = random(); data/qtcurve-1.9/gtk2/common/config_file.cpp:178:19: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). int i=atoi(&str[14]); data/qtcurve-1.9/gtk2/common/config_file.cpp:515: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). FILE *f=fopen(qtcGetBarFileName(app, prefix), "w"); data/qtcurve-1.9/gtk2/common/config_file.cpp:571:19: [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 *f=fopen(filename, "r"); data/qtcurve-1.9/gtk2/common/config_file.cpp:576: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 line[MAX_CONFIG_INPUT_LINE_LEN]; data/qtcurve-1.9/gtk2/common/config_file.cpp:619:18: [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 str ? atoi(str) : def; data/qtcurve-1.9/gtk2/common/config_file.cpp:877:17: [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(destGrad->stops, srcGrad->stops, data/qtcurve-1.9/gtk2/common/config_file.cpp:891: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(dest, src, sizeof(Options)); data/qtcurve-1.9/gtk2/common/config_file.cpp:898: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(dest->customShades, src->customShades, data/qtcurve-1.9/gtk2/common/config_file.cpp:900: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(dest->customAlphas, src->customAlphas, data/qtcurve-1.9/gtk2/common/config_file.cpp:1234:21: [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(opts->customShades, def->customShades, data/qtcurve-1.9/gtk2/common/config_file.cpp:1426: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. char gradKey[18]; data/qtcurve-1.9/gtk2/common/config_file.cpp:1427:17: [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(gradKey, "customgradient%d", i + 1); data/qtcurve-1.9/gtk2/common/config_file.cpp:1530:41: [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(&stops[addStart], grad->stops, data/qtcurve-1.9/gtk2/style/helpers.cpp:1229: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(qtcPalette.menubar, qtcPalette.background, data/qtcurve-1.9/gtk2/style/qt_settings.cpp:351: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). return line[offset]!='\0' ? atoi(&line[offset]) : 0; data/qtcurve-1.9/gtk2/style/qt_settings.cpp:371: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 family[MAX_CONFIG_INPUT_LINE_LEN+1]; data/qtcurve-1.9/gtk2/style/qt_settings.cpp:392: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 fontLine[MAX_CONFIG_INPUT_LINE_LEN+1]; data/qtcurve-1.9/gtk2/style/qt_settings.cpp:396: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(fontLine, line, MAX_CONFIG_INPUT_LINE_LEN + 1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:499:19: [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). if (FILE *f = fopen(kwinrc(), "r")) { data/qtcurve-1.9/gtk2/style/qt_settings.cpp:501: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 line[MAX_CONFIG_INPUT_LINE_LEN + 1]; data/qtcurve-1.9/gtk2/style/qt_settings.cpp:529: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 line[MAX_CONFIG_INPUT_LINE_LEN+1]; data/qtcurve-1.9/gtk2/style/qt_settings.cpp:530:22: [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 *f=fopen(rc, "r"); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:866: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(qtSettings.colors[p], qtSettings.colors[PAL_ACTIVE], sizeof(GdkColor) * COLOR_NUMCOLORS_STD); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1021:15: [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 *f = fopen(fname, "r"); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1030:13: [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[constVLen + 1]; data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1081:17: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). switch (atoi(dbg)) { data/qtcurve-1.9/gtk2/style/qt_settings.h:130: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 *fonts[FONT_NUM_TOTAL]; data/qtcurve-1.9/gtk2/style/qtcurve.cpp:3135: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(copy.color_flags, dest->color_flags, sizeof(GtkRcFlags)*5); data/qtcurve-1.9/gtk2/style/qtcurve.cpp:3136: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(copy.fg, dest->fg, sizeof(GdkColor)*5); data/qtcurve-1.9/gtk2/style/qtcurve.cpp:3137: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(copy.bg, dest->bg, sizeof(GdkColor)*5); data/qtcurve-1.9/gtk2/style/qtcurve.cpp:3138: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(copy.text, dest->text, sizeof(GdkColor)*5); data/qtcurve-1.9/gtk2/style/qtcurve.cpp:3139: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(copy.base, dest->base, sizeof(GdkColor)*5); data/qtcurve-1.9/gtk2/style/qtcurve.cpp:3146: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(dest->color_flags, copy.color_flags, sizeof(GtkRcFlags)*5); data/qtcurve-1.9/gtk2/style/qtcurve.cpp:3147: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(dest->fg, copy.fg, sizeof(GdkColor)*5); data/qtcurve-1.9/gtk2/style/qtcurve.cpp:3148: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(dest->bg, copy.bg, sizeof(GdkColor)*5); data/qtcurve-1.9/gtk2/style/qtcurve.cpp:3149: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(dest->text, copy.text, sizeof(GdkColor)*5); data/qtcurve-1.9/gtk2/style/qtcurve.cpp:3150: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(dest->base, copy.base, sizeof(GdkColor)*5); data/qtcurve-1.9/lib/utils/color.cpp:468:5: [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(str, "#%02X%02X%02X", (unsigned)(qtcBound(0, color->red, 1) * 255), data/qtcurve-1.9/lib/utils/fd_utils.cpp:36: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 control[CMSG_SPACE(sizeof(int))]; data/qtcurve-1.9/lib/utils/fd_utils.cpp:48: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(CMSG_DATA(cmsg), &fd, sizeof(int)); data/qtcurve-1.9/lib/utils/fd_utils.cpp:62: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 control[CMSG_SPACE(sizeof(int))]; data/qtcurve-1.9/lib/utils/fd_utils.cpp:76: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(&fd, CMSG_DATA(cmsg), sizeof(int)); data/qtcurve-1.9/lib/utils/process.cpp:136:26: [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). replace_fd = open("/dev/null", O_RDWR); data/qtcurve-1.9/lib/utils/strs.cpp:139: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(buff.get() + len, p, sub_len); data/qtcurve-1.9/lib/utils/strs.h:76: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(dest, src, len); data/qtcurve-1.9/lib/utils/strs.h:125: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(p, strs_l[i], str_lens[i]); data/qtcurve-1.9/lib/utils/strs.h:195: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(p, strs_l[i], str_lens[i]); data/qtcurve-1.9/lib/utils/utils.h:188: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(m_ptr, ary, sizeof(T) * size); data/qtcurve-1.9/lib/utils/utils.h:202:17: [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(m_ptr, m_static_buf, sizeof(T) * m_size); data/qtcurve-1.9/lib/utils/x11helpers.cpp:91: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(shadow_data_xcb, shadow_xpixmaps, sizeof(shadow_xpixmaps)); data/qtcurve-1.9/lib/utils/x11helpers.cpp:125: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(shadow_data, shadow_data_xlib, 12 * sizeof(unsigned long)); data/qtcurve-1.9/lib/utils/x11helpers.cpp:133: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(shadow_data, shadow_data_xcb, 12 * sizeof(uint32_t)); data/qtcurve-1.9/lib/utils/x11helpers.cpp:176: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 _buff[32]; data/qtcurve-1.9/lib/utils/x11utils.cpp: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 wm_cm_s_atom_name[100] = "_NET_WM_CM_S"; data/qtcurve-1.9/lib/utils/x11utils.cpp:165:5: [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(wm_cm_s_atom_name + base_len, "%d", screen_no); data/qtcurve-1.9/qt4/common/config_file.cpp:196:19: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). int i=atoi(&str[14]); data/qtcurve-1.9/qt4/common/config_file.cpp:512:15: [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 (f.open(QIODevice::ReadOnly)) { data/qtcurve-1.9/qt4/common/config_file.cpp:538:68: [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). QFile(QFile::decodeName(QtCurve::getConfDir())+prefix+app).open(QIODevice::WriteOnly); data/qtcurve-1.9/qt4/common/config_file.cpp:598: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). if (f.open(QIODevice::ReadOnly)) { data/qtcurve-1.9/qt4/common/config_file.cpp:1164:21: [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(opts->customShades, def->customShades, sizeof(double)*QTC_NUM_STD_SHADES); data/qtcurve-1.9/qt4/config/qtcurveconfig.cpp:2694:27: [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 (!zip->open(QIODevice::ReadOnly)) { data/qtcurve-1.9/qt4/config/qtcurveconfig.cpp:2836: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 (zip && !zip->open(QIODevice::WriteOnly)) data/qtcurve-1.9/qt4/config/qtcurveconfig.cpp:2840:32: [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 (temp && !temp->open()) data/qtcurve-1.9/qt4/kwin/qtcurveclient.cpp:1124: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 _buff[32]; data/qtcurve-1.9/qt4/kwin/qtcurveclient.cpp:1142:13: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char _buff[32]; data/qtcurve-1.9/qt4/kwin/qtcurveclient.cpp:1162:13: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char _buff[32]; data/qtcurve-1.9/qt4/kwin/qtcurvehandler.cpp:308: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). if (in.open(QIODevice::ReadOnly)) { data/qtcurve-1.9/qt4/kwin/qtcurvehandler.cpp:326:22: [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 (sizeFile.open()) data/qtcurve-1.9/qt4/style/qtcurve.cpp:12850: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(m_menubarCols, m_backgroundCols, sizeof(QColor)*(TOTAL_SHADES+1)); data/qtcurve-1.9/qt4/style/qtcurve.cpp:12972:14: [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(f.open(QIODevice::ReadOnly)) data/qtcurve-1.9/qt5/common/config_file.cpp:202:19: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). int i=atoi(&str[14]); data/qtcurve-1.9/qt5/common/config_file.cpp:518:14: [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(f.open(QIODevice::ReadOnly)) { data/qtcurve-1.9/qt5/common/config_file.cpp:545:68: [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). QFile(QFile::decodeName(QtCurve::getConfDir())+prefix+app).open(QIODevice::WriteOnly); data/qtcurve-1.9/qt5/common/config_file.cpp:606: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). if (f.open(QIODevice::ReadOnly)) { data/qtcurve-1.9/qt5/common/config_file.cpp:1171:21: [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(opts->customShades, def->customShades, sizeof(double)*QTC_NUM_STD_SHADES); data/qtcurve-1.9/qt5/config/qtcurveconfig.cpp:2658:27: [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 (!zip->open(QIODevice::ReadOnly)) { data/qtcurve-1.9/qt5/config/qtcurveconfig.cpp:2799:29: [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 (zip && zip->open(QIODevice::WriteOnly)) data/qtcurve-1.9/qt5/config/qtcurveconfig.cpp:2803:32: [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 (temp && !temp->open()) data/qtcurve-1.9/qt5/kwin/qtcurveclient.cpp:1125: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 _buff[32]; data/qtcurve-1.9/qt5/kwin/qtcurveclient.cpp:1143:13: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char _buff[32]; data/qtcurve-1.9/qt5/kwin/qtcurveclient.cpp:1163:13: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char _buff[32]; data/qtcurve-1.9/qt5/kwin/qtcurvehandler.cpp:308: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). if (in.open(QIODevice::ReadOnly)) { data/qtcurve-1.9/qt5/kwin/qtcurvehandler.cpp:326:22: [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 (sizeFile.open()) data/qtcurve-1.9/qt5/style/qtcurve.cpp:3752: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(m_menubarCols, m_backgroundCols, sizeof(QColor)*(TOTAL_SHADES+1)); data/qtcurve-1.9/qt5/style/qtcurve.cpp:3887:15: [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 (f.open(QIODevice::ReadOnly)) { data/qtcurve-1.9/test/test-color-str.cpp:28: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 origin[10]; data/qtcurve-1.9/test/test-color-str.cpp:29: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 res[10]; data/qtcurve-1.9/test/test-color-str.cpp:34:17: [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(origin, "#%01X%01X%01X", r, g, b); data/qtcurve-1.9/test/test-color-str.cpp:40:17: [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(origin, "#%02X%02X%02X", r * 255 / 15, g * 255 / 15, data/qtcurve-1.9/test/test-color-str.cpp:51: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 origin[10]; data/qtcurve-1.9/test/test-color-str.cpp:52: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 res[10]; data/qtcurve-1.9/test/test-color-str.cpp:57:17: [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(origin, "#%02X%02X%02X", r, g, b); data/qtcurve-1.9/test/test-popen-buff.cpp:29: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 buff1[1024]; data/qtcurve-1.9/test/test-popen-buff.cpp:30: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 buff2[1024]; data/qtcurve-1.9/test/test-popen-buff.cpp:46: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 buff3[1024] = {0}; data/qtcurve-1.9/test/test-popen.cpp:28: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 buff1[1024]; data/qtcurve-1.9/test/test-popen.cpp:29: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 buff2[1024]; data/qtcurve-1.9/test/test-popen.cpp:45: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 buff3[1024] = {0}; data/qtcurve-1.9/test/test-popen.cpp:73: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 buff3[1024] = {0}; data/qtcurve-1.9/test/test-printf.cpp:32: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 static_res[1024]; data/qtcurve-1.9/test/test-printf.cpp:53: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 buff5[size]; data/qtcurve-1.9/test/test-printf.cpp:59: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 buff6[size]; data/qtcurve-1.9/test/test-strmap.cpp:83: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 key[4]; data/qtcurve-1.9/tools/qt_dump_png.cpp:32:24: [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 *outputfile = fopen(outputname, "w"); data/qtcurve-1.9/tools/qt_dump_png.cpp:39:23: [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 *inputfile = fopen(filename, "r"); data/qtcurve-1.9/gtk2/common/config_file.cpp:51: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). if (str && strlen(str)>6) { data/qtcurve-1.9/gtk2/common/config_file.cpp:173:86: [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(nullptr!=pix && APP_ALLOW_STRIPED==allow && 0==strncmp(str, "file", 4) && strlen(str)>9) data/qtcurve-1.9/gtk2/common/config_file.cpp:176:53: [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(0==strncmp(str, "customgradient", 14) && strlen(str)>14) data/qtcurve-1.9/gtk2/style/helpers.cpp:1420: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). char *str = (char*)malloc(strlen(format) + 24 + 1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:451:41: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). qtSettings.fonts[f] = (char*)malloc(strlen(font->family) + 1 + data/qtcurve-1.9/gtk2/style/qt_settings.cpp:452:41: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). strlen(weightStr(font->weight)) + 1 + data/qtcurve-1.9/gtk2/style/qt_settings.cpp:453:41: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). strlen(italicStr(font->italic)) + 1 + data/qtcurve-1.9/gtk2/style/qt_settings.cpp:463:27: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). (char*)malloc(strlen(font->family) + 1 + data/qtcurve-1.9/gtk2/style/qt_settings.cpp:464:27: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). strlen(weightStr(WEIGHT_BOLD)) + 1 + data/qtcurve-1.9/gtk2/style/qt_settings.cpp:465:27: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). strlen(italicStr(font->italic)) + 1 + data/qtcurve-1.9/gtk2/style/qt_settings.cpp:633: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). unsigned int len = strlen(eq); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:795: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). int len=strlen(line); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:796:68: [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). qtSettings.styleName=realloc(qtSettings.styleName, strlen(&line[12])+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:936:60: [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). qtSettings.icons=(char *)realloc(qtSettings.icons, strlen(defaultIcons())+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:971:23: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). strlen(QTC_KDE4_ICONS_PREFIX) > 2 ? data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1006:20: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). auto len = strlen(buff.get()); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1046: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). int app_len=strlen(app), data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1047:23: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). check_len=strlen(check); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1396: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). int versionLen = (1 + strlen(qtcVersion()) + 1 + data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1397: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). strlen(iconTheme) + 1 + 2 + 6 * 2 + 1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1414: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). int fileNameLen = strlen(tmpStr); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1415:50: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). char *cmdStr = (char*)malloc(strlen(constCmdStrFmt) + 2 + data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1416:62: [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). 4 * 6 + 2 + strlen(iconTheme) + data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1418: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). strlen(kdeprefix) : data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1421:50: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). strlen(qtcVersion()) + 1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1477: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). tmpStr=(char *)realloc(tmpStr, strlen(constFormat)+strlen(qtSettings.fonts[FONT_GENERAL])+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1477:68: [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). tmpStr=(char *)realloc(tmpStr, strlen(constFormat)+strlen(qtSettings.fonts[FONT_GENERAL])+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1495:52: [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). tmpStr=(char *)realloc(tmpStr, strlen(constStdPrefix)+strlen(qtSettings.fonts[FONT_GENERAL])+strlen(constStdSuffix)+ data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1495:75: [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). tmpStr=(char *)realloc(tmpStr, strlen(constStdPrefix)+strlen(qtSettings.fonts[FONT_GENERAL])+strlen(constStdSuffix)+ data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1495:114: [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). tmpStr=(char *)realloc(tmpStr, strlen(constStdPrefix)+strlen(qtSettings.fonts[FONT_GENERAL])+strlen(constStdSuffix)+ data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1496:52: [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(constBoldPrefix)+strlen(qtSettings.fonts[FONT_BOLD])+ data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1496:76: [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(constBoldPrefix)+strlen(qtSettings.fonts[FONT_BOLD])+ data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1497:73: [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). (opts.boldProgress ? strlen(constBoldSuffix) : strlen(constStdSuffix))+ data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1497:99: [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). (opts.boldProgress ? strlen(constBoldSuffix) : strlen(constStdSuffix))+ data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1498:52: [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(constGrpBoxBoldSuffix)+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1507:52: [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). tmpStr=(char *)realloc(tmpStr, strlen(constBoldPrefix)+strlen(qtSettings.fonts[FONT_BOLD])+strlen(constBoldSuffix)+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1507:76: [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). tmpStr=(char *)realloc(tmpStr, strlen(constBoldPrefix)+strlen(qtSettings.fonts[FONT_BOLD])+strlen(constBoldSuffix)+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1507:112: [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). tmpStr=(char *)realloc(tmpStr, strlen(constBoldPrefix)+strlen(qtSettings.fonts[FONT_BOLD])+strlen(constBoldSuffix)+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1518: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). tmpStr=(char *)realloc(tmpStr, strlen(constFormat)+strlen(qtSettings.fonts[FONT_MENU])+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1518:68: [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). tmpStr=(char *)realloc(tmpStr, strlen(constFormat)+strlen(qtSettings.fonts[FONT_MENU])+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1528: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). tmpStr=(char *)realloc(tmpStr, strlen(constFormat)+strlen(qtSettings.fonts[FONT_TOOLBAR])+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1528:68: [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). tmpStr=(char *)realloc(tmpStr, strlen(constFormat)+strlen(qtSettings.fonts[FONT_TOOLBAR])+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1567: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). tmpStr=(char *)realloc(tmpStr, strlen(constSbStrFormat)+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1605:44: [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). tmpStr=(char *)realloc(tmpStr, strlen(constStrFormat)+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1628:45: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). tmpStr = (char*)realloc(tmpStr, strlen(constStrFormat) + 2); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1643:45: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). tmpStr = (char*)realloc(tmpStr, strlen(constStrFormat) + 8); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1656:49: [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). tmpStr = (char*)realloc(tmpStr, strlen(constStrFormat) + 4); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1681:45: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). tmpStr = (char*)realloc(tmpStr, strlen(constStrFormat) + 1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1692:45: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). tmpStr = (char*)realloc(tmpStr, strlen(constStrFormat) + 1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1703:45: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). tmpStr = (char*)realloc(tmpStr, strlen(constStrFormat) + 1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1747:45: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). tmpStr = (char*)realloc(tmpStr, strlen(constStrFormat) + 1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1773:49: [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). tmpStr = (char*)realloc(tmpStr, strlen(constStrFormat) + 1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1804:49: [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). tmpStr = (char*)realloc(tmpStr, strlen(constStrFormat)+1); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1819:49: [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). tmpStr = (char*)realloc(tmpStr, strlen(constStrFormat) + 16); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1848:45: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). tmpStr = (char*)realloc(tmpStr, strlen(constStrFormat) + 8); data/qtcurve-1.9/gtk2/style/qt_settings.cpp:1877:49: [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). tmpStr = (char*)realloc(tmpStr, strlen(constStrFormat) + 16); data/qtcurve-1.9/gtk2/style/qtcurve.cpp:1821:41: [1] (buffer) equal: Function does not check the second iterator for over-read conditions (CWE-126). This function is often discouraged by most C++ coding standards in favor of its safer alternatives provided since C++14. Consider using a form of this function that checks the second iterator before potentially overflowing it. windowFrame = Rect::equal(wAlloc, pAlloc); data/qtcurve-1.9/lib/cairo/utils.h:53:1: [1] (buffer) equal: Function does not check the second iterator for over-read conditions (CWE-126). This function is often discouraged by most C++ coding standards in favor of its safer alternatives provided since C++14. Consider using a form of this function that checks the second iterator before potentially overflowing it. equal(const QtcRect &a, const QtcRect &b) data/qtcurve-1.9/lib/utils/color.cpp:450: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). size_t len = strlen(str); data/qtcurve-1.9/lib/utils/dirs.cpp:231: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). size_t name_len = strlen(fname) - strlen(".qtcurve"); data/qtcurve-1.9/lib/utils/dirs.cpp:231:47: [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 name_len = strlen(fname) - strlen(".qtcurve"); data/qtcurve-1.9/lib/utils/log.cpp:119: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). fwrite("\e[0m", strlen("\e[0m"), 1, stderr); data/qtcurve-1.9/lib/utils/process.cpp:232:19: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). ssize_t len = read(buffs->orig, buffs->buff + buffs->len, 1024); data/qtcurve-1.9/lib/utils/strs.h:58: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). return strncmp(str, head, strlen(head)) == 0; data/qtcurve-1.9/lib/utils/strs.h:64: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). size_t len1 = strlen(str); data/qtcurve-1.9/lib/utils/strs.h:65: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). size_t len2 = strlen(tail); data/qtcurve-1.9/lib/utils/strs.h:83:27: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return dup(dest, src, strlen(src)); data/qtcurve-1.9/lib/utils/strs.h:118:57: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). const std::array<size_t, sizeof...(strs)> str_lens{{strlen(strs)...}}; data/qtcurve-1.9/lib/utils/strs.h:146: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). : Buff(str ? strlen(str) + 1 : 0, str) data/qtcurve-1.9/lib/utils/strs.h:181:34: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return this->append_from(strlen(this->m_ptr), data/qtcurve-1.9/lib/utils/strs.h:189:61: [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). const std::array<size_t, sizeof...(strs)> str_lens{{strlen(strs)...}}; data/qtcurve-1.9/lib/utils/x11utils.cpp:126:47: [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). cookies[i] = xcb_intern_atom(conn, 0, strlen(qtc_x11_atoms[i].name), data/qtcurve-1.9/lib/utils/x11utils.cpp:164: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). const size_t base_len = strlen("_NET_WM_CM_S"); data/qtcurve-1.9/lib/utils/x11utils_p.h:70:45: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). strlen(name), name); data/qtcurve-1.9/qt4/common/config_file.cpp:61: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). if (str && strlen(str) > 6) { data/qtcurve-1.9/qt4/common/config_file.cpp:191:43: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). 0==strncmp(str, "file", 4) && strlen(str)>9) data/qtcurve-1.9/qt4/common/config_file.cpp:194:53: [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(0==strncmp(str, "customgradient", 14) && strlen(str)>14) data/qtcurve-1.9/qt4/common/config_file.cpp:1756:41: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). ? pix->file.mid(strlen(QtCurve::getConfDir())+1) data/qtcurve-1.9/qt5/common/config_file.cpp:68: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). if (str && strlen(str) > 6) { data/qtcurve-1.9/qt5/common/config_file.cpp:197:78: [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 (pix && APP_ALLOW_STRIPED==allow && 0==strncmp(str, "file", 4) && strlen(str)>9) data/qtcurve-1.9/qt5/common/config_file.cpp:200:53: [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(0==strncmp(str, "customgradient", 14) && strlen(str)>14) data/qtcurve-1.9/qt5/common/config_file.cpp:1771:41: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). ? pix->file.mid(strlen(QtCurve::getConfDir())+1) data/qtcurve-1.9/test/test-popen-buff.cpp:47:5: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). read(0, buff3, sizeof(buff3)); data/qtcurve-1.9/test/test-popen-buff.cpp:49:23: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). write(1, argv[2], strlen(argv[2]) + 1); data/qtcurve-1.9/test/test-popen.cpp:46:5: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). read(0, buff3, sizeof(buff3)); data/qtcurve-1.9/test/test-popen.cpp:48:23: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). write(1, argv[2], strlen(argv[2]) + 1); data/qtcurve-1.9/test/test-popen.cpp:74:5: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). read(fds[1].replace, buff3, sizeof(buff3)); data/qtcurve-1.9/test/test-printf.cpp:41: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). assert(size > strlen(m_res2)); data/qtcurve-1.9/test/test-printf.cpp:43: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). size = strlen(m_res2); data/qtcurve-1.9/test/test-printf.cpp:45: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). assert(size > strlen(m_res3)); data/qtcurve-1.9/test/test-printf.cpp:47: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). size = strlen(m_res3) + 1; data/qtcurve-1.9/test/test-printf.cpp:51:20: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). assert(size == strlen(m_res4) + 1); data/qtcurve-1.9/test/test-printf.cpp:56:20: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). assert(size == strlen(m_res5) + 1); data/qtcurve-1.9/test/test-printf.cpp:62: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). assert(size > strlen(m_res6) + 1); data/qtcurve-1.9/test/test-process.cpp:68:24: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). ssize_t read_res = read(pipe_fds[0], &num_sent, sizeof(num_sent)); data/qtcurve-1.9/test/test-strlist.cpp:55: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). assert(strlen(str) == len); ANALYSIS SUMMARY: Hits = 334 Lines analyzed = 88522 in approximately 2.25 seconds (39327 lines/second) Physical Source Lines of Code (SLOC) = 71337 Hits@level = [0] 17 [1] 96 [2] 105 [3] 27 [4] 106 [5] 0 Hits@level+ = [0+] 351 [1+] 334 [2+] 238 [3+] 133 [4+] 106 [5+] 0 Hits/KSLOC@level+ = [0+] 4.92031 [1+] 4.682 [2+] 3.33628 [3+] 1.86439 [4+] 1.4859 [5+] 0 Symlinks skipped = 3 (--allowlink overrides but see doc for security issue) 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.