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/exactimage-1.0.2/frontends/bardecode.cc Examining data/exactimage-1.0.2/frontends/edentify.cc Examining data/exactimage-1.0.2/frontends/optimize2bw.cc Examining data/exactimage-1.0.2/frontends/e2mtiff.cc Examining data/exactimage-1.0.2/frontends/hocr2pdf.cc Examining data/exactimage-1.0.2/frontends/empty-page.cc Examining data/exactimage-1.0.2/frontends/econvert.cc Examining data/exactimage-1.0.2/bardecode/Scanner.cc Examining data/exactimage-1.0.2/image/riemersma.cc Examining data/exactimage-1.0.2/image/scale.cc Examining data/exactimage-1.0.2/image/Image.cc Examining data/exactimage-1.0.2/image/empty-page.cc Examining data/exactimage-1.0.2/image/agg.cc Examining data/exactimage-1.0.2/image/floyd-steinberg.h Examining data/exactimage-1.0.2/image/Contours.cc Examining data/exactimage-1.0.2/image/FG-Matrix.cc Examining data/exactimage-1.0.2/image/GaussianBlur.cc Examining data/exactimage-1.0.2/image/DistanceMatrix.cc Examining data/exactimage-1.0.2/image/ContourUtility.cc Examining data/exactimage-1.0.2/image/Image2.cc Examining data/exactimage-1.0.2/image/rotate.cc Examining data/exactimage-1.0.2/image/floyd-steinberg.cc Examining data/exactimage-1.0.2/image/ContourMatching.cc Examining data/exactimage-1.0.2/image/segmentation.cc Examining data/exactimage-1.0.2/image/Colorspace.cc Examining data/exactimage-1.0.2/image/vectorial.cc Examining data/exactimage-1.0.2/image/crop.cc Examining data/exactimage-1.0.2/image/Matrix.cc Examining data/exactimage-1.0.2/image/optimize2bw.cc Examining data/exactimage-1.0.2/image/riemersma.h Examining data/exactimage-1.0.2/image/canvas.cc Examining data/exactimage-1.0.2/image/low-level.cc Examining data/exactimage-1.0.2/image/hocr.cc Examining data/exactimage-1.0.2/codecs/jpeg.cc Examining data/exactimage-1.0.2/codecs/tga.cc Examining data/exactimage-1.0.2/codecs/eps.cc Examining data/exactimage-1.0.2/codecs/jpeg2000.cc Examining data/exactimage-1.0.2/codecs/pcx.cc Examining data/exactimage-1.0.2/codecs/png.cc Examining data/exactimage-1.0.2/codecs/ps.cc Examining data/exactimage-1.0.2/codecs/Codecs.cc Examining data/exactimage-1.0.2/codecs/jpegint.h Examining data/exactimage-1.0.2/codecs/dcraw.cc Examining data/exactimage-1.0.2/codecs/openexr.cc Examining data/exactimage-1.0.2/codecs/jpegcomp.h Examining data/exactimage-1.0.2/codecs/agg_svg_parser.cc Examining data/exactimage-1.0.2/codecs/agg_svg_path_renderer.cc Examining data/exactimage-1.0.2/codecs/transupp.h Examining data/exactimage-1.0.2/codecs/jinclude.h Examining data/exactimage-1.0.2/codecs/bmp.cc Examining data/exactimage-1.0.2/codecs/pdf.cc Examining data/exactimage-1.0.2/codecs/pnm.cc Examining data/exactimage-1.0.2/codecs/xpm.cc Examining data/exactimage-1.0.2/codecs/tiff.cc Examining data/exactimage-1.0.2/codecs/transupp.c Examining data/exactimage-1.0.2/codecs/agg_svg_path_tokenizer.cc Examining data/exactimage-1.0.2/codecs/dcraw.h Examining data/exactimage-1.0.2/codecs/raw.cc Examining data/exactimage-1.0.2/codecs/svg.cc Examining data/exactimage-1.0.2/codecs/gif_quantization.c Examining data/exactimage-1.0.2/codecs/gif.cc Examining data/exactimage-1.0.2/edisplay/edisplay.cc Examining data/exactimage-1.0.2/api/api.cc Examining data/exactimage-1.0.2/ContourMatching/Contours.cc Examining data/exactimage-1.0.2/ContourMatching/ContourMatching.cc Examining data/exactimage-1.0.2/ContourMatching/distance.cc Examining data/exactimage-1.0.2/ContourMatching/segmentation.cc Examining data/exactimage-1.0.2/utility/tests/Logging.cc Examining data/exactimage-1.0.2/utility/tests/Thread.cc Examining data/exactimage-1.0.2/utility/tests/pstream.cc Examining data/exactimage-1.0.2/utility/tests/File.cc Examining data/exactimage-1.0.2/utility/tests/Find.cc Examining data/exactimage-1.0.2/utility/tests/ThreadedFind.cc Examining data/exactimage-1.0.2/utility/tests/Delete.cc Examining data/exactimage-1.0.2/utility/tests/Attribute.cc Examining data/exactimage-1.0.2/utility/Logging.cc Examining data/exactimage-1.0.2/utility/Storage.cc Examining data/exactimage-1.0.2/utility/ArgumentList.cc Examining data/exactimage-1.0.2/utility/Lua.cc Examining data/exactimage-1.0.2/utility/Threads.cc Examining data/exactimage-1.0.2/utility/File.cc Examining data/exactimage-1.0.2/utility/C.h Examining data/exactimage-1.0.2/utility/DirIterator.cc Examining data/exactimage-1.0.2/utility/Logger.cc Examining data/exactimage-1.0.2/utility/TypeInformation.cc Examining data/exactimage-1.0.2/utility/Timer.cc Examining data/exactimage-1.0.2/config/pkgcheck-cocoa.c Examining data/exactimage-1.0.2/config/pkgcheck-atsui.c Examining data/exactimage-1.0.2/config/cc-available.c Examining data/exactimage-1.0.2/config/c++-function-template.c Examining data/exactimage-1.0.2/config/c++-exception.c Examining data/exactimage-1.0.2/config/c++-stl.c Examining data/exactimage-1.0.2/config/pkgcheck-oss.c Examining data/exactimage-1.0.2/config/c++-template.c Examining data/exactimage-1.0.2/config/cc-99.c Examining data/exactimage-1.0.2/config/pkgcheck-x11.c Examining data/exactimage-1.0.2/config/c++-available.c Examining data/exactimage-1.0.2/config/c++-partial-template-specialization.c Examining data/exactimage-1.0.2/config/c++-rtti.c Examining data/exactimage-1.0.2/config/pkgcheck-alsa.c Examining data/exactimage-1.0.2/config/c++-template-specialization.c Examining data/exactimage-1.0.2/gfx/EvasHelper.cc Examining data/exactimage-1.0.2/gfx/X11Helper.cc FINAL RESULTS: data/exactimage-1.0.2/codecs/agg_svg_parser.cc:243:17: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(msg, data/exactimage-1.0.2/codecs/agg_svg_parser.cc:446:13: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy(c.name, str); data/exactimage-1.0.2/codecs/dcraw.cc:68:13: [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 n = vsnprintf(p, size, fmt, ap); data/exactimage-1.0.2/codecs/dcraw.cc:112:9: [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. #define fprintf wrapped_fprintf data/exactimage-1.0.2/codecs/dcraw.cc:113:9: [4] (buffer) fscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. #define fscanf wrapped_fscanf data/exactimage-1.0.2/codecs/dcraw.h:58:9: [4] (format) snprintf: 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. #define snprintf _snprintf data/exactimage-1.0.2/codecs/dcraw.h:58:18: [4] (format) _snprintf: 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. #define snprintf _snprintf data/exactimage-1.0.2/codecs/dcraw.h:1325:7: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (make, table[i].make ); data/exactimage-1.0.2/codecs/dcraw.h:1326:7: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (model, table[i].model); data/exactimage-1.0.2/codecs/dcraw.h:3415:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (str, "%sRGBNeutral", model2); data/exactimage-1.0.2/codecs/dcraw.h:5595:2: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (model, mod[i]); data/exactimage-1.0.2/codecs/dcraw.h:6046:4: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy(model,cp+1); data/exactimage-1.0.2/codecs/dcraw.h:6423:3: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (jname, ifname); data/exactimage-1.0.2/codecs/dcraw.h:6427:5: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (jext, isupper(ext[1]) ? ".JPG":".jpg"); data/exactimage-1.0.2/codecs/dcraw.h:6645:5: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (model, cp+1); data/exactimage-1.0.2/codecs/dcraw.h:6819:9: [4] (buffer) sscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. if (sscanf (date, "%*s %s %d %d:%d:%d %d", month, &t.tm_mday, data/exactimage-1.0.2/codecs/dcraw.h:7094:6: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (make, value); data/exactimage-1.0.2/codecs/dcraw.h:7096:6: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (model, value); data/exactimage-1.0.2/codecs/dcraw.h:7098:6: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (model2, value); data/exactimage-1.0.2/codecs/dcraw.h:8272:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (name, "%s %s", make, model); data/exactimage-1.0.2/codecs/dcraw.h:8805:2: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (make, table[i].make ); data/exactimage-1.0.2/codecs/dcraw.h:8806:2: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (model, table[i].model); data/exactimage-1.0.2/codecs/dcraw.h:8856:6: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (make, corp[i]); data/exactimage-1.0.2/codecs/dcraw.h:8871:5: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (model, model+8); data/exactimage-1.0.2/codecs/dcraw.h:8873:5: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (model, model+15); data/exactimage-1.0.2/codecs/dcraw.h:8941:2: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (model, unique[i].model); data/exactimage-1.0.2/codecs/dcraw.h:8945:7: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (model, sonique[i].model); data/exactimage-1.0.2/codecs/dcraw.h:9195:7: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf (model+20, "DYNAX %-10s", model+6+(model[0]=='M')); data/exactimage-1.0.2/codecs/dcraw.h:9644:5: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (cdesc, colors == 3 ? "RGBG":"GMCY"); data/exactimage-1.0.2/codecs/dcraw.h:9785:5: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy ((char *)oprof+pbody[5]+12, name[output_color-1]); data/exactimage-1.0.2/codecs/dcraw.h:9792:5: [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, raw_color ? _("Building histograms...\n") : data/exactimage-1.0.2/codecs/dcraw.h:9961:3: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (th->soft, "dcraw v"DCRAW_VERSION); data/exactimage-1.0.2/codecs/dcraw.h:10481:7: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (ofname, ifname); data/exactimage-1.0.2/codecs/dcraw.h:10488:7: [4] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). strcat (ofname, write_ext); data/exactimage-1.0.2/utility/Threads.cc:44:3: [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. access.Lock(); data/exactimage-1.0.2/utility/Threads.cc:46:3: [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. access.Unlock(); data/exactimage-1.0.2/utility/Threads.cc:52:3: [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. access.Lock(); data/exactimage-1.0.2/utility/Threads.cc:54:15: [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. sig.Wait (access); data/exactimage-1.0.2/utility/Threads.cc:56:3: [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. access.Unlock(); data/exactimage-1.0.2/ContourMatching/ContourMatching.cc:164: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). FILE* test=fopen("test.cnt", "w"); data/exactimage-1.0.2/ContourMatching/ContourMatching.cc:171:8: [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). test=fopen("test.cnt", "r"); data/exactimage-1.0.2/api/api.cc:138:3: [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 (payload, stream.str().c_str(), stream.str().size()); data/exactimage-1.0.2/codecs/agg_svg_parser.cc:37: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 name[22]; data/exactimage-1.0.2/codecs/agg_svg_parser.cc:223: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 msg[1024]; data/exactimage-1.0.2/codecs/agg_svg_parser.cc:366: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(self.m_title + self.m_title_len, s, len); data/exactimage-1.0.2/codecs/agg_svg_parser.cc:563: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. if(len) memcpy(m_attr_name, start, len); data/exactimage-1.0.2/codecs/agg_svg_parser.cc:579: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. if(len) memcpy(m_attr_value, start, len); data/exactimage-1.0.2/codecs/agg_svg_path_renderer.cc:375: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 buf[100]; data/exactimage-1.0.2/codecs/agg_svg_path_renderer.cc:376:21: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf(buf, "parse_path: Invalid Command %c", cmd); data/exactimage-1.0.2/codecs/agg_svg_path_tokenizer.cc:81: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 buf[100]; data/exactimage-1.0.2/codecs/agg_svg_path_tokenizer.cc:82:17: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf(buf, "path_tokenizer::next : Invalid Character %c", *m_path); data/exactimage-1.0.2/codecs/agg_svg_path_tokenizer.cc:112:13: [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 buf[100]; data/exactimage-1.0.2/codecs/agg_svg_path_tokenizer.cc:113:13: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf(buf, "parse_path: Command %c: bad or missing parameters", cmd); data/exactimage-1.0.2/codecs/agg_svg_path_tokenizer.cc:123: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 buf[256]; // Should be enough for any number data/exactimage-1.0.2/codecs/bmp.cc:113:3: [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 bType[2]; /* Signature "BM" */ data/exactimage-1.0.2/codecs/bmp.cc:722:4: [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(&payload[0], image.getRawData() + stride * row, stride); data/exactimage-1.0.2/codecs/dcraw.cc:123:9: [2] (tmpfile) tmpfile: Function tmpfile() has a security flaw on some systems (e.g., older System V systems) (CWE-377). #define tmpfile new std::stringstream data/exactimage-1.0.2/codecs/dcraw.cc:124:9: [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). #define fopen(name, mode) new std::fstream(name) data/exactimage-1.0.2/codecs/dcraw.cc:221: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 (rgb_cam, cmatrix, sizeof cmatrix); data/exactimage-1.0.2/codecs/dcraw.h:110:1: [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 *meta_data, xtrans[6][6], xtrans_abs[6][6]; data/exactimage-1.0.2/codecs/dcraw.h:111:1: [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 cdesc[5], desc[512], make[64], model[64], model2[64], artist[64]; data/exactimage-1.0.2/codecs/dcraw.h:233:16: [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 filter[16][16] = data/exactimage-1.0.2/codecs/dcraw.h:342:11: [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. union { char c[8]; double d; } u; data/exactimage-1.0.2/codecs/dcraw.h:1313: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 make[12], model[15]; data/exactimage-1.0.2/codecs/dcraw.h:1336:3: [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 tail[424]; data/exactimage-1.0.2/codecs/dcraw.h:1491:23: [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 signed char dir[12][2] = data/exactimage-1.0.2/codecs/dcraw.h:2279:2: [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[c][0]+!c, buf[c][2], sizeof buf[c][0]-2*!c); data/exactimage-1.0.2/codecs/dcraw.h:2394:11: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. FORC3 memcpy (cur[c], curve, sizeof cur[0]); data/exactimage-1.0.2/codecs/dcraw.h:3135:32: [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). if (!bit && !load_flags && atoi(model+2) < 14) get4(); data/exactimage-1.0.2/codecs/dcraw.h:3297:3: [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 (ptr, dp, size*4); data/exactimage-1.0.2/codecs/dcraw.h:3369:3: [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 str[128]; data/exactimage-1.0.2/codecs/dcraw.h:3457:3: [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 (black, black+8, sizeof *black*8); data/exactimage-1.0.2/codecs/dcraw.h:3458:3: [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 (black+height-11, black+height-22, 11*sizeof *black); data/exactimage-1.0.2/codecs/dcraw.h:3459:3: [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 (last, black, sizeof last); data/exactimage-1.0.2/codecs/dcraw.h:3469: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 (last[2], black[row+1], sizeof last[2]); data/exactimage-1.0.2/codecs/dcraw.h:3475:3: [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 (fsum, black, sizeof fsum); data/exactimage-1.0.2/codecs/dcraw.h:3479:3: [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 (last[0], black[height-1], sizeof last[0]); data/exactimage-1.0.2/codecs/dcraw.h:3499: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 (prev, pix, sizeof prev); data/exactimage-1.0.2/codecs/dcraw.h:3709: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 (smrow[2], smrow[1], sizeof **smrow * width); data/exactimage-1.0.2/codecs/dcraw.h:3745: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 (image[row*i], image[(row+active[1])*width+active[0]], data/exactimage-1.0.2/codecs/dcraw.h:3848:3: [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 *fname, *cp, line[128]; data/exactimage-1.0.2/codecs/dcraw.h:3853: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 (cfname, "r"); data/exactimage-1.0.2/codecs/dcraw.h:3871:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (cp, "/.badpixels"); data/exactimage-1.0.2/codecs/dcraw.h:3872:17: [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). if ((fp = fopen (fname, "r"))) break; data/exactimage-1.0.2/codecs/dcraw.h:3910: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). if (!(fp = fopen (fname, "rb"))) { data/exactimage-1.0.2/codecs/dcraw.h:3969: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 (gamm, g, sizeof gamm); data/exactimage-1.0.2/codecs/dcraw.h:4207: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 (pre_mul, user_mul, sizeof pre_mul); data/exactimage-1.0.2/codecs/dcraw.h:4246: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 (pre_mul, cam_mul, sizeof pre_mul); data/exactimage-1.0.2/codecs/dcraw.h:4528:2: [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 (brow[2][col], pix, sizeof *image); data/exactimage-1.0.2/codecs/dcraw.h:4552: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 (image[(row-2)*width+2], brow[0]+2, (width-4)*sizeof *image); data/exactimage-1.0.2/codecs/dcraw.h:4556:3: [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 (image[(row-2)*width+2], brow[0]+2, (width-4)*sizeof *image); data/exactimage-1.0.2/codecs/dcraw.h:4557:3: [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 (image[(row-1)*width+2], brow[1]+2, (width-4)*sizeof *image); data/exactimage-1.0.2/codecs/dcraw.h:4666:4: [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 (*homo)[TS][TS], *buffer; data/exactimage-1.0.2/codecs/dcraw.h:4678:11: [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. homo = (char (*)[TS][TS]) (buffer + TS*TS*(ndir*10+6)); data/exactimage-1.0.2/codecs/dcraw.h:4720:4: [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 (rgb[0][row-top][col-left], image[row*width+col], 6); data/exactimage-1.0.2/codecs/dcraw.h:4721: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. FORC3 memcpy (rgb[c+1], rgb[0], sizeof *rgb); data/exactimage-1.0.2/codecs/dcraw.h:4742:4: [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 (rgb+=4, buffer, 4*sizeof *rgb); data/exactimage-1.0.2/codecs/dcraw.h:4891:4: [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 (*homo)[TS][TS], *buffer; data/exactimage-1.0.2/codecs/dcraw.h:4901:11: [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. homo = (char (*)[TS][TS]) (buffer + 24*TS*TS); data/exactimage-1.0.2/codecs/dcraw.h:5060:23: [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 signed char dir[8][2] = data/exactimage-1.0.2/codecs/dcraw.h:5196:3: [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 buf[10]; data/exactimage-1.0.2/codecs/dcraw.h:5478:3: [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 str[20]; data/exactimage-1.0.2/codecs/dcraw.h:5567:3: [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 data[40]; data/exactimage-1.0.2/codecs/dcraw.h:5690:3: [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 software[64], *cbuf, *cp; data/exactimage-1.0.2/codecs/dcraw.h:5862:2: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "Sarnoff"); data/exactimage-1.0.2/codecs/dcraw.h:5895:15: [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. FORC(36) ((char *)xtrans)[c] = fgetc(ifp) & 3; data/exactimage-1.0.2/codecs/dcraw.h:5905:18: [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 (cfa == 070) memcpy (cfa_pc,"\003\004\005",3); /* CMY */ data/exactimage-1.0.2/codecs/dcraw.h:5906:18: [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 (cfa == 072) memcpy (cfa_pc,"\005\003\004\001",4); /* GMCY */ data/exactimage-1.0.2/codecs/dcraw.h:5937:2: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "Leaf"); data/exactimage-1.0.2/codecs/dcraw.h:5976:2: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "Imacon"); data/exactimage-1.0.2/codecs/dcraw.h:6006:2: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf (model, "Ixpress %d-Mp", height*width/1000000); data/exactimage-1.0.2/codecs/dcraw.h:6024:16: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. if (!make[0]) strcpy (make, "Hasselblad"); data/exactimage-1.0.2/codecs/dcraw.h:6039:16: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. if (!make[0]) strcpy (make, "DNG"); data/exactimage-1.0.2/codecs/dcraw.h:6161:16: [2] (tmpfile) tmpfile: Function tmpfile() has a security flaw on some systems (e.g., older System V systems) (CWE-377). if ((ifp = tmpfile())) { data/exactimage-1.0.2/codecs/dcraw.h:6429: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 (jfile, file+4, 4); data/exactimage-1.0.2/codecs/dcraw.h:6430: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 (jfile+4, file, 4); data/exactimage-1.0.2/codecs/dcraw.h:6441: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). if ((ifp = fopen (jname, "rb"))) { data/exactimage-1.0.2/codecs/dcraw.h:6589:3: [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[128], *val; data/exactimage-1.0.2/codecs/dcraw.h:6605:22: [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). thumb_offset = atoi(val); data/exactimage-1.0.2/codecs/dcraw.h:6607:19: [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). raw_width = atoi(val); data/exactimage-1.0.2/codecs/dcraw.h:6609:20: [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). raw_height = atoi(val); data/exactimage-1.0.2/codecs/dcraw.h:6611:21: [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). thumb_width = atoi(val); data/exactimage-1.0.2/codecs/dcraw.h:6613:22: [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). thumb_height = atoi(val); data/exactimage-1.0.2/codecs/dcraw.h:6620:3: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "Rollei"); data/exactimage-1.0.2/codecs/dcraw.h:6621:3: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model,"d530flex"); data/exactimage-1.0.2/codecs/dcraw.h:6628:3: [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 str[8], *cp; data/exactimage-1.0.2/codecs/dcraw.h:6716:3: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "Phase One"); data/exactimage-1.0.2/codecs/dcraw.h:6719:16: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. case 2060: strcpy (model,"LightPhase"); break; data/exactimage-1.0.2/codecs/dcraw.h:6720:16: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. case 2682: strcpy (model,"H 10"); break; data/exactimage-1.0.2/codecs/dcraw.h:6721:16: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. case 4128: strcpy (model,"H 20"); break; data/exactimage-1.0.2/codecs/dcraw.h:6722:16: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. case 5488: strcpy (model,"H 25"); break; data/exactimage-1.0.2/codecs/dcraw.h:6794:3: [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 tag[4], date[64], month[64]; data/exactimage-1.0.2/codecs/dcraw.h:6795:16: [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 mon[12][4] = data/exactimage-1.0.2/codecs/dcraw.h:6901:3: [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 tag[4]; data/exactimage-1.0.2/codecs/dcraw.h:6931:3: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "SMaL"); data/exactimage-1.0.2/codecs/dcraw.h:6932:3: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf (model, "v%d %dx%d", ver, width, height); data/exactimage-1.0.2/codecs/dcraw.h:6959:3: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "CINE"); data/exactimage-1.0.2/codecs/dcraw.h:6960:3: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf (model, "%d", get4()); data/exactimage-1.0.2/codecs/dcraw.h:7028:3: [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[64], value[64]; data/exactimage-1.0.2/codecs/dcraw.h:7092:18: [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). iso_speed = atoi(value); data/exactimage-1.0.2/codecs/dcraw.h:7100:18: [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). timestamp = atoi(value); data/exactimage-1.0.2/codecs/dcraw.h:7102:16: [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). shutter = atoi(value) / 1000000.0; data/exactimage-1.0.2/codecs/dcraw.h:8269:3: [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[130]; data/exactimage-1.0.2/codecs/dcraw.h:8431: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 model[20]; data/exactimage-1.0.2/codecs/dcraw.h:8520: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 make[10], model[20]; data/exactimage-1.0.2/codecs/dcraw.h:8631:3: [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 head[32], *cp; data/exactimage-1.0.2/codecs/dcraw.h:8689:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "Contax"); data/exactimage-1.0.2/codecs/dcraw.h:8690:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model,"N Digital"); data/exactimage-1.0.2/codecs/dcraw.h:8696:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "Logitech"); data/exactimage-1.0.2/codecs/dcraw.h:8697:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model,"Fotoman Pixtura"); data/exactimage-1.0.2/codecs/dcraw.h:8699:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "Apple"); data/exactimage-1.0.2/codecs/dcraw.h:8700:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model,"QuickTake 100"); data/exactimage-1.0.2/codecs/dcraw.h:8703:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "Apple"); data/exactimage-1.0.2/codecs/dcraw.h:8704:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model,"QuickTake 150"); data/exactimage-1.0.2/codecs/dcraw.h:8748:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "NOKIA"); data/exactimage-1.0.2/codecs/dcraw.h:8767:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "ARRI"); data/exactimage-1.0.2/codecs/dcraw.h:8786:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "Red"); data/exactimage-1.0.2/codecs/dcraw.h:8787:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model,"One"); data/exactimage-1.0.2/codecs/dcraw.h:8845:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "OmniVision"); data/exactimage-1.0.2/codecs/dcraw.h:8862:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "Pentax"); data/exactimage-1.0.2/codecs/dcraw.h:8963:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model,"C603"); data/exactimage-1.0.2/codecs/dcraw.h:9023:23: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. if (canon_s2is()) strcpy (model+10, "S2 IS"); data/exactimage-1.0.2/codecs/dcraw.h:9105:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model, "E995"); data/exactimage-1.0.2/codecs/dcraw.h:9115:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model,"E2500"); data/exactimage-1.0.2/codecs/dcraw.h:9124:28: [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). if (model[0] == 'E' && atoi(model+1) < 3700) data/exactimage-1.0.2/codecs/dcraw.h:9141:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "Minolta"); data/exactimage-1.0.2/codecs/dcraw.h:9142:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model,"DiMAGE Z2"); data/exactimage-1.0.2/codecs/dcraw.h:9151:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (make, "ISG"); data/exactimage-1.0.2/codecs/dcraw.h:9156:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model,"S2Pro"); data/exactimage-1.0.2/codecs/dcraw.h:9175:18: [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. FORC(36) ((char *)xtrans)[c] = data/exactimage-1.0.2/codecs/dcraw.h:9267:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model, "WB550"); data/exactimage-1.0.2/codecs/dcraw.h:9309:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model, "V96C"); data/exactimage-1.0.2/codecs/dcraw.h:9335:2: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (cdesc, "RBTG"); data/exactimage-1.0.2/codecs/dcraw.h:9336:2: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model, "CatchLight"); data/exactimage-1.0.2/codecs/dcraw.h:9339:2: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model, "DCB2"); data/exactimage-1.0.2/codecs/dcraw.h:9343:22: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. if (!model[0]) strcpy (model, "Cantare"); data/exactimage-1.0.2/codecs/dcraw.h:9354:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model, "Valeo 6"); data/exactimage-1.0.2/codecs/dcraw.h:9359:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model, "Valeo 6"); data/exactimage-1.0.2/codecs/dcraw.h:9431:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (cdesc, "RGBE"); data/exactimage-1.0.2/codecs/dcraw.h:9508:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (cdesc, "MYCY"); data/exactimage-1.0.2/codecs/dcraw.h:9510:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model, "DC25"); data/exactimage-1.0.2/codecs/dcraw.h:9531:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model, "DC40"); data/exactimage-1.0.2/codecs/dcraw.h:9538:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model, "DC50"); data/exactimage-1.0.2/codecs/dcraw.h:9544:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (model, "DC120"); data/exactimage-1.0.2/codecs/dcraw.h:9566:18: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. if (head[5]) strcpy (model+10, "200"); data/exactimage-1.0.2/codecs/dcraw.h:9595:5: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf (model, "%dx%d", width, height); data/exactimage-1.0.2/codecs/dcraw.h:9607: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 (rgb_cam, cmatrix, sizeof cmatrix); data/exactimage-1.0.2/codecs/dcraw.h:9678:18: [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). else if ((fp = fopen (output, "rb"))) { data/exactimage-1.0.2/codecs/dcraw.h:9755:3: [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_cam, rgb_cam, sizeof out_cam); data/exactimage-1.0.2/codecs/dcraw.h:9761: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 (oprof, phead, sizeof phead); data/exactimage-1.0.2/codecs/dcraw.h:9769: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 (oprof+32, pbody, sizeof pbody); data/exactimage-1.0.2/codecs/dcraw.h:9771: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 ((char *)oprof+pbody[8]+8, pwhite, sizeof pwhite); data/exactimage-1.0.2/codecs/dcraw.h:9774: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 ((char *)oprof+pbody[i*3+2], pcurve, sizeof pcurve); data/exactimage-1.0.2/codecs/dcraw.h:9784:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy ((char *)oprof+pbody[2]+8, "auto-generated by dcraw"); data/exactimage-1.0.2/codecs/dcraw.h:9901:11: [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. union { char c[4]; short s[2]; int i; } val; data/exactimage-1.0.2/codecs/dcraw.h:9917:3: [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 desc[512], make[64], model[64], soft[32], date[20], artist[64]; data/exactimage-1.0.2/codecs/dcraw.h:9933:32: [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. FORC(4) tt->val.c[c] = ((char *)th)[val+c]; data/exactimage-1.0.2/codecs/dcraw.h:9963:3: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf (th->date, "%04d:%02d:%02d %02d:%02d:%02d", data/exactimage-1.0.2/codecs/dcraw.h:10013: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 (th->gps, gpsdata, sizeof th->gps); data/exactimage-1.0.2/codecs/dcraw.h:10029: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 (exif, "\xff\xe1 Exif\0\0", 10); data/exactimage-1.0.2/codecs/dcraw.h:10178:32: [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 'k': user_black = atoi(argv[arg++]); break; data/exactimage-1.0.2/codecs/dcraw.h:10179:32: [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 'S': user_sat = atoi(argv[arg++]); break; data/exactimage-1.0.2/codecs/dcraw.h:10180:32: [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': user_flip = atoi(argv[arg++]); break; data/exactimage-1.0.2/codecs/dcraw.h:10181:32: [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 'q': user_qual = atoi(argv[arg++]); break; data/exactimage-1.0.2/codecs/dcraw.h:10182:32: [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': med_passes = atoi(argv[arg++]); break; data/exactimage-1.0.2/codecs/dcraw.h:10183:32: [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 'H': highlight = atoi(argv[arg++]); break; data/exactimage-1.0.2/codecs/dcraw.h:10185:20: [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). shot_select = abs(atoi(argv[arg])); data/exactimage-1.0.2/codecs/dcraw.h:10190:19: [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). output_color = atoi(argv[arg++]); data/exactimage-1.0.2/codecs/dcraw.h:10206:38: [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 'A': FORC4 greybox[c] = atoi(argv[arg++]); data/exactimage-1.0.2/codecs/dcraw.h:10255:17: [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). if (!(ifp = fopen (ifname, "rb"))) { data/exactimage-1.0.2/codecs/dcraw.h:10479:7: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (ofname,_("standard output")); data/exactimage-1.0.2/codecs/dcraw.h:10484:2: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf (ofname+strlen(ofname), "_%0*d", data/exactimage-1.0.2/codecs/dcraw.h:10487:2: [2] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). Risk is low because the source is a constant string. strcat (ofname, ".thumb"); data/exactimage-1.0.2/codecs/dcraw.h:10489:13: [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). ofp = fopen (ofname, "wb"); data/exactimage-1.0.2/codecs/gif.cc:56: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 buf [3]; data/exactimage-1.0.2/codecs/jinclude.h:62:32: [2] (buffer) bcopy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. #define MEMCOPY(dest,src,size) bcopy((const void *)(src), (void *)(dest), (size_t)(size)) data/exactimage-1.0.2/codecs/jinclude.h:68:32: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. #define MEMCOPY(dest,src,size) memcpy((void *)(dest), (const void *)(src), (size_t)(size)) data/exactimage-1.0.2/codecs/jpeg.cc:295: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 buf [10]; data/exactimage-1.0.2/codecs/jpeg2000.cc:130: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 buf [6]; data/exactimage-1.0.2/codecs/openexr.cc: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 buf [3]; data/exactimage-1.0.2/codecs/png.cc:51: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 buf [4]; data/exactimage-1.0.2/codecs/pnm.cc:257:4: [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 (&ptr[0], image.getRawData() + y * stride, stridefill); data/exactimage-1.0.2/codecs/tga.cc:62:3: [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 Signature[16]; data/exactimage-1.0.2/image/Image.cc:70: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(data + y * dststride, src + y * srcstride, dststride); data/exactimage-1.0.2/image/Image.cc:192: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(newdata, data, stride() * h); data/exactimage-1.0.2/image/canvas.cc:39:3: [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(image.getRawData() + image.stride() * old_height, data/exactimage-1.0.2/image/low-level.cc:37: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(dst, src, stride); data/exactimage-1.0.2/image/scale.cc:384: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 dir_map [image.h - 1][image.w - 1]; data/exactimage-1.0.2/image/scale.cc:416:2: [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 dir_map2 [image.h - 1][image.w - 1]; data/exactimage-1.0.2/codecs/agg_svg_parser.cc:441:28: [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). unsigned len = strlen(str); data/exactimage-1.0.2/codecs/bmp.cc:243:11: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read ((char*)&file_hdr.bType, 2); data/exactimage-1.0.2/codecs/bmp.cc:251:11: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read ((char*)&file_hdr.iOffBits, 4); data/exactimage-1.0.2/codecs/bmp.cc:273:11: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read ((char*)&info_hdr.iSize, 4); data/exactimage-1.0.2/codecs/bmp.cc:304:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read ((char*)&iShort, 2); data/exactimage-1.0.2/codecs/bmp.cc:306:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read ((char*)&iShort, 2); data/exactimage-1.0.2/codecs/bmp.cc:308:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read ((char*)&iShort, 2); data/exactimage-1.0.2/codecs/bmp.cc:310:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read ((char*)&iShort, 2); data/exactimage-1.0.2/codecs/bmp.cc:316:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&info_hdr.iWidth, 4); data/exactimage-1.0.2/codecs/bmp.cc:317:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&info_hdr.iHeight, 4); data/exactimage-1.0.2/codecs/bmp.cc:318:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&info_hdr.iPlanes, 2); data/exactimage-1.0.2/codecs/bmp.cc:319:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&info_hdr.iBitCount, 2); data/exactimage-1.0.2/codecs/bmp.cc:320:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&info_hdr.iCompression, 4); data/exactimage-1.0.2/codecs/bmp.cc:321:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&info_hdr.iSizeImage, 4); data/exactimage-1.0.2/codecs/bmp.cc:322:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&info_hdr.iXPelsPerMeter, 4); data/exactimage-1.0.2/codecs/bmp.cc:323:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&info_hdr.iYPelsPerMeter, 4); data/exactimage-1.0.2/codecs/bmp.cc:324:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&info_hdr.iClrUsed, 4); data/exactimage-1.0.2/codecs/bmp.cc:325:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&info_hdr.iClrImportant, 4); data/exactimage-1.0.2/codecs/bmp.cc:331:15: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&info_hdr.iRedMask, 4); data/exactimage-1.0.2/codecs/bmp.cc:332:15: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&info_hdr.iGreenMask, 4); data/exactimage-1.0.2/codecs/bmp.cc:333:15: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&info_hdr.iBlueMask, 4); data/exactimage-1.0.2/codecs/bmp.cc:335:10: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&info_hdr.iAlphaMask, 4); data/exactimage-1.0.2/codecs/bmp.cc:388:15: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read ((char*)clr_tbl, n_clr_elems * clr_tbl_size); data/exactimage-1.0.2/codecs/bmp.cc:483:10: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)row_ptr, file_stride); data/exactimage-1.0.2/codecs/bmp.cc:543:15: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&comprbuf[0], compr_size); data/exactimage-1.0.2/codecs/dcraw.cc:47:18: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). return stream->read (mem, n) ? n : 0; data/exactimage-1.0.2/codecs/dcraw.cc:115:9: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). #define fgetc(stream) stream->get () data/exactimage-1.0.2/codecs/dcraw.cc:116:8: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). #undef getc data/exactimage-1.0.2/codecs/dcraw.cc:117:9: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). #define getc(stream) stream->get () data/exactimage-1.0.2/codecs/dcraw.h:271:33: [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 (!strncasecmp(c, needle, strlen(needle))) data/exactimage-1.0.2/codecs/dcraw.h:358:17: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). u.c[i ^ rev] = fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:360:21: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). default: return fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:590:9: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (getc(ifp) > 15) return 1; data/exactimage-1.0.2/codecs/dcraw.h:605:42: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). while (!reset && vbits < nbits && (c = fgetc(ifp)) != EOF && data/exactimage-1.0.2/codecs/dcraw.h:606:45: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). !(reset = zero_after_ff && c == 0xff && fgetc(ifp))) { data/exactimage-1.0.2/codecs/dcraw.h:798:6: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). c = fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:824:8: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if ((fgetc(ifp),fgetc(ifp)) != 0xd8) return 0; data/exactimage-1.0.2/codecs/dcraw.h:824:19: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if ((fgetc(ifp),fgetc(ifp)) != 0xd8) return 0; data/exactimage-1.0.2/codecs/dcraw.h:841:32: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (len == 9 && !dng_version) getc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:902:36: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). do mark = (mark << 8) + (c = fgetc(ifp)); data/exactimage-1.0.2/codecs/dcraw.h:1170:25: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). FORC(dep) bit[1][c] = fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:1206:10: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). ver0 = fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:1207:10: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). ver1 = fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:1261:29: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). FORC(6) bitbuf |= (UINT64) fgetc(ifp) << c*8; data/exactimage-1.0.2/codecs/dcraw.h:1282:11: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). histo[fgetc(ifp)]++; data/exactimage-1.0.2/codecs/dcraw.h:1950:24: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). bitbuf |= ((UINT64) fgetc(ifp) << i); data/exactimage-1.0.2/codecs/dcraw.h:1954:48: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (load_flags & 1 && (col % 10) == 9 && fgetc(ifp) && data/exactimage-1.0.2/codecs/dcraw.h:2556:9: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). c = fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:2571:15: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). bitbuf = fgetc(ifp) << 8; data/exactimage-1.0.2/codecs/dcraw.h:2572:15: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). bitbuf += fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:2579:20: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). bitbuf += (INT64) fgetc(ifp) << (bits+(j^8)); data/exactimage-1.0.2/codecs/dcraw.h:2686:26: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). fseek (ifp, (unsigned) fgetc(ifp)*4 - 1, SEEK_CUR); data/exactimage-1.0.2/codecs/dcraw.h:2817:9: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). opt = fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:2984:18: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). nseg = (uchar) fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:2989:11: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). holes = fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:3114:33: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). bitbuf = (bitbuf << 8) + fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:3145:33: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). bitbuf = (bitbuf << 8) + fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:3162:12: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). clen = getc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:3163:12: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). code = getc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:3868: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). cp = fname + strlen(fname); data/exactimage-1.0.2/codecs/dcraw.h:3913:7: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (fgetc(fp) != 'P' || fgetc(fp) != '5') error = 1; data/exactimage-1.0.2/codecs/dcraw.h:3913:27: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (fgetc(fp) != 'P' || fgetc(fp) != '5') error = 1; data/exactimage-1.0.2/codecs/dcraw.h:3914:35: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). while (!error && nd < 3 && (c = fgetc(fp)) != EOF) { data/exactimage-1.0.2/codecs/dcraw.h:5288:15: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). c = c << 8 | fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:5290:47: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (get4() == 257 && (i=len) && (c = (get4(),fgetc(ifp))) < 3) data/exactimage-1.0.2/codecs/dcraw.h:5319:19: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). while ((c = fgetc(ifp)) && c != EOF) data/exactimage-1.0.2/codecs/dcraw.h:5349:23: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). ver97 = ver97 * 10 + fgetc(ifp)-'0'; data/exactimage-1.0.2/codecs/dcraw.h:5379:20: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). cj = xlat[1][fgetc(ifp)^fgetc(ifp)^fgetc(ifp)^fgetc(ifp)]; data/exactimage-1.0.2/codecs/dcraw.h:5379:31: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). cj = xlat[1][fgetc(ifp)^fgetc(ifp)^fgetc(ifp)^fgetc(ifp)]; data/exactimage-1.0.2/codecs/dcraw.h:5379:42: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). cj = xlat[1][fgetc(ifp)^fgetc(ifp)^fgetc(ifp)^fgetc(ifp)]; data/exactimage-1.0.2/codecs/dcraw.h:5379:53: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). cj = xlat[1][fgetc(ifp)^fgetc(ifp)^fgetc(ifp)^fgetc(ifp)]; data/exactimage-1.0.2/codecs/dcraw.h:5483:32: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). for (i=19; i--; ) str[i] = fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:5524:18: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). exif_cfa |= fgetc(ifp) * 0x01010101 << c; data/exactimage-1.0.2/codecs/dcraw.h:5539:22: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). gpsdata[29+tag/2] = getc(ifp); break; data/exactimage-1.0.2/codecs/dcraw.h:5674:29: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (tag == 64013) wbi = fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:5734:19: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (type != 7 || fgetc(ifp) != 0xff || fgetc(ifp) != 0xd8) break; data/exactimage-1.0.2/codecs/dcraw.h:5734:41: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (type != 7 || fgetc(ifp) != 0xff || fgetc(ifp) != 0xd8) break; data/exactimage-1.0.2/codecs/dcraw.h:5895:35: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). FORC(36) ((char *)xtrans)[c] = fgetc(ifp) & 3; data/exactimage-1.0.2/codecs/dcraw.h:6038:43: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). FORC4 dng_version = (dng_version << 8) + fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:6375:7: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (fgetc(ifp) || fgetc(ifp)-'M' || fgetc(ifp)-'R') return; data/exactimage-1.0.2/codecs/dcraw.h:6375:21: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (fgetc(ifp) || fgetc(ifp)-'M' || fgetc(ifp)-'R') return; data/exactimage-1.0.2/codecs/dcraw.h:6375:39: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (fgetc(ifp) || fgetc(ifp)-'M' || fgetc(ifp)-'R') return; data/exactimage-1.0.2/codecs/dcraw.h:6376:11: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). order = fgetc(ifp) * 0x101; data/exactimage-1.0.2/codecs/dcraw.h:6380:24: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). tag = tag << 8 | fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:6420: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). if (!ext || strlen(ext) != 4 || ext-file != 8) return; data/exactimage-1.0.2/codecs/dcraw.h:6421:28: [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). jname = (char *) malloc (strlen(ifname) + 1); data/exactimage-1.0.2/codecs/dcraw.h:6503: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). fseek (ifp, strlen(make) - 63, SEEK_CUR); data/exactimage-1.0.2/codecs/dcraw.h:6599: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). val = line + strlen(line); data/exactimage-1.0.2/codecs/dcraw.h:6744:21: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). fuji_layout = fgetc(ifp) >> 7; data/exactimage-1.0.2/codecs/dcraw.h:6745:22: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). fuji_width = !(fgetc(ifp) & 8); data/exactimage-1.0.2/codecs/dcraw.h:6748:38: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). FORC(36) xtrans_abs[0][35-c] = fgetc(ifp) & 3; data/exactimage-1.0.2/codecs/dcraw.h:6770:7: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (fgetc(ifp) != 0xff || fgetc(ifp) != 0xd8) return 0; data/exactimage-1.0.2/codecs/dcraw.h:6770:29: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (fgetc(ifp) != 0xff || fgetc(ifp) != 0xd8) return 0; data/exactimage-1.0.2/codecs/dcraw.h:6772:10: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). while (fgetc(ifp) == 0xff && (mark = fgetc(ifp)) != 0xda) { data/exactimage-1.0.2/codecs/dcraw.h:6772:40: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). while (fgetc(ifp) == 0xff && (mark = fgetc(ifp)) != 0xda) { data/exactimage-1.0.2/codecs/dcraw.h:6777:7: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:6924:9: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). ver = fgetc(ifp); data/exactimage-1.0.2/codecs/dcraw.h:7064:6: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (fgetc(ifp) == 0xff && fgetc(ifp) == 0xd8 data/exactimage-1.0.2/codecs/dcraw.h:7064:28: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (fgetc(ifp) == 0xff && fgetc(ifp) == 0xd8 data/exactimage-1.0.2/codecs/dcraw.h:8274: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). if (!strncmp (name, table[i].prefix, strlen(table[i].prefix))) { data/exactimage-1.0.2/codecs/dcraw.h:8338:26: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). bitbuf |= (unsigned) (fgetc(ifp) << i); data/exactimage-1.0.2/codecs/dcraw.h:8685:9: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (fgetc(ifp) != 0xff) data/exactimage-1.0.2/codecs/dcraw.h:8863: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). cp = make + strlen(make); /* Remove trailing spaces */ data/exactimage-1.0.2/codecs/dcraw.h:8865: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). cp = model + strlen(model); data/exactimage-1.0.2/codecs/dcraw.h:8867:7: [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). i = strlen(make); /* Remove make from model */ data/exactimage-1.0.2/codecs/dcraw.h:8940:30: [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 (model[4] == 'K' && strlen(model) == 8) data/exactimage-1.0.2/codecs/dcraw.h:9770: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). oprof[pbody[5]/4+2] = strlen(name[output_color-1]) + 1; data/exactimage-1.0.2/codecs/dcraw.h:9958:3: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (th->desc, desc, 512); data/exactimage-1.0.2/codecs/dcraw.h:9959:3: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (th->make, make, 64); data/exactimage-1.0.2/codecs/dcraw.h:9960:3: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (th->model, model, 64); data/exactimage-1.0.2/codecs/dcraw.h:9965:3: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy (th->artist, artist, 64); data/exactimage-1.0.2/codecs/dcraw.h:10476: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). ofname = (char *) malloc (strlen(ifname) + 64); data/exactimage-1.0.2/codecs/dcraw.h:10484: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). sprintf (ofname+strlen(ofname), "_%0*d", data/exactimage-1.0.2/codecs/gif.cc:41:11: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)mem, len); data/exactimage-1.0.2/codecs/gif.cc:57:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read (buf, sizeof (buf)); data/exactimage-1.0.2/codecs/jpeg.cc:125:16: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). src->stream->read ((char*)src->buffer, INPUT_BUF_SIZE); data/exactimage-1.0.2/codecs/jpeg.cc:296:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read(buf, sizeof(buf)); data/exactimage-1.0.2/codecs/jpeg.cc:336:10: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&buffer[0], 2); data/exactimage-1.0.2/codecs/jpeg.cc:371:14: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&(buffer[2]), 2); data/exactimage-1.0.2/codecs/jpeg.cc:375:14: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)&(buffer[4]), len - 2); data/exactimage-1.0.2/codecs/jpeg2000.cc:73:11: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read (buf, cnt); data/exactimage-1.0.2/codecs/jpeg2000.cc:131:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read (buf, sizeof (buf)); data/exactimage-1.0.2/codecs/openexr.cc:50:16: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). virtual bool read (char c[], int n) data/exactimage-1.0.2/codecs/openexr.cc:53:14: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _stream->read (c, n); data/exactimage-1.0.2/codecs/openexr.cc:133:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read (buf, sizeof (buf)); data/exactimage-1.0.2/codecs/pcx.cc:90:16: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (!stream->read((char*)&header, sizeof(header))) data/exactimage-1.0.2/codecs/pcx.cc:230:12: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)entry, sizeof(entry)); data/exactimage-1.0.2/codecs/png.cc:31:11: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read ((char*)data, length); data/exactimage-1.0.2/codecs/png.cc:52:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read (buf, sizeof (buf)); data/exactimage-1.0.2/codecs/pnm.cc:158:12: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read ((char*)dest, stride); data/exactimage-1.0.2/codecs/raw.cc:43:15: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)image.getRawData() + image.stride() * y, data/exactimage-1.0.2/codecs/tga.cc:93:16: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (!stream->read((char*)&header, sizeof(header))) { data/exactimage-1.0.2/codecs/tga.cc:169:15: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)data + y * stride, stride); data/exactimage-1.0.2/codecs/tga.cc:187:12: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)data + i, bytes); data/exactimage-1.0.2/codecs/tga.cc:195:12: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). stream->read((char*)data + i, n * bytes); data/exactimage-1.0.2/codecs/tiff.cc:53:15: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). data->IS->read((char*)buf, (int)size); data/exactimage-1.0.2/codecs/tiff.cc:70:6: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). is->read((char*)buf, (int)size); data/exactimage-1.0.2/edisplay/edisplay.cc:698:7: [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. usleep (10000); data/exactimage-1.0.2/frontends/econvert.cc:645:14: [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 strl = strlen(color); data/exactimage-1.0.2/image/ContourUtility.cc:338:9: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). c=fgetc(f); data/exactimage-1.0.2/image/ContourUtility.cc:353:3: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). fgetc(f); // read linebreak; data/exactimage-1.0.2/image/hocr.cc:312: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). std::string::size_type i2 = s.find("\"", i + strlen(tS)); data/exactimage-1.0.2/image/hocr.cc:316: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). std::stringstream stream(s.substr(i + strlen(tS), i2 - i - strlen(tS))); data/exactimage-1.0.2/image/hocr.cc:316:62: [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). std::stringstream stream(s.substr(i + strlen(tS), i2 - i - strlen(tS))); data/exactimage-1.0.2/image/vectorial.cc:310:49: [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). std::vector<uint32_t> utf8 = DecodeUtf8(text, strlen(text)); data/exactimage-1.0.2/image/vectorial.cc:459:49: [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). std::vector<uint32_t> utf8 = DecodeUtf8(text, strlen(text)); data/exactimage-1.0.2/utility/Threads.cc:131:5: [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. usleep (delay); data/exactimage-1.0.2/utility/Threads.cc:146:5: [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. usleep (delay); ANALYSIS SUMMARY: Hits = 377 Lines analyzed = 35583 in approximately 1.11 seconds (32131 lines/second) Physical Source Lines of Code (SLOC) = 27456 Hits@level = [0] 194 [1] 148 [2] 190 [3] 0 [4] 39 [5] 0 Hits@level+ = [0+] 571 [1+] 377 [2+] 229 [3+] 39 [4+] 39 [5+] 0 Hits/KSLOC@level+ = [0+] 20.7969 [1+] 13.7311 [2+] 8.34062 [3+] 1.42045 [4+] 1.42045 [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.