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/apriltag-0.10.0/tagCustom48h12.h
Examining data/apriltag-0.10.0/common/zhash.h
Examining data/apriltag-0.10.0/common/pam.h
Examining data/apriltag-0.10.0/common/timeprofile.h
Examining data/apriltag-0.10.0/common/string_util.h
Examining data/apriltag-0.10.0/common/pnm.c
Examining data/apriltag-0.10.0/common/zarray.c
Examining data/apriltag-0.10.0/common/unionfind.h
Examining data/apriltag-0.10.0/common/workerpool.h
Examining data/apriltag-0.10.0/common/svd22.c
Examining data/apriltag-0.10.0/common/zmaxheap.h
Examining data/apriltag-0.10.0/common/zmaxheap.c
Examining data/apriltag-0.10.0/common/image_u8x4.h
Examining data/apriltag-0.10.0/common/image_u8x3.c
Examining data/apriltag-0.10.0/common/pam.c
Examining data/apriltag-0.10.0/common/pnm.h
Examining data/apriltag-0.10.0/common/homography.h
Examining data/apriltag-0.10.0/common/image_u8x3.h
Examining data/apriltag-0.10.0/common/pjpeg.h
Examining data/apriltag-0.10.0/common/image_types.h
Examining data/apriltag-0.10.0/common/math_util.h
Examining data/apriltag-0.10.0/common/pjpeg-idct.c
Examining data/apriltag-0.10.0/common/g2d.c
Examining data/apriltag-0.10.0/common/workerpool.c
Examining data/apriltag-0.10.0/common/getopt.c
Examining data/apriltag-0.10.0/common/zhash.c
Examining data/apriltag-0.10.0/common/g2d.h
Examining data/apriltag-0.10.0/common/matd.c
Examining data/apriltag-0.10.0/common/time_util.c
Examining data/apriltag-0.10.0/common/zarray.h
Examining data/apriltag-0.10.0/common/doubles.h
Examining data/apriltag-0.10.0/common/string_util.c
Examining data/apriltag-0.10.0/common/homography.c
Examining data/apriltag-0.10.0/common/floats.h
Examining data/apriltag-0.10.0/common/image_u8.c
Examining data/apriltag-0.10.0/common/postscript_utils.h
Examining data/apriltag-0.10.0/common/pjpeg.c
Examining data/apriltag-0.10.0/common/time_util.h
Examining data/apriltag-0.10.0/common/getopt.h
Examining data/apriltag-0.10.0/common/doubles_floats_impl.h
Examining data/apriltag-0.10.0/common/image_u8.h
Examining data/apriltag-0.10.0/common/matd.h
Examining data/apriltag-0.10.0/common/unionfind.c
Examining data/apriltag-0.10.0/common/svd22.h
Examining data/apriltag-0.10.0/common/image_u8x4.c
Examining data/apriltag-0.10.0/tagStandard52h13.h
Examining data/apriltag-0.10.0/tagCircle21h7.h
Examining data/apriltag-0.10.0/apriltag_math.h
Examining data/apriltag-0.10.0/tag25h9.h
Examining data/apriltag-0.10.0/apriltag.h
Examining data/apriltag-0.10.0/tagStandard25h7.h
Examining data/apriltag-0.10.0/tag36h11.h
Examining data/apriltag-0.10.0/tagStandard41h12.h
Examining data/apriltag-0.10.0/tag16h5.h
Examining data/apriltag-0.10.0/apriltag_pose.h
Examining data/apriltag-0.10.0/tagStandard32h10.h
Examining data/apriltag-0.10.0/tagCircle49h12.h
Examining data/apriltag-0.10.0/example/opencv_demo.cc
Examining data/apriltag-0.10.0/example/apriltag_demo.c
Examining data/apriltag-0.10.0/example/simple_demo.c
Examining data/apriltag-0.10.0/apriltag_pose.c
Examining data/apriltag-0.10.0/apriltag_quad_thresh.c
Examining data/apriltag-0.10.0/tag16h5.c
Examining data/apriltag-0.10.0/tag25h9.c
Examining data/apriltag-0.10.0/tag36h11.c
Examining data/apriltag-0.10.0/tagCircle21h7.c
Examining data/apriltag-0.10.0/tagCircle49h12.c
Examining data/apriltag-0.10.0/tagCustom48h12.c
Examining data/apriltag-0.10.0/tagStandard25h7.c
Examining data/apriltag-0.10.0/tagStandard32h10.c
Examining data/apriltag-0.10.0/tagStandard41h12.c
Examining data/apriltag-0.10.0/tagStandard52h13.c
Examining data/apriltag-0.10.0/make-tag-data.c
Examining data/apriltag-0.10.0/tagCircle49h12.readdatafile.c
Examining data/apriltag-0.10.0/tagCustom48h12.readdatafile.c
Examining data/apriltag-0.10.0/tagStandard41h12.readdatafile.c
Examining data/apriltag-0.10.0/tagStandard52h13.readdatafile.c
Examining data/apriltag-0.10.0/try-read.h
Examining data/apriltag-0.10.0/apriltag.c
Examining data/apriltag-0.10.0/apriltag_pywrap.c

