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/xfce4-screenshooter-1.9.7/src/main.c Examining data/xfce4-screenshooter-1.9.7/panel-plugin/screenshooter-plugin.c Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-actions.h Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-simple-job.h Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-imgur.c Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-marshal.h Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-global.h Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-dialogs.h Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-imgur-dialog_ui.h Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-actions.c Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-utils.c Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-imgur-dialog.c Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-capture.c Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-imgur.h Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-job.c Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-dialogs.c Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-simple-job.c Examining data/xfce4-screenshooter-1.9.7/lib/libscreenshooter.h Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-utils.h Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-job-callbacks.c Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-imgur-dialog.h Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-job.h Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-marshal.c Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-job-callbacks.h Examining data/xfce4-screenshooter-1.9.7/lib/screenshooter-capture.h FINAL RESULTS: data/xfce4-screenshooter-1.9.7/lib/screenshooter-actions.c:102:46: [3] (buffer) g_get_tmp_dir: This function is synonymous with 'getenv("TMP")';it returns untrustable input if the environment can beset by an attacker. It 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. GFile *temp_dir = g_file_new_for_path (g_get_tmp_dir ()); data/xfce4-screenshooter-1.9.7/lib/screenshooter-dialogs.c:547:40: [3] (buffer) g_get_tmp_dir: This function is synonymous with 'getenv("TMP")';it returns untrustable input if the environment can beset by an attacker. It 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. gchar *save_path = g_build_filename (g_get_tmp_dir (), save_basename, NULL); data/xfce4-screenshooter-1.9.7/lib/screenshooter-utils.c:282:17: [3] (buffer) g_get_home_dir: This function is synonymous with 'getenv("HOME")';it returns untrustable input if the environment can beset by an attacker. It 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. home_path = g_get_home_dir (); data/xfce4-screenshooter-1.9.7/lib/screenshooter-capture.c:740:56: [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_window_get_offset (rbdata->size_window, strlen (coords), data/xfce4-screenshooter-1.9.7/lib/screenshooter-imgur-dialog.c:344:87: [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). gtk_text_buffer_set_text (gtk_text_view_get_buffer (dialog->embed_text_view), text, strlen(text)); data/xfce4-screenshooter-1.9.7/lib/screenshooter-imgur-dialog.c:369:9: [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). len = strlen (text); data/xfce4-screenshooter-1.9.7/lib/screenshooter-imgur-dialog.c:387:59: [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). gtk_clipboard_set_text (clipboard, dialog->delete_link, strlen (dialog->delete_link)); data/xfce4-screenshooter-1.9.7/lib/screenshooter-imgur.c:128: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(msg->response_body->data)); ANALYSIS SUMMARY: Hits = 8 Lines analyzed = 6467 in approximately 0.18 seconds (36085 lines/second) Physical Source Lines of Code (SLOC) = 4372 Hits@level = [0] 2 [1] 5 [2] 0 [3] 3 [4] 0 [5] 0 Hits@level+ = [0+] 10 [1+] 8 [2+] 3 [3+] 3 [4+] 0 [5+] 0 Hits/KSLOC@level+ = [0+] 2.28728 [1+] 1.82983 [2+] 0.686185 [3+] 0.686185 [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.