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/node-srs-1.2.0+~2.5.0/gdal/src/async/async_open.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/async/async_open.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/async/async_rasterio.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/async/async_rasterio.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/dataset_bands.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/dataset_bands.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/dataset_layers.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/dataset_layers.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/feature_defn_fields.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/feature_defn_fields.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/feature_fields.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/feature_fields.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/gdal_drivers.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/gdal_drivers.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/geometry_collection_children.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/geometry_collection_children.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/layer_features.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/layer_features.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/layer_fields.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/layer_fields.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/linestring_points.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/linestring_points.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/polygon_rings.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/polygon_rings.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/rasterband_overviews.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/rasterband_overviews.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/rasterband_pixels.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/collections/rasterband_pixels.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_algorithms.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_algorithms.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_common.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_common.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_coordinate_transformation.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_coordinate_transformation.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_dataset.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_driver.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_driver.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_feature.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_feature.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_feature_defn.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_feature_defn.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_field_defn.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_field_defn.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_geometry.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_geometrycollection.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_geometrycollection.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_layer.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_linearring.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_linearring.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_linestring.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_linestring.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_majorobject.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_majorobject.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_multilinestring.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_multilinestring.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_multipoint.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_multipoint.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_multipolygon.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_multipolygon.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_point.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_point.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_polygon.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_polygon.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_rasterband.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_spatial_reference.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_spatial_reference.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_warper.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_warper.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/nan-wrapper.h
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/node_gdal.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/utils/field_types.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/utils/number_list.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/utils/number_list.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/utils/obj_cache.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/utils/ptr_manager.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/utils/ptr_manager.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/utils/string_list.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/utils/string_list.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/utils/typed_array.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/utils/typed_array.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/utils/warp_options.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/utils/warp_options.hpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_dataset.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_geometry.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_layer.cpp
Examining data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_rasterband.cpp

FINAL RESULTS:

data/node-srs-1.2.0+~2.5.0/gdal/src/gdal.hpp:52:85:  [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.
  OGRDataSource *ogr_ds = OGRSFDriverRegistrar::Open(path.c_str(), static_cast<int>(access));
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal.hpp:58:64:  [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.
  GDALDataset *gdal_ds = (GDALDataset *)GDALOpen(path.c_str(), access);
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_common.hpp:22: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(node_gdal::log_file, fmt "\n", __VA_ARGS__);                                                               \
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_driver.cpp:580:66:  [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.
    OGRDataSource *ds = raw->Open(path.c_str(), static_cast<int>(access));
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_driver.cpp:588:60:  [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.
  GDALOpenInfo *open_info = new GDALOpenInfo(path.c_str(), access);
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_driver.cpp:592:53:  [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.
  std::function<GDALDataset *()> doit = [raw, path, access]() {
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_driver.cpp:594:63:  [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.
    GDALDataset *ds = (GDALDataset *)GDALOpenEx(path.c_str(), access, driver_list, NULL, NULL);
data/node-srs-1.2.0+~2.5.0/gdal/src/collections/feature_fields.cpp:579: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(reallocated_data, data, count_of_bytes);
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal.hpp:96:19:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
static NAN_METHOD(open) {
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_dataset.cpp:571:19:  [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.
    gcp->pszId = (char *)pszId_list[i].c_str();
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_dataset.cpp:572: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.
    gcp->pszInfo = (char *)pszInfo_list[i].c_str();
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_driver.cpp:24:42:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
  Nan::SetPrototypeMethod(lcons, "open", open);
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_driver.cpp:593: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.
    const char *driver_list[2] = {raw->GetDescription(), nullptr};
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_driver.cpp:624:20:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
NAN_METHOD(Driver::open) {
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_driver.hpp:35:21:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
  static NAN_METHOD(open);
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_rasterband.cpp:939: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.
    list = new char *[names->Length() + 1];
data/node-srs-1.2.0+~2.5.0/gdal/src/gdal_rasterband.cpp:944: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.
      list[i] = (char *)strlist[i].c_str();
data/node-srs-1.2.0+~2.5.0/gdal/src/node_gdal.cpp:154: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).
  log_file = fopen(filename.c_str(), "w");
data/node-srs-1.2.0+~2.5.0/gdal/src/node_gdal.cpp:233:34:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
  Nan::SetMethod(target, "open", open);
data/node-srs-1.2.0+~2.5.0/gdal/src/utils/string_list.cpp:22: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.
    list = new char *[array->Length() + 1];
data/node-srs-1.2.0+~2.5.0/gdal/src/utils/string_list.cpp:26: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.
      list[i] = (char *)strlist[i].c_str();
data/node-srs-1.2.0+~2.5.0/gdal/src/utils/string_list.cpp:34: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.
    list = new char *[keys->Length() + 1];
data/node-srs-1.2.0+~2.5.0/gdal/src/utils/string_list.cpp:40: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.
      list[i] = (char *)strlist[i].c_str();
data/node-srs-1.2.0+~2.5.0/gdal/src/collections/rasterband_pixels.cpp:23:42:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
  Nan::SetPrototypeMethod(lcons, "read", read);
data/node-srs-1.2.0+~2.5.0/gdal/src/collections/rasterband_pixels.cpp:287:30:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
NAN_METHOD(RasterBandPixels::read) {
data/node-srs-1.2.0+~2.5.0/gdal/src/collections/rasterband_pixels.hpp:32:21:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
  static NAN_METHOD(read);

ANALYSIS SUMMARY:

Hits = 26
Lines analyzed = 17682 in approximately 0.43 seconds (40712 lines/second)
Physical Source Lines of Code (SLOC) = 10960
Hits@level = [0]   0 [1]   3 [2]  16 [3]   0 [4]   7 [5]   0
Hits@level+ = [0+]  26 [1+]  26 [2+]  23 [3+]   7 [4+]   7 [5+]   0
Hits/KSLOC@level+ = [0+] 2.37226 [1+] 2.37226 [2+] 2.09854 [3+] 0.638686 [4+] 0.638686 [5+]   0
Dot directories skipped = 2 (--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.