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-py2bit-0.3.0/lib2bit/2bit.c
Examining data/python-py2bit-0.3.0/lib2bit/2bit.h
Examining data/python-py2bit-0.3.0/py2bit.c
Examining data/python-py2bit-0.3.0/py2bit.h

FINAL RESULTS:

data/python-py2bit-0.3.0/lib2bit/2bit.c:21:12:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        if(memcpy(data, tb->data + tb->offset, nmemb * sz) == NULL) return 0;
data/python-py2bit-0.3.0/lib2bit/2bit.c:61: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 bases[4] = "TCAG";
data/python-py2bit-0.3.0/lib2bit/2bit.c:67: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 bases[4] = "TCAG";
data/python-py2bit-0.3.0/lib2bit/2bit.c:700:14:  [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).
    tb->fp = fopen(fname, "rb");

ANALYSIS SUMMARY:

Hits = 4
Lines analyzed = 1609 in approximately 0.09 seconds (18193 lines/second)
Physical Source Lines of Code (SLOC) = 1078
Hits@level = [0]   4 [1]   0 [2]   4 [3]   0 [4]   0 [5]   0
Hits@level+ = [0+]   8 [1+]   4 [2+]   4 [3+]   0 [4+]   0 [5+]   0
Hits/KSLOC@level+ = [0+] 7.42115 [1+] 3.71058 [2+] 3.71058 [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.