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/opensm-3.3.23/complib/cl_complib.c
Examining data/opensm-3.3.23/complib/cl_dispatcher.c
Examining data/opensm-3.3.23/complib/cl_event.c
Examining data/opensm-3.3.23/complib/cl_event_wheel.c
Examining data/opensm-3.3.23/complib/cl_heap.c
Examining data/opensm-3.3.23/complib/cl_list.c
Examining data/opensm-3.3.23/complib/cl_log.c
Examining data/opensm-3.3.23/complib/cl_map.c
Examining data/opensm-3.3.23/complib/cl_nodenamemap.c
Examining data/opensm-3.3.23/complib/cl_pool.c
Examining data/opensm-3.3.23/complib/cl_ptr_vector.c
Examining data/opensm-3.3.23/complib/cl_spinlock.c
Examining data/opensm-3.3.23/complib/cl_statustext.c
Examining data/opensm-3.3.23/complib/cl_thread.c
Examining data/opensm-3.3.23/complib/cl_threadpool.c
Examining data/opensm-3.3.23/complib/cl_timer.c
Examining data/opensm-3.3.23/complib/cl_vector.c
Examining data/opensm-3.3.23/complib/ib_statustext.c
Examining data/opensm-3.3.23/include/complib/cl_atomic.h
Examining data/opensm-3.3.23/include/complib/cl_atomic_osd.h
Examining data/opensm-3.3.23/include/complib/cl_byteswap.h
Examining data/opensm-3.3.23/include/complib/cl_byteswap_osd.h
Examining data/opensm-3.3.23/include/complib/cl_comppool.h
Examining data/opensm-3.3.23/include/complib/cl_debug.h
Examining data/opensm-3.3.23/include/complib/cl_debug_osd.h
Examining data/opensm-3.3.23/include/complib/cl_dispatcher.h
Examining data/opensm-3.3.23/include/complib/cl_event.h
Examining data/opensm-3.3.23/include/complib/cl_event_osd.h
Examining data/opensm-3.3.23/include/complib/cl_event_wheel.h
Examining data/opensm-3.3.23/include/complib/cl_fleximap.h
Examining data/opensm-3.3.23/include/complib/cl_heap.h
Examining data/opensm-3.3.23/include/complib/cl_list.h
Examining data/opensm-3.3.23/include/complib/cl_log.h
Examining data/opensm-3.3.23/include/complib/cl_map.h
Examining data/opensm-3.3.23/include/complib/cl_math.h
Examining data/opensm-3.3.23/include/complib/cl_nodenamemap.h
Examining data/opensm-3.3.23/include/complib/cl_packoff.h
Examining data/opensm-3.3.23/include/complib/cl_packon.h
Examining data/opensm-3.3.23/include/complib/cl_passivelock.h
Examining data/opensm-3.3.23/include/complib/cl_pool.h
Examining data/opensm-3.3.23/include/complib/cl_ptr_vector.h
Examining data/opensm-3.3.23/include/complib/cl_qcomppool.h
Examining data/opensm-3.3.23/include/complib/cl_qlist.h
Examining data/opensm-3.3.23/include/complib/cl_qmap.h
Examining data/opensm-3.3.23/include/complib/cl_qpool.h
Examining data/opensm-3.3.23/include/complib/cl_spinlock.h
Examining data/opensm-3.3.23/include/complib/cl_spinlock_osd.h
Examining data/opensm-3.3.23/include/complib/cl_thread.h
Examining data/opensm-3.3.23/include/complib/cl_thread_osd.h
Examining data/opensm-3.3.23/include/complib/cl_threadpool.h
Examining data/opensm-3.3.23/include/complib/cl_timer.h
Examining data/opensm-3.3.23/include/complib/cl_timer_osd.h
Examining data/opensm-3.3.23/include/complib/cl_types.h
Examining data/opensm-3.3.23/include/complib/cl_types_osd.h
Examining data/opensm-3.3.23/include/complib/cl_vector.h
Examining data/opensm-3.3.23/include/iba/ib_cm_types.h
Examining data/opensm-3.3.23/include/iba/ib_types.h
Examining data/opensm-3.3.23/include/opensm/osm_base.h
Examining data/opensm-3.3.23/include/opensm/osm_congestion_control.h
Examining data/opensm-3.3.23/include/opensm/osm_console.h
Examining data/opensm-3.3.23/include/opensm/osm_console_io.h
Examining data/opensm-3.3.23/include/opensm/osm_db.h
Examining data/opensm-3.3.23/include/opensm/osm_db_pack.h
Examining data/opensm-3.3.23/include/opensm/osm_errors.h
Examining data/opensm-3.3.23/include/opensm/osm_event_plugin.h
Examining data/opensm-3.3.23/include/opensm/osm_file_ids.h
Examining data/opensm-3.3.23/include/opensm/osm_guid.h
Examining data/opensm-3.3.23/include/opensm/osm_helper.h
Examining data/opensm-3.3.23/include/opensm/osm_inform.h
Examining data/opensm-3.3.23/include/opensm/osm_lid_mgr.h
Examining data/opensm-3.3.23/include/opensm/osm_log.h
Examining data/opensm-3.3.23/include/opensm/osm_mad_pool.h
Examining data/opensm-3.3.23/include/opensm/osm_madw.h
Examining data/opensm-3.3.23/include/opensm/osm_mcast_mgr.h
Examining data/opensm-3.3.23/include/opensm/osm_mcast_tbl.h
Examining data/opensm-3.3.23/include/opensm/osm_mcm_port.h
Examining data/opensm-3.3.23/include/opensm/osm_mesh.h
Examining data/opensm-3.3.23/include/opensm/osm_msgdef.h
Examining data/opensm-3.3.23/include/opensm/osm_mtree.h
Examining data/opensm-3.3.23/include/opensm/osm_multicast.h
Examining data/opensm-3.3.23/include/opensm/osm_node.h
Examining data/opensm-3.3.23/include/opensm/osm_opensm.h
Examining data/opensm-3.3.23/include/opensm/osm_partition.h
Examining data/opensm-3.3.23/include/opensm/osm_path.h
Examining data/opensm-3.3.23/include/opensm/osm_perfmgr.h
Examining data/opensm-3.3.23/include/opensm/osm_perfmgr_db.h
Examining data/opensm-3.3.23/include/opensm/osm_pkey.h
Examining data/opensm-3.3.23/include/opensm/osm_port.h
Examining data/opensm-3.3.23/include/opensm/osm_port_profile.h
Examining data/opensm-3.3.23/include/opensm/osm_prefix_route.h
Examining data/opensm-3.3.23/include/opensm/osm_qos_policy.h
Examining data/opensm-3.3.23/include/opensm/osm_remote_sm.h
Examining data/opensm-3.3.23/include/opensm/osm_router.h
Examining data/opensm-3.3.23/include/opensm/osm_sa.h
Examining data/opensm-3.3.23/include/opensm/osm_sa_mad_ctrl.h
Examining data/opensm-3.3.23/include/opensm/osm_service.h
Examining data/opensm-3.3.23/include/opensm/osm_sm.h
Examining data/opensm-3.3.23/include/opensm/osm_sm_mad_ctrl.h
Examining data/opensm-3.3.23/include/opensm/osm_stats.h
Examining data/opensm-3.3.23/include/opensm/osm_subnet.h
Examining data/opensm-3.3.23/include/opensm/osm_switch.h
Examining data/opensm-3.3.23/include/opensm/osm_ucast_cache.h
Examining data/opensm-3.3.23/include/opensm/osm_ucast_lash.h
Examining data/opensm-3.3.23/include/opensm/osm_ucast_mgr.h
Examining data/opensm-3.3.23/include/opensm/osm_vl15intf.h
Examining data/opensm-3.3.23/include/opensm/st.h
Examining data/opensm-3.3.23/include/vendor/osm_mtl_bind.h
Examining data/opensm-3.3.23/include/vendor/osm_pkt_randomizer.h
Examining data/opensm-3.3.23/include/vendor/osm_ts_useraccess.h
Examining data/opensm-3.3.23/include/vendor/osm_umadt.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_al.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_api.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_ibumad.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mlx.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mlx_defs.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mlx_dispatcher.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mlx_hca.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mlx_inout.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mlx_rmpp_ctx.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mlx_sar.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mlx_sender.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mlx_svc.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mlx_transport.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mlx_transport_anafa.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mlx_txn.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mtl.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mtl_hca_guid.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_mtl_transaction_mgr.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_sa_api.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_test.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_ts.h
Examining data/opensm-3.3.23/include/vendor/osm_vendor_umadt.h
Examining data/opensm-3.3.23/libopensm/osm_helper.c
Examining data/opensm-3.3.23/libopensm/osm_log.c
Examining data/opensm-3.3.23/libvendor/osm_mad_pool.c
Examining data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_al.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_ibumad.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_ibumad_sa.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_anafa.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_dispatcher.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_anafa.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_ibmgt.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_rmpp_ctx.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_sa.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_sar.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_sender.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_sim.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_ts.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_ts_anafa.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mlx_txn.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mtl.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mtl_hca_guid.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_mtl_transaction_mgr.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_test.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_ts.c
Examining data/opensm-3.3.23/libvendor/osm_vendor_umadt.c
Examining data/opensm-3.3.23/opensm/main.c
Examining data/opensm-3.3.23/opensm/osm_congestion_control.c
Examining data/opensm-3.3.23/opensm/osm_console.c
Examining data/opensm-3.3.23/opensm/osm_console_io.c
Examining data/opensm-3.3.23/opensm/osm_db_files.c
Examining data/opensm-3.3.23/opensm/osm_db_pack.c
Examining data/opensm-3.3.23/opensm/osm_drop_mgr.c
Examining data/opensm-3.3.23/opensm/osm_dump.c
Examining data/opensm-3.3.23/opensm/osm_event_plugin.c
Examining data/opensm-3.3.23/opensm/osm_guid_info_rcv.c
Examining data/opensm-3.3.23/opensm/osm_guid_mgr.c
Examining data/opensm-3.3.23/opensm/osm_inform.c
Examining data/opensm-3.3.23/opensm/osm_lid_mgr.c
Examining data/opensm-3.3.23/opensm/osm_lin_fwd_rcv.c
Examining data/opensm-3.3.23/opensm/osm_link_mgr.c
Examining data/opensm-3.3.23/opensm/osm_mcast_fwd_rcv.c
Examining data/opensm-3.3.23/opensm/osm_mcast_mgr.c
Examining data/opensm-3.3.23/opensm/osm_mcast_tbl.c
Examining data/opensm-3.3.23/opensm/osm_mcm_port.c
Examining data/opensm-3.3.23/opensm/osm_mesh.c
Examining data/opensm-3.3.23/opensm/osm_mlnx_ext_port_info_rcv.c
Examining data/opensm-3.3.23/opensm/osm_mtree.c
Examining data/opensm-3.3.23/opensm/osm_multicast.c
Examining data/opensm-3.3.23/opensm/osm_node.c
Examining data/opensm-3.3.23/opensm/osm_node_desc_rcv.c
Examining data/opensm-3.3.23/opensm/osm_node_info_rcv.c
Examining data/opensm-3.3.23/opensm/osm_opensm.c
Examining data/opensm-3.3.23/opensm/osm_perfmgr.c
Examining data/opensm-3.3.23/opensm/osm_perfmgr_db.c
Examining data/opensm-3.3.23/opensm/osm_pkey.c
Examining data/opensm-3.3.23/opensm/osm_pkey_mgr.c
Examining data/opensm-3.3.23/opensm/osm_pkey_rcv.c
Examining data/opensm-3.3.23/opensm/osm_port.c
Examining data/opensm-3.3.23/opensm/osm_port_info_rcv.c
Examining data/opensm-3.3.23/opensm/osm_prtn.c
Examining data/opensm-3.3.23/opensm/osm_prtn_config.c
Examining data/opensm-3.3.23/opensm/osm_qos.c
Examining data/opensm-3.3.23/opensm/osm_qos_policy.c
Examining data/opensm-3.3.23/opensm/osm_remote_sm.c
Examining data/opensm-3.3.23/opensm/osm_req.c
Examining data/opensm-3.3.23/opensm/osm_resp.c
Examining data/opensm-3.3.23/opensm/osm_router.c
Examining data/opensm-3.3.23/opensm/osm_sa.c
Examining data/opensm-3.3.23/opensm/osm_sa_class_port_info.c
Examining data/opensm-3.3.23/opensm/osm_sa_guidinfo_record.c
Examining data/opensm-3.3.23/opensm/osm_sa_informinfo.c
Examining data/opensm-3.3.23/opensm/osm_sa_lft_record.c
Examining data/opensm-3.3.23/opensm/osm_sa_link_record.c
Examining data/opensm-3.3.23/opensm/osm_sa_mad_ctrl.c
Examining data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c
Examining data/opensm-3.3.23/opensm/osm_sa_mft_record.c
Examining data/opensm-3.3.23/opensm/osm_sa_multipath_record.c
Examining data/opensm-3.3.23/opensm/osm_sa_node_record.c
Examining data/opensm-3.3.23/opensm/osm_sa_path_record.c
Examining data/opensm-3.3.23/opensm/osm_sa_pkey_record.c
Examining data/opensm-3.3.23/opensm/osm_sa_portinfo_record.c
Examining data/opensm-3.3.23/opensm/osm_sa_service_record.c
Examining data/opensm-3.3.23/opensm/osm_sa_slvl_record.c
Examining data/opensm-3.3.23/opensm/osm_sa_sminfo_record.c
Examining data/opensm-3.3.23/opensm/osm_sa_sw_info_record.c
Examining data/opensm-3.3.23/opensm/osm_sa_vlarb_record.c
Examining data/opensm-3.3.23/opensm/osm_service.c
Examining data/opensm-3.3.23/opensm/osm_slvl_map_rcv.c
Examining data/opensm-3.3.23/opensm/osm_sm.c
Examining data/opensm-3.3.23/opensm/osm_sm_mad_ctrl.c
Examining data/opensm-3.3.23/opensm/osm_sm_state_mgr.c
Examining data/opensm-3.3.23/opensm/osm_sminfo_rcv.c
Examining data/opensm-3.3.23/opensm/osm_state_mgr.c
Examining data/opensm-3.3.23/opensm/osm_subnet.c
Examining data/opensm-3.3.23/opensm/osm_sw_info_rcv.c
Examining data/opensm-3.3.23/opensm/osm_switch.c
Examining data/opensm-3.3.23/opensm/osm_torus.c
Examining data/opensm-3.3.23/opensm/osm_trap_rcv.c
Examining data/opensm-3.3.23/opensm/osm_ucast_cache.c
Examining data/opensm-3.3.23/opensm/osm_ucast_dfsssp.c
Examining data/opensm-3.3.23/opensm/osm_ucast_dnup.c
Examining data/opensm-3.3.23/opensm/osm_ucast_file.c
Examining data/opensm-3.3.23/opensm/osm_ucast_ftree.c
Examining data/opensm-3.3.23/opensm/osm_ucast_lash.c
Examining data/opensm-3.3.23/opensm/osm_ucast_mgr.c
Examining data/opensm-3.3.23/opensm/osm_ucast_nue.c
Examining data/opensm-3.3.23/opensm/osm_ucast_updn.c
Examining data/opensm-3.3.23/opensm/osm_vl15intf.c
Examining data/opensm-3.3.23/opensm/osm_vl_arb_rcv.c
Examining data/opensm-3.3.23/opensm/st.c
Examining data/opensm-3.3.23/osmeventplugin/src/osmeventplugin.c
Examining data/opensm-3.3.23/osmroutingplugin/src/osmroutingplugin.c
Examining data/opensm-3.3.23/osmtest/include/osmt_inform.h
Examining data/opensm-3.3.23/osmtest/include/osmt_mtl_regular_qp.h
Examining data/opensm-3.3.23/osmtest/include/osmtest.h
Examining data/opensm-3.3.23/osmtest/include/osmtest_base.h
Examining data/opensm-3.3.23/osmtest/include/osmtest_subnet.h
Examining data/opensm-3.3.23/osmtest/main.c
Examining data/opensm-3.3.23/osmtest/osmt_inform.c
Examining data/opensm-3.3.23/osmtest/osmt_mtl_regular_qp.c
Examining data/opensm-3.3.23/osmtest/osmt_multicast.c
Examining data/opensm-3.3.23/osmtest/osmt_service.c
Examining data/opensm-3.3.23/osmtest/osmt_slvl_vl_arb.c
Examining data/opensm-3.3.23/osmtest/osmtest.c