FINAL RESULTS:

data/apriltag-0.10.0/common/doubles_floats_impl.h:81:9:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
        printf(fmt, a[i]);
data/apriltag-0.10.0/common/doubles_floats_impl.h:88:9:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
        printf(fmt, a[i]);
data/apriltag-0.10.0/common/doubles_floats_impl.h:97:9:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
        printf(fmt, a[i]);
data/apriltag-0.10.0/common/matd.c:191:9:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
        printf(fmt, MATD_EL(m, 0, 0));
data/apriltag-0.10.0/common/matd.c:196:17:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
                printf(fmt, MATD_EL(m, i, j));
data/apriltag-0.10.0/common/matd.c:209:9:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
        printf(fmt, MATD_EL(m, 0, 0));
data/apriltag-0.10.0/common/matd.c:214:17:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
                printf(fmt, MATD_EL(m, i, j));
data/apriltag-0.10.0/common/string_util.c:72:18:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
    returnsize = vsnprintf(buf, size, fmt, args);
data/apriltag-0.10.0/common/string_util.c:86:18:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
    returnsize = vsnprintf(buf, size, fmt, args);
data/apriltag-0.10.0/common/string_util.c:374:18:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
    returnsize = vsnprintf(buf, size, fmt, args);
data/apriltag-0.10.0/common/string_util.c:384:22:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
        returnsize = vsnprintf(buf, size, fmt, args);
data/apriltag-0.10.0/common/string_util.c:698:16:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
    int slen = vsnprintf(s, salloc, fmt, ap);
data/apriltag-0.10.0/common/string_util.c:704:9:  [4] (format) vsprintf:
  Potential format string problem (CWE-134). Make format string constant.
        vsprintf((char*) s, fmt, ap);
data/apriltag-0.10.0/common/string_util.h:59:67:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
char *sprintf_alloc(const char *fmt, ...) __attribute__ ((format (printf, 1, 2)));
data/apriltag-0.10.0/common/string_util.h:289:95:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
void string_buffer_appendf(string_buffer_t *sb, const char *fmt, ...) __attribute__ ((format (printf, 2, 3)));
data/apriltag-0.10.0/example/simple_demo.c:117:13:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
            printf(usage, argv[0]);
data/apriltag-0.10.0/example/simple_demo.c:121:13:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
            fprintf(stderr, usage, argv[0]);
data/apriltag-0.10.0/apriltag.c:1101:9:  [3] (random) srandom:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
        srandom(0);
data/apriltag-0.10.0/apriltag.c:1108:33:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
            int color = bias + (random() % (255-bias));
data/apriltag-0.10.0/apriltag.c:1157:9:  [3] (random) srandom:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
        srandom(0);
data/apriltag-0.10.0/apriltag.c:1164:33:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
            int color = bias + (random() % (255-bias));
data/apriltag-0.10.0/apriltag.c:1279:34:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
                rgb[i] = bias + (random() % (255-bias));
data/apriltag-0.10.0/apriltag.c:1316:34:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
                rgb[i] = bias + (random() % (255-bias));
data/apriltag-0.10.0/apriltag.c:1358:34:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
                rgb[i] = bias + (random() % (255-bias));
data/apriltag-0.10.0/apriltag_quad_thresh.c:1653:33:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
                    r = bias + (random() % (200-bias));
data/apriltag-0.10.0/apriltag_quad_thresh.c:1654:33:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
                    g = bias + (random() % (200-bias));
data/apriltag-0.10.0/apriltag_quad_thresh.c:1655:33:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
                    b = bias + (random() % (200-bias));
data/apriltag-0.10.0/apriltag_quad_thresh.c:1687:29:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
                r = bias + (random() % (200-bias));
data/apriltag-0.10.0/apriltag_quad_thresh.c:1688:29:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
                g = bias + (random() % (200-bias));
data/apriltag-0.10.0/apriltag_quad_thresh.c:1689:29:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
                b = bias + (random() % (200-bias));
data/apriltag-0.10.0/apriltag_quad_thresh.c:1741:34:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
                rgb[i] = bias + (random() % (255-bias));
data/apriltag-0.10.0/common/g2d.c:762:5:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    srand(0);
data/apriltag-0.10.0/common/g2d.c:771:28:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
            q[0] = 10.0f * random() / RAND_MAX - 2;
data/apriltag-0.10.0/common/g2d.c:772:28:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
            q[1] = 10.0f * random() / RAND_MAX - 2;
