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/python-evdev-1.3.0+dfsg/evdev/input.c
Examining data/python-evdev-1.3.0+dfsg/evdev/uinput.c

FINAL RESULTS:

data/python-evdev-1.3.0+dfsg/evdev/input.c:132: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 ev_bits[EV_MAX/8 + 1], code_bits[KEY_MAX/8 + 1];
data/python-evdev-1.3.0+dfsg/evdev/input.c:222:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
    char name[MAX_NAME_SIZE];
data/python-evdev-1.3.0+dfsg/evdev/input.c:223: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 phys[MAX_NAME_SIZE] = {0};
data/python-evdev-1.3.0+dfsg/evdev/input.c:224: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 uniq[MAX_NAME_SIZE] = {0};
data/python-evdev-1.3.0+dfsg/evdev/input.c:394: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 bytes[(max+7)/8];
data/python-evdev-1.3.0+dfsg/evdev/input.c:522: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 bytes[(INPUT_PROP_MAX+7)/8];
data/python-evdev-1.3.0+dfsg/evdev/uinput.c:50: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).
    int fd = open(devnode, O_RDWR | O_NONBLOCK);
data/python-evdev-1.3.0+dfsg/evdev/input.c:56:13:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    int n = read(fd, &event, sizeof(event));
data/python-evdev-1.3.0+dfsg/evdev/input.c:101:21:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    ssize_t nread = read(fd, event, event_size*64);
data/python-evdev-1.3.0+dfsg/evdev/uinput.c:145:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
    strncpy(usetup.name, name, sizeof(usetup.name) - 1);
data/python-evdev-1.3.0+dfsg/evdev/uinput.c:180:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
    strncpy(uidev.name, name, sizeof(uidev.name) - 1);

ANALYSIS SUMMARY:

Hits = 11
Lines analyzed = 1020 in approximately 0.03 seconds (32353 lines/second)
Physical Source Lines of Code (SLOC) = 758
Hits@level = [0]   3 [1]   4 [2]   7 [3]   0 [4]   0 [5]   0
Hits@level+ = [0+]  14 [1+]  11 [2+]   7 [3+]   0 [4+]   0 [5+]   0
Hits/KSLOC@level+ = [0+] 18.4697 [1+] 14.5119 [2+] 9.23483 [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.