FINAL RESULTS:

data/opensm-3.3.23/opensm/osm_sa.c:568:6:  [5] (race) chmod:
  This accepts filename arguments; if an attacker can move those files, a
  race condition results. (CWE-362). Use fchmod( ) instead.
	if (chmod(path_tmp, S_IRUSR | S_IWUSR)) {
data/opensm-3.3.23/include/complib/cl_debug_osd.h:72:20:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
#define cl_msg_out	printf
data/opensm-3.3.23/include/complib/cl_debug_osd.h:74:20:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
#define cl_dbg_out	printf
data/opensm-3.3.23/include/opensm/osm_log.h:55:53:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
#define STRICT_OSM_LOG_FORMAT __attribute__((format(printf, 3, 4)))
data/opensm-3.3.23/include/opensm/osm_log.h:56:56:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
#define STRICT_OSM_LOG_V2_FORMAT __attribute__((format(printf, 4, 5)))
data/opensm-3.3.23/libopensm/osm_helper.c:582:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(line, "%s%s", p_prefix_str, p_new_str);
data/opensm-3.3.23/libopensm/osm_helper.c:588: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(*pp_local, line);
data/opensm-3.3.23/libopensm/osm_helper.c:854:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:1049:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:1310:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:1371:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:1439:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:1509:10:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
				n += sprintf(buf_line + n,
data/opensm-3.3.23/libopensm/osm_helper.c:1520:10:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
				n += sprintf(buf_line + n,
data/opensm-3.3.23/libopensm/osm_helper.c:1529:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:1592:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:1665:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:1774:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:1811:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:1882:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:1930:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:2179:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:2237:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:2296:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:2452:4:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
			sprintf(buff,
data/opensm-3.3.23/libopensm/osm_helper.c:2545:4:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
			sprintf(buff,
data/opensm-3.3.23/libopensm/osm_helper.c:2573:4:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
			sprintf(buff,
data/opensm-3.3.23/libopensm/osm_helper.c:2606:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(log_buf,
data/opensm-3.3.23/libopensm/osm_helper.c:2676:7:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		n = sprintf(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:2807:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf,
data/opensm-3.3.23/libopensm/osm_log.c:136:3:  [4] (format) vsprintf:
  Potential format string problem (CWE-134). Make format string constant.
		vsprintf(buffer, p_str, args);
data/opensm-3.3.23/libopensm/osm_log.c:139:3:  [4] (format) vsprintf:
  Potential format string problem (CWE-134). Make format string constant.
		vsprintf(buffer + n, p_str, args);
data/opensm-3.3.23/libopensm/osm_log.c:250:3:  [4] (format) vsprintf:
  Potential format string problem (CWE-134). Make format string constant.
		vsprintf(buffer, p_str, args);
data/opensm-3.3.23/libopensm/osm_log.c:253:3:  [4] (format) vsprintf:
  Potential format string problem (CWE-134). Make format string constant.
		vsprintf(buffer + n, p_str, args);
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:164:3:  [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(buf, line);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:179:6:  [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(p_ch, "name: %s", pfs_ca_info->name) != 1) {
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:311:6:  [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(p_ch, "state: %s", state) != 1) {
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:724: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(p_hca_id,
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:94:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(dirName, "%s/%s", ibmgtSimDir, ibmgtSimNode);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:189:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(file_name, "%s/ca%d/info", __get_simulator_dir(), idx);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:222:6:  [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(p_ch, "name: %s", sim_ca_info->name) != 1) {
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:322:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(file_name, "%s/ca%d/port%d/info", __get_simulator_dir(),
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:354:6:  [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(p_ch, "state: %s", state) != 1) {
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:473:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(file_name, "%s/ca%d/port%d/gid_table",
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:767: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(p_hca_id,
data/opensm-3.3.23/opensm/osm_db_files.c:345: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(p_key, p_first_word);
data/opensm-3.3.23/opensm/osm_db_files.c:351: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(p_accum_val, p_rest_of_line);
data/opensm-3.3.23/opensm/osm_db_files.c:417: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(p_accum_val, p_prev_val);
data/opensm-3.3.23/opensm/osm_db_files.c:420:5:  [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(p_accum_val, sLine);
data/opensm-3.3.23/opensm/osm_db_files.c:464: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(p_tmp_file_name, p_domain_imp->file_name);
data/opensm-3.3.23/opensm/osm_db_files.c:603: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(p_new_key, p_key);
data/opensm-3.3.23/opensm/osm_db_files.c:608: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(p_new_val, p_val);
data/opensm-3.3.23/opensm/osm_db_pack.c:48:2:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
	sprintf(p_guid_str, "0x%016" PRIx64, guid);
data/opensm-3.3.23/opensm/osm_db_pack.c:94:2:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
	sprintf(p_mkey_str, "0x%016" PRIx64, mkey);
data/opensm-3.3.23/opensm/osm_dump.c:325:4:  [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(file, " # portguid 0x%016" PRIx64,
data/opensm-3.3.23/opensm/osm_mesh.c:249:8:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		p += sprintf(p, "%s", sign? "-" : (first? "" : "+"));
data/opensm-3.3.23/opensm/osm_mesh.c:820:7:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	p += sprintf(p, "%s[%d] = ", name, port);
data/opensm-3.3.23/opensm/osm_mesh.c:822:8:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		p += sprintf(p, "%s%c -> ", ((c - 1) & 1) ? "-" : "+", 'X' + (c - 1)/2);
data/opensm-3.3.23/opensm/osm_mesh.c:825:7:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	p += sprintf(p, "%s\n",
data/opensm-3.3.23/opensm/osm_mesh.c:1679:7:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	p += sprintf(p, "%snode shape is ",
data/opensm-3.3.23/opensm/osm_mesh.c:1686:9:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
			p += sprintf(p, "%s%d%s", i? " x " : "", t->size[i],
data/opensm-3.3.23/opensm/osm_mesh.c:1718:9:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
			p += sprintf(p, "%s%d", i? " x " : "", mesh->size[i]);
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:896:3:  [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(fp, "     xmit_data            : %" PRIu64,
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:899:3:  [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(fp, "     rcv_data             : %" PRIu64,
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:902:3:  [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(fp, "     xmit_pkts            : %" PRIu64,
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:905:3:  [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(fp, "     rcv_pkts             : %" PRIu64,
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:908:3:  [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(fp, "     unicast_xmit_pkts    : %" PRIu64,
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:911:3:  [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(fp, "     unicast_rcv_pkts     : %" PRIu64,
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:914:3:  [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(fp, "     multicast_xmit_pkts  : %" PRIu64,
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:917:3:  [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(fp, "     multicast_rcv_pkts   : %" PRIu64,
data/opensm-3.3.23/opensm/osm_subnet.c:217:2:  [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.
	vsnprintf(buf, sizeof(buf), fmt, args);
data/opensm-3.3.23/opensm/osm_subnet.c:232:7:  [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.
	n += vsnprintf(buf + n, sizeof(buf) - n, fmt, args);
data/opensm-3.3.23/opensm/osm_subnet.c:2130: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(p_opts->part_enforce, OSM_PARTITION_ENFORCE_OFF);
data/opensm-3.3.23/opensm/osm_subnet.c:2145: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(p_opts->part_enforce, OSM_PARTITION_ENFORCE_BOTH);
data/opensm-3.3.23/osmtest/main.c:363: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(opt.file_name, optarg);
data/opensm-3.3.23/osmtest/main.c:376: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(flow_name, optarg);
data/opensm-3.3.23/osmtest/osmt_service.c:656: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(mad_stat_err,
data/opensm-3.3.23/osmtest/osmt_service.c:661: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(mad_stat_err, ib_get_err_str(status));
data/opensm-3.3.23/osmtest/osmt_service.c:916: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(mad_stat_err,
data/opensm-3.3.23/osmtest/osmt_service.c:921: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(mad_stat_err, ib_get_err_str(status));
data/opensm-3.3.23/osmtest/osmt_service.c:1245:3:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
		sprintf((char *)(service_name[i]),
data/opensm-3.3.23/osmtest/osmtest.c:267:3:  [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(&line[offset], ib_mad_status_str_busy);
data/opensm-3.3.23/osmtest/osmtest.c:272:4:  [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(&line[offset], generic_or_str);
data/opensm-3.3.23/osmtest/osmtest.c:276:3:  [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(&line[offset], ib_mad_status_str_redirect);
data/opensm-3.3.23/osmtest/osmtest.c:282:4:  [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(&line[offset], generic_or_str);
data/opensm-3.3.23/osmtest/osmtest.c:286:3:  [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(&line[offset], ib_mad_status_str_unsup_class_ver);
data/opensm-3.3.23/osmtest/osmtest.c:292:4:  [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(&line[offset], generic_or_str);
data/opensm-3.3.23/osmtest/osmtest.c:296:3:  [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(&line[offset], ib_mad_status_str_unsup_method);
data/opensm-3.3.23/osmtest/osmtest.c:302:4:  [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(&line[offset], generic_or_str);
data/opensm-3.3.23/osmtest/osmtest.c:306:3:  [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(&line[offset], ib_mad_status_str_unsup_method_attr);
data/opensm-3.3.23/osmtest/osmtest.c:312:4:  [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(&line[offset], generic_or_str);
data/opensm-3.3.23/osmtest/osmtest.c:316:3:  [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(&line[offset], ib_mad_status_str_invalid_field);
data/opensm-3.3.23/osmtest/osmtest.c:322:4:  [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(&line[offset], generic_or_str);
data/opensm-3.3.23/osmtest/osmtest.c:326:3:  [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(&line[offset], ib_mad_status_str_no_resources);
data/opensm-3.3.23/osmtest/osmtest.c:331:4:  [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(&line[offset], generic_or_str);
data/opensm-3.3.23/osmtest/osmtest.c:335:3:  [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(&line[offset], ib_mad_status_str_req_invalid);
data/opensm-3.3.23/osmtest/osmtest.c:340:4:  [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(&line[offset], generic_or_str);
data/opensm-3.3.23/osmtest/osmtest.c:344:3:  [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(&line[offset], ib_mad_status_str_no_records);
data/opensm-3.3.23/osmtest/osmtest.c:350:4:  [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(&line[offset], generic_or_str);
data/opensm-3.3.23/osmtest/osmtest.c:354:3:  [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(&line[offset], ib_mad_status_str_too_many_records);
data/opensm-3.3.23/osmtest/osmtest.c:359:4:  [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(&line[offset], generic_or_str);
data/opensm-3.3.23/osmtest/osmtest.c:363:3:  [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(&line[offset], ib_mad_status_str_invalid_gid);
data/opensm-3.3.23/osmtest/osmtest.c:368:4:  [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(&line[offset], generic_or_str);
data/opensm-3.3.23/osmtest/osmtest.c:372:3:  [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(&line[offset], ib_mad_status_str_insuf_comps);
data/opensm-3.3.23/include/vendor/osm_vendor_mlx_svc.h:190:2:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
	srand(1);		/* Pick a new base */
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:151:3:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
		srand(seed);
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:270:13:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	tmp = atol(getenv("OSM_PKT_DROP_RATE"));
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:273:6:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if (getenv("OSM_PKT_NUM_UNSTABLE_LINKS") != NULL
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:274:21:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	    && (tmp = atol(getenv("OSM_PKT_NUM_UNSTABLE_LINKS"))) > 0)
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:279:6:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if (getenv("OSM_PKT_UNSTABLE_LINK_RATE") != NULL
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:280:21:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	    && (tmp = atol(getenv("OSM_PKT_UNSTABLE_LINK_RATE"))) > 0)
data/opensm-3.3.23/libvendor/osm_vendor_ibumad.c:576:13:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if ((max = getenv("OSM_UMAD_MAX_PENDING")) != NULL) {
data/opensm-3.3.23/libvendor/osm_vendor_mlx.c:164:6:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if (getenv("OSM_PKT_DROP_RATE") != NULL
data/opensm-3.3.23/libvendor/osm_vendor_mlx.c:165:14:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	    && atol(getenv("OSM_PKT_DROP_RATE")) != 0) {
data/opensm-3.3.23/libvendor/osm_vendor_mlx_anafa.c:184:6:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if (getenv("OSM_PKT_DROP_RATE") != NULL
data/opensm-3.3.23/libvendor/osm_vendor_mlx_anafa.c:185:14:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	    && atol(getenv("OSM_PKT_DROP_RATE")) != 0) {
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:74:17:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
		ibmgtSimDir = getenv("IBMGTSIM_DIR");
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:85:18:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
		ibmgtSimNode = getenv("IBMGTSIM_NODE");
data/opensm-3.3.23/opensm/osm_db_files.c:161:26:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	p_db_imp->db_dir_name = getenv("OSM_CACHE_DIR");
data/opensm-3.3.23/opensm/osm_dump.c:730:4:  [3] (random) srandom:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
			srandom(osm->subn.opt.scatter_ports);
data/opensm-3.3.23/opensm/osm_subnet.c:1626:26:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	p_opt->dump_files_dir = getenv("OSM_TMP_DIR");
data/opensm-3.3.23/opensm/osm_switch.c:589:22:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
		unsigned int idx = random() % scatter_possible_ports_count;
data/opensm-3.3.23/opensm/osm_ucast_dfsssp.c:2758:2:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
	srand(time(NULL));
data/opensm-3.3.23/opensm/osm_ucast_mgr.c:1069:3:  [3] (random) srandom:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
		srandom(osm->subn.opt.scatter_ports);
data/opensm-3.3.23/osmtest/osmt_service.c:1241:23:  [3] (random) random:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
		uint64_t rand_val = random() - (uint64_t) i;
data/opensm-3.3.23/complib/cl_log.c:64: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 data[CL_LOG_DATA_SIZE];
data/opensm-3.3.23/complib/cl_log.c:93: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(p_buf, "%02x", *p_int_data++);
data/opensm-3.3.23/complib/cl_nodenamemap.c:79: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 linebuf[PARSE_NODE_MAP_BUFLEN + 1];
data/opensm-3.3.23/complib/cl_nodenamemap.c:176: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 line[PARSE_NODE_MAP_BUFLEN];
data/opensm-3.3.23/complib/cl_nodenamemap.c:179:12:  [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 (!(f = fopen(file_name, "r")))
data/opensm-3.3.23/complib/cl_nodenamemap.c:197: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(linebuf, line,
data/opensm-3.3.23/complib/cl_pool.c:118: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(p_pool->component_sizes, component_sizes,
data/opensm-3.3.23/complib/cl_ptr_vector.c:190: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(p_new_ptr_array, p_vector->p_ptr_array,
data/opensm-3.3.23/complib/cl_vector.c:77: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(p_dest, p_src, size);
data/opensm-3.3.23/complib/cl_vector.c:360: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(p_new_ptr_array, p_vector->p_ptr_array,
data/opensm-3.3.23/include/complib/cl_byteswap.h:496: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(p_dest, p_src, size);
data/opensm-3.3.23/include/complib/cl_thread.h:108: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 name[16];
data/opensm-3.3.23/include/iba/ib_types.h:7327: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(&sid_union.sid_arr[1], p_rec->service_id_56lsb, 7);
data/opensm-3.3.23/include/iba/ib_types.h:8986: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 id_string[CTRL_ID_STRING_LEN];
data/opensm-3.3.23/include/iba/ib_types.h:9073: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 name[MAX_SVC_ENTRY_NAME_LEN];
data/opensm-3.3.23/include/opensm/osm_base.h:277:37:  [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.
#define OSM_DEFAULT_TORUS_CONF_FILE strcat(GetOsmCachePath(), "osm-torus-2QoS.conf")
data/opensm-3.3.23/include/opensm/osm_base.h:313:47:  [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.
#define OSM_DEFAULT_PER_MOD_LOGGING_CONF_FILE strcat(GetOsmCachePath(), "per-module-logging.conf")
data/opensm-3.3.23/include/opensm/osm_console_io.h:78: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 client_type[32];
data/opensm-3.3.23/include/opensm/osm_console_io.h:79: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 client_ip[64];
data/opensm-3.3.23/include/opensm/osm_console_io.h:80: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 client_hn[128];
data/opensm-3.3.23/include/opensm/osm_event_plugin.h:89: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 node_name[OSM_EPI_NODE_NAME_LEN];
data/opensm-3.3.23/include/opensm/osm_partition.h:99: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 name[32];
data/opensm-3.3.23/include/opensm/osm_path.h:141: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(p_path->path, path, hop_count + 1);
data/opensm-3.3.23/include/opensm/osm_perfmgr_db.h:144: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 node_name[NODE_NAME_SIZE];
data/opensm-3.3.23/include/opensm/osm_sa.h:134: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[0];
data/opensm-3.3.23/include/opensm/osm_switch.h:721: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(&p_sw->lft[lid_start], p_block, IB_SMP_DATA_SIZE);
data/opensm-3.3.23/include/vendor/osm_vendor_ibumad.h:161: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 ca_names[OSM_UMAD_MAX_CAS][UMAD_CA_NAME_LEN];
data/opensm-3.3.23/include/vendor/osm_vendor_ibumad.h:169: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 issm_path[256];
data/opensm-3.3.23/include/vendor/osm_vendor_mlx_svc.h:178: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(p_copy, p_mad, MAD_BLOCK_SIZE);
data/opensm-3.3.23/include/vendor/osm_vendor_mlx_transport.h:71:10:  [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.
		    IN char hca_id[VENDOR_HCA_MAXNAMES],
data/opensm-3.3.23/libopensm/osm_helper.c:579: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 line[LINE_LENGTH];
data/opensm-3.3.23/libopensm/osm_helper.c:600: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(p_local, "Capability Mask:\n");
data/opensm-3.3.23/libopensm/osm_helper.c:804: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(p_local, "Capability Mask2:\n");
data/opensm-3.3.23/libopensm/osm_helper.c:938: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:966: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:996: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(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:1017: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1032: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1134: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1162: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1193: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(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:1220: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1236: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1253: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(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:1282: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1296: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1339: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1351: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1365: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[sizeof(p_nr->node_desc.description) + 1];
data/opensm-3.3.23/libopensm/osm_helper.c:1368: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(desc, p_nr->node_desc.description,
data/opensm-3.3.23/libopensm/osm_helper.c:1408: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1422: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1436: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/libopensm/osm_helper.c:1437: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 gid_str2[INET6_ADDRSTRLEN];
data/opensm-3.3.23/libopensm/osm_helper.c:1476: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1488: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1502: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/libopensm/osm_helper.c:1503: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_line[1024];
data/opensm-3.3.23/libopensm/osm_helper.c:1561: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1575: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1589: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/libopensm/osm_helper.c:1590: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 gid_str2[INET6_ADDRSTRLEN];
data/opensm-3.3.23/libopensm/osm_helper.c:1622: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1634: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1648: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/libopensm/osm_helper.c:1649: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_service_key[35];
data/opensm-3.3.23/libopensm/osm_helper.c:1650: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_service_name[65];
data/opensm-3.3.23/libopensm/osm_helper.c:1652: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(buf_service_key,
data/opensm-3.3.23/libopensm/osm_helper.c:1739: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1753: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1769: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/libopensm/osm_helper.c:1806: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/libopensm/osm_helper.c:1840: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1857: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1874: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/libopensm/osm_helper.c:1875: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 gid_str2[INET6_ADDRSTRLEN];
data/opensm-3.3.23/libopensm/osm_helper.c:1922: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/libopensm/osm_helper.c:1923: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 gid_str2[INET6_ADDRSTRLEN];
data/opensm-3.3.23/libopensm/osm_helper.c:1969: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:1986: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2003: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(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:2020: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2034: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2048: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(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:2077: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2091: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2105: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(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:2141: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2155: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2172: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_line[1024];
data/opensm-3.3.23/libopensm/osm_helper.c:2176:9:  [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.
			n += sprintf(buf_line + n, " 0x%04x |",
data/opensm-3.3.23/libopensm/osm_helper.c:2194: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2210: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2228: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_line1[1024], buf_line2[1024];
data/opensm-3.3.23/libopensm/osm_helper.c:2233:9:  [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.
			n += sprintf(buf_line1 + n, " %-2u |", i);
data/opensm-3.3.23/libopensm/osm_helper.c:2235:9:  [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.
			n += sprintf(buf_line2 + n, "0x%01X |",
data/opensm-3.3.23/libopensm/osm_helper.c:2253: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2269: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2287: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_line1[1024], buf_line2[1024];
data/opensm-3.3.23/libopensm/osm_helper.c:2291:9:  [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.
			n += sprintf(buf_line1 + n, " 0x%01X |",
data/opensm-3.3.23/libopensm/osm_helper.c:2294:9:  [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.
			n += sprintf(buf_line2 + n, " 0x%01X |",
data/opensm-3.3.23/libopensm/osm_helper.c:2311: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2327: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2342: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(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:2360: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2372: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2386: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(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:2411: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2425: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2439: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/libopensm/osm_helper.c:2440: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 gid_str2[INET6_ADDRSTRLEN];
data/opensm-3.3.23/libopensm/osm_helper.c:2441: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 buff[1024];
data/opensm-3.3.23/libopensm/osm_helper.c:2459:4:  [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(buff,
data/opensm-3.3.23/libopensm/osm_helper.c:2466:4:  [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(buff,
data/opensm-3.3.23/libopensm/osm_helper.c:2474:4:  [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(buff,
data/opensm-3.3.23/libopensm/osm_helper.c:2490:4:  [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(buff,
data/opensm-3.3.23/libopensm/osm_helper.c:2500:8:  [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.
			n = sprintf(buff,
data/opensm-3.3.23/libopensm/osm_helper.c:2625: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(buf,
data/opensm-3.3.23/libopensm/osm_helper.c:2641: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2657: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2776: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2788: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2803:4:  [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, "NULL MAD POINTER\n");
data/opensm-3.3.23/libopensm/osm_helper.c:2850: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2862: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2878:7:  [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.
		n = sprintf(buf, "Directed Path Dump of %u hop path: "
data/opensm-3.3.23/libopensm/osm_helper.c:2890: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2902: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2918:7:  [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.
		n = sprintf(buf, "Received SMP on a %u hop path: "
data/opensm-3.3.23/libopensm/osm_helper.c:2934: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_helper.c:2946: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[BUF_SIZE];
data/opensm-3.3.23/libopensm/osm_log.c:115: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 buffer[LOG_ENTRY_SIZE_MAX];
data/opensm-3.3.23/libopensm/osm_log.c:226: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 buffer[LOG_ENTRY_SIZE_MAX];
data/opensm-3.3.23/libopensm/osm_log.c:359: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 buf[MSG_BOX_LENGTH + 1];
data/opensm-3.3.23/libopensm/osm_log.c:387: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 buf[MSG_BOX_LENGTH + 1];
data/opensm-3.3.23/libopensm/osm_log.c:424:21:  [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).
		p_log->out_port = fopen(p_log->log_file_name, "a+");
data/opensm-3.3.23/libopensm/osm_log.c:426:21:  [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).
		p_log->out_port = fopen(p_log->log_file_name, "w+");
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:126: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 buf[BUF_SIZE];
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:127: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 line[BUF_SIZE];
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:160: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(buf, "Path: ");
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:163: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(line, "[%X]", p_dr_path->path[i]);
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:188: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(&
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:270:8:  [2] (integer) atol:
  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).
	tmp = atol(getenv("OSM_PKT_DROP_RATE"));
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:274:16:  [2] (integer) atol:
  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).
	    && (tmp = atol(getenv("OSM_PKT_NUM_UNSTABLE_LINKS"))) > 0)
data/opensm-3.3.23/libvendor/osm_pkt_randomizer.c:280:16:  [2] (integer) atol:
  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).
	    && (tmp = atol(getenv("OSM_PKT_UNSTABLE_LINK_RATE"))) > 0)
data/opensm-3.3.23/libvendor/osm_vendor_ibumad.c:302: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(&osm_mad_addr->addr_type.gsi.grh_info.dest_gid,
data/opensm-3.3.23/libvendor/osm_vendor_ibumad.c:1151: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(&mad_addr.gid, &p_mad_addr->addr_type.gsi.grh_info.dest_gid, 16);
data/opensm-3.3.23/libvendor/osm_vendor_ibumad.c:1249: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).
		p_vend->issmfd = open(p_vend->issm_path, O_NONBLOCK);
data/opensm-3.3.23/libvendor/osm_vendor_ibumad_sa.c:403: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(p_sa_mad->data, p_sa_mad_data->p_attr, sa_size);
data/opensm-3.3.23/libvendor/osm_vendor_ibumad_sa.c:428: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(&p_madw->mad_addr.addr_type.gsi.grh_info.dest_gid, &(p_query_req->gid), 16);
data/opensm-3.3.23/libvendor/osm_vendor_ibumad_sa.c:537: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(u.svc_rec.service_name, p_query_req->p_query_input,
data/opensm-3.3.23/libvendor/osm_vendor_ibumad_sa.c:633: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(&u.path_rec.dgid,
data/opensm-3.3.23/libvendor/osm_vendor_ibumad_sa.c:637: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(&u.path_rec.sgid,
data/opensm-3.3.23/libvendor/osm_vendor_mlx.c:165:9:  [2] (integer) atol:
  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).
	    && atol(getenv("OSM_PKT_DROP_RATE")) != 0) {
data/opensm-3.3.23/libvendor/osm_vendor_mlx.c:199: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 hca_id[32];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_anafa.c:165: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 device_file[16];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_anafa.c:185:9:  [2] (integer) atol:
  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).
	    && atol(getenv("OSM_PKT_DROP_RATE")) != 0) {
data/opensm-3.3.23/libvendor/osm_vendor_mlx_anafa.c:201: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(device_file, "/dev/ts_ua0");
data/opensm-3.3.23/libvendor/osm_vendor_mlx_anafa.c:202:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	device_fd = open("/dev/ts_ua0", O_RDWR);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_dispatcher.c:266: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((void *)p_mad_buf, (void *)p_mad, MAD_BLOCK_SIZE);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca.c:70: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(guid, gid + 8, 8);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca.c:206: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(&(p_ca_info->guid), hca_cap.node_guid, 8 * sizeof(u_int8_t));
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca.c:209: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(&(p_ca_info->p_attr->ca_guid), hca_cap.node_guid,
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca.c:494:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
				memcpy(p_hca_id, p_ca_ids[ca],
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_anafa.c:73: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(p_guid, gid + 8, 8);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_anafa.c:103: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(&(p_ca_info->attr.ca_guid), dev_info.dev_info.node_guid,
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:114: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 name[32];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:115: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 provider[32];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:133: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 file_name[256];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:134: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 file_buffer[3200];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:146: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(file_name, "/proc/infiniband/core/ca%d/info", idx);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:147:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	info_file = open(file_name, O_RDONLY);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:264: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 file_name[256];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:265: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 file_buffer[3200];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:266: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 state[12];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:279: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(file_name, "/proc/infiniband/core/ca%d/port%d/info", hca_idx,
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:281:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	info_file = open(file_name, O_RDONLY);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c: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 file_name[256];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:417: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 file_buffer[3200];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:430: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(file_name, "/proc/infiniband/core/ca%d/port%d/gid_table",
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:432:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	info_file = open(file_name, O_RDONLY);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:69: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.
	static char dirName[1024];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:157: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 name[32];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:158: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 provider[32];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:176: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 file_name[256];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:177: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 file_buffer[3200];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:190:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	info_file = open(file_name, O_RDONLY);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:307: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 file_name[256];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:308: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 file_buffer[3200];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:309: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 state[12];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:324:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	info_file = open(file_name, O_RDONLY);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:459: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 file_name[256];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:460: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 file_buffer[3200];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:475:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	info_file = open(file_name, O_RDONLY);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_ibmgt.c:103:10:  [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.
		    IN char hca_id[VENDOR_HCA_MAXNAMES],
data/opensm-3.3.23/libvendor/osm_vendor_mlx_ibmgt.c:738: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(&p_mad_addr->addr_type.gsi.grh_info.src_gid.raw,
data/opensm-3.3.23/libvendor/osm_vendor_mlx_ibmgt.c:740: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(&p_mad_addr->addr_type.gsi.grh_info.dest_gid.raw,
data/opensm-3.3.23/libvendor/osm_vendor_mlx_ibmgt.c:777: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(&p_av->dgid,
data/opensm-3.3.23/libvendor/osm_vendor_mlx_rmpp_ctx.c:247: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(p_list_mad, p_mad, MAD_BLOCK_SIZE);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sa.c:491: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(p_sa_mad->data, p_sa_mad_data->p_attr, sa_size);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sa.c:613: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(u.svc_rec.service_name, p_query_req->p_query_input,
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sa.c:709: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(&u.path_rec.dgid,
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sa.c:712: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(&u.path_rec.sgid,
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sar.c:92: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(p_buf, p_sar->p_arbt_mad, p_sar->hdr_sz);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sar.c:100: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((char *)p_buf + p_sar->hdr_sz, (char *)p_seg,
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sar.c:103: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((char *)p_buf + p_sar->hdr_sz, (char *)p_seg, sz_left);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sar.c:126: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(p_mad, buf_tmp, p_sar->hdr_sz);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sar.c:138: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((char *)p_mad, (char *)buf_tmp + p_sar->hdr_sz,
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sar.c:144: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((char *)p_mad, (char *)buf_tmp + p_sar->hdr_sz,
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sender.c:79: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(p_mad, osm_madw_get_mad_ptr(p_madw), p_madw->mad_size);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sender.c:265: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(p_resp_mad, p_req_mad, MAD_BLOCK_SIZE);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sender.c:291: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(p_resp_mad, p_req_mad, MAD_BLOCK_SIZE);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sim.c:149:10:  [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.
		    IN char hca_id[VENDOR_HCA_MAXNAMES],
data/opensm-3.3.23/libvendor/osm_vendor_mlx_sim.c:268: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(&mad_msg.header, p_mad_hdr, MAD_BLOCK_SIZE);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_ts.c:178:10:  [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.
		    IN char hca_id[VENDOR_HCA_MAXNAMES],
data/opensm-3.3.23/libvendor/osm_vendor_mlx_ts.c:182: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 device_file[16];
data/opensm-3.3.23/libvendor/osm_vendor_mlx_ts.c:197: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(device_file, "/dev/ts_ua%u", hca_idx);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_ts.c:198:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	device_fd = open(device_file, O_RDWR);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_ts.c:299: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(&ts_mad, p_mad_hdr, MAD_BLOCK_SIZE);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_ts_anafa.c:168:10:  [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.
		    IN char hca_id[VENDOR_HCA_MAXNAMES],
data/opensm-3.3.23/libvendor/osm_vendor_mlx_ts_anafa.c:191:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	device_fd = open(device_file, O_RDWR);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_ts_anafa.c:284: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(&ts_mad, p_mad_hdr, MAD_BLOCK_SIZE);
data/opensm-3.3.23/libvendor/osm_vendor_mtl.c:67: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(&wrid, &p_madw, sizeof(osm_madw_t *));
data/opensm-3.3.23/libvendor/osm_vendor_mtl.c:80: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(pp_madw, &wrid, sizeof(osm_madw_t *));
data/opensm-3.3.23/libvendor/osm_vendor_mtl.c:129: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(&p_mad_addr->addr_type.gsi.grh_info.src_gid.raw,
data/opensm-3.3.23/libvendor/osm_vendor_mtl.c:131: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(&p_mad_addr->addr_type.gsi.grh_info.dest_gid.raw,
data/opensm-3.3.23/libvendor/osm_vendor_mtl.c:168: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(&p_av->dgid,
data/opensm-3.3.23/libvendor/osm_vendor_mtl.c:491: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(p_new_vw->mad_buf_p, payload_p, MAD_BLOCK_SIZE);
data/opensm-3.3.23/libvendor/osm_vendor_mtl.c:650: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(p_bind->hca_id, hca_id, sizeof(VAPI_hca_id_t));
data/opensm-3.3.23/libvendor/osm_vendor_mtl_hca_guid.c:65: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(guid, gid + 8, 8);
data/opensm-3.3.23/libvendor/osm_vendor_mtl_hca_guid.c:226: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(&(p_ca_info->guid), hca_cap.node_guid, 8 * sizeof(u_int8_t));
data/opensm-3.3.23/libvendor/osm_vendor_mtl_hca_guid.c:229: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(&(p_ca_info->p_attr->ca_guid), hca_cap.node_guid,
data/opensm-3.3.23/libvendor/osm_vendor_mtl_hca_guid.c:512:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
				memcpy(p_hca_id, p_ca_ids[ca],
data/opensm-3.3.23/libvendor/osm_vendor_ts.c:62: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(&wrid, &p_madw, sizeof(osm_madw_t *));
data/opensm-3.3.23/libvendor/osm_vendor_ts.c:75: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(pp_madw, &wrid, sizeof(osm_madw_t *));
data/opensm-3.3.23/libvendor/osm_vendor_ts.c:353: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(p_new_vw->p_mad_buf, p_mad, mad_size);
data/opensm-3.3.23/libvendor/osm_vendor_ts.c:520: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 device_file[16];
data/opensm-3.3.23/libvendor/osm_vendor_ts.c:580: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(device_file, "/dev/ts_ua0");
data/opensm-3.3.23/libvendor/osm_vendor_ts.c:586:14:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	device_fd = open(device_file, O_RDWR);
data/opensm-3.3.23/libvendor/osm_vendor_ts.c:740: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(&ts_mad, p_mad, 256);
data/opensm-3.3.23/libvendor/osm_vendor_umadt.c:588: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(&p_madt_struct->IBMad, p_mad, MAD_BLOCK_SIZE);
data/opensm-3.3.23/libvendor/osm_vendor_umadt.c:638:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
				memcpy(&p_madt_struct->IBMad, p_mad,
data/opensm-3.3.23/libvendor/osm_vendor_umadt.c:661:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
				memcpy(&p_madt_struct->IBMad, p_mad,
data/opensm-3.3.23/libvendor/osm_vendor_umadt.c:671: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(((uint8_t *) & p_madt_struct->IBMad) +
data/opensm-3.3.23/libvendor/osm_vendor_umadt.c:678:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
				memcpy(&p_madt_struct->IBMad, p_mad,
data/opensm-3.3.23/libvendor/osm_vendor_umadt.c:690: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((((uint8_t *) & p_madt_struct->IBMad)) +
data/opensm-3.3.23/opensm/main.c:506: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 junk[128];
data/opensm-3.3.23/opensm/main.c:533:7:  [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).
	fd = open("/dev/null", O_WRONLY);
data/opensm-3.3.23/opensm/main.c:555:7:  [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).
		f = fopen(pidfile, "w");
data/opensm-3.3.23/opensm/main.c:1083:27:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			opt.max_reverse_hops = atoi(optarg);
data/opensm-3.3.23/opensm/main.c:1117:31:  [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).
			opt.perfmgr_sweep_time_s = atoi(optarg);
data/opensm-3.3.23/opensm/osm_congestion_control.c:135: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(p_cc->sw_cong_setting.victim_mask,
data/opensm-3.3.23/opensm/osm_congestion_control.c:139: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(p_cc->sw_cong_setting.credit_mask,
data/opensm-3.3.23/opensm/osm_congestion_control.c:251: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(p_sw_cong_setting,
data/opensm-3.3.23/opensm/osm_congestion_control.c:295: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(p_ca_cong_setting,
data/opensm-3.3.23/opensm/osm_congestion_control.c:341: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(p_cc_tbl,
data/opensm-3.3.23/opensm/osm_console.c:348: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 buf[1024];
data/opensm-3.3.23/opensm/osm_console.c:351: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).
		fp = fopen(p_osm->subn.opt.per_module_logging_file, "r");
data/opensm-3.3.23/opensm/osm_console.c:673: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 print_desc[IB_NODE_DESCRIPTION_SIZE + 1];
data/opensm-3.3.23/opensm/osm_console.c:686: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(rep->print_desc, print_desc, IB_NODE_DESCRIPTION_SIZE + 1);
data/opensm-3.3.23/opensm/osm_console.c:1603:23:  [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).
				uint16_t time_s = atoi(p_cmd);
data/opensm-3.3.23/opensm/osm_console.c:1684: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).
				output = fopen(p_cmd, "w+");
data/opensm-3.3.23/opensm/osm_db_files.c:246:11:  [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).
	p_file = fopen(p_domain_imp->file_name, "a+");
data/opensm-3.3.23/opensm/osm_db_files.c:282: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 sLine[OSM_DB_MAX_LINE_LEN];
data/opensm-3.3.23/opensm/osm_db_files.c:296:11:  [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).
	p_file = fopen(p_domain_imp->file_name, "r");
data/opensm-3.3.23/opensm/osm_db_files.c:465: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(p_tmp_file_name, ".tmp");
data/opensm-3.3.23/opensm/osm_db_files.c:473:11:  [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).
	p_file = fopen(p_tmp_file_name, "w");
data/opensm-3.3.23/opensm/osm_db_files.c:716: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 val_buf[16];
data/opensm-3.3.23/opensm/osm_db_files.c:717: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 key_buf[16];
data/opensm-3.3.23/opensm/osm_db_files.c:721: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(key_buf, "%u", k);
data/opensm-3.3.23/opensm/osm_db_files.c:722: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(val_buf, "%u", v);
data/opensm-3.3.23/opensm/osm_db_pack.c:58: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(lid_str, "0x%04x 0x%04x", min_lid, max_lid);
data/opensm-3.3.23/opensm/osm_db_pack.c:67: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 lids_str[24];
data/opensm-3.3.23/opensm/osm_db_pack.c:104: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(p_str, "0x%016" PRIx64 ":%u", guid, portnum);
data/opensm-3.3.23/opensm/osm_db_pack.c:110: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 tmp_str[24];
data/opensm-3.3.23/opensm/osm_db_pack.c:163: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 guid_str[20];
data/opensm-3.3.23/opensm/osm_db_pack.c:185: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 guid_str[20];
data/opensm-3.3.23/opensm/osm_db_pack.c:186: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 lid_str[16];
data/opensm-3.3.23/opensm/osm_db_pack.c:196: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 guid_str[20];
data/opensm-3.3.23/opensm/osm_db_pack.c:230: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 guid_str[20];
data/opensm-3.3.23/opensm/osm_db_pack.c:247: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 guid_str[20];
data/opensm-3.3.23/opensm/osm_db_pack.c:248: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 mkey_str[20];
data/opensm-3.3.23/opensm/osm_db_pack.c:258: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 guid_str[20];
data/opensm-3.3.23/opensm/osm_db_pack.c:294: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 neighbor_str[24];
data/opensm-3.3.23/opensm/osm_db_pack.c:318: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 n1_str[24], n2_str[24];
data/opensm-3.3.23/opensm/osm_db_pack.c:329: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 n_str[24];
data/opensm-3.3.23/opensm/osm_drop_mgr.c:206: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(&(notice.data_details.ntc_64_67.gid),
data/opensm-3.3.23/opensm/osm_dump.c:252: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 sw_hdr[256];
data/opensm-3.3.23/opensm/osm_dump.c:253: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 mlid_hdr[32];
data/opensm-3.3.23/opensm/osm_dump.c:259: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(sw_hdr, "\nSwitch 0x%016" PRIx64 "\nLID    : Out Port(s)\n",
data/opensm-3.3.23/opensm/osm_dump.c:268:4:  [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(mlid_hdr, "0x%04X :",
data/opensm-3.3.23/opensm/osm_dump.c:512: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 buf[1024];
data/opensm-3.3.23/opensm/osm_dump.c:536:11:  [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.
					n += sprintf(buf + n, " %-2d",
data/opensm-3.3.23/opensm/osm_dump.c:546:9:  [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.
			n += sprintf(buf + n, " %-2d",
data/opensm-3.3.23/opensm/osm_dump.c:675: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 path[1024];
data/opensm-3.3.23/opensm/osm_dump.c:681: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).
	file = fopen(path, "w");
data/opensm-3.3.23/opensm/osm_event_plugin.c:70: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 lib_name[OSM_PATH_MAX];
data/opensm-3.3.23/opensm/osm_guid_mgr.c:65: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(payload,
data/opensm-3.3.23/opensm/osm_inform.c:78: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(p_infr, p_infr_rec, sizeof(osm_infr_t));
data/opensm-3.3.23/opensm/osm_inform.c:247: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_inform.c:414: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_inform.c:424: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_inform.c:604: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 gid_str[INET6_ADDRSTRLEN], gid_str2[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_lid_mgr.c:857: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(payload, p_old_pi, sizeof(ib_port_info_t));
data/opensm-3.3.23/opensm/osm_link_mgr.c:121: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(payload, p_old_pi, sizeof(ib_port_info_t));
data/opensm-3.3.23/opensm/osm_link_mgr.c:375: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(payload2, p_old_epi,
data/opensm-3.3.23/opensm/osm_mesh.c:228: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.
	static char str[(MAX_DEGREE+1)*20];
data/opensm-3.3.23/opensm/osm_mesh.c:253:9:  [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.
			p += sprintf(p, "%d", t);
data/opensm-3.3.23/opensm/osm_mesh.c:258:9:  [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.
			p += sprintf(p, "^%d", i);
data/opensm-3.3.23/opensm/osm_mesh.c:824:8:  [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.
		p += sprintf(p, "N/A -> ");
data/opensm-3.3.23/opensm/osm_mesh.c:878: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[256], *p;
data/opensm-3.3.23/opensm/osm_mesh.c:1583: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 buf[256];
data/opensm-3.3.23/opensm/osm_mesh.c:1643: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 buf[256], *p;
data/opensm-3.3.23/opensm/osm_mesh.c:1689:8:  [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.
		p += sprintf(p, " mesh\n");
data/opensm-3.3.23/opensm/osm_mesh.c:1693:8:  [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.
		p += sprintf(p, "unknown geometry\n");
data/opensm-3.3.23/opensm/osm_mesh.c:1716:8:  [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.
		p += sprintf(p, "found ");
data/opensm-3.3.23/opensm/osm_mesh.c:1719:8:  [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.
		p += sprintf(p, " mesh\n");
data/opensm-3.3.23/opensm/osm_multicast.c:202: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(&notice.data_details.ntc_64_67.gid,
data/opensm-3.3.23/opensm/osm_multicast.c:282: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_multicast.c:362: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_node_desc_rcv.c:65: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 print_desc[IB_NODE_DESCRIPTION_SIZE + 1];
data/opensm-3.3.23/opensm/osm_node_desc_rcv.c:69: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(&p_node->node_desc.description, p_nd, sizeof(*p_nd));
data/opensm-3.3.23/opensm/osm_node_desc_rcv.c:72: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(print_desc, p_nd, sizeof(*p_nd));
data/opensm-3.3.23/opensm/osm_perfmgr.c:1565: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_perfmgr.c:1627: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(&p_mon_node->port[port].gid, &cpi->redir_gid,
data/opensm-3.3.23/opensm/osm_perfmgr.c:1994: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 path[256];
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:696: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 lr[128];
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:698: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 leu[128];
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:700: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 ldu[128];
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:812: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 lr[128];
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:814: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 leu[128];
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:816: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 ldu[128];
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:1022:15:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	context.fp = fopen(file, "w+");
data/opensm-3.3.23/opensm/osm_pkey.c:144: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(p_pkey_block, p_tbl, sizeof(ib_pkey_table_t));
data/opensm-3.3.23/opensm/osm_pkey_mgr.c:287: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(payload, p_pi, sizeof(ib_port_info_t));
data/opensm-3.3.23/opensm/osm_port.c:302: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(&k, p, sizeof(void *));
data/opensm-3.3.23/opensm/osm_port.c:311: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(&p, &k, sizeof(void *));
data/opensm-3.3.23/opensm/osm_prtn.c:94: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_prtn.c:214: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_prtn.c:250: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_prtn_config.c:131: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_prtn_config.c:151: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_prtn_config.c:169: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_prtn_config.c:254: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(&broadcast_mgroup.mgid.raw[4], &pkey , sizeof(pkey));
data/opensm-3.3.23/opensm/osm_prtn_config.c:634: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(&mgroup.mgid.raw[4], &pkey, sizeof(pkey));
data/opensm-3.3.23/opensm/osm_prtn_config.c:776: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 line[4096];
data/opensm-3.3.23/opensm/osm_prtn_config.c:783: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).
	file = fopen(file_name, "r");
data/opensm-3.3.23/opensm/osm_qos.c:168: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(&block, table_block, block_length * sizeof(block.vl_entry[0]));
data/opensm-3.3.23/opensm/osm_req.c:313: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(osm_madw_get_smp_ptr(p_madw)->data, p_payload, payload_size);
data/opensm-3.3.23/opensm/osm_resp.c:88: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(&p_dest_smp->data, p_payload, IB_SMP_DATA_SIZE);
data/opensm-3.3.23/opensm/osm_sa.c:490: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(resp_sa_mad, sa_mad, IB_SA_MAD_HDR_SIZE);
data/opensm-3.3.23/opensm/osm_sa.c:519: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(p, ((osm_sa_item_t *)item)->resp.data, attr_size);
data/opensm-3.3.23/opensm/osm_sa.c:550: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 path[1024];
data/opensm-3.3.23/opensm/osm_sa.c:551: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 path_tmp[1032];
data/opensm-3.3.23/opensm/osm_sa.c:560: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).
	file = fopen(path_tmp, "w");
data/opensm-3.3.23/opensm/osm_sa.c:1017: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(&(*p_port->p_physp->p_guids)[gir->block_num * GUID_TABLE_MAX_ENTRIES],
data/opensm-3.3.23/opensm/osm_sa.c:1108: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 line[1024];
data/opensm-3.3.23/opensm/osm_sa.c:1130: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).
	file = fopen(file_name, "r");
data/opensm-3.3.23/opensm/osm_sa_class_port_info.c:100: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(p_resp_sa_mad, p_sa_mad, IB_SA_MAD_HDR_SIZE);
data/opensm-3.3.23/opensm/osm_sa_guidinfo_record.c:111: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(&p_rec_item->resp.guid_rec.guid_info,
data/opensm-3.3.23/opensm/osm_sa_guidinfo_record.c:482: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(&p_rcvd_rec->guid_info,
data/opensm-3.3.23/opensm/osm_sa_guidinfo_record.c:711: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(&p_rcvd_rec->guid_info,
data/opensm-3.3.23/opensm/osm_sa_informinfo.c:225: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(&item->resp.inform,
data/opensm-3.3.23/opensm/osm_sa_informinfo.c:294: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(&p_rec_item->resp.inform_rec, &p_infr->inform_record,
data/opensm-3.3.23/opensm/osm_sa_informinfo.c:326: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:170: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[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:420: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:421: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 gid_str2[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:813: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(&mgid->raw[4], &sa->p_subn->opt.subnet_prefix, sizeof(uint64_t));
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:816: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(&mgid->raw[10], &uniq_count, 4);
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:840: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1019: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1032: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1033: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 gid_str2[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1250: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1270: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1305: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1347: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1369: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1392: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1531: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(&port_gid, &(p_mcm_alias_guid->port_gid),
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1545: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1559: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(&match_rec.port_gid,
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1585: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(&(match_rec.port_gid), &port_gid, sizeof(ib_gid_t));
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1728: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_mcmember_record.c:1729: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 gid_str2[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_node_record.c:104: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(&(p_rec_item->resp.node_rec.node_desc), &(p_node->node_desc),
data/opensm-3.3.23/opensm/osm_sa_path_record.c:1394: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_path_record.c:1585: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sa_path_record.c:1681: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/opensm/osm_sm_mad_ctrl.c:559: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 buf[BUF_SIZE];
data/opensm-3.3.23/opensm/osm_sm_mad_ctrl.c:563: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 ipath[IB_SUBNET_PATH_HOPS_MAX * 4];
data/opensm-3.3.23/opensm/osm_sm_mad_ctrl.c:564: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 rpath[IB_SUBNET_PATH_HOPS_MAX * 4];
data/opensm-3.3.23/opensm/osm_sm_mad_ctrl.c:565:12:  [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.
		int ni = sprintf(ipath, "%d", p_smp->initial_path[0]);
data/opensm-3.3.23/opensm/osm_sm_mad_ctrl.c:566:12:  [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.
		int nr = sprintf(rpath, "%d", p_smp->return_path[0]);
data/opensm-3.3.23/opensm/osm_sm_mad_ctrl.c:568:10:  [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.
			ni += sprintf(ipath + ni, ",%d", p_smp->initial_path[i]);
data/opensm-3.3.23/opensm/osm_sm_mad_ctrl.c:569:10:  [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.
			nr += sprintf(rpath + nr, ",%d", p_smp->return_path[i]);
data/opensm-3.3.23/opensm/osm_sm_state_mgr.c:69: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 buf[64];
data/opensm-3.3.23/opensm/osm_sm_state_mgr.c:125: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(&dr_path, osm_physp_get_dr_path_ptr(p_port->p_physp), sizeof(osm_dr_path_t));
data/opensm-3.3.23/opensm/osm_sminfo_rcv.c:424: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 buf[256];
data/opensm-3.3.23/opensm/osm_sminfo_rcv.c:451:4:  [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, "LID %u",
data/opensm-3.3.23/opensm/osm_sminfo_rcv.c:605: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[256];
data/opensm-3.3.23/opensm/osm_sminfo_rcv.c:624:6:  [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, "LID %u",
data/opensm-3.3.23/opensm/osm_sminfo_rcv.c:643:6:  [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, "LID %u",
data/opensm-3.3.23/opensm/osm_state_mgr.c:174: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(&rem_node_dr_path, p_dr_path, sizeof(osm_dr_path_t));
data/opensm-3.3.23/opensm/osm_state_mgr.c:1061: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(&(notice.data_details.ntc_64_67.gid), &(port_gid),
data/opensm-3.3.23/opensm/osm_subnet.c:214: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 buf[128];
data/opensm-3.3.23/opensm/osm_subnet.c:225: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 buf[128];
data/opensm-3.3.23/opensm/osm_subnet.c:500: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 tmpbuf[3] = { 0 };
data/opensm-3.3.23/opensm/osm_subnet.c:536: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(tmpbuf, strptr, 1);
data/opensm-3.3.23/opensm/osm_subnet.c:540: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(tmpbuf, strptr, 2);
data/opensm-3.3.23/opensm/osm_subnet.c:548: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(tmpbuf, strptr, 2);
data/opensm-3.3.23/opensm/osm_subnet.c:558: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(p_val1, val, IB_CC_PORT_MASK_DATA_SIZE);
data/opensm-3.3.23/opensm/osm_subnet.c:559: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(p_val2, val, IB_CC_PORT_MASK_DATA_SIZE);
data/opensm-3.3.23/opensm/osm_subnet.c:570: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 buf[512] = { 0 };
data/opensm-3.3.23/opensm/osm_subnet.c:656: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(p_val1->entries, newcct.entries, sizeof(newcct.entries));
data/opensm-3.3.23/opensm/osm_subnet.c:657: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(p_val2->entries, newcct.entries, sizeof(newcct.entries));
data/opensm-3.3.23/opensm/osm_subnet.c:1543: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(f, opt, sizeof(*f));
data/opensm-3.3.23/opensm/osm_subnet.c:1750: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 buf[1024];
data/opensm-3.3.23/opensm/osm_subnet.c:1759:7:  [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(p_subn->opt.prefix_routes_file, "r");
data/opensm-3.3.23/opensm/osm_subnet.c:1851: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 buf[1024];
data/opensm-3.3.23/opensm/osm_subnet.c:1860:7:  [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(p_subn->opt.per_module_logging_file, "r");
data/opensm-3.3.23/opensm/osm_subnet.c:2209: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 line[1024];
data/opensm-3.3.23/opensm/osm_subnet.c:2216: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).
	opts_file = fopen(file_name, "r");
data/opensm-3.3.23/opensm/osm_subnet.c:2232: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(p_opts->file_opts, p_opts, sizeof(*p_opts));
data/opensm-3.3.23/opensm/osm_subnet.c:2274: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 line[1024];
data/opensm-3.3.23/opensm/osm_subnet.c:2285: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).
	opts_file = fopen(p_opts->config_file, "r");
data/opensm-3.3.23/opensm/osm_subnet.c:3136: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).
	opts_file = fopen(file_name, "w");
data/opensm-3.3.23/opensm/osm_switch.c:172: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(p_block, &(p_sw->new_lft[base_lid_ho]), IB_SMP_DATA_SIZE);
data/opensm-3.3.23/opensm/osm_torus.c:1038:7:  [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(fn, "r");
data/opensm-3.3.23/opensm/osm_torus.c:7509: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 path[1024];
data/opensm-3.3.23/opensm/osm_torus.c:7514: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).
	file = fopen(path, "w");
data/opensm-3.3.23/opensm/osm_torus.c:9264:30:  [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.
void sum_vlarb_weights(const char *vlarb_str,
data/opensm-3.3.23/opensm/osm_trap_rcv.c:232: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(payload, &p->port_info, sizeof(ib_port_info_t));
data/opensm-3.3.23/opensm/osm_trap_rcv.c:287: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[32];
data/opensm-3.3.23/opensm/osm_trap_rcv.c:390: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 buf[1024];
data/opensm-3.3.23/opensm/osm_trap_rcv.c:429: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(payload, &p_smp->data, IB_SMP_DATA_SIZE);
data/opensm-3.3.23/opensm/osm_trap_rcv.c:597:9:  [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.
				n = sprintf(buf, "SM class trap %u: ",
data/opensm-3.3.23/opensm/osm_trap_rcv.c:649: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(&p_ntci->issuer_gid,
data/opensm-3.3.23/opensm/osm_ucast_dfsssp.c:348: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(tmp, link->srcdest_pairs,
data/opensm-3.3.23/opensm/osm_ucast_file.c:124: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 line[1024];
data/opensm-3.3.23/opensm/osm_ucast_file.c:143: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).
	file = fopen(file_name, "r");
data/opensm-3.3.23/opensm/osm_ucast_file.c:265: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 line[1024];
data/opensm-3.3.23/opensm/osm_ucast_file.c:284: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).
	file = fopen(file_name, "r");
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:289: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.
	static char buffer[FTREE_TUPLE_BUFFERS_NUM][FTREE_TUPLE_BUFF_LEN];
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:304: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(&buffer[ind][strlen(buffer[ind])], "%u", tuple[i]);
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:317: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(&key, tuple, FTREE_TUPLE_LEN);
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:327: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(tuple, &key, FTREE_TUPLE_LEN);
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:410: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(&p_group->port_guid, &port_guid, sizeof(ib_net64_t));
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:411: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(&p_group->node_guid, &node_guid, sizeof(ib_net64_t));
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:412: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(&p_group->remote_port_guid, &remote_port_guid,
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:414: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(&p_group->remote_node_guid, &remote_node_guid,
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:504:4:  [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(buff, ", ");
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:505: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(buff + strlen(buff), "%u", p_port->port_num);
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:1296: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 path[1024], path_tmp[1032];
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:1305:24:  [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).
	p_hca_ordering_file = fopen(path_tmp, "w");
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:1366: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(p_sw->tuple, new_tuple, FTREE_TUPLE_LEN);
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:1418: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(temp_tuple, from_tuple, FTREE_TUPLE_LEN);
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:1439: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(new_tuple, temp_tuple, FTREE_TUPLE_LEN);
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:1784: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(p_ftree->leaf_switches,
data/opensm-3.3.23/opensm/osm_ucast_nue.c:3781: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(dlid_arr_iter, nue_ctx->destinations,
data/opensm-3.3.23/opensm/st.c:179:12:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	FILE *f = fopen("/var/log/osm_st_col", "w");
data/opensm-3.3.23/osmeventplugin/src/osmeventplugin.c:72: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).
	log->log_file = fopen(SAMPLE_PLUGIN_OUTPUT_FILE, "a+");
data/opensm-3.3.23/osmtest/include/osmtest.h:85: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 file_name[OSMTEST_FILE_PATH_MAX];
data/opensm-3.3.23/osmtest/main.c:282: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 flow_name[64];
data/opensm-3.3.23/osmtest/main.c:339: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(flow_name, "All Validations");
data/opensm-3.3.23/osmtest/main.c:340: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(opt.file_name, "osmtest.dat");
data/opensm-3.3.23/osmtest/main.c:379: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(flow_name, "Create Inventory");
data/opensm-3.3.23/osmtest/main.c:382: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(flow_name, "Validate Inventory");
data/opensm-3.3.23/osmtest/main.c:385: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(flow_name, "Services Registration");
data/opensm-3.3.23/osmtest/main.c:388: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(flow_name, "Event Forwarding");
data/opensm-3.3.23/osmtest/main.c:391: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(flow_name, "Stress SA");
data/opensm-3.3.23/osmtest/main.c:394: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(flow_name, "Multicast");
data/opensm-3.3.23/osmtest/main.c:397: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(flow_name, "QoS: VLArb and SLtoVL");
data/opensm-3.3.23/osmtest/main.c:400: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(flow_name, "Trap 64/65");
data/opensm-3.3.23/osmtest/main.c:403: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(flow_name, "All Validations");
data/opensm-3.3.23/osmtest/main.c:424:25:  [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).
			max_lid = (uint16_t) atoi(optarg);
data/opensm-3.3.23/osmtest/osmt_inform.c:199: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(p_ii, p_inform_info, sizeof(ib_inform_info_t));
data/opensm-3.3.23/osmtest/osmt_multicast.c:81: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmt_multicast.c:185: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmt_multicast.c:234: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/osmtest/osmt_multicast.c:341: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmt_multicast.c:353: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(p_res, osm_madw_get_mad_ptr(context.result.p_result_madw),
data/opensm-3.3.23/osmtest/osmt_multicast.c:390: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(&p_mc_req->port_gid.unicast.interface_id,
data/opensm-3.3.23/osmtest/osmt_multicast.c:472: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 gid_str[INET6_ADDRSTRLEN];
data/opensm-3.3.23/osmtest/osmt_multicast.c:473: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 gid_str2[INET6_ADDRSTRLEN];
data/opensm-3.3.23/osmtest/osmt_multicast.c:611: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(&mc_req_rec.mgid, &osm_ipoib_good_mgid,
data/opensm-3.3.23/osmtest/osmt_multicast.c:662: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(&mc_req_rec.mgid, &osm_ipoib_good_mgid,
data/opensm-3.3.23/osmtest/osmt_multicast.c:1778: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(&special_mgid, &mc_req_rec.mgid, sizeof(ib_gid_t));
data/opensm-3.3.23/osmtest/osmt_multicast.c:1802: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(&mc_req_rec.mgid, &p_mc_res->mgid, sizeof(ib_gid_t));
data/opensm-3.3.23/osmtest/osmt_multicast.c:2261: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(&tmp_mgid, &p_mc_res->mgid, sizeof(ib_gid_t));
data/opensm-3.3.23/osmtest/osmt_multicast.c:2267: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(&mc_req_rec.mgid, &tmp_mgid, sizeof(ib_gid_t));
data/opensm-3.3.23/osmtest/osmt_multicast.c:2354: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(&proxy_mgid, &p_mc_res->mgid, sizeof(ib_gid_t));
data/opensm-3.3.23/osmtest/osmt_service.c:94: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(svc_rec.service_name, service_name,
data/opensm-3.3.23/osmtest/osmt_service.c:129: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmt_service.c:200: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(svc_rec.service_key, service_key, 16 * sizeof(uint8_t));
data/opensm-3.3.23/osmtest/osmt_service.c:203: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(svc_rec.service_name, service_name,
data/opensm-3.3.23/osmtest/osmt_service.c:238: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmt_service.c:332: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(svc_rec.service_data8, service_data8, 16 * sizeof(uint8_t));
data/opensm-3.3.23/osmtest/osmt_service.c:333: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(svc_rec.service_data16, service_data16, 8 * sizeof(ib_net16_t));
data/opensm-3.3.23/osmtest/osmt_service.c:334: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(svc_rec.service_data32, service_data32, 4 * sizeof(ib_net32_t));
data/opensm-3.3.23/osmtest/osmt_service.c:335: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(svc_rec.service_data64, service_data64, 2 * sizeof(ib_net64_t));
data/opensm-3.3.23/osmtest/osmt_service.c:338: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(svc_rec.service_name, service_name,
data/opensm-3.3.23/osmtest/osmt_service.c:394: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmt_service.c:463: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 mad_stat_err[ERR_SIZE];
data/opensm-3.3.23/osmtest/osmt_service.c:496: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(svc_rec.service_name, sr_name,
data/opensm-3.3.23/osmtest/osmt_service.c:508: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmt_service.c:637: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmt_service.c:651: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 mad_stat_err[256];
data/opensm-3.3.23/osmtest/osmt_service.c:725: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 mad_stat_err[ERR_SIZE];
data/opensm-3.3.23/osmtest/osmt_service.c:761: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(svc_rec.service_name, sr_name,
data/opensm-3.3.23/osmtest/osmt_service.c:775: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmt_service.c:892: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(service_name, sr_name, (strlen(sr_name) + 1) * sizeof(char));
data/opensm-3.3.23/osmtest/osmt_service.c:897: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmt_service.c:911: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 mad_stat_err[256];
data/opensm-3.3.23/osmtest/osmt_service.c:1018: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmt_service.c:1062:10:  [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 *)p_valid_service_names_arr[j],
data/opensm-3.3.23/osmtest/osmt_service.c:1127: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(svc_rec.service_name, sr_name,
data/opensm-3.3.23/osmtest/osmt_service.c:1147: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmt_service.c:1245:12:  [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.
		sprintf((char *)(service_name[i]),
data/opensm-3.3.23/osmtest/osmt_service.c:1254: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 *)service_name[0]	/*  IN char            *service_name */
data/opensm-3.3.23/osmtest/osmt_service.c:1264: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 *)service_name[1]	/*  IN char            *service_name */
data/opensm-3.3.23/osmtest/osmt_service.c:1274: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 *)service_name[2]	/*  IN char            *service_name */
data/opensm-3.3.23/osmtest/osmt_service.c:1297:10:  [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 *)service_name[3]	/*  IN char            *service_name */
data/opensm-3.3.23/osmtest/osmt_service.c:1312: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 *)service_name[5]	/*  IN char            *service_name */
data/opensm-3.3.23/osmtest/osmt_service.c:1327: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 *)service_name[6]	/*  IN char            *service_name */
data/opensm-3.3.23/osmtest/osmt_service.c:1338: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 *)service_name[0], 1, &srv_rec);
data/opensm-3.3.23/osmtest/osmt_service.c:1342: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 *)service_name[0]);
data/opensm-3.3.23/osmtest/osmt_service.c:1349: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 *)service_name[1], 1, &srv_rec);
data/opensm-3.3.23/osmtest/osmt_service.c:1353: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 *)service_name[1]);
data/opensm-3.3.23/osmtest/osmt_service.c:1360: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 *)service_name[2], 1, &srv_rec);
data/opensm-3.3.23/osmtest/osmt_service.c:1364: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 *)service_name[2]);
data/opensm-3.3.23/osmtest/osmt_service.c:1372: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 *)service_name[3], 1, &srv_rec);
data/opensm-3.3.23/osmtest/osmt_service.c:1376: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 *)service_name[3]);
data/opensm-3.3.23/osmtest/osmt_service.c:1384: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 *)service_name[3], 0, &srv_rec);
data/opensm-3.3.23/osmtest/osmt_service.c:1389: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 *)service_name[3]);
data/opensm-3.3.23/osmtest/osmt_service.c:1416: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 *)service_name[0],
data/opensm-3.3.23/osmtest/osmt_service.c:1421:26:  [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.
			"name: %s\n", id[0], (char *)service_name[0]);
data/opensm-3.3.23/osmtest/osmt_service.c:1428: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 *)service_name[6],
data/opensm-3.3.23/osmtest/osmt_service.c:1433:26:  [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.
			"name: %s\n", id[5], (char *)service_name[6]);
data/opensm-3.3.23/osmtest/osmt_service.c:1440: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 *)service_name[3],
data/opensm-3.3.23/osmtest/osmt_service.c:1446:12:  [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.
			id[0], (char *)service_name[3]);
data/opensm-3.3.23/osmtest/osmt_service.c:1453: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 *)service_name[5],
data/opensm-3.3.23/osmtest/osmt_service.c:1459:12:  [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.
			id[3], (char *)service_name[5]);
data/opensm-3.3.23/osmtest/osmt_service.c:1466: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 *)service_name[4], 0, &srv_rec);
data/opensm-3.3.23/osmtest/osmt_service.c:1470: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 *)service_name[4]);
data/opensm-3.3.23/osmtest/osmt_service.c:1478: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 *)service_name[5], 0, &srv_rec);
data/opensm-3.3.23/osmtest/osmt_service.c:1482:26:  [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.
			"invalid service\n", (char *)service_name[5]);
data/opensm-3.3.23/osmtest/osmt_service.c:1490: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 *)service_name[6], 1, &srv_rec);
data/opensm-3.3.23/osmtest/osmt_service.c:1494: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 *)service_name[6]);
data/opensm-3.3.23/osmtest/osmt_service.c:1505:10:  [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 *)service_name[5],
data/opensm-3.3.23/osmtest/osmt_service.c:1511: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 *)service_name[5]);
data/opensm-3.3.23/osmtest/osmt_service.c:1519:10:  [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 *)service_name[6],
data/opensm-3.3.23/osmtest/osmt_service.c:1525: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 *)service_name[6]);
data/opensm-3.3.23/osmtest/osmt_service.c:1534:10:  [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 *)service_name[6],
data/opensm-3.3.23/osmtest/osmt_service.c:1539:30:  [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.
			"correct service key\n", (char *)service_name[6]);
data/opensm-3.3.23/osmtest/osmt_service.c:1545: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(&service_valid_names[0], &service_name[0], sizeof(uint8_t) * 64);
data/opensm-3.3.23/osmtest/osmt_service.c:1546: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(&service_valid_names[1], &service_name[2], sizeof(uint8_t) * 64);
data/opensm-3.3.23/osmtest/osmt_service.c:1547: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(&service_valid_names[2], &service_name[6], sizeof(uint8_t) * 64);
data/opensm-3.3.23/osmtest/osmt_service.c:1562:12:  [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 *)service_name[0], 1);
data/opensm-3.3.23/osmtest/osmt_service.c:1566: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 *)service_name[0]);
data/opensm-3.3.23/osmtest/osmt_service.c:1573: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 *)service_name[0], 0, &srv_rec);
data/opensm-3.3.23/osmtest/osmt_service.c:1577: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 *)service_name[0]);
data/opensm-3.3.23/osmtest/osmt_service.c:1584: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 *)service_name[1], 0, &srv_rec);
data/opensm-3.3.23/osmtest/osmt_service.c:1588: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 *)service_name[1]);
data/opensm-3.3.23/osmtest/osmt_service.c:1595: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 *)service_name[2], 1, &srv_rec);
data/opensm-3.3.23/osmtest/osmt_service.c:1599: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 *)service_name[2]);
data/opensm-3.3.23/osmtest/osmt_service.c:1606:12:  [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 *)service_name[5], 0);
data/opensm-3.3.23/osmtest/osmt_service.c:1610: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 *)service_name[5]);
data/opensm-3.3.23/osmtest/osmt_service.c:1617:12:  [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 *)service_name[2], 1);
data/opensm-3.3.23/osmtest/osmt_service.c:1621: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 *)service_name[2]);
data/opensm-3.3.23/osmtest/osmt_service.c:1628:12:  [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 *)service_name[6], 1);
data/opensm-3.3.23/osmtest/osmt_service.c:1632: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 *)service_name[6]);
data/opensm-3.3.23/osmtest/osmt_slvl_vl_arb.c:140: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmt_slvl_vl_arb.c:346: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmt_slvl_vl_arb.c:501:7:  [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).
	fh = fopen("qos.txt", "w");
data/opensm-3.3.23/osmtest/osmtest.c:252: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.
	static char line[512];
data/opensm-3.3.23/osmtest/osmtest.c:262:3:  [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(&line[offset], "IB_SUCCESS");
data/opensm-3.3.23/osmtest/osmtest.c:578: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:644: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:748: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:818: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:886: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:958: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:1096: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:1173: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:1668: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:1848: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 desc[IB_NODE_DESCRIPTION_SIZE + 1];
data/opensm-3.3.23/osmtest/osmtest.c:1852: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(desc, p_rec->node_desc.description, IB_NODE_DESCRIPTION_SIZE);
data/opensm-3.3.23/osmtest/osmtest.c:2029: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:2636:7:  [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).
	fh = fopen(p_osmt->opt.file_name, "w");
data/opensm-3.3.23/osmtest/osmtest.c:4295: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:4378: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:4461: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:4544: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:4627: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:4710: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:4806: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:4920: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:5055: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:5197: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(&req.gid, &p_osmt->sm_port_gid, 16);
data/opensm-3.3.23/osmtest/osmtest.c:6283: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 line[OSMTEST_MAX_LINE_LEN];
data/opensm-3.3.23/osmtest/osmtest.c:6509: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 line[OSMTEST_MAX_LINE_LEN];
data/opensm-3.3.23/osmtest/osmtest.c:6915: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 line[OSMTEST_MAX_LINE_LEN];
data/opensm-3.3.23/osmtest/osmtest.c:7076: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 line[OSMTEST_MAX_LINE_LEN];
data/opensm-3.3.23/osmtest/osmtest.c:7154: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 line[OSMTEST_MAX_LINE_LEN];
data/opensm-3.3.23/osmtest/osmtest.c:7161:7:  [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).
	fh = fopen(p_osmt->opt.file_name, "r");
data/opensm-3.3.23/osmtest/osmtest.c:7279: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 junk[256];
data/opensm-3.3.23/complib/cl_log.c:98:6:  [1] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source is a constant character.
					sprintf(p_buf++, "\n");
data/opensm-3.3.23/complib/cl_log.c:104:6:  [1] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source is a constant character.
					sprintf(p_buf++, " ");
data/opensm-3.3.23/complib/cl_thread.c:109:2:  [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(pause_ms * 1000);
data/opensm-3.3.23/complib/cl_thread.c:118:2:  [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(pause_us);
data/opensm-3.3.23/include/opensm/osm_event_plugin.h:202:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(port_id->node_name, node_name, OSM_EPI_NODE_NAME_LEN);
data/opensm-3.3.23/libopensm/osm_helper.c:583: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).
	len = (uint32_t) strlen(line);
data/opensm-3.3.23/libopensm/osm_helper.c:601:13:  [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).
	p_local += strlen(p_local);
data/opensm-3.3.23/libopensm/osm_helper.c:805:13:  [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).
	p_local += strlen(p_local);
data/opensm-3.3.23/libopensm/osm_helper.c:1662:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(buf_service_name, (char *)p_sr->service_name, 64);
data/opensm-3.3.23/libopensm/osm_helper.c:2842:3:  [1] (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 character.
		strcat(buf, "\n");
data/opensm-3.3.23/libopensm/osm_log.c:365:24:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	n = (MSG_BOX_LENGTH - strlen(msg)) / 2 - 1;
data/opensm-3.3.23/libopensm/osm_log.c:369:3:  [1] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source is a constant character.
		sprintf(buf + i, "*");
data/opensm-3.3.23/libopensm/osm_log.c:393:24:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	n = (MSG_BOX_LENGTH - strlen(msg)) / 2 - 1;
data/opensm-3.3.23/libopensm/osm_log.c:397:3:  [1] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source is a constant character.
		sprintf(buf + i, "*");
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:157:8:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	len = read(info_file, file_buffer, 3200);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:291:8:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	len = read(info_file, file_buffer, 3200);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_pfs.c:442:8:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	len = read(info_file, file_buffer, 3200);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:200:8:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	len = read(info_file, file_buffer, 3200);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:334:8:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	len = read(info_file, file_buffer, 3200);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_hca_sim.c:485:8:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	len = read(info_file, file_buffer, 3200);
data/opensm-3.3.23/libvendor/osm_vendor_mlx_ts.c:103:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		    read(((osmv_TOPSPIN_transport_mgr_t *) (p_bo->
data/opensm-3.3.23/libvendor/osm_vendor_mlx_ts_anafa.c:99:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		    read(((osmv_TOPSPIN_ANAFA_transport_mgr_t *) (p_bo->
data/opensm-3.3.23/libvendor/osm_vendor_ts.c:458:17:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		ts_ret_code = read(p_bind->ul_dev_fd, &mad, sizeof(mad));
data/opensm-3.3.23/opensm/main.c:507:8:  [1] (buffer) scanf:
  It's unclear if the %s limit in the format string is small enough
  (CWE-120). Check that the limit is sufficiently small, or use a different
  input function.
			if (scanf("%127s", junk) <= 0)
data/opensm-3.3.23/opensm/osm_console_io.c:185:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(p_oct->client_type, opt->console, sizeof(p_oct->client_type) - 1);
data/opensm-3.3.23/opensm/osm_db_files.c:229:13:  [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).
	path_len = strlen(((osm_db_imp_t *) p_db->p_db_imp)->db_dir_name)
data/opensm-3.3.23/opensm/osm_db_files.c:230:8:  [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).
	    + strlen(domain_name) + 2;
data/opensm-3.3.23/opensm/osm_db_files.c:321:35:  [1] (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 character.
	       ((before_key == FALSE) && strcpy(sLine, "\n"))
data/opensm-3.3.23/opensm/osm_db_files.c:344: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).
					       (strlen(p_first_word) + 1));
data/opensm-3.3.23/opensm/osm_db_files.c:350:11:  [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).
					    (strlen(p_rest_of_line) + 1));
data/opensm-3.3.23/opensm/osm_db_files.c:354:6:  [1] (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 character.
					strcpy(p_accum_val, "\0");
data/opensm-3.3.23/opensm/osm_db_files.c:415:26:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
				p_accum_val = malloc(strlen(p_prev_val) +
data/opensm-3.3.23/opensm/osm_db_files.c:416:12:  [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).
						     strlen(sLine) + 1);
data/opensm-3.3.23/opensm/osm_db_files.c:458: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).
				 (strlen(p_domain_imp->file_name) + 8));
data/opensm-3.3.23/opensm/osm_db_files.c:602:38:  [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).
		p_new_key = malloc(sizeof(char) * (strlen(p_key) + 1));
data/opensm-3.3.23/opensm/osm_db_files.c:607:37:  [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).
	p_new_val = malloc(sizeof(char) * (strlen(p_val) + 1));
data/opensm-3.3.23/opensm/osm_db_pack.c:69:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(lids_str, p_lid_str, 23);
data/opensm-3.3.23/opensm/osm_db_pack.c:114:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(tmp_str, p_str, 23);
data/opensm-3.3.23/opensm/osm_mesh.c:256:9:  [1] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source is a constant character.
			p += sprintf(p, "x");
data/opensm-3.3.23/opensm/osm_mesh.c:1590:7:  [1] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source is a constant character.
		n = sprintf(buf, "[");
data/opensm-3.3.23/opensm/osm_perfmgr.c:2018: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).
		if (nodename + strlen(nodename) != end)
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:706: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).
		last_reset[strlen(last_reset) - 1] = '\0';	/* remove \n */
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:707: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).
		last_err_update[strlen(last_err_update) - 1] = '\0';	/* remove \n */
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:708: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).
		last_data_update[strlen(last_data_update) - 1] = '\0';	/* remove \n */
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:804: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).
		if (port + strlen(port) == end && p >= i && p < num_ports) {
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:822: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).
		last_reset[strlen(last_reset) - 1] = '\0';	/* remove \n */
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:823: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).
		last_err_update[strlen(last_err_update) - 1] = '\0';	/* remove \n */
data/opensm-3.3.23/opensm/osm_perfmgr_db.c:824: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).
		last_data_update[strlen(last_data_update) - 1] = '\0';	/* remove \n */
data/opensm-3.3.23/opensm/osm_prtn.c:84:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(p->name, name, sizeof(p->name) - 1);
data/opensm-3.3.23/opensm/osm_prtn_config.c:288:12:  [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 len = strlen(flag);
data/opensm-3.3.23/opensm/osm_prtn_config.c:313:37:  [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).
	} else if (!strncmp(flag, "Q_Key", strlen(flag))) {
data/opensm-3.3.23/opensm/osm_prtn_config.c:320:38:  [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).
	} else if (!strncmp(flag, "TClass", strlen(flag))) {
data/opensm-3.3.23/opensm/osm_prtn_config.c:362:12:  [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 len = strlen(flag);
data/opensm-3.3.23/opensm/osm_prtn_config.c:372:40:  [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 (!val || (strncmp(val, "limited", strlen(val))
data/opensm-3.3.23/opensm/osm_prtn_config.c:373: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).
			     && strncmp(val, "both", strlen(val))
data/opensm-3.3.23/opensm/osm_prtn_config.c:374: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).
			     && strncmp(val, "full", strlen(val))))
data/opensm-3.3.23/opensm/osm_prtn_config.c:380: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 (!strncmp(val, "full", strlen(val)))
data/opensm-3.3.23/opensm/osm_prtn_config.c:382:35:  [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).
			else if (!strncmp(val, "both", strlen(val)))
data/opensm-3.3.23/opensm/osm_prtn_config.c:470: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).
	if (!name || !*name || !strncmp(name, "NONE", strlen(name)))
data/opensm-3.3.23/opensm/osm_prtn_config.c:476: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 (!strncmp(flag, "full", strlen(flag)))
data/opensm-3.3.23/opensm/osm_prtn_config.c:478:35:  [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).
		else if (!strncmp(flag, "both", strlen(flag)))
data/opensm-3.3.23/opensm/osm_prtn_config.c:480:37:  [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).
		else if (strncmp(flag, "limited", strlen(flag))) {
data/opensm-3.3.23/opensm/osm_prtn_config.c:488: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).
	if (!strncmp(name, "ALL", strlen(name)))
data/opensm-3.3.23/opensm/osm_prtn_config.c:490:37:  [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).
	else if (!strncmp(name, "ALL_CAS", strlen(name)))
data/opensm-3.3.23/opensm/osm_prtn_config.c:492: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).
	else if (!strncmp(name, "ALL_SWITCHES", strlen(name)))
data/opensm-3.3.23/opensm/osm_prtn_config.c:495: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).
	else if (!strncmp(name, "ALL_ROUTERS", strlen(name)))
data/opensm-3.3.23/opensm/osm_prtn_config.c:498:34:  [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).
	else if (!strncmp(name, "SELF", strlen(name))) {
data/opensm-3.3.23/opensm/osm_prtn_config.c:524: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).
#define STRIP_TAIL_SPACES(p) { char *q = (p) + strlen(p); \
data/opensm-3.3.23/opensm/osm_prtn_config.c:545:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	len = strlen(str) + 1;
data/opensm-3.3.23/opensm/osm_prtn_config.c:548:10:  [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).
	q = p + strlen(p);
data/opensm-3.3.23/opensm/osm_prtn_config.c:561:10:  [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).
	q = p + strlen(p);
data/opensm-3.3.23/opensm/osm_sa.c:1079: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).
	p += strlen(name); \
data/opensm-3.3.23/opensm/osm_subnet.c:573:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(buf, p_val_str, 511);
data/opensm-3.3.23/opensm/osm_subnet.c:1701:12:  [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).
	p = val + strlen(val) - 1;
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:300:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		if ((strlen(buffer[ind]) + 10) > FTREE_TUPLE_BUFF_LEN)
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:303:4:  [1] (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 character.
			strcat(buffer[ind], ".");
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:304:24:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		sprintf(&buffer[ind][strlen(buffer[ind])], "%u", tuple[i]);
data/opensm-3.3.23/opensm/osm_ucast_ftree.c:505: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(buff + strlen(buff), "%u", p_port->port_num);
data/opensm-3.3.23/osmroutingplugin/src/osmroutingplugin.c:278:40:  [1] (buffer) mismatch:
  Function does not check the second iterator for over-read conditions
  (CWE-126). This function is often discouraged by most C++ coding standards
  in favor of its safer alternatives provided since C++14. Consider using a
  form of this function that checks the second iterator before potentially
  overflowing it.
#error OpenSM plugin interface version mismatch
data/opensm-3.3.23/osmtest/main.c:359:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			if (strlen(optarg) > OSMTEST_FILE_PATH_MAX)
data/opensm-3.3.23/osmtest/main.c:372:8:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			if (strlen(optarg) > OSMTEST_FILE_PATH_MAX)
data/opensm-3.3.23/osmtest/osmt_inform.c:99:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(p_qp_ctx->qp_bind_hndl.hca_id, hca_id, sizeof(hca_id));
data/opensm-3.3.23/osmtest/osmt_mtl_regular_qp.c:439:3:  [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(poll_sleep);
data/opensm-3.3.23/osmtest/osmt_service.c:95:10:  [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).
	       (strlen(service_name) + 1) * sizeof(char));
data/opensm-3.3.23/osmtest/osmt_service.c:204:10:  [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).
	       (strlen(service_name) + 1) * sizeof(char));
data/opensm-3.3.23/osmtest/osmt_service.c:339:10:  [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).
	       (strlen(service_name) + 1) * sizeof(char));
data/opensm-3.3.23/osmtest/osmt_service.c:497:10:  [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).
	       (strlen(sr_name) + 1) * sizeof(char));
data/opensm-3.3.23/osmtest/osmt_service.c:526:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(mad_stat_err,
data/opensm-3.3.23/osmtest/osmt_service.c:532:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(mad_stat_err, ib_get_err_str(status),
data/opensm-3.3.23/osmtest/osmt_service.c:762:10:  [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).
	       (strlen(sr_name) + 1) * sizeof(char));
data/opensm-3.3.23/osmtest/osmt_service.c:793:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(mad_stat_err,
data/opensm-3.3.23/osmtest/osmt_service.c:799:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(mad_stat_err, ib_get_err_str(status),
data/opensm-3.3.23/osmtest/osmt_service.c:892: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).
	memcpy(service_name, sr_name, (strlen(sr_name) + 1) * sizeof(char));
data/opensm-3.3.23/osmtest/osmt_service.c:1128:10:  [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).
	       (strlen(sr_name) + 1) * sizeof(char));
data/opensm-3.3.23/osmtest/osmt_service.c:1334:2:  [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(100);
data/opensm-3.3.23/osmtest/osmtest.c:7280:8:  [1] (buffer) scanf:
  It's unclear if the %s limit in the format string is small enough
  (CWE-120). Check that the limit is sufficiently small, or use a different
  input function.
			if (scanf("%255s", junk) <= 0)

ANALYSIS SUMMARY:

Hits = 829
Lines analyzed = 178786 in approximately 4.25 seconds (42066 lines/second)
Physical Source Lines of Code (SLOC) = 97385
Hits@level = [0] 794 [1]  96 [2] 608 [3]  21 [4] 103 [5]   1
Hits@level+ = [0+] 1623 [1+] 829 [2+] 733 [3+] 125 [4+] 104 [5+]   1
Hits/KSLOC@level+ = [0+] 16.6658 [1+] 8.5126 [2+] 7.52683 [3+] 1.28357 [4+] 1.06793 [5+] 0.0102685
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.