data/apriltag-0.10.0/common/g2d.c:781:28:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
            q[0] = 10.0f * random() / RAND_MAX - 2;
data/apriltag-0.10.0/common/g2d.c:782:28:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
            q[1] = 10.0f * random() / RAND_MAX - 2;
data/apriltag-0.10.0/common/g2d.c:791:28:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
            q[0] = 10.0f * random() / RAND_MAX - 2;
data/apriltag-0.10.0/common/g2d.c:792:28:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
            q[1] = 10.0f * random() / RAND_MAX - 2;
data/apriltag-0.10.0/common/g2d.c:885:29:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
             q[0] = 10.0f * random() / RAND_MAX - 2;
data/apriltag-0.10.0/common/g2d.c:886:29:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
             q[1] = 10.0f * random() / RAND_MAX - 2;
data/apriltag-0.10.0/common/getopt.c:59:8:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
struct getopt
data/apriltag-0.10.0/common/getopt.c:420:30:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
int getopt_get_int(getopt_t *getopt, const char *lname)
data/apriltag-0.10.0/common/getopt.c:422:39:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    const char *v = getopt_get_string(getopt, lname);
data/apriltag-0.10.0/common/getopt.c:442:31:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
int getopt_get_bool(getopt_t *getopt, const char *lname)
data/apriltag-0.10.0/common/getopt.c:444:39:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    const char *v = getopt_get_string(getopt, lname);
data/apriltag-0.10.0/common/getopt.c:450:37:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
double getopt_get_double (getopt_t *getopt, const char *lname)
data/apriltag-0.10.0/common/getopt.c:452:40:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    const char *v = getopt_get_string (getopt, lname);
data/apriltag-0.10.0/common/getopt.c:472:36:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
int getopt_was_specified(getopt_t *getopt, const char *lname)
data/apriltag-0.10.0/common/getopt.h:37:16:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
typedef struct getopt getopt_t;
data/apriltag-0.10.0/common/getopt.h:56:30:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
int getopt_get_int(getopt_t *getopt, const char *lname);
data/apriltag-0.10.0/common/getopt.h:57:31:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
int getopt_get_bool(getopt_t *getopt, const char *lname);
data/apriltag-0.10.0/common/getopt.h:58:36:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
double getopt_get_double(getopt_t *getopt, const char *lname);
data/apriltag-0.10.0/common/matd.c:1689:13:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    int v = random()&31;
data/apriltag-0.10.0/common/matd.c:1696:21:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    double v = 1.0 *random() / RAND_MAX;
data/apriltag-0.10.0/common/matd.c:1707:13:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
            srand(iter);
data/apriltag-0.10.0/common/matd.c:1712:26:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
            int m = 1 + (random()%(maxdim-1));
data/apriltag-0.10.0/common/matd.c:1713:26:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
            int n = 1 + (random()%(maxdim-1));
