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/lxappearance-0.6.3/src/icon-theme.h
Examining data/lxappearance-0.6.3/src/utils.c
Examining data/lxappearance-0.6.3/src/other.h
Examining data/lxappearance-0.6.3/src/font.c
Examining data/lxappearance-0.6.3/src/color-scheme.c
Examining data/lxappearance-0.6.3/src/cursor-theme.c
Examining data/lxappearance-0.6.3/src/utils.h
Examining data/lxappearance-0.6.3/src/font.h
Examining data/lxappearance-0.6.3/src/icon-theme.c
Examining data/lxappearance-0.6.3/src/widget-theme.c
Examining data/lxappearance-0.6.3/src/plugin.h
Examining data/lxappearance-0.6.3/src/plugin.c
Examining data/lxappearance-0.6.3/src/lxappearance.h
Examining data/lxappearance-0.6.3/src/other.c
Examining data/lxappearance-0.6.3/src/cursor-theme.h
Examining data/lxappearance-0.6.3/src/lxappearance.c
Examining data/lxappearance-0.6.3/src/widget-theme.h
Examining data/lxappearance-0.6.3/src/color-scheme.h

FINAL RESULTS:

data/lxappearance-0.6.3/src/icon-theme.c:82:45:  [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.
                theme->is_removable = (0 == access(base_dir, W_OK));
data/lxappearance-0.6.3/src/color-scheme.c:267:38:  [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.
            gtkrc = g_build_filename(g_get_home_dir(), ".themes", app.widget_theme, "gtk-2.0/gtkrc", NULL);
data/lxappearance-0.6.3/src/lxappearance.c:122:30:  [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.
    fpath = g_build_filename(g_get_home_dir(), ".icons", cursor_theme,
data/lxappearance-0.6.3/src/lxappearance.c:158:33:  [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.
    dir_path = g_build_filename(g_get_home_dir(), ".icons/default", NULL);
data/lxappearance-0.6.3/src/lxappearance.c:253:46:  [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.
        if (g_str_has_prefix(gtkrc_files[0], g_get_home_dir()))
data/lxappearance-0.6.3/src/lxappearance.c:261:59:  [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.
        g_debug("none found, use hardcoded %s/.gtkrc-2.0",g_get_home_dir());
data/lxappearance-0.6.3/src/lxappearance.c:262:38:  [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.
        file_path = g_build_filename(g_get_home_dir(), ".gtkrc-2.0", NULL);
data/lxappearance-0.6.3/src/lxappearance.c:272:9:  [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.
        g_get_home_dir());
data/lxappearance-0.6.3/src/lxappearance.c:561:40:  [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.
        char* fpath = g_build_filename(g_get_home_dir(), ".icons/default/index.theme", NULL);
data/lxappearance-0.6.3/src/lxappearance.c:609:45:  [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.
        char* gtkrc_file = g_build_filename(g_get_home_dir(), ".gtkrc-2.0", NULL);
data/lxappearance-0.6.3/src/widget-theme.c:79:28:  [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.
    dir = g_build_filename(g_get_home_dir(), ".themes", NULL);
data/lxappearance-0.6.3/src/lxappearance.c:451:15:  [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(user_config_file) - strlen("/desktop.conf");
data/lxappearance-0.6.3/src/lxappearance.c:451:42:  [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(user_config_file) - strlen("/desktop.conf");

ANALYSIS SUMMARY:

Hits = 13
Lines analyzed = 2601 in approximately 0.10 seconds (26961 lines/second)
Physical Source Lines of Code (SLOC) = 1745
Hits@level = [0]   0 [1]   2 [2]   0 [3]  10 [4]   1 [5]   0
Hits@level+ = [0+]  13 [1+]  13 [2+]  11 [3+]  11 [4+]   1 [5+]   0
Hits/KSLOC@level+ = [0+] 7.44986 [1+] 7.44986 [2+] 6.30372 [3+] 6.30372 [4+] 0.573066 [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.