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/kde-spectacle-20.08.3/tests/FilenameTest.cpp Examining data/kde-spectacle-20.08.3/desktop/MigrateShortcuts.cpp Examining data/kde-spectacle-20.08.3/src/Gui/ExportMenu.cpp Examining data/kde-spectacle-20.08.3/src/Gui/SmartSpinBox.cpp Examining data/kde-spectacle-20.08.3/src/Gui/SmartSpinBox.h Examining data/kde-spectacle-20.08.3/src/Gui/KSMainWindow.h Examining data/kde-spectacle-20.08.3/src/Gui/KSWidget.h Examining data/kde-spectacle-20.08.3/src/Gui/KSImageWidget.cpp Examining data/kde-spectacle-20.08.3/src/Gui/ProgressButton.h Examining data/kde-spectacle-20.08.3/src/Gui/KSImageWidget.h Examining data/kde-spectacle-20.08.3/src/Gui/KSMainWindow.cpp Examining data/kde-spectacle-20.08.3/src/Gui/ProgressButton.cpp Examining data/kde-spectacle-20.08.3/src/Gui/KSWidget.cpp Examining data/kde-spectacle-20.08.3/src/Gui/SettingsDialog/ShortcutsOptionsPage.cpp Examining data/kde-spectacle-20.08.3/src/Gui/SettingsDialog/SaveOptionsPage.h Examining data/kde-spectacle-20.08.3/src/Gui/SettingsDialog/GeneralOptionsPage.h Examining data/kde-spectacle-20.08.3/src/Gui/SettingsDialog/SettingsDialog.h Examining data/kde-spectacle-20.08.3/src/Gui/SettingsDialog/SettingsDialog.cpp Examining data/kde-spectacle-20.08.3/src/Gui/SettingsDialog/ShortcutsOptionsPage.h Examining data/kde-spectacle-20.08.3/src/Gui/SettingsDialog/GeneralOptionsPage.cpp Examining data/kde-spectacle-20.08.3/src/Gui/SettingsDialog/SaveOptionsPage.cpp Examining data/kde-spectacle-20.08.3/src/Gui/ExportMenu.h Examining data/kde-spectacle-20.08.3/src/SpectacleCommon.h Examining data/kde-spectacle-20.08.3/src/Platforms/PlatformLoader.h Examining data/kde-spectacle-20.08.3/src/Platforms/PlatformKWinWayland.h Examining data/kde-spectacle-20.08.3/src/Platforms/PlatformKWinWayland.cpp Examining data/kde-spectacle-20.08.3/src/Platforms/PlatformNull.cpp Examining data/kde-spectacle-20.08.3/src/Platforms/PlatformNull.h Examining data/kde-spectacle-20.08.3/src/Platforms/PlatformLoader.cpp Examining data/kde-spectacle-20.08.3/src/Platforms/Platform.cpp Examining data/kde-spectacle-20.08.3/src/Platforms/Platform.h Examining data/kde-spectacle-20.08.3/src/Platforms/PlatformXcb.cpp Examining data/kde-spectacle-20.08.3/src/Platforms/PlatformXcb.h Examining data/kde-spectacle-20.08.3/src/ShortcutActions.h Examining data/kde-spectacle-20.08.3/src/SpectacleCore.h Examining data/kde-spectacle-20.08.3/src/ExportManager.h Examining data/kde-spectacle-20.08.3/src/SpectacleCore.cpp Examining data/kde-spectacle-20.08.3/src/QuickEditor/QuickEditor.cpp Examining data/kde-spectacle-20.08.3/src/QuickEditor/QuickEditor.h Examining data/kde-spectacle-20.08.3/src/SpectacleDBusAdapter.cpp Examining data/kde-spectacle-20.08.3/src/KipiInterface/KSGKipiInfoShared.cpp Examining data/kde-spectacle-20.08.3/src/KipiInterface/KSGKipiInterface.h Examining data/kde-spectacle-20.08.3/src/KipiInterface/KSGKipiImageCollectionShared.h Examining data/kde-spectacle-20.08.3/src/KipiInterface/KSGKipiInterface.cpp Examining data/kde-spectacle-20.08.3/src/KipiInterface/KSGKipiImageCollectionShared.cpp Examining data/kde-spectacle-20.08.3/src/KipiInterface/KSGKipiInfoShared.h Examining data/kde-spectacle-20.08.3/src/KipiInterface/KSGKipiImageCollectionSelector.cpp Examining data/kde-spectacle-20.08.3/src/KipiInterface/KSGKipiImageCollectionSelector.h Examining data/kde-spectacle-20.08.3/src/Main.cpp Examining data/kde-spectacle-20.08.3/src/ShortcutActions.cpp Examining data/kde-spectacle-20.08.3/src/SpectacleDBusAdapter.h Examining data/kde-spectacle-20.08.3/src/ExportManager.cpp FINAL RESULTS: data/kde-spectacle-20.08.3/src/ExportManager.cpp:337:16: [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). outputFile.open(QFile::WriteOnly); data/kde-spectacle-20.08.3/src/ExportManager.cpp:369:17: [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 (tmpFile.open()) { data/kde-spectacle-20.08.3/src/ExportManager.cpp:412:21: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). if (tmpFile.open(QFile::WriteOnly)) { data/kde-spectacle-20.08.3/src/Gui/ExportMenu.cpp:102:47: [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). openWith->setShortcuts(KStandardShortcut::open()); data/kde-spectacle-20.08.3/src/Platforms/PlatformKWinWayland.cpp:39: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 lBuffer[4096]; data/kde-spectacle-20.08.3/tests/FilenameTest.cpp:80:10: [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). file.open(QIODevice::WriteOnly); data/kde-spectacle-20.08.3/tests/FilenameTest.cpp:85:10: [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). file.open(QIODevice::WriteOnly); data/kde-spectacle-20.08.3/src/Platforms/PlatformKWinWayland.cpp:46:13: [1] (obsolete) usleep: This C routine is considered obsolete (as opposed to the shell command by the same name). The interaction of this function with SIGALRM and other timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead. usleep(1000); ANALYSIS SUMMARY: Hits = 8 Lines analyzed = 7014 in approximately 0.24 seconds (29084 lines/second) Physical Source Lines of Code (SLOC) = 4706 Hits@level = [0] 0 [1] 1 [2] 7 [3] 0 [4] 0 [5] 0 Hits@level+ = [0+] 8 [1+] 8 [2+] 7 [3+] 0 [4+] 0 [5+] 0 Hits/KSLOC@level+ = [0+] 1.69996 [1+] 1.69996 [2+] 1.48746 [3+] 0 [4+] 0 [5+] 0 Dot directories skipped = 1 (--followdotdir overrides) Minimum risk level = 1 Not every hit is necessarily a security vulnerability. There may be other security vulnerabilities; review your code! See 'Secure Programming HOWTO' (https://dwheeler.com/secure-programs) for more information.