data/apriltag-0.10.0/common/matd.c:1742:5:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    srand(0);
data/apriltag-0.10.0/common/string_util.c:760:25:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They 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 *env = getenv(varname);
data/apriltag-0.10.0/common/zmaxheap.c:366:14:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
        if ((random() & 1) == 0 && sz < cap) {
data/apriltag-0.10.0/common/zmaxheap.c:368:36:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
            int32_t v = (int32_t) (random() / 1000);
data/apriltag-0.10.0/example/apriltag_demo.c:64:21:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_bool(getopt, 'h', "help", 0, "Show this help");
data/apriltag-0.10.0/example/apriltag_demo.c:65:21:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_bool(getopt, 'd', "debug", 0, "Enable debugging output (slow)");
data/apriltag-0.10.0/example/apriltag_demo.c:66:21:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_bool(getopt, 'q', "quiet", 0, "Reduce output");
data/apriltag-0.10.0/example/apriltag_demo.c:67:23:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_string(getopt, 'f', "family", "tag36h11", "Tag family to use");
data/apriltag-0.10.0/example/apriltag_demo.c:68:20:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_int(getopt, 'i', "iters", "1", "Repeat processing on input set this many times");
data/apriltag-0.10.0/example/apriltag_demo.c:69:20:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_int(getopt, 't', "threads", "1", "Use this many CPU threads");
data/apriltag-0.10.0/example/apriltag_demo.c:70:23:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_double(getopt, 'x', "decimate", "1.0", "Decimate input image by this factor");
data/apriltag-0.10.0/example/apriltag_demo.c:71:23:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_double(getopt, 'b', "blur", "0.0", "Apply low-pass blur to input; negative sharpens");
data/apriltag-0.10.0/example/apriltag_demo.c:72:21:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_bool(getopt, '0', "refine-edges", 1, "Spend more time trying to align edges of tags");
data/apriltag-0.10.0/example/apriltag_demo.c:74:23:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    if (!getopt_parse(getopt, argc, argv, 1) || getopt_get_bool(getopt, "help")) {
data/apriltag-0.10.0/example/apriltag_demo.c:74:65:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    if (!getopt_parse(getopt, argc, argv, 1) || getopt_get_bool(getopt, "help")) {
data/apriltag-0.10.0/example/apriltag_demo.c:76:25:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
        getopt_do_usage(getopt);
data/apriltag-0.10.0/example/apriltag_demo.c:80:52:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    const zarray_t *inputs = getopt_get_extra_args(getopt);
data/apriltag-0.10.0/example/apriltag_demo.c:83:45:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    const char *famname = getopt_get_string(getopt, "family");
data/apriltag-0.10.0/example/apriltag_demo.c:105:43:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    td->quad_decimate = getopt_get_double(getopt, "decimate");
data/apriltag-0.10.0/example/apriltag_demo.c:106:40:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    td->quad_sigma = getopt_get_double(getopt, "blur");
data/apriltag-0.10.0/example/apriltag_demo.c:107:35:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    td->nthreads = getopt_get_int(getopt, "threads");
data/apriltag-0.10.0/example/apriltag_demo.c:108:33:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    td->debug = getopt_get_bool(getopt, "debug");
data/apriltag-0.10.0/example/apriltag_demo.c:109:40:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    td->refine_edges = getopt_get_bool(getopt, "refine-edges");
data/apriltag-0.10.0/example/apriltag_demo.c:111:33:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    int quiet = getopt_get_bool(getopt, "quiet");
data/apriltag-0.10.0/example/apriltag_demo.c:113:35:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    int maxiters = getopt_get_int(getopt, "iters");
data/apriltag-0.10.0/example/opencv_demo.cc:53:21:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_bool(getopt, 'h', "help", 0, "Show this help");
data/apriltag-0.10.0/example/opencv_demo.cc:54:21:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_bool(getopt, 'd', "debug", 1, "Enable debugging output (slow)");
data/apriltag-0.10.0/example/opencv_demo.cc:55:21:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_bool(getopt, 'q', "quiet", 0, "Reduce output");
data/apriltag-0.10.0/example/opencv_demo.cc:56:23:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_string(getopt, 'f', "family", "tag36h11", "Tag family to use");
data/apriltag-0.10.0/example/opencv_demo.cc:57:20:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_int(getopt, 't', "threads", "1", "Use this many CPU threads");
data/apriltag-0.10.0/example/opencv_demo.cc:58:23:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_double(getopt, 'x', "decimate", "1.0", "Decimate input image by this factor");
data/apriltag-0.10.0/example/opencv_demo.cc:59:23:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_double(getopt, 'b', "blur", "0.0", "Apply low-pass blur to input");
data/apriltag-0.10.0/example/opencv_demo.cc:60:21:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_add_bool(getopt, '0', "refine-edges", 1, "Spend more time trying to align edges of tags");
data/apriltag-0.10.0/example/opencv_demo.cc:62:23:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    if (!getopt_parse(getopt, argc, argv, 1) ||
data/apriltag-0.10.0/example/opencv_demo.cc:63:29:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
            getopt_get_bool(getopt, "help")) {
data/apriltag-0.10.0/example/opencv_demo.cc:65:25:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
        getopt_do_usage(getopt);
data/apriltag-0.10.0/example/opencv_demo.cc:78:45:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    const char *famname = getopt_get_string(getopt, "family");
data/apriltag-0.10.0/example/opencv_demo.cc:101:43:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    td->quad_decimate = getopt_get_double(getopt, "decimate");
data/apriltag-0.10.0/example/opencv_demo.cc:102:40:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    td->quad_sigma = getopt_get_double(getopt, "blur");
data/apriltag-0.10.0/example/opencv_demo.cc:103:35:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    td->nthreads = getopt_get_int(getopt, "threads");
data/apriltag-0.10.0/example/opencv_demo.cc:104:33:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    td->debug = getopt_get_bool(getopt, "debug");
data/apriltag-0.10.0/example/opencv_demo.cc:105:40:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    td->refine_edges = getopt_get_bool(getopt, "refine-edges");
data/apriltag-0.10.0/example/opencv_demo.cc:177:20:  [3] (buffer) getopt:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
    getopt_destroy(getopt);
data/apriltag-0.10.0/example/simple_demo.c:101:15:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
        opt = getopt_long(argc, argv, "dqf:i:t:x:m:b:0vh", opts, NULL);
data/apriltag-0.10.0/apriltag.c:160:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(q, quad, sizeof(struct quad));
data/apriltag-0.10.0/apriltag.c:1261:19:  [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).
        FILE *f = fopen("debug_output.ps", "w");
data/apriltag-0.10.0/apriltag.c:1333:19:  [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).
        FILE *f = fopen("debug_quads.ps", "w");
data/apriltag-0.10.0/apriltag_quad_thresh.c:335:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(errs, y, sizeof(y));
data/apriltag-0.10.0/apriltag_quad_thresh.c:564:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(&lfps[i], &lfps[i-1], sizeof(struct line_fit_pt));
data/apriltag-0.10.0/apriltag_quad_thresh.c:666:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(tmp, pts, sizeof(struct pt) * sz);
data/apriltag-0.10.0/apriltag_quad_thresh.c:694:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(&pts[outpos], &as[apos], (asz-apos)*sizeof(struct pt));
data/apriltag-0.10.0/apriltag_quad_thresh.c:696:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(&pts[outpos], &bs[bpos], (bsz-bpos)*sizeof(struct pt));
data/apriltag-0.10.0/apriltag_quad_thresh.c:819:25:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                        memcpy(out, p, sizeof(struct pt));
data/apriltag-0.10.0/apriltag_quad_thresh.c:1718:19:  [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).
        FILE *f = fopen("debug_lines.ps", "w");
data/apriltag-0.10.0/common/doubles_floats_impl.h:74:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(r, v, len * sizeof(TNAME));
data/apriltag-0.10.0/common/doubles_floats_impl.h:219:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(dst, src, n * sizeof(TNAME));
data/apriltag-0.10.0/common/doubles_floats_impl.h:511:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(xytr, xyta, 3 * sizeof(TNAME));
data/apriltag-0.10.0/common/doubles_floats_impl.h:512:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(Cr, Ca, 9 * sizeof(TNAME));
data/apriltag-0.10.0/common/doubles_floats_impl.h:735:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(q1, _q1, sizeof(TNAME) * 4);
data/apriltag-0.10.0/common/doubles_floats_impl.h:834:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(out, prod, sizeof(TNAME)*16);
data/apriltag-0.10.0/common/doubles_floats_impl.h:842:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(out, prod, sizeof(TNAME)*16);
data/apriltag-0.10.0/common/doubles_floats_impl.h:850:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(out, prod, sizeof(TNAME)*16);
data/apriltag-0.10.0/common/g2d.c:310:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(p, thisp, sizeof(double[2]));
data/apriltag-0.10.0/common/getopt.c:246:17:  [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 sopt[2];
data/apriltag-0.10.0/common/getopt.c:323: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 sname[2];
data/apriltag-0.10.0/common/getopt.c:373: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 sname[2];
data/apriltag-0.10.0/common/image_u8.c:50:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(im, &tmp, sizeof(image_u8_t));
data/apriltag-0.10.0/common/image_u8.c:72:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(buf, in->buf, in->height*in->stride*sizeof(uint8_t));
data/apriltag-0.10.0/common/image_u8.c:78:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(copy, &tmp, sizeof(image_u8_t));
data/apriltag-0.10.0/common/image_u8.c:112:21:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                    memcpy(&im->buf[y*im->stride], &pnm->buf[y*im->width], im->width);
data/apriltag-0.10.0/common/image_u8.c:202:15:  [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).
    FILE *f = fopen(path, "wb");
data/apriltag-0.10.0/common/image_u8.c:324:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(x, &im->buf[y*im->stride], im->stride);
data/apriltag-0.10.0/common/image_u8x3.c:61:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(im, &tmp, sizeof(image_u8x3_t));
data/apriltag-0.10.0/common/image_u8x3.c:68:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(buf, in->buf, in->height*in->stride*sizeof(uint8_t));
data/apriltag-0.10.0/common/image_u8x3.c:74:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(copy, &tmp, sizeof(image_u8x3_t));
data/apriltag-0.10.0/common/image_u8x3.c:140:15:  [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).
    FILE *f = fopen(path, "wb");
data/apriltag-0.10.0/common/image_u8x4.c:59:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(im, &tmp, sizeof(image_u8x4_t));
data/apriltag-0.10.0/common/image_u8x4.c:66:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(buf, in->buf, in->height*in->stride*sizeof(uint8_t));
data/apriltag-0.10.0/common/image_u8x4.c:72:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(copy, &tmp, sizeof(image_u8x4_t));
data/apriltag-0.10.0/common/image_u8x4.c:110:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(&im->buf[y*im->stride], &pam->data[4*pam->width*y], 4*pam->width);
data/apriltag-0.10.0/common/image_u8x4.c:186:15:  [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).
    FILE *f = fopen(path, "wb");
data/apriltag-0.10.0/common/image_u8x4.c:219:15:  [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).
    FILE *f = fopen(path, "w");
data/apriltag-0.10.0/common/matd.c:161:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(x->data, m->data, sizeof(TYPE)*m->ncols*m->nrows);
data/apriltag-0.10.0/common/matd.c:1535:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(tmp, &MATD_EL(lu, p, 0), sizeof(TYPE) * lu->ncols);
data/apriltag-0.10.0/common/matd.c:1536:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(&MATD_EL(lu, p, 0), &MATD_EL(lu, j, 0), sizeof(TYPE) * lu->ncols);
data/apriltag-0.10.0/common/matd.c:1537:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(&MATD_EL(lu, j, 0), tmp, sizeof(TYPE) * lu->ncols);
data/apriltag-0.10.0/common/matd.c:1649:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(&MATD_EL(x, i, 0), &MATD_EL(b, mlu->piv[i], 0), sizeof(TYPE) * b->ncols);
data/apriltag-0.10.0/common/matd.c:1765:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(U->data, s.U, 4*sizeof(double));
data/apriltag-0.10.0/common/matd.c:1766:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(V->data, s.V, 4*sizeof(double));
data/apriltag-0.10.0/common/matd.c:1892:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(x, b, n*sizeof(TYPE));
data/apriltag-0.10.0/common/matd.h:243:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(m->data, data, m->nrows * m->ncols * sizeof(double));
data/apriltag-0.10.0/common/pam.c:37:20:  [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).
    FILE *infile = fopen(inpath, "r");
data/apriltag-0.10.0/common/pam.c:53:9:  [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 line[1024];
data/apriltag-0.10.0/common/pam.c:87:26:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
            pam->width = atoi(tok1);
data/apriltag-0.10.0/common/pam.c:92:27:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
            pam->height = atoi(tok1);
data/apriltag-0.10.0/common/pam.c:97:26:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
            pam->depth = atoi(tok1);
data/apriltag-0.10.0/common/pam.c:102:27:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
            pam->maxval = atoi(tok1);
data/apriltag-0.10.0/common/pam.c:160:15:  [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).
    FILE *f = fopen(outpath, "w+");
data/apriltag-0.10.0/common/pam.c:215:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(copy->data, pam->data, pam->datalen);
data/apriltag-0.10.0/common/pjpeg.c:149:14:  [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.
static const char ZZ[64] = { 0,   1,  8, 16,  9,  2,  3, 10,
data/apriltag-0.10.0/common/pjpeg.c:711:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(&im->buf[y*im->stride], &comp->data[y*comp->stride], pj->width);
data/apriltag-0.10.0/common/pjpeg.c:825:15:  [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).
    FILE *f = fopen(path, "r");
data/apriltag-0.10.0/common/pnm.c:37:15:  [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).
    FILE *f = fopen(path, "rb");
data/apriltag-0.10.0/common/pnm.c:44: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 tmp[1024];
data/apriltag-0.10.0/common/string_util.c:207:7:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
      memcpy(tok, &str[off0], len);
data/apriltag-0.10.0/common/string_util.c:406:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&sb->s[sb->size], str, len);
data/apriltag-0.10.0/common/string_util.c:533:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(substr, &sf->s[sf->pos], length*sizeof(char));
data/apriltag-0.10.0/common/string_util.c:633:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(b, &str[startidx], blen);
data/apriltag-0.10.0/common/string_util.c:711:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&buf[*bufpos], s, slen + 1); // get trailing \0
data/apriltag-0.10.0/common/timeprofile.h:44: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[32];
data/apriltag-0.10.0/common/zarray.h:91:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(zb->data, za->data, za->size * za->el_sz);
data/apriltag-0.10.0/common/zarray.h:121:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(out->data,  za->data +(start_idx*out->el_sz), out->size*out->el_sz);
data/apriltag-0.10.0/common/zarray.h:186:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&za->data[za->size*za->el_sz], p, za->el_sz);
data/apriltag-0.10.0/common/zarray.h:202:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(p, &za->data[idx*za->el_sz], za->el_sz);
data/apriltag-0.10.0/common/zarray.h:245:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(buffer, za->data, za->el_sz * za->size);
data/apriltag-0.10.0/common/zarray.h:262:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(&za->data[idx*za->el_sz], &za->data[(za->size-1)*za->el_sz], za->el_sz);
data/apriltag-0.10.0/common/zarray.h:328:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&za->data[idx*za->el_sz], p, za->el_sz);
data/apriltag-0.10.0/common/zarray.h:347:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(outp, &za->data[idx*za->el_sz], za->el_sz);
data/apriltag-0.10.0/common/zarray.h:349:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&za->data[idx*za->el_sz], p, za->el_sz);
data/apriltag-0.10.0/common/zhash.c:140:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(out_value, tmp, zh->valuesz);
data/apriltag-0.10.0/common/zhash.c:159:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(oldkey, this_key, zh->keysz);
data/apriltag-0.10.0/common/zhash.c:161:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(oldvalue, this_value, zh->valuesz);
data/apriltag-0.10.0/common/zhash.c:162:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(this_key, key, zh->keysz);
data/apriltag-0.10.0/common/zhash.c:163:13:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
            memcpy(this_value, value, zh->valuesz);
data/apriltag-0.10.0/common/zhash.c:173:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&zh->entries[entry_idx * zh->entrysz + 1], key, zh->keysz);
data/apriltag-0.10.0/common/zhash.c:174:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&zh->entries[entry_idx * zh->entrysz + 1 + zh->keysz], value, zh->valuesz);
data/apriltag-0.10.0/common/zhash.c:194:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(&tmp, zh, sizeof(zhash_t));
data/apriltag-0.10.0/common/zhash.c:195:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(zh, newhash, sizeof(zhash_t));
data/apriltag-0.10.0/common/zhash.c:196:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(newhash, &tmp, sizeof(zhash_t));
data/apriltag-0.10.0/common/zhash.c:214:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(old_key, this_key, zh->keysz);
data/apriltag-0.10.0/common/zhash.c:216:17:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                memcpy(old_value, this_value, zh->valuesz);
data/apriltag-0.10.0/common/zhash.c:228:21:  [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 tmp[zh->entrysz];
data/apriltag-0.10.0/common/zhash.c:229:21:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
                    memcpy(tmp, &zh->entries[entry_idx * zh->entrysz], zh->entrysz);
data/apriltag-0.10.0/common/zhash.c:320:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(outkey, outkeyp, zh->keysz);
data/apriltag-0.10.0/common/zhash.c:322:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(outvalue, outvaluep, zh->valuesz);
data/apriltag-0.10.0/common/zhash.c:339:9:  [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 tmp[zh->entrysz];
data/apriltag-0.10.0/common/zhash.c:340:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(tmp, &zh->entries[entry_idx * zh->entrysz], zh->entrysz);
data/apriltag-0.10.0/common/zhash.c:556:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(&k, &zh->entries[entry_idx * zh->entrysz + 1], sizeof(char*));
data/apriltag-0.10.0/common/zhash.c:557:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(&v, &zh->entries[entry_idx * zh->entrysz + 1 + zh->keysz], sizeof(char*));
data/apriltag-0.10.0/common/zmaxheap.c:68: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 tmp[heap->el_sz];
data/apriltag-0.10.0/common/zmaxheap.c:69:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(tmp, &heap->data[a*heap->el_sz], heap->el_sz);
data/apriltag-0.10.0/common/zmaxheap.c:70:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&heap->data[a*heap->el_sz], &heap->data[b*heap->el_sz], heap->el_sz);
data/apriltag-0.10.0/common/zmaxheap.c:71:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&heap->data[b*heap->el_sz], tmp, heap->el_sz);
data/apriltag-0.10.0/common/zmaxheap.c:143:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&heap->data[idx*heap->el_sz], p, heap->el_sz);
data/apriltag-0.10.0/common/zmaxheap.c:169:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(&p, &heap->data[idx*heap->el_sz], heap->el_sz);
data/apriltag-0.10.0/common/zmaxheap.c:190:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(p, &heap->data[idx*heap->el_sz], heap->el_sz);
data/apriltag-0.10.0/common/zmaxheap.c:202:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(&heap->data[idx*heap->el_sz], &heap->data[heap->el_sz * heap->size], heap->el_sz);
data/apriltag-0.10.0/common/zmaxheap.c:264:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    memcpy(p, &heap->data[it->in*heap->el_sz], heap->el_sz);
data/apriltag-0.10.0/common/zmaxheap.c:268:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(&heap->data[it->out*heap->el_sz], &heap->data[it->in*heap->el_sz], heap->el_sz);
data/apriltag-0.10.0/common/zmaxheap.c:288:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(&heap->data[it->out*heap->el_sz], &heap->data[it->in*heap->el_sz], heap->el_sz);
data/apriltag-0.10.0/example/simple_demo.c:108:35:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
        case 'i': maxiters      = atoi(optarg); break;
data/apriltag-0.10.0/example/simple_demo.c:109:35:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
        case 't': threads       = atoi(optarg); break;
data/apriltag-0.10.0/example/simple_demo.c:111:35:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
        case 'm': maxhamming    = atoi(optarg); break;
data/apriltag-0.10.0/make-tag-data.c:21:16:  [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).
    fp       = fopen(filename, "w");                                    \
data/apriltag-0.10.0/make-tag-data.c:35:16:  [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).
    fp       = fopen(filename, "w");                                    \
data/apriltag-0.10.0/make-tag-data.c:49:16:  [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).
    fp       = fopen(filename, "w");                                    \
data/apriltag-0.10.0/try-read.h:10:10:  [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).
    fp = fopen(filename, "r");
data/apriltag-0.10.0/common/getopt.c:166:31:  [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_t last = strlen(val) - 1;
data/apriltag-0.10.0/common/getopt.c:243:26:  [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_t len = strlen(tok);
data/apriltag-0.10.0/common/getopt.c:328: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).
    if (strlen(lname) < 1) { // must have long name
data/apriltag-0.10.0/common/getopt.c:378: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).
    if (strlen(lname) < 1) { // must have long name
data/apriltag-0.10.0/common/getopt.c:509: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).
        longwidth = max(longwidth, (int) strlen(goo->lname));
data/apriltag-0.10.0/common/getopt.c:512:48:  [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).
            valuewidth = max(valuewidth, (int) strlen(goo->svalue));
data/apriltag-0.10.0/common/getopt.c:521:36:  [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).
            if (goo->help==NULL || strlen(goo->help)==0)
data/apriltag-0.10.0/common/getopt.c:539: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).
        string_buffer_appendf(sb,"%*s", (int) (valuewidth-strlen(goo->svalue)), "");
data/apriltag-0.10.0/common/pam.c:66:26:  [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_t linelen = strlen(line);
data/apriltag-0.10.0/common/string_util.c:103:20:  [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(arg);
data/apriltag-0.10.0/common/string_util.c:136:19:  [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_t lena = strlen(a);
data/apriltag-0.10.0/common/string_util.c:137:19:  [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_t lenb = strlen(b);
data/apriltag-0.10.0/common/string_util.c:157:24:  [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_t delim_len = strlen(delim);
data/apriltag-0.10.0/common/string_util.c:158:18:  [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_t len = strlen(str);
data/apriltag-0.10.0/common/string_util.c:189:16:  [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_t len = strlen(str);
data/apriltag-0.10.0/common/string_util.c:237:23:  [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).
    char *end = str + strlen(str);
data/apriltag-0.10.0/common/string_util.c:240:23:  [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).
    memmove(str, ptr, strlen(ptr)+1);
data/apriltag-0.10.0/common/string_util.c:248:23:  [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).
    char *ptr = str + strlen(str) - 1;
data/apriltag-0.10.0/common/string_util.c:260:22:  [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).
    int hlen = (int) strlen(haystack);
data/apriltag-0.10.0/common/string_util.c:261:22:  [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).
    int nlen = (int) strlen(needle);
data/apriltag-0.10.0/common/string_util.c:279:22:  [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).
    int hlen = (int) strlen(haystack);
data/apriltag-0.10.0/common/string_util.c:280:22:  [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).
    int nlen = (int) strlen(needle);
data/apriltag-0.10.0/common/string_util.c:296:19:  [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_t slen = strlen(s);
data/apriltag-0.10.0/common/string_util.c:309:19:  [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_t slen = strlen(s);
data/apriltag-0.10.0/common/string_util.c:399:18:  [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_t len = strlen(str);
data/apriltag-0.10.0/common/string_util.c:448: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).
    sf->len = strlen(sf->s);
data/apriltag-0.10.0/common/string_util.c:552:18:  [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_t len = strlen(str);
data/apriltag-0.10.0/common/string_util.c:566:19:  [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_t lens = strlen(haystack);
data/apriltag-0.10.0/common/string_util.c:567:24:  [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_t lenneedle = strlen(needle);
data/apriltag-0.10.0/common/string_util.c:624:41:  [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).
    assert(startidx >= 0 && startidx <= strlen(str)+1);
data/apriltag-0.10.0/common/string_util.c:626:36:  [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).
    assert(endidx < 0 || endidx <= strlen(str)+1);
data/apriltag-0.10.0/common/string_util.c:629:25:  [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).
        endidx = (long) strlen(str);
data/apriltag-0.10.0/common/string_util.c:645:27:  [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_t haystack_len = strlen(haystack);
data/apriltag-0.10.0/common/string_util.c:646:25:  [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_t needle_len = strlen(needle);
data/apriltag-0.10.0/common/string_util.c:736:20:  [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_t inlen = strlen(in);
data/apriltag-0.10.0/common/time_util.c:82:12:  [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.
    return usleep(useconds);
data/apriltag-0.10.0/common/timeprofile.h:81:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
    strncpy(tpe.name, name, sizeof(tpe.name));

ANALYSIS SUMMARY:

Hits = 251
Lines analyzed = 180689 in approximately 5.95 seconds (30376 lines/second)
Physical Source Lines of Code (SLOC) = 172290
Hits@level = [0] 168 [1]  37 [2] 113 [3]  84 [4]  17 [5]   0
Hits@level+ = [0+] 419 [1+] 251 [2+] 214 [3+] 101 [4+]  17 [5+]   0
Hits/KSLOC@level+ = [0+] 2.43195 [1+] 1.45685 [2+] 1.24209 [3+] 0.586221 [4+] 0.0986708 [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.