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/freeradius-3.0.21+dfsg/doc/source/extra/client.c Examining data/freeradius-3.0.21+dfsg/doc/source/extra/core.c Examining data/freeradius-3.0.21+dfsg/doc/source/extra/module.c Examining data/freeradius-3.0.21+dfsg/doc/source/extra/toc.c Examining data/freeradius-3.0.21+dfsg/scripts/jlibtool.c Examining data/freeradius-3.0.21+dfsg/src/include/atomic_queue.h Examining data/freeradius-3.0.21+dfsg/src/include/automask.h Examining data/freeradius-3.0.21+dfsg/src/include/base64.h Examining data/freeradius-3.0.21+dfsg/src/include/build.h Examining data/freeradius-3.0.21+dfsg/src/include/channel.h Examining data/freeradius-3.0.21+dfsg/src/include/clients.h Examining data/freeradius-3.0.21+dfsg/src/include/conf.h Examining data/freeradius-3.0.21+dfsg/src/include/conffile.h Examining data/freeradius-3.0.21+dfsg/src/include/connection.h Examining data/freeradius-3.0.21+dfsg/src/include/detail.h Examining data/freeradius-3.0.21+dfsg/src/include/dhcp.h Examining data/freeradius-3.0.21+dfsg/src/include/event.h Examining data/freeradius-3.0.21+dfsg/src/include/exfile.h Examining data/freeradius-3.0.21+dfsg/src/include/hash.h Examining data/freeradius-3.0.21+dfsg/src/include/heap.h Examining data/freeradius-3.0.21+dfsg/src/include/libradius.h Examining data/freeradius-3.0.21+dfsg/src/include/listen.h Examining data/freeradius-3.0.21+dfsg/src/include/log.h Examining data/freeradius-3.0.21+dfsg/src/include/map.h Examining data/freeradius-3.0.21+dfsg/src/include/md4.h Examining data/freeradius-3.0.21+dfsg/src/include/md5.h Examining data/freeradius-3.0.21+dfsg/src/include/modcall.h Examining data/freeradius-3.0.21+dfsg/src/include/modpriv.h Examining data/freeradius-3.0.21+dfsg/src/include/modules.h Examining data/freeradius-3.0.21+dfsg/src/include/net.h Examining data/freeradius-3.0.21+dfsg/src/include/packet.h Examining data/freeradius-3.0.21+dfsg/src/include/parser.h Examining data/freeradius-3.0.21+dfsg/src/include/pcap.h Examining data/freeradius-3.0.21+dfsg/src/include/process.h Examining data/freeradius-3.0.21+dfsg/src/include/protocol.h Examining data/freeradius-3.0.21+dfsg/src/include/rad_assert.h Examining data/freeradius-3.0.21+dfsg/src/include/radclient.h Examining data/freeradius-3.0.21+dfsg/src/include/radius.h Examining data/freeradius-3.0.21+dfsg/src/include/radiusd.h Examining data/freeradius-3.0.21+dfsg/src/include/radsniff.h Examining data/freeradius-3.0.21+dfsg/src/include/radutmp.h Examining data/freeradius-3.0.21+dfsg/src/include/realms.h Examining data/freeradius-3.0.21+dfsg/src/include/regex.h Examining data/freeradius-3.0.21+dfsg/src/include/sha1.h Examining data/freeradius-3.0.21+dfsg/src/include/soh.h Examining data/freeradius-3.0.21+dfsg/src/include/state.h Examining data/freeradius-3.0.21+dfsg/src/include/stats.h Examining data/freeradius-3.0.21+dfsg/src/include/stdatomic.h Examining data/freeradius-3.0.21+dfsg/src/include/sysutmp.h Examining data/freeradius-3.0.21+dfsg/src/include/tcp.h Examining data/freeradius-3.0.21+dfsg/src/include/threads.h Examining data/freeradius-3.0.21+dfsg/src/include/tmpl.h Examining data/freeradius-3.0.21+dfsg/src/include/token.h Examining data/freeradius-3.0.21+dfsg/src/include/udpfromto.h Examining data/freeradius-3.0.21+dfsg/src/include/xlat.h Examining data/freeradius-3.0.21+dfsg/src/lib/atomic_queue.c Examining data/freeradius-3.0.21+dfsg/src/lib/base64.c Examining data/freeradius-3.0.21+dfsg/src/lib/cbuff.c Examining data/freeradius-3.0.21+dfsg/src/lib/cursor.c Examining data/freeradius-3.0.21+dfsg/src/lib/debug.c Examining data/freeradius-3.0.21+dfsg/src/lib/dict.c Examining data/freeradius-3.0.21+dfsg/src/lib/event.c Examining data/freeradius-3.0.21+dfsg/src/lib/fifo.c Examining data/freeradius-3.0.21+dfsg/src/lib/filters.c Examining data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c Examining data/freeradius-3.0.21+dfsg/src/lib/hash.c Examining data/freeradius-3.0.21+dfsg/src/lib/heap.c Examining data/freeradius-3.0.21+dfsg/src/lib/hmacmd5.c Examining data/freeradius-3.0.21+dfsg/src/lib/hmacsha1.c Examining data/freeradius-3.0.21+dfsg/src/lib/isaac.c Examining data/freeradius-3.0.21+dfsg/src/lib/log.c Examining data/freeradius-3.0.21+dfsg/src/lib/md4.c Examining data/freeradius-3.0.21+dfsg/src/lib/md5.c Examining data/freeradius-3.0.21+dfsg/src/lib/misc.c Examining data/freeradius-3.0.21+dfsg/src/lib/missing.c Examining data/freeradius-3.0.21+dfsg/src/lib/net.c Examining data/freeradius-3.0.21+dfsg/src/lib/packet.c Examining data/freeradius-3.0.21+dfsg/src/lib/pair.c Examining data/freeradius-3.0.21+dfsg/src/lib/pcap.c Examining data/freeradius-3.0.21+dfsg/src/lib/print.c Examining data/freeradius-3.0.21+dfsg/src/lib/radius.c Examining data/freeradius-3.0.21+dfsg/src/lib/rbtree.c Examining data/freeradius-3.0.21+dfsg/src/lib/regex.c Examining data/freeradius-3.0.21+dfsg/src/lib/sha1.c Examining data/freeradius-3.0.21+dfsg/src/lib/snprintf.c Examining data/freeradius-3.0.21+dfsg/src/lib/snprintf.h Examining data/freeradius-3.0.21+dfsg/src/lib/socket.c Examining data/freeradius-3.0.21+dfsg/src/lib/strlcat.c Examining data/freeradius-3.0.21+dfsg/src/lib/strlcpy.c Examining data/freeradius-3.0.21+dfsg/src/lib/tcp.c Examining data/freeradius-3.0.21+dfsg/src/lib/token.c Examining data/freeradius-3.0.21+dfsg/src/lib/udpfromto.c Examining data/freeradius-3.0.21+dfsg/src/lib/value.c Examining data/freeradius-3.0.21+dfsg/src/lib/version.c Examining data/freeradius-3.0.21+dfsg/src/main/acct.c Examining data/freeradius-3.0.21+dfsg/src/main/auth.c Examining data/freeradius-3.0.21+dfsg/src/main/cb.c Examining data/freeradius-3.0.21+dfsg/src/main/channel.c Examining data/freeradius-3.0.21+dfsg/src/main/client.c Examining data/freeradius-3.0.21+dfsg/src/main/collectd.c Examining data/freeradius-3.0.21+dfsg/src/main/command.c Examining data/freeradius-3.0.21+dfsg/src/main/conffile.c Examining data/freeradius-3.0.21+dfsg/src/main/connection.c Examining data/freeradius-3.0.21+dfsg/src/main/crypt.c Examining data/freeradius-3.0.21+dfsg/src/main/detail.c Examining data/freeradius-3.0.21+dfsg/src/main/evaluate.c Examining data/freeradius-3.0.21+dfsg/src/main/exec.c Examining data/freeradius-3.0.21+dfsg/src/main/exfile.c Examining data/freeradius-3.0.21+dfsg/src/main/files.c Examining data/freeradius-3.0.21+dfsg/src/main/listen.c Examining data/freeradius-3.0.21+dfsg/src/main/log.c Examining data/freeradius-3.0.21+dfsg/src/main/mainconfig.c Examining data/freeradius-3.0.21+dfsg/src/main/map.c Examining data/freeradius-3.0.21+dfsg/src/main/modcall.c Examining data/freeradius-3.0.21+dfsg/src/main/modules.c Examining data/freeradius-3.0.21+dfsg/src/main/pair.c Examining data/freeradius-3.0.21+dfsg/src/main/parser.c Examining data/freeradius-3.0.21+dfsg/src/main/process.c Examining data/freeradius-3.0.21+dfsg/src/main/radattr.c Examining data/freeradius-3.0.21+dfsg/src/main/radclient.c Examining data/freeradius-3.0.21+dfsg/src/main/radmin.c Examining data/freeradius-3.0.21+dfsg/src/main/radsniff.c Examining data/freeradius-3.0.21+dfsg/src/main/radwho.c Examining data/freeradius-3.0.21+dfsg/src/main/realms.c Examining data/freeradius-3.0.21+dfsg/src/main/regex.c Examining data/freeradius-3.0.21+dfsg/src/main/session.c Examining data/freeradius-3.0.21+dfsg/src/main/soh.c Examining data/freeradius-3.0.21+dfsg/src/main/state.c Examining data/freeradius-3.0.21+dfsg/src/main/stats.c Examining data/freeradius-3.0.21+dfsg/src/main/threads.c Examining data/freeradius-3.0.21+dfsg/src/main/tls.c Examining data/freeradius-3.0.21+dfsg/src/main/tls_listen.c Examining data/freeradius-3.0.21+dfsg/src/main/tmpl.c Examining data/freeradius-3.0.21+dfsg/src/main/unittest.c Examining data/freeradius-3.0.21+dfsg/src/main/util.c Examining data/freeradius-3.0.21+dfsg/src/main/version.c Examining data/freeradius-3.0.21+dfsg/src/main/xlat.c Examining data/freeradius-3.0.21+dfsg/src/main/radiusd.c Examining data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c Examining data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcpclient.c Examining data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcpd.c Examining data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/rlm_dhcp.c Examining data/freeradius-3.0.21+dfsg/src/modules/proto_vmps/vmps.c Examining data/freeradius-3.0.21+dfsg/src/modules/proto_vmps/vqp.c Examining data/freeradius-3.0.21+dfsg/src/modules/proto_vmps/vqp.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_always/rlm_always.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_attr_filter/rlm_attr_filter.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_cache/drivers/rlm_cache_memcached/rlm_cache_memcached.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_cache/drivers/rlm_cache_rbtree/rlm_cache_rbtree.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_cache/rlm_cache.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_cache/rlm_cache.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_cache/serialize.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_cache/serialize.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_chap/rlm_chap.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/couchbase.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/couchbase.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/jsonc_missing.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/jsonc_missing.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/mod.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/mod.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/rlm_couchbase.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_cram/rlm_cram.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_date/rlm_date.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_detail/rlm_detail.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_dynamic_clients/rlm_dynamic_clients.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/eap.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/eap.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/comp128.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/comp128.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eap_chbind.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eap_chbind.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eap_sim.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eap_tls.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eap_tls.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eap_types.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapclient.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcommon.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcrypto.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapsimlib.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/fips186prf.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/mem.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/rlm_eap.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/rlm_eap.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast_crypto.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast_crypto.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/rlm_eap_fast.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_gtc/rlm_eap_gtc.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ikev2/ike_conf.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ikev2/ike_conf.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ikev2/logging_impl.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ikev2/logging_impl.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ikev2/rlm_eap_ikev2.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/rlm_eap_leap.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_md5/eap_md5.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_md5/eap_md5.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_md5/rlm_eap_md5.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/eap_mschapv2.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_peap/eap_peap.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_peap/peap.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_peap/rlm_eap_peap.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/eap_pwd.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/eap_pwd.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_tls/rlm_eap_tls.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_tls/rlm_eap_tls.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_tnc/rlm_eap_tnc.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/eap_ttls.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/rlm_eap_ttls.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_example/other.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_example/other.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_example/rlm_example.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_exec/rlm_exec.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_expiration/rlm_expiration.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/paircmp.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_files/rlm_files.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_idn/rlm_idn.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_krb5/krb5.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_krb5/krb5.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_krb5/rlm_krb5.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/attrmap.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/clients.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/edir.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/groups.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/ldap.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/ldap.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/sasl.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_linelog/rlm_linelog.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/rlm_logintime.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/timestr.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/auth_wbclient.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/auth_wbclient.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/mschap.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/mschap.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbencrypt.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_opendirectory/rlm_opendirectory.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/extern.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pw_valid.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pw_valid.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pwe.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_radstate.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_util.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/rlm_otp.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_pam/rlm_pam.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_pap/rlm_pap.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_passwd/rlm_passwd.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_perl/rlm_perl.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_preprocess/rlm_preprocess.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_python/rlm_python.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_python3/rlm_python3.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_python3/rlm_python3.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_radutmp/rlm_radutmp.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_realm/rlm_realm.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_realm/trustrouter.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_realm/trustrouter.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_redis/rlm_redis.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_redis/rlm_redis.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_rediswho/rlm_rediswho.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_replicate/rlm_replicate.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rest.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rest.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rlm_rest.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_ruby/rlm_ruby.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_securid/mem.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_securid/rlm_securid.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_securid/rlm_securid.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_smsotp/rlm_smsotp.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_soh/rlm_soh.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sometimes/rlm_sometimes.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_db2/rlm_sql_db2.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/rlm_sql_firebird.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_freetds/rlm_sql_freetds.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_iodbc/rlm_sql_iodbc.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_mongo/rlm_sql_mongo.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_mysql/rlm_sql_mysql.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_null/rlm_sql_null.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_oracle/rlm_sql_oracle.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_postgresql/rlm_sql_postgresql.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_postgresql/sql_postgresql.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_sqlite/rlm_sql_sqlite.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_unixodbc/rlm_sql_unixodbc.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/rlm_sql.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/rlm_sql.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/sql.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlhpwippool/rlm_sqlhpwippool.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlippool/rlm_sqlippool.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_test/rlm_test.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_unix/rlm_unix.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_unpack/rlm_unpack.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_utf8/rlm_utf8.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_wimax/rlm_wimax.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_yubikey/decrypt.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_yubikey/rlm_yubikey.c Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_yubikey/rlm_yubikey.h Examining data/freeradius-3.0.21+dfsg/src/modules/rlm_yubikey/validate.c Examining data/freeradius-3.0.21+dfsg/src/tests/map/map_unit.c Examining data/freeradius-3.0.21+dfsg/src/tests/rbmonkey.c FINAL RESULTS: data/freeradius-3.0.21+dfsg/src/main/command.c:249: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, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP) < 0) { data/freeradius-3.0.21+dfsg/src/main/tls.c:3650:7: [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(conf->verify_tmp_dir, S_IRWXU) < 0) { data/freeradius-3.0.21+dfsg/src/modules/rlm_detail/rlm_detail.c:406:7: [5] (race) chown: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchown( ) instead. if (chown(buffer, -1, gid) == -1) { data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/rlm_eap.c:424:19: [5] (race) chmod: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchmod( ) instead. if (vp) (void) chmod(vp->vp_strvalue, S_IRUSR | S_IWUSR); data/freeradius-3.0.21+dfsg/src/modules/rlm_linelog/rlm_linelog.c:272:7: [5] (race) chown: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchown( ) instead. if (chown(path, -1, gid) == -1) { data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:221:48: [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 DEBUG(fmt, ...) if(cmd->options.debug) printf(fmt, ## __VA_ARGS__) data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:222:51: [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 NOTICE(fmt, ...) if(!cmd->options.silent) printf(fmt, ## __VA_ARGS__) data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:223:25: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. #define ERROR(fmt, ...) fprintf(stderr, fmt, ## __VA_ARGS__) data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:376:12: [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. static int vsnprintf(char *str, size_t n, char const *fmt, va_list ap) data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:390:8: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. res = vfprintf(f, fmt, ap); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:393:9: [4] (format) vsprintf: Potential format string problem (CWE-134). Make format string constant. res = vsprintf( str, fmt, ap ); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:398:12: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. static int snprintf(char *str, size_t n, char const *fmt, ...) data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:404:8: [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. res = vsnprintf(str, n, fmt, ap); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:514: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(newval, cc->vals[i]); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:584:11: [4] (shell) execvp: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. return execvp(argv[0], (char**)argv); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:652:57: [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 printc(_x,_y) if (!value || !strcmp(value, _x)) printf(_x "=\"%s\"\n", _y) data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:725: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(value, equal_pos + 1); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:876: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(newname, newname + 4); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:881: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(newname + 8, strchr(newname, '.')); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1048: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(newarg, file_name(name)); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1051: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(newarg, name); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1065: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(newext, STATIC_LIB_EXT); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1068: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(newext, DYNAMIC_LIB_EXT); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1071: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(newext, MODULE_LIB_EXT); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1113: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(ext, OBJECT_EXT); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1136: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(newarg, arg); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1145: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(newarg + newpathlen, arg + pathlen); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1164: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(ext, DYNAMIC_LIB_EXT); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1171: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(ext, STATIC_LIB_EXT); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1175: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(ext, MODULE_LIB_EXT); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1179: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(ext, OBJECT_EXT); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1237: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(newarg, arg); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1305: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(tmp, LINKER_FLAG_PREFIX); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1306:2: [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(tmp, RPATH); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1308: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(tmp, RPATH); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1313:2: [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(tmp, path); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1370: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(exp_argument, install_path); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1375: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(exp_argument+cur_len, DYNAMIC_LIB_EXT); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1378: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(exp_argument+cur_len, current_path); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1383: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(exp_argument+cur_len, DYNAMIC_LIB_EXT); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1409: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(newarg, file); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1425: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(newarg, LINKER_FLAG_PREFIX); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1426:2: [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(newarg, arg); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1666: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(tmp, arg); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1706: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(newarg, arg); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1709: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(newarg, EXE_EXT); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1735: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(newname, cmd->static_name.normal); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1771: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(newname, cmd->static_name.normal); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1803: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(newname, cmd->shared_name.normal); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1824: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(newarg, arg); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1826: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(newext, OBJECT_EXT); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1884: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(def_file, cmd->output_name); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1900: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(cmd, GEN_EXPORTS); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1904: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(cmd, cmd->obj_files[a] ); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1908: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(cmd, def_file); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1923: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(implib_file, cmd->basename); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1931: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(implib_file, STATIC_LIB_EXT); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1950: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(newpath, foo); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1952:2: [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(newpath, relpath); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1989: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(tmp, cmd->install_path); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1992:6: [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(tmp, strrchr(cmd->shared_name.install, '/')); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1994:6: [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(tmp, strrchr(cmd->shared_name.normal, '/')); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:2240: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(libpath, cmd->arglist->vals[0]); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:2292: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(fullname, dirname); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:2294: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(fullname, entry->d_name); data/freeradius-3.0.21+dfsg/src/include/build.h:136:45: [4] (shell) system: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. # error Failed determining endianness of system data/freeradius-3.0.21+dfsg/src/include/conffile.h:281:77: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. void cf_log_err(CONF_ITEM const *ci, char const *fmt, ...) CC_HINT(format (printf, 2, 3)); data/freeradius-3.0.21+dfsg/src/include/conffile.h:282:82: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. void cf_log_err_cs(CONF_SECTION const *cs, char const *fmt, ...) CC_HINT(format (printf, 2, 3)); data/freeradius-3.0.21+dfsg/src/include/conffile.h:283:80: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. void cf_log_err_cp(CONF_PAIR const *cp, char const *fmt, ...) CC_HINT(format (printf, 2, 3)); data/freeradius-3.0.21+dfsg/src/include/conffile.h:284:81: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. void cf_log_info(CONF_SECTION const *cs, char const *fmt, ...) CC_HINT(format (printf, 2, 3)); data/freeradius-3.0.21+dfsg/src/include/conffile.h:285:82: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. void cf_log_module(CONF_SECTION const *cs, char const *fmt, ...) CC_HINT(format (printf, 2, 3)); data/freeradius-3.0.21+dfsg/src/include/libradius.h:165:40: [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 PRINTF_LIKE(n) CC_HINT(format(printf, n, n+1)) data/freeradius-3.0.21+dfsg/src/include/libradius.h:634:84: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. void fr_pair_value_sprintf(VALUE_PAIR *vp, char const * fmt, ...) CC_HINT(format (printf, 2, 3)); data/freeradius-3.0.21+dfsg/src/include/libradius.h:687:61: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. void fr_strerror_printf(char const *, ...) CC_HINT(format (printf, 1, 2)); data/freeradius-3.0.21+dfsg/src/include/libradius.h:688:52: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. void fr_perror(char const *, ...) CC_HINT(format (printf, 1, 2)); data/freeradius-3.0.21+dfsg/src/include/libradius.h:702: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. void fr_printf_log(char const *, ...) CC_HINT(format (printf, 1, 2)); data/freeradius-3.0.21+dfsg/src/include/libradius.h:814:70: [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. typedef void (*fr_fault_log_t)(char const *msg, ...) CC_HINT(format (printf, 1, 2)); data/freeradius-3.0.21+dfsg/src/include/libradius.h:846:58: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. void fr_fault_log(char const *msg, ...) CC_HINT(format (printf, 1, 2)); data/freeradius-3.0.21+dfsg/src/include/log.h:85:18: [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. CC_HINT(format (printf, 2, 0)) CC_HINT(nonnull); data/freeradius-3.0.21+dfsg/src/include/log.h:87:18: [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. CC_HINT(format (printf, 2, 3)) CC_HINT(nonnull (2)); data/freeradius-3.0.21+dfsg/src/include/log.h:97:18: [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. CC_HINT(format (printf, 4, 0)) CC_HINT(nonnull (3, 4)); data/freeradius-3.0.21+dfsg/src/include/log.h:100:18: [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. CC_HINT(format (printf, 4, 5)) CC_HINT(nonnull (3, 4)); data/freeradius-3.0.21+dfsg/src/include/log.h:103:18: [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. CC_HINT(format (printf, 4, 5)) CC_HINT(nonnull (3, 4)); data/freeradius-3.0.21+dfsg/src/include/radclient.h:36:63: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. #define DEBUG(fmt, ...) if (do_output && (fr_debug_lvl > 0)) fprintf(fr_log_fp, fmt "\n", ## __VA_ARGS__) data/freeradius-3.0.21+dfsg/src/include/radclient.h:38:63: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. #define DEBUG2(fmt, ...) if (do_output && (fr_debug_lvl > 1)) fprintf(fr_log_fp, fmt "\n", ## __VA_ARGS__) data/freeradius-3.0.21+dfsg/src/include/radiusd.h:514:81: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. void module_failure_msg(REQUEST *request, char const *fmt, ...) CC_HINT(format (printf, 2, 3)); data/freeradius-3.0.21+dfsg/src/include/radiusd.h:515:89: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. void vmodule_failure_msg(REQUEST *request, char const *fmt, va_list ap) CC_HINT(format (printf, 2, 0)); data/freeradius-3.0.21+dfsg/src/include/radsniff.h:50:48: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. #define DEBUG2(fmt, ...) if (fr_debug_lvl > 2) fprintf(fr_log_fp , fmt "\n", ## __VA_ARGS__) data/freeradius-3.0.21+dfsg/src/include/radsniff.h:52:48: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. #define DEBUG(fmt, ...) if (fr_debug_lvl > 1) fprintf(fr_log_fp , fmt "\n", ## __VA_ARGS__) data/freeradius-3.0.21+dfsg/src/include/radsniff.h:54:47: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. #define INFO(fmt, ...) if (fr_debug_lvl > 0) fprintf(fr_log_fp , fmt "\n", ## __VA_ARGS__) data/freeradius-3.0.21+dfsg/src/lib/debug.c:791:10: [4] (shell) system: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. code = system(cmd); data/freeradius-3.0.21+dfsg/src/lib/dict.c:559: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(dv->name, name); data/freeradius-3.0.21+dfsg/src/lib/dict.c:1196: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(dval->name, namestr); data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:90: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(ptr, from->h_name); data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:102: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(ptr, from->h_aliases[i]); data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:393: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(serv, tmpserv); data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:401: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(host, inet_ntoa(sin->sin_addr)); data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:425: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(host, hp->h_name); data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:432: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(host, inet_ntoa(sin->sin_addr)); data/freeradius-3.0.21+dfsg/src/lib/log.c:204:3: [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(buffer + FR_STRERROR_BUFSIZE, FR_STRERROR_BUFSIZE, fmt, ap); data/freeradius-3.0.21+dfsg/src/lib/log.c:209:3: [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(buffer, FR_STRERROR_BUFSIZE, fmt, ap); data/freeradius-3.0.21+dfsg/src/lib/log.c:333:2: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. vfprintf(stderr, fmt, ap); data/freeradius-3.0.21+dfsg/src/lib/missing.c:31:7: [4] (crypto) crypt: The crypt functions use a poor one-way hashing algorithm; since they only accept passwords of 8 characters or fewer and only a two-byte salt, they are excessively vulnerable to dictionary attacks given today's faster computing equipment (CWE-327). Use a different algorithm, such as SHA-256, with a larger, non-repeating salt. char *crypt(UNUSED char *key, char *salt) data/freeradius-3.0.21+dfsg/src/lib/missing.c:169: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(l_buf, ctime(l_clock)); data/freeradius-3.0.21+dfsg/src/lib/missing.c:210:8: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. ret = vfprintf(fp, format, args); data/freeradius-3.0.21+dfsg/src/lib/radius.c:45:18: [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 VP_TRACE printf data/freeradius-3.0.21+dfsg/src/lib/radius.c:160:2: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. vfprintf(fr_log_fp, fmt, ap); data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:501:1: [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(char *string, size_t length, char const * format, va_list args) data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:503:1: [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(string, length, format, args) data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:684:1: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. snprintf(char *string, size_t length, char const * format, ...) data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:686:1: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. snprintf(string, length, format, va_alist) data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:702:9: [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. rval = vsnprintf (string, length, format, args); data/freeradius-3.0.21+dfsg/src/lib/token.c:198: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(buf, t->name); data/freeradius-3.0.21+dfsg/src/lib/value.c:851:7: [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 the scanf format is influenceable by an attacker, it's exploitable. if (sscanf(src, "%" PRIu64, &i) != 1) { data/freeradius-3.0.21+dfsg/src/lib/value.c:1812:10: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. return snprintf(out, outlen, "%" PRIu64, data->integer64); data/freeradius-3.0.21+dfsg/src/main/cb.c:152: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(buf, (char *)userdata); data/freeradius-3.0.21+dfsg/src/main/command.c:698:32: [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. static ssize_t CC_HINT(format (printf, 2, 3)) cprintf(rad_listen_t *listener, char const *fmt, ...) data/freeradius-3.0.21+dfsg/src/main/command.c:705:8: [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. len = vsnprintf(buffer, sizeof(buffer), fmt, ap); data/freeradius-3.0.21+dfsg/src/main/command.c:719:32: [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. static ssize_t CC_HINT(format (printf, 2, 3)) cprintf_error(rad_listen_t *listener, char const *fmt, ...) data/freeradius-3.0.21+dfsg/src/main/command.c:726:8: [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. len = vsnprintf(buffer, sizeof(buffer), fmt, ap); data/freeradius-3.0.21+dfsg/src/main/conffile.c:1143: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, mycs->name1); data/freeradius-3.0.21+dfsg/src/main/conffile.c:1147: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, mycs->name2 ? mycs->name2 : mycs->name1); data/freeradius-3.0.21+dfsg/src/main/conffile.c:1189: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, cp->value); data/freeradius-3.0.21+dfsg/src/main/conffile.c:1276: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, env); data/freeradius-3.0.21+dfsg/src/main/conffile.c:3711: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(buffer, sizeof(buffer), fmt, ap); data/freeradius-3.0.21+dfsg/src/main/conffile.c:3730: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(buffer, sizeof(buffer), fmt, ap); data/freeradius-3.0.21+dfsg/src/main/conffile.c:3747: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(buffer, sizeof(buffer), fmt, ap); data/freeradius-3.0.21+dfsg/src/main/conffile.c:3777:3: [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(buffer, sizeof(buffer), fmt, ap); data/freeradius-3.0.21+dfsg/src/main/crypt.c:64:11: [4] (crypto) crypt: The crypt functions use a poor one-way hashing algorithm; since they only accept passwords of 8 characters or fewer and only a two-byte salt, they are excessively vulnerable to dictionary attacks given today's faster computing equipment (CWE-327). Use a different algorithm, such as SHA-256, with a larger, non-repeating salt. passwd = crypt(key, crypted); data/freeradius-3.0.21+dfsg/src/main/evaluate.c:35:49: [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 EVAL_DEBUG(fmt, ...) printf("EVAL: ");printf(fmt, ## __VA_ARGS__);printf("\n");fflush(stdout) data/freeradius-3.0.21+dfsg/src/main/log.c:430:3: [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(buffer + len, sizeof(buffer) - len - 1, msg, ap); data/freeradius-3.0.21+dfsg/src/main/log.c:550:81: [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. static int radlog_always(log_type_t type, char const *msg, ...) CC_HINT(format (printf, 2, 3)); data/freeradius-3.0.21+dfsg/src/main/log.c:695: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(buffer + len, sizeof(buffer) - len, msg, aq); data/freeradius-3.0.21+dfsg/src/main/modcall.c:2114: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(mx->xlat_name, fmt + 1); data/freeradius-3.0.21+dfsg/src/main/modules.c:216:12: [4] (race) access: This usually indicates a security flaw. If an attacker can change anything along the path between the call to access() and the file's actual use (e.g., by moving files), the attacker can exploit the race condition (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid()) and try to open the file directly. (access(path, R_OK) < 0) ? fr_syserror(errno) : "No access errors"); data/freeradius-3.0.21+dfsg/src/main/session.c:212:2: [4] (shell) execl: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. execl(getenv("COMSPEC"), "", "/C","checkrad", cl->nas_type, address, port, data/freeradius-3.0.21+dfsg/src/main/session.c:215:2: [4] (shell) execl: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. execl(main_config.checkrad, "checkrad", cl->nas_type, address, port, data/freeradius-3.0.21+dfsg/src/main/tls.c:2882:21: [4] (shell) popen: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. FILE* cmd_pipe = popen(cmd, "r"); data/freeradius-3.0.21+dfsg/src/main/util.c:1157: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(&out[0], rwx[(mode >> 6) & 0x07]); data/freeradius-3.0.21+dfsg/src/main/util.c:1158: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(&out[3], rwx[(mode >> 3) & 0x07]); data/freeradius-3.0.21+dfsg/src/main/util.c:1159: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(&out[6], rwx[(mode & 7)]); data/freeradius-3.0.21+dfsg/src/main/xlat.c:145:11: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. return snprintf(out, outlen, "%" PRIu64, htonll(int64)); data/freeradius-3.0.21+dfsg/src/main/xlat.c:152:10: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. return snprintf(out, outlen, "%" PRIu64, vp->vp_integer64); data/freeradius-3.0.21+dfsg/src/main/xlat.c:182:10: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. return snprintf(out, outlen, "%" PRIu64, htonll(int64)); data/freeradius-3.0.21+dfsg/src/main/xlat.c:2137:4: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. snprintf(str, freespace, "%" PRIu64, (uint64_t) time(NULL)); data/freeradius-3.0.21+dfsg/src/main/xlat.c:2177:5: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. snprintf(str, freespace, "%" PRIu64, (uint64_t) tv.tv_usec); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:77: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(stdout, ## __VA_ARGS__); \ data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c:842:3: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(msg, "Your maximum %s usage time has been reached", inst->reset); data/freeradius-3.0.21+dfsg/src/modules/rlm_date/rlm_date.c:103:10: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. return snprintf(out, outlen, "%" PRIu64, (uint64_t) date); data/freeradius-3.0.21+dfsg/src/modules/rlm_detail/rlm_detail.c:237:6: [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. if (fprintf(out, fmt, ## __VA_ARGS__) < 0) {\ data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ikev2/logging_impl.h:34:22: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. void CC_HINT(format (printf, 2, 0)) vxlogf(int iklevel, char const * fmt, va_list ap); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:1217:6: [4] (crypto) crypt_r: The crypt functions use a poor one-way hashing algorithm; since they only accept passwords of 8 characters or fewer and only a two-byte salt, they are excessively vulnerable to dictionary attacks given today's faster computing equipment (CWE-327). Use a different algorithm, such as SHA-256, with a larger, non-repeating salt. p = crypt_r((const char *) pass, (const char *) salt, &cdata); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:1570:9: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. return snprintf(out, outlen, "%" PRIu64, (uint64_t)(mktime(local) - now)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:256: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(entry.cli,cli); data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/timestr.c:43:31: [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 timestr_debug if (0) printf data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pw_valid.c:227:10: [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). (void) strcpy(passcode, otp_reply.passcode); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pw_valid.c:377:9: [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). (void) strcpy(sa.sun_path, path); data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rest.c:559:10: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. len = sprintf(p, "%s=", escaped); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:267:6: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(p, "%*s.%0*lld", field_width - 1 + dscale, data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:392: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(database, config->sql_server); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_sqlite/rlm_sql_sqlite.c:170:18: [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. CC_HINT(format (printf, 3, 4)) CC_HINT(nonnull (3)); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:321:5: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. snprintf(tmpdt, sizeof(tmpdt), "%" PRId64, (int64_t) inst->last_reset); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:327:5: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. snprintf(tmpdt, sizeof(tmpdt), "%" PRId64, (int64_t) inst->reset_time); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:390: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 the scanf format is influenceable by an attacker, it's exploitable. if (sscanf(expanded, "%" PRIu64, &counter) != 1) { data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:585: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 the scanf format is influenceable by an attacker, it's exploitable. if (sscanf(expanded, "%" PRIu64, &counter) != 1) { data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlhpwippool/rlm_sqlhpwippool.c:83:105: [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. int nvp_log(unsigned int line, rlm_sqlhpwippool_t *data, int lvl, char const *fmt, ...) CC_HINT(format (printf, 4, 5)); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlhpwippool/rlm_sqlhpwippool.c:94:2: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. snprintf(pfmt, sizeof(pfmt), RLM_NETVIM_LOG_FMT, data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlhpwippool/rlm_sqlhpwippool.c:109: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(query, MAX_QUERY_LEN, fmt, ap); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlippool/rlm_sqlippool.c:408: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(out, (*handle)->row[0]); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1247:18: [3] (buffer) realpath: This function does not protect against buffer overflows, and some implementations can overflow internally (CWE-120/CWE-785!). Ensure that the destination buffer is at least of size MAXPATHLEN, andto protect against implementation problems, the input argument should also be checked to ensure it is no larger than MAXPATHLEN. expanded_path = realpath(newarg, expanded_path); data/freeradius-3.0.21+dfsg/src/lib/debug.c:1004:9: [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. env = getenv("DEBUG"); data/freeradius-3.0.21+dfsg/src/lib/debug.c:1081:8: [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("TALLOC_FREE_FILL")) mallopt(M_PERTURB, 0x42); data/freeradius-3.0.21+dfsg/src/main/conffile.c:1264:10: [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. env = getenv(name); data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:639:7: [3] (misc) chroot: chroot can be very helpful, but is hard to use correctly (CWE-250, CWE-22). Make sure the program immediately chdir("/"), closes file descriptors, and drops root privileges, and that all necessary files (and no more!) are in the new root. if (chroot(chroot_dir) < 0) { data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:1089: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. p = getenv("TERM"); data/freeradius-3.0.21+dfsg/src/main/modules.c:177:8: [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. env = getenv("FR_LIBRARY_PATH"); data/freeradius-3.0.21+dfsg/src/main/modules.c:225:9: [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. env = getenv("LD_LIBRARY_PATH"); data/freeradius-3.0.21+dfsg/src/main/modules.c:229:9: [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. env = getenv("DYLD_LIBRARY_PATH"); data/freeradius-3.0.21+dfsg/src/main/modules.c:233:9: [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. env = getenv("DYLD_FALLBACK_LIBRARY_PATH"); data/freeradius-3.0.21+dfsg/src/main/modules.c:242:9: [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. env = getenv("LD_LIBRARY_PATH"); data/freeradius-3.0.21+dfsg/src/main/radattr.c:980: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. if (fr_fault_setup(getenv("PANIC_ACTION"), argv[0]) < 0) { data/freeradius-3.0.21+dfsg/src/main/radattr.c:986:14: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. while ((c = getopt(argc, argv, "d:D:xMh")) != EOF) switch (c) { data/freeradius-3.0.21+dfsg/src/main/radclient.c:1171: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. if (fr_fault_setup(getenv("PANIC_ACTION"), argv[0]) < 0) { data/freeradius-3.0.21+dfsg/src/main/radclient.c:1186:14: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. while ((c = getopt(argc, argv, "46c:d:D:f:Fhn:p:qr:sS:t:vx" data/freeradius-3.0.21+dfsg/src/main/radiusd.c:150:19: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. while ((argval = getopt(argc, argv, "Cd:D:fhi:l:mMn:p:PstvxX")) != EOF) { data/freeradius-3.0.21+dfsg/src/main/radiusd.c:363: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. panic_action = getenv("PANIC_ACTION"); data/freeradius-3.0.21+dfsg/src/main/radiusd.c:399: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("NOTIFY_SOCKET")) data/freeradius-3.0.21+dfsg/src/main/radmin.c:356: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. if (fr_fault_setup(getenv("PANIC_ACTION"), argv[0]) < 0) { data/freeradius-3.0.21+dfsg/src/main/radmin.c:370:19: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. while ((argval = getopt(argc, argv, "d:D:hi:e:Ef:n:qs:S")) != EOF) { data/freeradius-3.0.21+dfsg/src/main/radmin.c:594:57: [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. snprintf(history_file, sizeof(history_file), "%s/%s", getenv("HOME"), ".radmin_history"); data/freeradius-3.0.21+dfsg/src/main/radsniff.c:1962: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. if (fr_fault_setup(getenv("PANIC_ACTION"), argv[0]) < 0) { data/freeradius-3.0.21+dfsg/src/main/radsniff.c:2002:16: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. while ((opt = getopt(argc, argv, "ab:c:Cd:D:e:Ff:hi:I:l:L:mp:P:qr:R:s:Svw:xXW:T:P:N:O:")) != EOF) { data/freeradius-3.0.21+dfsg/src/main/radwho.c:219: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. if (fr_fault_setup(getenv("PANIC_ACTION"), argv[0]) < 0) { data/freeradius-3.0.21+dfsg/src/main/radwho.c:227:13: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. while((c = getopt(argc, argv, "d:D:fF:nN:sSipP:crRu:U:Z")) != EOF) switch (c) { data/freeradius-3.0.21+dfsg/src/main/session.c:212:8: [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. execl(getenv("COMSPEC"), "", "/C","checkrad", cl->nas_type, address, port, data/freeradius-3.0.21+dfsg/src/main/unittest.c:644: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. if (fr_fault_setup(getenv("PANIC_ACTION"), argv[0]) < 0) { data/freeradius-3.0.21+dfsg/src/main/unittest.c:674:19: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. while ((argval = getopt(argc, argv, "d:D:f:hi:mMn:o:O:xX")) != EOF) { data/freeradius-3.0.21+dfsg/src/main/unittest.c:785: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. panic_action = getenv("PANIC_ACTION"); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcpclient.c:441:14: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. while ((c = getopt(argc, argv, "d:D:f:hr:t:vx" data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1916:14: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. while ((c = getopt(argc, argv, "46c:d:D:f:hp:qst:r:S:xXv")) != EOF) data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:595:15: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. while ((ch = getopt(argc, argv, "acrvnou"))!= -1) data/freeradius-3.0.21+dfsg/src/tests/map/map_unit.c:159: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. if (fr_fault_setup(getenv("PANIC_ACTION"), argv[0]) < 0) { data/freeradius-3.0.21+dfsg/src/tests/map/map_unit.c:165:14: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. while ((c = getopt(argc, argv, "d:D:xMh")) != EOF) switch (c) { data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:381: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("/dev/null","w"); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:618: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 const *spawn_args[4]; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:716: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 var[50]; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:717: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 value[500]; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1026:4: [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(buffer, ".libs/"); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1034: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(name, ".libs/", 6); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1109: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(newarg, arg, arglen); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1206:6: [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(arg,"r"); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1241: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(newarg, ".libs"); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1408:3: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(newarg, "-l"); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1436: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 savewd[PATH_MAX]; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1440: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 const *lib_args[4]; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1667:4: [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(strrchr(tmp, '.') + 1, "lo"); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1873: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 def_file[1024]; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1874: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 implib_file[1024]; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1877: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 *export_args[1024]; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1885: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(def_file, ".def"); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1886:10: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). hDef = fopen(def_file, "w"); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1907: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(cmd, ">>"); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1922:4: [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(implib_file, ".libs/"); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1946: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 foo[PATH_MAX], *newpath; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:2125: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 const *lib_args[3], *static_lib_name; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:2174: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 const *lib_args[3]; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:2224: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 *l, libpath[PATH_MAX]; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:2276: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 fullname[1024]; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:2316: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 const *touch_args[3]; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:2339: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). FILE *f=fopen(cmd->fake_output_name,"w"); data/freeradius-3.0.21+dfsg/src/include/libradius.h:218: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[1]; data/freeradius-3.0.21+dfsg/src/include/libradius.h:228: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[1]; data/freeradius-3.0.21+dfsg/src/include/libradius.h:239: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[1]; data/freeradius-3.0.21+dfsg/src/include/libradius.h:343: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 l_opand[256]; //!< Left hand side of the pair. data/freeradius-3.0.21+dfsg/src/include/libradius.h:344: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 r_opand[1024]; //!< Right hand side of the pair. data/freeradius-3.0.21+dfsg/src/include/libradius.h:698:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. extern char const *fr_packet_codes[FR_MAX_PACKET_CODE]; data/freeradius-3.0.21+dfsg/src/include/modpriv.h:32: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_STRING_LEN]; data/freeradius-3.0.21+dfsg/src/include/modpriv.h:45: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_STRING_LEN]; data/freeradius-3.0.21+dfsg/src/include/pcap.h:72: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 errbuf[PCAP_ERRBUF_SIZE]; //!< Last error on this interface. data/freeradius-3.0.21+dfsg/src/include/radiusd.h:422:23: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. void rad_mode_to_str(char out[10], mode_t mode); data/freeradius-3.0.21+dfsg/src/include/radiusd.h:423:23: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. void rad_mode_to_oct(char out[5], mode_t mode); data/freeradius-3.0.21+dfsg/src/include/radutmp.h:38: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 login[32]; /* Loginname */ data/freeradius-3.0.21+dfsg/src/include/radutmp.h:41: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 session_id[8]; /* Radius session ID (first 8 bytes at least)*/ data/freeradius-3.0.21+dfsg/src/include/radutmp.h:51: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 caller_id[16]; /* Calling-Station-ID */ data/freeradius-3.0.21+dfsg/src/include/radutmp.h:52: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 reserved[12]; /* 3 ints reserved */ data/freeradius-3.0.21+dfsg/src/include/sysutmp.h: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 ut_line[UT_LINESIZE]; data/freeradius-3.0.21+dfsg/src/include/sysutmp.h:95: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 ut_id[4]; data/freeradius-3.0.21+dfsg/src/include/sysutmp.h:97: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 ut_user[UT_NAMESIZE]; data/freeradius-3.0.21+dfsg/src/include/sysutmp.h:98: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 ut_host[UT_HOSTSIZE]; data/freeradius-3.0.21+dfsg/src/include/tmpl.h:157:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char name[DICT_ATTR_SIZE]; //!< Raw unknown dictionary name. data/freeradius-3.0.21+dfsg/src/lib/base64.c:146:21: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. static const signed char b64[0x100] = { data/freeradius-3.0.21+dfsg/src/lib/cursor.c:97: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(out, in, sizeof(*out)); data/freeradius-3.0.21+dfsg/src/lib/debug.c:96:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 panic_action[512]; //!< The command to execute when panicking. data/freeradius-3.0.21+dfsg/src/lib/debug.c:647: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 filename[256]; data/freeradius-3.0.21+dfsg/src/lib/debug.c:690: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 cmd[sizeof(panic_action) + 20]; data/freeradius-3.0.21+dfsg/src/lib/dict.c:66: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 attrstr[DICT_ATTR_MAX_NAME_LEN]; data/freeradius-3.0.21+dfsg/src/lib/dict.c:365: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(&(this->stat_buf), stat_buf, sizeof(this->stat_buf)); data/freeradius-3.0.21+dfsg/src/lib/dict.c:384: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[2048]; data/freeradius-3.0.21+dfsg/src/lib/dict.c:630: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 buff[5]; data/freeradius-3.0.21+dfsg/src/lib/dict.c:1076: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(n->name, name, namelen); data/freeradius-3.0.21+dfsg/src/lib/dict.c:1145: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(v4, n, sizeof(*v4) + namelen); data/freeradius-3.0.21+dfsg/src/lib/dict.c:1148: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(v6, n, sizeof(*v6) + namelen); data/freeradius-3.0.21+dfsg/src/lib/dict.c:1638: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/lib/dict.c:1899: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/lib/dict.c:1941: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/lib/dict.c:2118:10: [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). value = atoi(argv[1]); data/freeradius-3.0.21+dfsg/src/lib/dict.c:2122: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/lib/dict.c:2231:2: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char dir[256], fn[256]; data/freeradius-3.0.21+dfsg/src/lib/dict.c:2232: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/freeradius-3.0.21+dfsg/src/lib/dict.c:2238: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 *argv[MAX_ARGV]; data/freeradius-3.0.21+dfsg/src/lib/dict.c:2308: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 ((fp = fopen(fn, "r")) == NULL) { data/freeradius-3.0.21+dfsg/src/lib/dict.c:2845: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, &da, sizeof(*tmp)); data/freeradius-3.0.21+dfsg/src/lib/dict.c:2989: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/lib/dict.c:3004: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(buffer, p, (q - p)); data/freeradius-3.0.21+dfsg/src/lib/dict.c:3094: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[DICT_ATTR_MAX_NAME_LEN + 1]; data/freeradius-3.0.21+dfsg/src/lib/filters.c:104:11: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char fill[4]; /* used to be fill[2] */ data/freeradius-3.0.21+dfsg/src/lib/filters.c:219: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[(sizeof(ascend_filter_t) == 32) ? 1 : -1 ]; data/freeradius-3.0.21+dfsg/src/lib/filters.c:596:15: [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). masklen = atoi(str); data/freeradius-3.0.21+dfsg/src/lib/filters.c:665:11: [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). token = atoi(str); data/freeradius-3.0.21+dfsg/src/lib/filters.c:804:13: [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). token = atoi(argv[0]); data/freeradius-3.0.21+dfsg/src/lib/filters.c:885:10: [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). rcode = atoi(argv[0]); data/freeradius-3.0.21+dfsg/src/lib/filters.c:958: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 *argv[32]; data/freeradius-3.0.21+dfsg/src/lib/filters.c:1063:18: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. if (rcode == 0) memcpy(out->filter, &filter, sizeof(filter)); data/freeradius-3.0.21+dfsg/src/lib/filters.c:1092:3: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(p, "0x"); data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:121:4: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr, from->h_addr_list[i], len); data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:268: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[2048]; data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:291:17: [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). port = htons(atoi(servname)); data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:385: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 tmpserv[16]; data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:386: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[2048]; data/freeradius-3.0.21+dfsg/src/lib/hash.c:365: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(buckets, ht->buckets, data/freeradius-3.0.21+dfsg/src/lib/heap.c:105: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, hp->p, sizeof(*p) * hp->size); data/freeradius-3.0.21+dfsg/src/lib/heap.c:275:10: [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). skip = atoi(argv[1]); data/freeradius-3.0.21+dfsg/src/lib/hmacmd5.c:109: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_ipad, key, key_len); data/freeradius-3.0.21+dfsg/src/lib/hmacmd5.c:110: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_opad, key, key_len); data/freeradius-3.0.21+dfsg/src/lib/hmacsha1.c:129: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_ipad, key, key_len); data/freeradius-3.0.21+dfsg/src/lib/hmacsha1.c:130: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_opad, key, key_len); data/freeradius-3.0.21+dfsg/src/lib/md4.c:152: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, in, inlen); data/freeradius-3.0.21+dfsg/src/lib/md4.c:155: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, in, count); data/freeradius-3.0.21+dfsg/src/lib/md4.c:164: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(ctx->buffer, in, MD4_BLOCK_LENGTH); data/freeradius-3.0.21+dfsg/src/lib/md4.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(ctx->buffer, in, inlen); data/freeradius-3.0.21+dfsg/src/lib/md4.c:222: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(out, ctx->state, MD4_DIGEST_LENGTH); data/freeradius-3.0.21+dfsg/src/lib/md5.c:116: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(ctx->buffer + have, in, need); data/freeradius-3.0.21+dfsg/src/lib/md5.c:132:18: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. if (inlen != 0) memcpy(ctx->buffer + have, in, inlen); data/freeradius-3.0.21+dfsg/src/lib/misc.c:243: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(buffer, "%d.%d.%d.%d", data/freeradius-3.0.21+dfsg/src/lib/misc.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 buffer[256]; data/freeradius-3.0.21+dfsg/src/lib/misc.c:339: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(buffer, value, inlen); data/freeradius-3.0.21+dfsg/src/lib/misc.c:381:17: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. if (inlen < 0) memcpy(buffer, value, p - value); data/freeradius-3.0.21+dfsg/src/lib/misc.c:429: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[256]; data/freeradius-3.0.21+dfsg/src/lib/misc.c:439: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(buffer, value, inlen); data/freeradius-3.0.21+dfsg/src/lib/misc.c:472:17: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. if (inlen < 0) memcpy(buffer, value, p - value); data/freeradius-3.0.21+dfsg/src/lib/misc.c:668: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[6]; data/freeradius-3.0.21+dfsg/src/lib/misc.c:734: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[INET6_ADDRSTRLEN]; data/freeradius-3.0.21+dfsg/src/lib/misc.c:927: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(dst, &tmp, sizeof(tmp)); data/freeradius-3.0.21+dfsg/src/lib/misc.c:1023: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(dst, tmp, IN6ADDRSZ); data/freeradius-3.0.21+dfsg/src/lib/misc.c:1596: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(sa, &s4, sizeof(s4)); data/freeradius-3.0.21+dfsg/src/lib/misc.c:1610: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(sa, &s6, sizeof(s6)); data/freeradius-3.0.21+dfsg/src/lib/misc.c:1889: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 buff[128 / 3 + 1 + 1]; data/freeradius-3.0.21+dfsg/src/lib/misc.c:1973: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/freeradius-3.0.21+dfsg/src/lib/misc.c:1975: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 *f[4]; data/freeradius-3.0.21+dfsg/src/lib/misc.c:2042:16: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). tm->tm_year = atoi(f[1]); data/freeradius-3.0.21+dfsg/src/lib/misc.c:2043:16: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). tm->tm_mday = atoi(f[2]); data/freeradius-3.0.21+dfsg/src/lib/misc.c:2083:18: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). tm->tm_sec = atoi(f[2]); data/freeradius-3.0.21+dfsg/src/lib/misc.c:2086:17: [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). tm->tm_hour = atoi(f[0]); data/freeradius-3.0.21+dfsg/src/lib/misc.c:2087:16: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). tm->tm_min = atoi(f[1]); data/freeradius-3.0.21+dfsg/src/lib/missing.c:150: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(result, localtime(l_clock), sizeof(*result)); data/freeradius-3.0.21+dfsg/src/lib/missing.c:188: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(result, gmtime(l_clock), sizeof(*result)); data/freeradius-3.0.21+dfsg/src/lib/missing.c:277: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(ntp, &sec, sizeof(sec)); data/freeradius-3.0.21+dfsg/src/lib/missing.c:278: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(ntp + sizeof(sec), &usec, sizeof(usec)); data/freeradius-3.0.21+dfsg/src/lib/missing.c:351: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(out, s->s3->client_random, outlen); data/freeradius-3.0.21+dfsg/src/lib/missing.c:362: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(out, s->s3->server_random, outlen); data/freeradius-3.0.21+dfsg/src/lib/missing.c:374: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(out, s->master_key, outlen); data/freeradius-3.0.21+dfsg/src/lib/missing.c:438: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, in, inlen); data/freeradius-3.0.21+dfsg/src/lib/packet.c:988: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 src_ipaddr[128]; data/freeradius-3.0.21+dfsg/src/lib/packet.c:989: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 dst_ipaddr[128]; data/freeradius-3.0.21+dfsg/src/lib/pair.c:661: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(n, vp, sizeof(*n)); data/freeradius-3.0.21+dfsg/src/lib/pair.c:836: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(da, vp->da, size); data/freeradius-3.0.21+dfsg/src/lib/pair.c:941: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(found, i, sizeof(*found)); data/freeradius-3.0.21+dfsg/src/lib/pair.c:1418: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[256]; data/freeradius-3.0.21+dfsg/src/lib/pair.c:1672: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[8]; data/freeradius-3.0.21+dfsg/src/lib/pair.c:1919: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[8192]; data/freeradius-3.0.21+dfsg/src/lib/pair.c:2234: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, src, len); /* embdedded \0 safe */ data/freeradius-3.0.21+dfsg/src/lib/print.c:199: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(out, in, outlen - 1); data/freeradius-3.0.21+dfsg/src/lib/print.c:202: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(out, in, inlen); data/freeradius-3.0.21+dfsg/src/lib/print.c:339:13: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. if (out) memcpy(out + used, p, utf8); data/freeradius-3.0.21+dfsg/src/lib/print.c:704: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/freeradius-3.0.21+dfsg/src/lib/radius.c:94:1: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char const *fr_packet_codes[FR_MAX_PACKET_CODE] = { data/freeradius-3.0.21+dfsg/src/lib/radius.c:194: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 buffer[32]; data/freeradius-3.0.21+dfsg/src/lib/radius.c:551: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(passwd, input, len); data/freeradius-3.0.21+dfsg/src/lib/radius.c:587: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(output, passwd, len); data/freeradius-3.0.21+dfsg/src/lib/radius.c:638: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(output + 3, input, inlen); data/freeradius-3.0.21+dfsg/src/lib/radius.c:881: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(array, &lvalue, sizeof(lvalue)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:906: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(array, &slvalue, sizeof(slvalue)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:1001:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr, data, len); data/freeradius-3.0.21+dfsg/src/lib/radius.c:1221: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(ptr + 2, &lvalue, 4); data/freeradius-3.0.21+dfsg/src/lib/radius.c:1293:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr + 2, p, left); data/freeradius-3.0.21+dfsg/src/lib/radius.c:1518: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(ptr + 2, &lvalue, 4); data/freeradius-3.0.21+dfsg/src/lib/radius.c:1801: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(ptr, reply->vp_octets, reply->vp_length); data/freeradius-3.0.21+dfsg/src/lib/radius.c:1892: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(packet->data, hdr, packet->data_len); data/freeradius-3.0.21+dfsg/src/lib/radius.c:1896: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(hdr->length, &total_length, sizeof(total_length)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:1947: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(packet->vector, original->vector, AUTH_VECTOR_LEN); data/freeradius-3.0.21+dfsg/src/lib/radius.c:1988: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(hdr->vector, original->vector, AUTH_VECTOR_LEN); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2003: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(packet->data + packet->offset + 2, data/freeradius-3.0.21+dfsg/src/lib/radius.c:2010: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(hdr->vector, packet->vector, AUTH_VECTOR_LEN); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2040: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(hdr->vector, digest, AUTH_VECTOR_LEN); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2041: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(packet->vector, digest, AUTH_VECTOR_LEN); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2192: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(packet->data + 4, original->vector, AUTH_VECTOR_LEN); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2205: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(packet->data + 4, packet->vector, AUTH_VECTOR_LEN); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2324: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 host_ipaddr[128]; data/freeradius-3.0.21+dfsg/src/lib/radius.c:2634: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(packet->vector, hdr->vector, AUTH_VECTOR_LEN); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2732: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[32]; data/freeradius-3.0.21+dfsg/src/lib/radius.c:2790: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(packet->data + 4, original->vector, AUTH_VECTOR_LEN); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2810:4: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(&ptr[2], msg_auth_vector, AUTH_VECTOR_LEN); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2811: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(packet->data + 4, packet->vector, AUTH_VECTOR_LEN); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2951: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, ptr + 2, ptr[1] - 2); data/freeradius-3.0.21+dfsg/src/lib/radius.c:3251: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(tail, attr + 2, attrlen - 2); data/freeradius-3.0.21+dfsg/src/lib/radius.c:3256:20: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. if (attr[1] > 4) memcpy(tail, attr + 4, attr[1] - 4); data/freeradius-3.0.21+dfsg/src/lib/radius.c:3436: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(tail, attr + 4 + 3, attr[4 + 1] - 3); data/freeradius-3.0.21+dfsg/src/lib/radius.c:3475: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(&vendor, data, 4); data/freeradius-3.0.21+dfsg/src/lib/radius.c:3643: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(buffer, data + 1, datalen - 1); data/freeradius-3.0.21+dfsg/src/lib/radius.c:3648: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(buffer, data, attrlen); data/freeradius-3.0.21+dfsg/src/lib/radius.c:3674: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(buffer, data, attrlen); data/freeradius-3.0.21+dfsg/src/lib/radius.c:3747:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(buffer, my_digest, data/freeradius-3.0.21+dfsg/src/lib/radius.c:3860: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(&vendor, data + 3, 4); data/freeradius-3.0.21+dfsg/src/lib/radius.c:3885: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(&vendor, data, 4); data/freeradius-3.0.21+dfsg/src/lib/radius.c:3973: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, data, vp->vp_length); data/freeradius-3.0.21+dfsg/src/lib/radius.c:3986: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(vp->vp_filter, data, vp->vp_length); data/freeradius-3.0.21+dfsg/src/lib/radius.c:3998: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(&vp->vp_integer, data, 4); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4003: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(&vp->vp_integer64, data, 8); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4008: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(&vp->vp_date, data, 4); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4013: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(vp->vp_ether, data, 6); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4017: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(&vp->vp_ipaddr, data, 4); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4021: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(vp->vp_ifid, data, 8); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4025: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(&vp->vp_ipv6addr, data, 16); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4033: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(vp->vp_ipv6prefix, data, vp->vp_length); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4042: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(vp->vp_ipv4prefix, data, vp->vp_length); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4058: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(vp->vp_ipv4prefix + 2, &addr, sizeof(addr)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4063: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(&vp->vp_integer, data, 4); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4173:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(out, &vp->data.ptr, sizeof(*out)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4190:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(out, &p, sizeof(*out)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4212: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(buffer, &lvalue, sizeof(lvalue)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4218: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(buffer, &lvalue64, sizeof(lvalue64)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4224: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(buffer, &lvalue, sizeof(lvalue)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4231: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(buffer, &slvalue, sizeof(slvalue)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4308: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 host_ipaddr[128]; data/freeradius-3.0.21+dfsg/src/lib/radius.c:4492:11: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char digest[AUTH_VECTOR_LEN]; data/freeradius-3.0.21+dfsg/src/lib/radius.c:4545: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(buffer, secret, secretlen); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4549: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(buffer + secretlen, vector, AUTH_VECTOR_LEN); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4550: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(buffer + secretlen + AUTH_VECTOR_LEN, salt, 2); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4553: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(buffer + secretlen, passwd + n2 - AUTH_PASS_LEN, AUTH_PASS_LEN); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4708: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(ptr, password->vp_strvalue, password->vp_length); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4718:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr, challenge->vp_strvalue, challenge->vp_length); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4721:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr, packet->vector, AUTH_VECTOR_LEN); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4748:8: [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/urandom", O_RDONLY); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4839: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(rp->vector + i, &hash, sizeof(hash)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4921: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(out, in, sizeof(*out)); data/freeradius-3.0.21+dfsg/src/lib/rbtree.c:461: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(y, z, sizeof(*y)); data/freeradius-3.0.21+dfsg/src/lib/regex.c:292: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 errbuf[128]; data/freeradius-3.0.21+dfsg/src/lib/regex.c:359: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 errbuf[128]; data/freeradius-3.0.21+dfsg/src/lib/sha1.c:47: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, buffer, 64); data/freeradius-3.0.21+dfsg/src/lib/sha1.c:117: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(&context->buffer[j], data, (i = 64-j)); data/freeradius-3.0.21+dfsg/src/lib/sha1.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(&context->buffer[j], &data[i], len - i); data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:178: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 integral_part[MAX_INT]; data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:179: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 fraction_part[MAX_FRACT]; data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:456: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 number[MAX_FIELD/2]; data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:490:14: [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). p->width = atoi(number); data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:492:18: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). p->precision = atoi(number); data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:511: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 conv_field[MAX_FIELD]; data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:719: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 holder[100]; data/freeradius-3.0.21+dfsg/src/lib/socket.c:87: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(saremote.sun_path, path, len + 1); /* SUN_LEN does strlen */ data/freeradius-3.0.21+dfsg/src/lib/tcp.c:114: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(packet->data, packet->vector, 4); data/freeradius-3.0.21+dfsg/src/lib/tcp.c:154: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 ip_buf[128], buffer[256]; data/freeradius-3.0.21+dfsg/src/lib/token.c:369: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 op[3]; data/freeradius-3.0.21+dfsg/src/lib/udpfromto.c:167: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 cbuf[256]; data/freeradius-3.0.21+dfsg/src/lib/udpfromto.c:313: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 cbuf[256]; data/freeradius-3.0.21+dfsg/src/lib/udpfromto.c:471: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[TESTLEN]; data/freeradius-3.0.21+dfsg/src/lib/udpfromto.c:477: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). if (argc > 2) port = atoi(argv[2]); data/freeradius-3.0.21+dfsg/src/lib/value.c:427: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[256]; data/freeradius-3.0.21+dfsg/src/lib/value.c:692: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(&dst->ipv4prefix[2], &addr.ipaddr.ip4addr.s_addr, sizeof(dst->ipv4prefix) - 2); data/freeradius-3.0.21+dfsg/src/lib/value.c:723: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(&dst->ipv6prefix[2], addr.ipaddr.ip6addr.s6_addr, sizeof(dst->ipv6prefix) - 2); data/freeradius-3.0.21+dfsg/src/lib/value.c:741: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(buffer, src, src_len); data/freeradius-3.0.21+dfsg/src/lib/value.c:1032: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(dst_ptr, src, dst_len); data/freeradius-3.0.21+dfsg/src/lib/value.c:1043: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(dst_ptr, src, src_len); data/freeradius-3.0.21+dfsg/src/lib/value.c:1083: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(dst_ptr, src, src_len); data/freeradius-3.0.21+dfsg/src/lib/value.c:1154: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(&dst->integer64, src->ifid, sizeof(src->ifid)); data/freeradius-3.0.21+dfsg/src/lib/value.c:1166: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(array, &i, 8); data/freeradius-3.0.21+dfsg/src/lib/value.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(dst->ether, &array[2], 6); data/freeradius-3.0.21+dfsg/src/lib/value.c:1370:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(dst->ipv6addr.s6_addr, v4_v6_map, sizeof(v4_v6_map)); data/freeradius-3.0.21+dfsg/src/lib/value.c:1371:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(&dst->ipv6addr.s6_addr[sizeof(v4_v6_map)], &src->ipaddr, data/freeradius-3.0.21+dfsg/src/lib/value.c:1380:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(dst->ipv6addr.s6_addr, v4_v6_map, sizeof(v4_v6_map)); data/freeradius-3.0.21+dfsg/src/lib/value.c:1381:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(&dst->ipv6addr.s6_addr[sizeof(v4_v6_map)], &src->ipv4prefix[2], data/freeradius-3.0.21+dfsg/src/lib/value.c:1399:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(&dst->ipv4prefix[2], &src->ipaddr, sizeof(dst->ipv4prefix) - 2); data/freeradius-3.0.21+dfsg/src/lib/value.c:1408:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(&dst->ipv4prefix[2], &src->ipv6addr.s6_addr[sizeof(v4_v6_map)], data/freeradius-3.0.21+dfsg/src/lib/value.c:1426:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(&dst->ipv4prefix[2], &src->ipv6prefix[2 + sizeof(v4_v6_map)], data/freeradius-3.0.21+dfsg/src/lib/value.c:1441:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(&dst->ipv6prefix[2], v4_v6_map, sizeof(v4_v6_map)); data/freeradius-3.0.21+dfsg/src/lib/value.c:1442:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(&dst->ipv6prefix[2 + sizeof(v4_v6_map)], &src->ipaddr, data/freeradius-3.0.21+dfsg/src/lib/value.c:1450:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(&dst->ipv6prefix[2], v4_v6_map, sizeof(v4_v6_map)); data/freeradius-3.0.21+dfsg/src/lib/value.c:1451:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(&dst->ipv6prefix[2 + sizeof(v4_v6_map)], &src->ipv4prefix[2], data/freeradius-3.0.21+dfsg/src/lib/value.c:1458:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(&dst->ipv6prefix[2], &src->ipv6addr, sizeof(dst->ipv6prefix) - 2); data/freeradius-3.0.21+dfsg/src/lib/value.c:1512: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(&dst, &src, src_len); data/freeradius-3.0.21+dfsg/src/lib/value.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(dst, src, sizeof(*src)); data/freeradius-3.0.21+dfsg/src/lib/value.c:1667: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[INET_ADDRSTRLEN + 4]; // + /prefix data/freeradius-3.0.21+dfsg/src/lib/value.c:1679: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[INET6_ADDRSTRLEN + 4]; // + /prefix data/freeradius-3.0.21+dfsg/src/lib/value.c:1740: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]; /* Interim buffer to use with poorly behaved printing functions */ data/freeradius-3.0.21+dfsg/src/main/auth.c: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 clean_password[1024]; data/freeradius-3.0.21+dfsg/src/main/auth.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 clean_username[1024]; data/freeradius-3.0.21+dfsg/src/main/auth.c: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 buf[1024]; data/freeradius-3.0.21+dfsg/src/main/auth.c:81: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 extra[1024]; data/freeradius-3.0.21+dfsg/src/main/auth.c:106:3: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(clean_username, "<no User-Name attribute>"); data/freeradius-3.0.21+dfsg/src/main/auth.c:125: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(clean_password, "<no User-Password attribute>"); data/freeradius-3.0.21+dfsg/src/main/auth.c:128:4: [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(clean_password, "<CHAP-Password>"); data/freeradius-3.0.21+dfsg/src/main/auth.c:396: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 msg[MAX_STRING_LEN+19]; data/freeradius-3.0.21+dfsg/src/main/auth.c:411: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 msg[MAX_STRING_LEN+12]; data/freeradius-3.0.21+dfsg/src/main/auth.c:530: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 msg[MAX_STRING_LEN + 16]; data/freeradius-3.0.21+dfsg/src/main/auth.c:640: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 logstr[1024]; data/freeradius-3.0.21+dfsg/src/main/auth.c:641: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 umsg[MAX_STRING_LEN + 1]; data/freeradius-3.0.21+dfsg/src/main/client.c:160: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[INET6_ADDRSTRLEN + 3]; data/freeradius-3.0.21+dfsg/src/main/client.c:559: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 buf2[2048]; data/freeradius-3.0.21+dfsg/src/main/client.c:681: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[128]; data/freeradius-3.0.21+dfsg/src/main/client.c:890: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 buffer[128]; data/freeradius-3.0.21+dfsg/src/main/client.c:1137: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[128]; data/freeradius-3.0.21+dfsg/src/main/client.c:1179: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[128]; data/freeradius-3.0.21+dfsg/src/main/client.c:1284: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(&c->ipaddr.ipaddr.ip4addr, &vp->vp_ipv4prefix[2], data/freeradius-3.0.21+dfsg/src/main/client.c:1424: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 buf2[128]; data/freeradius-3.0.21+dfsg/src/main/client.c:1461: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[256]; data/freeradius-3.0.21+dfsg/src/main/collectd.c:83: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 hostname[255]; data/freeradius-3.0.21+dfsg/src/main/collectd.c:84: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 fqdn[LCC_NAME_LEN]; data/freeradius-3.0.21+dfsg/src/main/collectd.c:242: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[LCC_NAME_LEN]; data/freeradius-3.0.21+dfsg/src/main/collectd.c:306: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 identifier[6 * LCC_NAME_LEN]; data/freeradius-3.0.21+dfsg/src/main/command.c:75: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[COMMAND_BUFFER_SIZE]; data/freeradius-3.0.21+dfsg/src/main/command.c: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 user[256]; data/freeradius-3.0.21+dfsg/src/main/command.c:181: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(salocal.sun_path, path, len + 1); /* SUN_LEN does strlen */ data/freeradius-3.0.21+dfsg/src/main/command.c:407: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). parent_fd = open(dir, O_DIRECTORY); data/freeradius-3.0.21+dfsg/src/main/command.c:511: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 str_need[10], oct_need[5]; data/freeradius-3.0.21+dfsg/src/main/command.c:512: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 str_have[10], oct_have[5]; data/freeradius-3.0.21+dfsg/src/main/command.c:602: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(salocal.sun_path, name, len + 1); /* SUN_LEN does strlen */ data/freeradius-3.0.21+dfsg/src/main/command.c:604: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(salocal.sun_path, path, len + 1); /* SUN_LEN does strlen */ data/freeradius-3.0.21+dfsg/src/main/command.c:615: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_need[10], oct_need[5]; data/freeradius-3.0.21+dfsg/src/main/command.c:702: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[256]; data/freeradius-3.0.21+dfsg/src/main/command.c:723: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[256]; data/freeradius-3.0.21+dfsg/src/main/command.c:744: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[256]; data/freeradius-3.0.21+dfsg/src/main/command.c:797: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[128]; data/freeradius-3.0.21+dfsg/src/main/command.c:857: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/main/command.c:1003:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 const *method_names[MOD_COUNT] = { data/freeradius-3.0.21+dfsg/src/main/command.c:1147: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[256]; data/freeradius-3.0.21+dfsg/src/main/command.c:1247: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[256]; data/freeradius-3.0.21+dfsg/src/main/command.c:1284:11: [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). number = atoi(argv[0]); data/freeradius-3.0.21+dfsg/src/main/command.c:1295:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 debug_log_file_buffer[1024]; data/freeradius-3.0.21+dfsg/src/main/command.c:1336: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 *p, buffer[1024]; data/freeradius-3.0.21+dfsg/src/main/command.c:1440: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[1024]; data/freeradius-3.0.21+dfsg/src/main/command.c:1525:18: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). server_port = atoi(argv[myarg + 2]); data/freeradius-3.0.21+dfsg/src/main/command.c:1573:9: [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). port = atoi(argv[1]); data/freeradius-3.0.21+dfsg/src/main/command.c:1713: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(output_file, "w"); data/freeradius-3.0.21+dfsg/src/main/command.c:1722: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 buffer[1024]; data/freeradius-3.0.21+dfsg/src/main/command.c:1772:9: [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). port = atoi(argv[1]); data/freeradius-3.0.21+dfsg/src/main/command.c:1862: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[2048]; data/freeradius-3.0.21+dfsg/src/main/command.c:1884: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(argv[0], "r"); data/freeradius-3.0.21+dfsg/src/main/command.c:1900: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(fake, sock->inject_listener, sizeof(*fake)); data/freeradius-3.0.21+dfsg/src/main/command.c:2229:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 const *elapsed_names[8] = { data/freeradius-3.0.21+dfsg/src/main/command.c:3004: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 *my_argv[MAX_ARGV], **argv; data/freeradius-3.0.21+dfsg/src/main/command.c:3140: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[16]; data/freeradius-3.0.21+dfsg/src/main/command.c:3326: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(this, listener, sizeof(*this)); data/freeradius-3.0.21+dfsg/src/main/conffile.c:338: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(filename, "r"); data/freeradius-3.0.21+dfsg/src/main/conffile.c:630: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[1024]; data/freeradius-3.0.21+dfsg/src/main/conffile.c:911: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[8192]; data/freeradius-3.0.21+dfsg/src/main/conffile.c:1062: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[8192]; data/freeradius-3.0.21+dfsg/src/main/conffile.c:1114: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(name, ptr, end - ptr); data/freeradius-3.0.21+dfsg/src/main/conffile.c:1257: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(name, ptr, end - ptr); data/freeradius-3.0.21+dfsg/src/main/conffile.c:1308: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 ipbuf[128]; data/freeradius-3.0.21+dfsg/src/main/conffile.c:1425: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[8192]; data/freeradius-3.0.21+dfsg/src/main/conffile.c:1760: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(data, &tv, sizeof(tv)); data/freeradius-3.0.21+dfsg/src/main/conffile.c:1838:6: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. *(char **) variables[i].data = NULL; data/freeradius-3.0.21+dfsg/src/main/conffile.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 buf[8192]; data/freeradius-3.0.21+dfsg/src/main/conffile.c:2275: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 buf1[8192]; data/freeradius-3.0.21+dfsg/src/main/conffile.c:2276: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 buf2[8192]; data/freeradius-3.0.21+dfsg/src/main/conffile.c:2277: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 buf3[8192]; data/freeradius-3.0.21+dfsg/src/main/conffile.c:2278: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 buf4[8192]; data/freeradius-3.0.21+dfsg/src/main/conffile.c:2736: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(buf2, ptr, slen); data/freeradius-3.0.21+dfsg/src/main/conffile.c:2751: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, &css->name2, sizeof(css->name2)); data/freeradius-3.0.21+dfsg/src/main/conffile.c:2820: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(buf3, ptr, (q - ptr)); data/freeradius-3.0.21+dfsg/src/main/conffile.c:3038: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 buffer[8192]; data/freeradius-3.0.21+dfsg/src/main/conffile.c:3708: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[256]; data/freeradius-3.0.21+dfsg/src/main/conffile.c:3727: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[256]; data/freeradius-3.0.21+dfsg/src/main/conffile.c:3744: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[256]; data/freeradius-3.0.21+dfsg/src/main/conffile.c:3773: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[256]; data/freeradius-3.0.21+dfsg/src/main/connection.c:272: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[64]; data/freeradius-3.0.21+dfsg/src/main/connection.c:1134: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 buff[128]; data/freeradius-3.0.21+dfsg/src/main/connection.c:1135: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 trigger_prefix[64]; data/freeradius-3.0.21+dfsg/src/main/detail.c:208:18: [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). data->work_fd = open(data->filename_work, O_RDWR); data/freeradius-3.0.21+dfsg/src/main/detail.c:276:19: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). data->work_fd = open(data->filename_work, O_RDWR); data/freeradius-3.0.21+dfsg/src/main/detail.c:438: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 key[256], op[8], value[1024]; data/freeradius-3.0.21+dfsg/src/main/detail.c:442: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[2048]; data/freeradius-3.0.21+dfsg/src/main/detail.c:666: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). data->timestamp = atoi(value); data/freeradius-3.0.21+dfsg/src/main/detail.c:679: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). data->timestamp = atoi(value); data/freeradius-3.0.21+dfsg/src/main/detail.c:851: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(&packet->src_ipaddr.ipaddr.ip6addr, data/freeradius-3.0.21+dfsg/src/main/detail.c:866: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(&packet->dst_ipaddr.ipaddr.ip6addr, data/freeradius-3.0.21+dfsg/src/main/detail.c:1144: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[2048]; data/freeradius-3.0.21+dfsg/src/main/evaluate.c:731: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[1024]; data/freeradius-3.0.21+dfsg/src/main/exec.c:77: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 *argv[MAX_ARGV], **argv_start = argv; data/freeradius-3.0.21+dfsg/src/main/exec.c: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 argv_buf[4096]; data/freeradius-3.0.21+dfsg/src/main/exec.c: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 *envp[MAX_ENVP]; data/freeradius-3.0.21+dfsg/src/main/exec.c:132: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 buffer[1024]; data/freeradius-3.0.21+dfsg/src/main/exec.c:197:13: [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). devnull = open("/dev/null", O_RDWR); data/freeradius-3.0.21+dfsg/src/main/exec.c:518: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 answer[4096]; data/freeradius-3.0.21+dfsg/src/main/exfile.c:155: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(filename, O_RDWR | O_CREAT, permissions); data/freeradius-3.0.21+dfsg/src/main/exfile.c:191:8: [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(filename, O_RDWR | O_CREAT, permissions); data/freeradius-3.0.21+dfsg/src/main/exfile.c:403:23: [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). ef->entries[i].fd = open(filename, O_RDWR | O_CREAT, permissions); data/freeradius-3.0.21+dfsg/src/main/exfile.c:441: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_need[10], oct_need[5]; data/freeradius-3.0.21+dfsg/src/main/exfile.c:442: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_have[10], oct_have[5]; data/freeradius-3.0.21+dfsg/src/main/files.c:84: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 entry[256]; data/freeradius-3.0.21+dfsg/src/main/files.c: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 buffer[8192]; data/freeradius-3.0.21+dfsg/src/main/files.c: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 newfile[8192]; data/freeradius-3.0.21+dfsg/src/main/files.c:107: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 ((fp = fopen(file, "r")) == NULL) { data/freeradius-3.0.21+dfsg/src/main/listen.c:58: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 src[256], dst[256]; data/freeradius-3.0.21+dfsg/src/main/listen.c:120:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char name[256], buffer[128]; data/freeradius-3.0.21+dfsg/src/main/listen.c:503: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/main/listen.c:681: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(this->data, listener->data, sizeof(*sock)); data/freeradius-3.0.21+dfsg/src/main/listen.c:682: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(this, listener, sizeof(*this)); data/freeradius-3.0.21+dfsg/src/main/listen.c:1168: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 buffer[128]; data/freeradius-3.0.21+dfsg/src/main/listen.c:1231: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 buffer[128]; data/freeradius-3.0.21+dfsg/src/main/listen.c:1987: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[128]; data/freeradius-3.0.21+dfsg/src/main/listen.c:2054: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[128]; data/freeradius-3.0.21+dfsg/src/main/listen.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 buffer[256]; data/freeradius-3.0.21+dfsg/src/main/listen.c:2626: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/main/listen.c:2805: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[256]; data/freeradius-3.0.21+dfsg/src/main/listen.c:2969: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[32]; data/freeradius-3.0.21+dfsg/src/main/listen.c:3005: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(&master_listen[type], proto, sizeof(*proto)); data/freeradius-3.0.21+dfsg/src/main/listen.c:3372: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/main/log.c:281:12: [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). devnull = open("/dev/null", O_RDWR); data/freeradius-3.0.21+dfsg/src/main/log.c:367: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[10240]; /* The largest config item size, then extra for prefixes and suffixes */ data/freeradius-3.0.21+dfsg/src/main/log.c:627: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[10240]; /* The largest config item size, then extra for prefixes and suffixes */ data/freeradius-3.0.21+dfsg/src/main/log.c:682: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(buffer, "a"); data/freeradius-3.0.21+dfsg/src/main/log.c:709: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 time_buff[64]; /* The current timestamp */ data/freeradius-3.0.21+dfsg/src/main/log.c:895: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(value, "...", 3); data/freeradius-3.0.21+dfsg/src/main/log.c:917: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(value + 95, "... ", 5); data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:335: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[1024]; data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:415: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[INET6_ADDRSTRLEN], *q; data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:713: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). default_log.fd = open(main_config.log_file, data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:807: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[1024]; data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:1221: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(main_config.log_file, data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:1281: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[1024]; data/freeradius-3.0.21+dfsg/src/main/map.c:663: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 answer[1024]; data/freeradius-3.0.21+dfsg/src/main/map.c:1575: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[1024]; data/freeradius-3.0.21+dfsg/src/main/map.c:1611: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 attr[256]; data/freeradius-3.0.21+dfsg/src/main/map.c:1654:3: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(buffer, "ANY"); data/freeradius-3.0.21+dfsg/src/main/modcall.c:197:12: [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). action = atoi(value); data/freeradius-3.0.21+dfsg/src/main/modcall.c:673: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 buffer[1024]; data/freeradius-3.0.21+dfsg/src/main/modcall.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 buffer[128]; data/freeradius-3.0.21+dfsg/src/main/modcall.c:1154: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 buf[32]; data/freeradius-3.0.21+dfsg/src/main/modcall.c:2186: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[256]; data/freeradius-3.0.21+dfsg/src/main/modcall.c:2468: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/main/modcall.c:2544: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/main/modcall.c:2684: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(csingle->actions, defaultactions[component][grouptype], data/freeradius-3.0.21+dfsg/src/main/modcall.c:2687: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(csingle->actions, authtype_actions[grouptype], data/freeradius-3.0.21+dfsg/src/main/modcall.c:3929: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[1024]; data/freeradius-3.0.21+dfsg/src/main/modules.c:154: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[2048]; data/freeradius-3.0.21+dfsg/src/main/modules.c:609: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 module_name[256]; data/freeradius-3.0.21+dfsg/src/main/modules.c:811: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/main/modules.c:1089:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 const *ignored[MAX_IGNORED]; data/freeradius-3.0.21+dfsg/src/main/pair.c:732: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[768]; data/freeradius-3.0.21+dfsg/src/main/pair.c:751: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[768]; data/freeradius-3.0.21+dfsg/src/main/pair.c:777: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[768]; data/freeradius-3.0.21+dfsg/src/main/parser.c:326: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(*out, start, len); data/freeradius-3.0.21+dfsg/src/main/process.c:93:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 const *master_state_names[REQUEST_MASTER_NUM_STATES] = { data/freeradius-3.0.21+dfsg/src/main/process.c:100:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 const *child_state_names[REQUEST_CHILD_NUM_STATES] = { data/freeradius-3.0.21+dfsg/src/main/process.c:447: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 src_ipaddr[128]; data/freeradius-3.0.21+dfsg/src/main/process.c:448: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 dst_ipaddr[128]; data/freeradius-3.0.21+dfsg/src/main/process.c:609: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[128]; data/freeradius-3.0.21+dfsg/src/main/process.c:2010: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[256]; data/freeradius-3.0.21+dfsg/src/main/process.c:2268: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/freeradius-3.0.21+dfsg/src/main/process.c:2549: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[128]; data/freeradius-3.0.21+dfsg/src/main/process.c:2574: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[128]; data/freeradius-3.0.21+dfsg/src/main/process.c:3011: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(&dst_ipaddr.ipaddr.ip6addr, &vp->vp_ipv6addr, sizeof(vp->vp_ipv6addr)); data/freeradius-3.0.21+dfsg/src/main/process.c:3043: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/main/process.c:3192: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 buffer[128]; data/freeradius-3.0.21+dfsg/src/main/process.c:3301: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[128]; data/freeradius-3.0.21+dfsg/src/main/process.c:3495: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[128]; data/freeradius-3.0.21+dfsg/src/main/process.c:3773: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[128]; data/freeradius-3.0.21+dfsg/src/main/process.c:3823: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[128]; data/freeradius-3.0.21+dfsg/src/main/process.c:3846: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[128]; data/freeradius-3.0.21+dfsg/src/main/process.c:3910: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[128]; data/freeradius-3.0.21+dfsg/src/main/process.c:4178: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[256]; data/freeradius-3.0.21+dfsg/src/main/process.c:4415: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[128]; data/freeradius-3.0.21+dfsg/src/main/process.c:4608: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/main/process.c:4758: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[128]; data/freeradius-3.0.21+dfsg/src/main/process.c:4857: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/main/process.c:4955: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[1024]; data/freeradius-3.0.21+dfsg/src/main/process.c:5026: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[1024]; data/freeradius-3.0.21+dfsg/src/main/process.c:5267:13: [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). devnull = open("/dev/null", O_RDWR); data/freeradius-3.0.21+dfsg/src/main/radattr.c:477: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(output + 255, output, 4); data/freeradius-3.0.21+dfsg/src/main/radattr.c:589: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 input[8192], buffer[8192]; data/freeradius-3.0.21+dfsg/src/main/radattr.c:590: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 output[8192]; data/freeradius-3.0.21+dfsg/src/main/radattr.c:591: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 directory[8192]; data/freeradius-3.0.21+dfsg/src/main/radattr.c:605: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(directory, "r"); data/freeradius-3.0.21+dfsg/src/main/radattr.c:738: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(&qvp, &pvp, sizeof(pvp)); data/freeradius-3.0.21+dfsg/src/main/radattr.c:809:21: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. if (vp->next) {strcpy(p, ", "); data/freeradius-3.0.21+dfsg/src/main/radattr.c:893:21: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. if (vp->next) {strcpy(p, ", "); data/freeradius-3.0.21+dfsg/src/main/radclient.c:313:13: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). packets = fopen(files->packets, "r"); data/freeradius-3.0.21+dfsg/src/main/radclient.c:323: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). filters = fopen(files->filters, "r"); data/freeradius-3.0.21+dfsg/src/main/radclient.c:529: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 + 2, vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/main/radclient.c:1154: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 filesecret[256]; data/freeradius-3.0.21+dfsg/src/main/radclient.c:1202:19: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). resend_count = atoi(optarg); data/freeradius-3.0.21+dfsg/src/main/radclient.c:1239:13: [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). persec = atoi(optarg); data/freeradius-3.0.21+dfsg/src/main/radclient.c:1251:15: [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). parallel = atoi(optarg); data/freeradius-3.0.21+dfsg/src/main/radclient.c:1278:14: [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). retries = atoi(optarg); data/freeradius-3.0.21+dfsg/src/main/radclient.c:1289: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). fp = fopen(optarg, "r"); data/freeradius-3.0.21+dfsg/src/main/radclient.c:1371:17: [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). packet_code = atoi(argv[2]); data/freeradius-3.0.21+dfsg/src/main/radiusd.c:181:22: [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). default_log.fd = open(main_config.log_file, data/freeradius-3.0.21+dfsg/src/main/radiusd.c:415:13: [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). devnull = open("/dev/null", O_RDWR); data/freeradius-3.0.21+dfsg/src/main/radiusd.c:573: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(main_config.pid_file, "w"); data/freeradius-3.0.21+dfsg/src/main/radmin.c:128: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 *p, buffer[1024]; data/freeradius-3.0.21+dfsg/src/main/radmin.c:136:10: [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). port = atoi(p + 1); data/freeradius-3.0.21+dfsg/src/main/radmin.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 buffer[65536]; data/freeradius-3.0.21+dfsg/src/main/radmin.c:296: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(buffer, &magic, sizeof(magic)); data/freeradius-3.0.21+dfsg/src/main/radmin.c:339: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 *p, buffer[65536]; data/freeradius-3.0.21+dfsg/src/main/radmin.c:347: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 history_file[PATH_MAX]; data/freeradius-3.0.21+dfsg/src/main/radmin.c:350: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 *commands[MAX_COMMANDS]; data/freeradius-3.0.21+dfsg/src/main/radmin.c:570:13: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). inputfp = fopen(input_file, "r"); data/freeradius-3.0.21+dfsg/src/main/radsniff.c:48:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 timestr[50]; data/freeradius-3.0.21+dfsg/src/main/radsniff.c:142: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(pidfile, "w"); data/freeradius-3.0.21+dfsg/src/main/radsniff.c:272: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[2048]; data/freeradius-3.0.21+dfsg/src/main/radsniff.c:316: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[2048]; data/freeradius-3.0.21+dfsg/src/main/radsniff.c:319: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 src[INET6_ADDRSTRLEN]; data/freeradius-3.0.21+dfsg/src/main/radsniff.c:320: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 dst[INET6_ADDRSTRLEN]; data/freeradius-3.0.21+dfsg/src/main/radsniff.c:409: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[2048]; data/freeradius-3.0.21+dfsg/src/main/radsniff.c:412: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 src[INET6_ADDRSTRLEN]; data/freeradius-3.0.21+dfsg/src/main/radsniff.c:413: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 dst[INET6_ADDRSTRLEN]; data/freeradius-3.0.21+dfsg/src/main/radsniff.c:487: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 vector[(AUTH_VECTOR_LEN * 2) + 1]; data/freeradius-3.0.21+dfsg/src/main/radsniff.c:985: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(request->capture_p->header, header, sizeof(struct pcap_pkthdr)); data/freeradius-3.0.21+dfsg/src/main/radsniff.c:986: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(request->capture_p->data, data, header->caplen); data/freeradius-3.0.21+dfsg/src/main/radsniff.c:1944: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 errbuf[PCAP_ERRBUF_SIZE]; /* Error buffer */ data/freeradius-3.0.21+dfsg/src/main/radsniff.c:1947: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[1024]; data/freeradius-3.0.21+dfsg/src/main/radsniff.c:2026:24: [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). conf->buffer_pkts = atoi(optarg); data/freeradius-3.0.21+dfsg/src/main/radsniff.c:2034:18: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). conf->limit = atoi(optarg); data/freeradius-3.0.21+dfsg/src/main/radsniff.c:2096:11: [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). port = atoi(optarg); data/freeradius-3.0.21+dfsg/src/main/radsniff.c:2150: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). conf->stats.interval = atoi(optarg); data/freeradius-3.0.21+dfsg/src/main/radsniff.c:2159:26: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). conf->stats.timeout = atoi(optarg); data/freeradius-3.0.21+dfsg/src/main/radwho.c:109: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 buf[8]; data/freeradius-3.0.21+dfsg/src/main/radwho.c:198: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 othername[256]; data/freeradius-3.0.21+dfsg/src/main/radwho.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 nasname[1024]; data/freeradius-3.0.21+dfsg/src/main/radwho.c:200: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 session_id[sizeof(rt.session_id)+1]; data/freeradius-3.0.21+dfsg/src/main/radwho.c:208: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[2048]; data/freeradius-3.0.21+dfsg/src/main/radwho.c:261:15: [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). nas_port = atoi(optarg); data/freeradius-3.0.21+dfsg/src/main/radwho.c:371: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 ((fp = fopen(radutmp_file, "r")) == NULL) { data/freeradius-3.0.21+dfsg/src/main/radwho.c:389:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char name[sizeof(rt.login) + 1]; data/freeradius-3.0.21+dfsg/src/main/radwho.c:426: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(session_id, rt.session_id, sizeof(rt.session_id)); data/freeradius-3.0.21+dfsg/src/main/radwho.c:441: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(nasname, rt.login, sizeof(rt.login)); data/freeradius-3.0.21+dfsg/src/main/radwho.c:487: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(nasname, rt.caller_id, data/freeradius-3.0.21+dfsg/src/main/radwho.c:502: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(name, rt.login, sizeof(rt.login)); data/freeradius-3.0.21+dfsg/src/main/realms.c:565: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 buffer[INET6_ADDRSTRLEN + 3]; data/freeradius-3.0.21+dfsg/src/main/realms.c:599: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(home2, home, sizeof(*home2)); data/freeradius-3.0.21+dfsg/src/main/realms.c:660: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 buffer[INET6_ADDRSTRLEN + 3]; data/freeradius-3.0.21+dfsg/src/main/realms.c:857: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 buffer[INET6_ADDRSTRLEN + 3]; data/freeradius-3.0.21+dfsg/src/main/realms.c:1527: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(q, name, (p - name)); data/freeradius-3.0.21+dfsg/src/main/regex.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, value, len); data/freeradius-3.0.21+dfsg/src/main/regex.c:157:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(out, &p, sizeof(*out)); data/freeradius-3.0.21+dfsg/src/main/regex.c:216:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(out, &p, sizeof(*out)); data/freeradius-3.0.21+dfsg/src/main/regex.c:270: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, start, len); data/freeradius-3.0.21+dfsg/src/main/session.c:135: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 address[16]; data/freeradius-3.0.21+dfsg/src/main/session.c:136: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 port[11]; data/freeradius-3.0.21+dfsg/src/main/soh.c:431: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(mode.corrid, data, 24); data += 24; data/freeradius-3.0.21+dfsg/src/main/state.c:284: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(entry->state + (i * 4), &x, sizeof(x)); data/freeradius-3.0.21+dfsg/src/main/state.c:311: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(entry->state, vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/main/state.c:379: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(my_entry.state, vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/main/state.c:503: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(buffer + (i * 4), &x, sizeof(x)); data/freeradius-3.0.21+dfsg/src/main/threads.c:260: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(&ret, &thread, sizeof(thread)); data/freeradius-3.0.21+dfsg/src/main/tls.c:171: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[256]; data/freeradius-3.0.21+dfsg/src/main/tls.c:373: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 buffer[2 * PSK_MAX_PSK_LEN + 4]; /* allow for too-long keys */ data/freeradius-3.0.21+dfsg/src/main/tls.c:933: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(rec->data + rec->used, ptr, added); data/freeradius-3.0.21+dfsg/src/main/tls.c:951:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr, rec->data, taken); data/freeradius-3.0.21+dfsg/src/main/tls.c:967: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[32]; data/freeradius-3.0.21+dfsg/src/main/tls.c:1004: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, "UNKNOWN TLS VERSION '%04X'", tls_session->info.version); data/freeradius-3.0.21+dfsg/src/main/tls.c:1381: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[2 * MAX_SESSION_SIZE + 1]; data/freeradius-3.0.21+dfsg/src/main/tls.c:1394: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 filename[3 * MAX_SESSION_SIZE + 1]; data/freeradius-3.0.21+dfsg/src/main/tls.c:1417: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[2 * MAX_SESSION_SIZE + 1]; data/freeradius-3.0.21+dfsg/src/main/tls.c:1433: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 filename[3 * MAX_SESSION_SIZE + 1]; data/freeradius-3.0.21+dfsg/src/main/tls.c:1464:8: [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(filename, O_RDWR|O_CREAT|O_EXCL, S_IWUSR); data/freeradius-3.0.21+dfsg/src/main/tls.c:1575: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[2 * MAX_SESSION_SIZE + 1]; data/freeradius-3.0.21+dfsg/src/main/tls.c:1606: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 filename[3 * MAX_SESSION_SIZE + 1]; data/freeradius-3.0.21+dfsg/src/main/tls.c:1618:8: [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(filename, O_RDONLY); data/freeradius-3.0.21+dfsg/src/main/tls.c:1797: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 hostheader[1024]; data/freeradius-3.0.21+dfsg/src/main/tls.c:2068:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 const *cert_attr_names[9][2] = { data/freeradius-3.0.21+dfsg/src/main/tls.c:2117: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 subject[1024]; /* Used for the subject name */ data/freeradius-3.0.21+dfsg/src/main/tls.c:2118: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 issuer[1024]; /* Used for the issuer name */ data/freeradius-3.0.21+dfsg/src/main/tls.c:2119: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 attribute[1024]; data/freeradius-3.0.21+dfsg/src/main/tls.c:2120: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 value[1024]; data/freeradius-3.0.21+dfsg/src/main/tls.c:2121: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 common_name[1024]; data/freeradius-3.0.21+dfsg/src/main/tls.c:2122: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 cn_str[1024]; data/freeradius-3.0.21+dfsg/src/main/tls.c:2123: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/freeradius-3.0.21+dfsg/src/main/tls.c:2199: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(p, "%02x", (unsigned int)sn->data[i]); data/freeradius-3.0.21+dfsg/src/main/tls.c:2213: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(buf, (char*) asn_time->data, asn_time->length); data/freeradius-3.0.21+dfsg/src/main/tls.c:2226: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(buf, (char*) asn_time->data, asn_time->length); data/freeradius-3.0.21+dfsg/src/main/tls.c:2548: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 filename[3 * MAX_SESSION_SIZE + 1]; data/freeradius-3.0.21+dfsg/src/main/tls.c:2554:9: [2] (tmpfile) mkstemp: Potential for temporary file vulnerability in some circumstances. Some older Unix-like systems create temp files with permission to write by all by default, so be sure to set the umask to override this. Also, some older Unix systems might fail to use O_EXCL when opening the file, so make sure that O_EXCL is used by the library (CWE-377). fd = mkstemp(filename); data/freeradius-3.0.21+dfsg/src/main/tls.c:2874: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 cmd[256]; data/freeradius-3.0.21+dfsg/src/main/tls.c:3768: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 buffer[2 * MAX_SESSION_SIZE + 1]; data/freeradius-3.0.21+dfsg/src/main/tls.c:3852: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 filename[3 * MAX_SESSION_SIZE + 1], buf[1024]; data/freeradius-3.0.21+dfsg/src/main/tls.c:3859: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). vp_file = fopen(filename, "w"); data/freeradius-3.0.21+dfsg/src/main/tls.c:3904: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 buffer[2 * MAX_SESSION_SIZE + 1]; data/freeradius-3.0.21+dfsg/src/main/tls.c:3914: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 filename[3 * MAX_SESSION_SIZE + 1]; data/freeradius-3.0.21+dfsg/src/main/tls_listen.c:315: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 host_ipaddr[128]; data/freeradius-3.0.21+dfsg/src/main/tls_listen.c:431: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[1]; data/freeradius-3.0.21+dfsg/src/main/tls_listen.c:679: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[256]; data/freeradius-3.0.21+dfsg/src/main/tls_listen.c:713: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(packet->data, data, packet->data_len); data/freeradius-3.0.21+dfsg/src/main/tls_listen.c:714: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(packet->vector, packet->data + 4, 16); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1320: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(buff, vpt->name, vpt->len >= bufflen ? bufflen : vpt->len + 1); data/freeradius-3.0.21+dfsg/src/main/unittest.c:261: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, vp->vp_strvalue, len); data/freeradius-3.0.21+dfsg/src/main/unittest.c:289: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 + 2, vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/main/unittest.c:524: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 input[8192]; data/freeradius-3.0.21+dfsg/src/main/unittest.c:525: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 output[8192]; data/freeradius-3.0.21+dfsg/src/main/unittest.c:799: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(input_file, "r"); data/freeradius-3.0.21+dfsg/src/main/unittest.c:847: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). fp = fopen(filter_file, "r"); data/freeradius-3.0.21+dfsg/src/main/unittest.c:874: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(output_file, "w"); data/freeradius-3.0.21+dfsg/src/main/util.c:261: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(dir, O_DIRECTORY); data/freeradius-3.0.21+dfsg/src/main/util.c:713: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(&(fake->log), &(request->log), sizeof(fake->log)); data/freeradius-3.0.21+dfsg/src/main/util.c:1153:22: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 rad_mode_to_str(char out[10], mode_t mode) data/freeradius-3.0.21+dfsg/src/main/util.c:1166:22: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 rad_mode_to_oct(char out[5], mode_t mode) data/freeradius-3.0.21+dfsg/src/main/version.c:116: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[18]; data/freeradius-3.0.21+dfsg/src/main/version.c:119: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. p += sprintf(p, "%u.%u.%u", data/freeradius-3.0.21+dfsg/src/main/version.c:134:3: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(p, "dev"); data/freeradius-3.0.21+dfsg/src/main/version.c:139: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(p, "beta %u", 0x0000000f & v); data/freeradius-3.0.21+dfsg/src/main/version.c:141:3: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(p, "release"); data/freeradius-3.0.21+dfsg/src/main/version.c:170: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[28]; data/freeradius-3.0.21+dfsg/src/main/version.c:189: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[256]; data/freeradius-3.0.21+dfsg/src/main/version.c:502: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[128]; data/freeradius-3.0.21+dfsg/src/main/xlat.c:37: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_STRING_LEN]; //!< Name of the xlat expansion. data/freeradius-3.0.21+dfsg/src/main/xlat.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(&int64, vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/main/xlat.c:148: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(&int32, vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/main/xlat.c:181: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(&int64, vp->vp_ether, vp->vp_length); data/freeradius-3.0.21+dfsg/src/main/xlat.c:682:10: [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). level = atoi(fmt); data/freeradius-3.0.21+dfsg/src/main/xlat.c:1958: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(&virtual->vp_ipv6addr, data/freeradius-3.0.21+dfsg/src/main/xlat.c:1968: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(&virtual->vp_ipv6addr, data/freeradius-3.0.21+dfsg/src/main/xlat.c:2477: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(answer + total, array[i], len); data/freeradius-3.0.21+dfsg/src/main/xlat.c:2626: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(&node->attr.data, &vpt->data, sizeof(vpt->data)); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:321: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(&magic, packet->data + 236, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.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(&magic, packet->data + 4, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:363: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(packet->vector, packet->data + 28, packet->data[2]); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:399: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 type_buf[64]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:401: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 src_ip_buf[256], dst_ip_buf[256]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:451: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 type_buf[64]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:454: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 src_ip_buf[INET6_ADDRSTRLEN]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:456: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 dst_ip_buf[INET6_ADDRSTRLEN]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:756: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(&vp->vp_short, data, 2); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:762: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(&vp->vp_integer, data, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:771: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(&vp->vp_ipaddr, data, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1009: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1047: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(&vp->vp_integer, p, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1053: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(&vp->vp_ipaddr, p, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1243: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, &lvalue, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1247: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, &vp->vp_ipaddr, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1251: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, vp->vp_ether, 6); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1255: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, vp->vp_strvalue, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1259: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, vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1518: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 src_ip_buf[256]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1520: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 dst_ip_buf[256]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1617: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, &lvalue, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1623: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, &svalue, 2); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1630: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, &svalue, 2); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1636: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, &vp->vp_ipaddr, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1646: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, &lvalue, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1656: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, &lvalue, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1667: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, &lvalue, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1680: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, vp->vp_ether, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1688: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, vp->vp_strvalue, DHCP_SNAME_LEN); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1690: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, vp->vp_strvalue, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1709: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, vp->vp_strvalue, DHCP_FILE_LEN); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1711: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, vp->vp_strvalue, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1718: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, &lvalue, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1735: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1751: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(&vp->vp_integer, p, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1756: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(&vp->vp_ipaddr, p, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1762:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(q, p, dhcp_header_sizes[i]); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1887: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.arp_ha.sa_data, macaddr->vp_ether, sizeof(macaddr->vp_ether)); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1889: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.arp_ha.sa_data, macaddr->vp_octets, macaddr->vp_length); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1959: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(dhmac, vp->vp_ether, vp->length); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1965: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(ethhdr->ether_dst, eth_bcast, ETH_ADDR_LEN); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1966: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(ethhdr->ether_src, dhmac, ETH_ADDR_LEN); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:2001: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(dhpointer, packet->data, packet->data_len); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:2008: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 type_buf[64]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:2010: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 src_ip_buf[INET6_ADDRSTRLEN]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:2011: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 dst_ip_buf[INET6_ADDRSTRLEN]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:2038: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, "%02x:%02x:%02x:%02x:%02x:%02x", data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:2105: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 eth_dest[17+1]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:2106: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 eth_req_src[17+1]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:2198: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(packet->vector, packet->data + 28, packet->data[2]); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.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 type_buf[64]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:2212: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 src_ip_buf[256], dst_ip_buf[256]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcpclient.c:127: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(filename, "r"); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcpclient.c:346: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(&tval, &tv_timeout, sizeof(struct timeval)); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcpclient.c:406: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 server_addr_buf[INET6_ADDRSTRLEN]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcpclient.c:407: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 offered_addr_buf[INET6_ADDRSTRLEN]; data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcpclient.c:464:14: [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). retries = atoi(optarg); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcpclient.c:540:18: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). packet_code = atoi(argv[2]); data/freeradius-3.0.21+dfsg/src/modules/proto_vmps/vqp.c:378: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(&id, packet->data + 4, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_vmps/vqp.c:483: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(&vp->vp_ether, ptr, 6); data/freeradius-3.0.21+dfsg/src/modules/proto_vmps/vqp.c:489: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(&vp->vp_ipaddr, ptr, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_vmps/vqp.c:517: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, ptr, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/proto_vmps/vqp.c:523: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, ptr, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/proto_vmps/vqp.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(ptr + 4, &sequence, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_vmps/vqp.c:654:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr + 4, original->data + 4, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_vmps/vqp.c:691:4: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr, &vp->vp_ipaddr, 4); data/freeradius-3.0.21+dfsg/src/modules/proto_vmps/vqp.c:695:4: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr, vp->vp_ether, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/proto_vmps/vqp.c:701:4: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr, vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_attr_filter/rlm_attr_filter.c:73: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 rule[1024], pair[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_attr_filter/rlm_attr_filter.c: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_cache/drivers/rlm_cache_memcached/rlm_cache_memcached.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[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_cache/rlm_cache.c:445: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[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_chap/rlm_chap.c:105: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 buffer[MAX_STRING_LEN * 2 + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/mod.c:352: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 value[255]; /* radius attribute value */ data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/mod.c:448: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 value[255]; /* store radius attribute values and our timestamp */ data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/mod.c:542: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 vpath[256], vid[MAX_KEY_SIZE], vkey[MAX_KEY_SIZE]; /* view path and fields */ data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/mod.c:543: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 error[512]; /* view error return */ data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/rlm_couchbase.c:187: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 dockey[MAX_KEY_SIZE]; /* our document key */ data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/rlm_couchbase.c:273: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 dockey[MAX_KEY_SIZE]; /* our document key */ data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/rlm_couchbase.c:274: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 document[MAX_VALUE_SIZE]; /* our document body */ data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/rlm_couchbase.c:275: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 element[MAX_KEY_SIZE]; /* mapped radius attribute to element name */ data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/rlm_couchbase.c:457: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 vpath[256], vkey[MAX_KEY_SIZE]; /* view path and query key */ data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/rlm_couchbase.c:458: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 docid[MAX_KEY_SIZE]; /* document id returned from view */ data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/rlm_couchbase.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 error[512]; /* view error return */ data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/rlm_couchbase.c:461: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 element[MAX_KEY_SIZE]; /* mapped radius attribute to element name */ data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c:104: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 uniqueid[UNIQUEID_MAX_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c:176: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(&counter, count_datum.dptr, sizeof(rad_counter)); data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.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 sCurrentTime[40], sNextTime[40]; data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c:281:9: [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). num = atoi(inst->reset); data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c:490: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(&next_reset, time_datum.dptr, sizeof(time_t)); data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c:510: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(&inst->last_reset, time_datum.dptr, sizeof(time_t)); data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.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(&counter, count_datum.dptr, sizeof(rad_counter)); data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c:708: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 msg[128]; data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c:764: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(&counter, count_datum.dptr, sizeof(rad_counter)); data/freeradius-3.0.21+dfsg/src/modules/rlm_cram/rlm_cram.c:71:2: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(buf+64, challenge, challen); data/freeradius-3.0.21+dfsg/src/modules/rlm_cram/rlm_cram.c:91:2: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(buf+64, challenge, challen); data/freeradius-3.0.21+dfsg/src/modules/rlm_cram/rlm_cram.c:112:2: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(buf+64, challenge, challen); data/freeradius-3.0.21+dfsg/src/modules/rlm_detail/rlm_detail.c:207: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(vp, stacked, sizeof(*vp)); data/freeradius-3.0.21+dfsg/src/modules/rlm_detail/rlm_detail.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 timestamp[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_detail/rlm_detail.c:277: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(&src_vp.vp_ipv6addr, &packet->src_ipaddr.ipaddr.ip6addr, data/freeradius-3.0.21+dfsg/src/modules/rlm_detail/rlm_detail.c:280: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(&dst_vp.vp_ipv6addr, &packet->dst_ipaddr.ipaddr.ip6addr, data/freeradius-3.0.21+dfsg/src/modules/rlm_detail/rlm_detail.c:331: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 proxy_buffer[128]; data/freeradius-3.0.21+dfsg/src/modules/rlm_detail/rlm_detail.c:352: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[DIRLEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.c:275: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(&a1[0], vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.c:286: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(&a1[a1_len], vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.c:293: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(&a1[a1_len], passwd->vp_octets, passwd->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.c:331: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(&a1[0], passwd->vp_strvalue, 32); data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.c:345: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(&a1[a1_len], nonce->vp_octets, nonce->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.c:364: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(&a1[a1_len], vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.c:384: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(&a2[0], vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.c:395: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(&a2[a2_len], vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.c:426: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(a2 + a2_len, body->vp_octets, body->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.c:449: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(&hash[0], &a1[0], a1_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.c:467: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(&kd[kd_len], nonce->vp_octets, nonce->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.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(&kd[kd_len], vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.c:502: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(&kd[kd_len], vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.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(&kd[kd_len], qop->vp_octets, qop->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_digest/rlm_digest.c:541: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(&kd[0], &hash[0], 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_dynamic_clients/rlm_dynamic_clients.c:41: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[2048]; data/freeradius-3.0.21+dfsg/src/modules/rlm_dynamic_clients/rlm_dynamic_clients.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(buffer, value, length + 1); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/eap.c:901: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(&len, eap_packet->length, sizeof(uint16_t)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/eap.c:1009: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(&len, eap_packet->length, sizeof(uint16_t)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/eap.c:1024: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(identity, &eap_packet->data[1], size); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/eap.c:1052: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(&len, eap_packet->length, sizeof(uint16_t)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/comp128.c:245: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(&x[16], rand, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/comp128.c:252: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(x, ki, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/comp128.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(x, ki, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/comp128.c:296: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(km_rm, rand, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/comp128.c:297: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(km_rm + 16, kxor, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/comp128.c:382: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(sres, buffer, 4); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/comp128.c:383: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(kc, buffer + 4, 8); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/comp128.c:412:18: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). !(version = atoi(argv[3]))) { data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eap_chbind.c:274:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr, vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eap_tls.c:261: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(reply.data, &nlen, lbit); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eap_tls.c:593: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(&data_len, &eap_ds->response->type.data[1], 4); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eap_tls.c:628: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(&data_len, &eap_ds->response->type.data[1], sizeof(uint32_t)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eap_tls.c:664: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(tlspacket->data, data, data_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eap_tls.c:921: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 buffer[2 * MAX_SESSION_SIZE + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eap_tls.c:1026:19: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. if (reply->dlen) memcpy(ptr, reply->data, reply->dlen); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcommon.c:159: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(header->length, &total_length, sizeof(total_length)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcommon.c:177: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(&header->data[1], reply->type.data, reply->type.length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcommon.c:378:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr, i->vp_strvalue, i->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcrypto.c:41:11: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char buf[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcrypto.c:46: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, ek->identity, ek->identitylen); p = p+ek->identitylen; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcrypto.c:47: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, ek->Kc[0], EAPSIM_KC_SIZE); p = p+EAPSIM_KC_SIZE; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcrypto.c:48: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, ek->Kc[1], EAPSIM_KC_SIZE); p = p+EAPSIM_KC_SIZE; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcrypto.c:49: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, ek->Kc[2], EAPSIM_KC_SIZE); p = p+EAPSIM_KC_SIZE; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcrypto.c:50: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, ek->nonce_mt, sizeof(ek->nonce_mt)); p=p+sizeof(ek->nonce_mt); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcrypto.c:51: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, ek->versionlist, ek->versionlistlen);p=p+ek->versionlistlen; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcrypto.c:52: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, ek->versionselect, sizeof(ek->versionselect)); p=p+sizeof(ek->versionselect); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcrypto.c:96: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(ek->K_encr, fk + 0, 16); /* 128 bits for encryption */ data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcrypto.c:97: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(ek->K_aut, fk + 16, EAPSIM_AUTH_SIZE); /*128 bits for auth */ data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcrypto.c:98: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(ek->msk, fk + 32, 64); /* 64 bytes for Master Session Key */ data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapcrypto.c:99: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(ek->emsk, fk + 96, 64); /* 64- extended Master Session Key */ data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapsimlib.c:207: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(&attr[2], vp->vp_strvalue, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapsimlib.c:230: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. unsigned char sha1digest[20]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapsimlib.c:244: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(hdr->length, &total_length, sizeof(total_length)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapsimlib.c:249: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(&hdr->data[1], encodedmsg, encoded_size); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapsimlib.c:252: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(&hdr->data[encoded_size+1], append, appendlen); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapsimlib.c:262: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(macspace, sha1digest, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapsimlib.c:343: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, &attr[2], eapsim_len-2); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapsimlib.c:394: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(buffer, e, elen); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/eapsimlib.c:395: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(buffer + elen, extra, extralen); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/fips186prf.c:137: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(zeros, xval.p, 20); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/fips186prf.c:156: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(zeros, xval.p, 20); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/fips186prf.c:169: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, &w_0, 20); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/fips186prf.c:172: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, &w_1, 20); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c:41:11: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char a[HMAC_MAX_MD_CBLOCK]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c:67: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(out, a, out_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.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(buf + SHA1_DIGEST_LENGTH, prf_label, prf_size); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c:104:12: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. if (seed) memcpy(buf + SHA1_DIGEST_LENGTH + prf_size, seed, seed_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c:112: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(out, buf, MIN(out_len, SHA1_DIGEST_LENGTH)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c:119:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(&out[pos], buf, MIN(out_len - pos, SHA1_DIGEST_LENGTH)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c:173: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, prf_label, prf_size); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c:176: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, s->s3->client_random, SSL3_RANDOM_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c:180: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, s->s3->server_random, SSL3_RANDOM_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c:217: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, FR_TLS_PRF_CHALLENGE, sizeof(FR_TLS_PRF_CHALLENGE)-1); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c:219: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, s->s3->client_random, SSL3_RANDOM_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c:221: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, s->s3->server_random, SSL3_RANDOM_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.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(buffer, out, size); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.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(p, prf_label, len); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/mem.c:317: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(handler->state + i * 4, &lvalue, data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:65:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 filesecret[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:97: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 password[256]; //!< copy of User-Password (or CHAP-Password). data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:147: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 password[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:315:13: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). file_in = fopen(filename, "r"); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:453: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 + 2, vp->vp_octets, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:681: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 buffer[33]; /* 32 hexits (16 bytes) + 1 */ data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:720: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, "%02x", ess.keys.rand[idx][i]); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:729: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, "%02x", ess.keys.sres[idx][i]); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:738: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, "%02x", ess.keys.Kc[idx][i]); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:794: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(eap_context->eap.sim.keys.versionlist, (unsigned char const *)(versions+1), data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:857: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(eap_context->eap.sim.keys.versionselect, &no_versions, 2); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:876: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[2], nonce, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:882: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(eap_context->eap.sim.keys.nonce_mt, nonce, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:904: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, &no_idlen, 2); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:905: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 + 2, vp->vp_strvalue, idlen); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:911: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(eap_context->eap.sim.keys.identity, vp->vp_strvalue, idlen); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1102: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+EAPSIM_SRES_SIZE * 0, sres1->vp_strvalue, EAPSIM_SRES_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1103: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+EAPSIM_SRES_SIZE * 1, sres2->vp_strvalue, EAPSIM_SRES_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1104: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+EAPSIM_SRES_SIZE * 2, sres3->vp_strvalue, EAPSIM_SRES_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1130: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 statenamebuf[32], subtypenamebuf[32]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1306: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, &lg_response, 1); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1307: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 + 1, response, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1328: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 src_addr[15+1] = ""; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1329: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 dst_addr[15+1] = ""; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1484: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[128]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1847: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1855: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(buffer, server_arg + 1, p - server_arg - 1); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1877: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). if (portname) server_port = atoi(portname); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1935:15: [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). parallel = atoi(optarg); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1956:14: [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). retries = atoi(optarg); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1976: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). fp = fopen(optarg, "r"); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:2061:17: [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). packet_code = atoi(argv[2]); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/rlm_eap.c:87: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 src1[64], src2[64]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/rlm_eap.c:483: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(new, old, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:116: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(t->keyblock, &buf[ksize], sizeof(*t->keyblock)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:120: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(t->simck, t->keyblock, EAP_FAST_SKS_LEN); /* S-IMCK[0] = session_key_seed */ data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c: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(t->simck, imck, EAP_FAST_SIMCK_LEN); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:142: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(t->cmk, &imck[EAP_FAST_SIMCK_LEN], EAP_FAST_CMK_LEN); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:236: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(pac.info.a_id_info.data, t->authority_identity, alen); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:254: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(pac.opaque.aad, t->a_id, PAC_A_ID_LENGTH); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:387: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(&status, data, 2); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:514: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(vp->vp_filter, p, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:526: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(&vp->vp_integer, p, 4); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:531: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(&vp->vp_integer64, p, 8); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.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(&vp->vp_date, p, 4); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:541: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(vp->vp_ether, p, 6); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:545: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(&vp->vp_ipaddr, p, 4); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:549: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(vp->vp_ifid, p, 8); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:553: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(&vp->vp_ipv6addr, p, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:561: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(vp->vp_ipv6prefix, p, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:570: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(vp->vp_ipv4prefix, p, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:586: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(vp->vp_ipv4prefix + 2, &addr, sizeof(addr)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:591: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(&vp->vp_integer, p, 4); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:785: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(t->isk.mppe_send, vp->vp_octets, CHAP_VALUE_LENGTH); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:791: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(t->isk.mppe_recv, vp->vp_octets, CHAP_VALUE_LENGTH); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:1103:6: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(&my_binding.reserved, vp->vp_octets, sizeof(my_binding) - 4); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.c:1190: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/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.h:132:11: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char aad[PAC_A_ID_LENGTH]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.h:133:11: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char iv[EVP_MAX_IV_LENGTH]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/eap_fast.h:134:11: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char tag[EVP_GCM_TLS_TAG_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/rlm_eap_fast.c:175: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(seed, server_random, SSL3_RANDOM_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/rlm_eap_fast.c:176: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(&seed[SSL3_RANDOM_SIZE], client_random, SSL3_RANDOM_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_fast/rlm_eap_fast.c:325: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(t->pac.key, vp->vp_octets, PAC_KEY_LENGTH); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_gtc/rlm_eap_gtc.c: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 challenge_str[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_gtc/rlm_eap_gtc.c:111: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(eap_ds->request->type.data, challenge_str, length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ikev2/ike_conf.c:305: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(&ike_id, &id, sizeof(id)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ikev2/ike_conf.c:411: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). FILE *fp=fopen(filename,"r"); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ikev2/rlm_eap_ikev2.c: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(eap_ds->request->type.data, out + 5, len - 5); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ikev2/rlm_eap_ikev2.c:422: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(in + 5, eap_ds->response->type.data, eap_ds->response->length - 5); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c:134: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(packet->challenge, data->challenge, packet->count); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c:150: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(packet->name, &data->challenge[packet->count], name_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c:198:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(out, password->vp_octets, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c:229: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(session->peer_response, response, sizeof(response)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c:282: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(reply->name, user_name->vp_strvalue, user_name->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c:314: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, mppe, 16); /* MPPEHASH */ data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c:316: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, packet->challenge, 8); /* APC */ data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c:318: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, reply->challenge, 24); /* APR */ data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c:320: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, session->peer_challenge, 8); /* PC */ data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c:322: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, session->peer_response, 24); /* PR */ data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c:330: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(q, "leap:session-key="); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.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(q + 17, hash, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c:386: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(reply->name, user_name->vp_strvalue, user_name->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c:425: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(&data->challenge[0], reply->challenge, reply->count); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/eap_leap.c:426: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(&data->challenge[reply->count], reply->name, reply->name_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/rlm_eap_leap.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(session->peer_challenge, reply->challenge, reply->count); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:54:24: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. #define uchar unsigned char data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:164: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 out[64]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:190: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 pk1[56]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:191: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 c[28]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:192: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 d[28]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:193: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 cd[56]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:194: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 ki[16][48]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:195: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 pd1[64]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.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 l[32], r[32]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:197: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 rl[64]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:222: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 er[48]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:223: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 erk[48]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:224: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 b[8][6]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:225: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 cb[32]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:226: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 pcb[32]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:227: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 r2[32]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:287: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 outb[64]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:288: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 inb[64]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:289: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 keyb[64]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:290:11: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char key2[8]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:319:11: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char p21[21]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_leap/smbdes.c:322: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(p21, win_password, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_md5/eap_md5.c:105: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(packet->value, data->value_name, packet->value_size); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_md5/eap_md5.c:118: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(packet->name, data->value_name + packet->value_size, data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_md5/eap_md5.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 string[1 + MAX_STRING_LEN*2]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_md5/eap_md5.c:154: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(ptr, password->vp_strvalue, password->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_md5/eap_md5.c:161: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(ptr, challenge, MD5_CHALLENGE_LEN); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_md5/eap_md5.c:204:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr, reply->value, reply->value_size); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_md5/eap_md5.c:217:4: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr, reply->name, name_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_md5/rlm_eap_md5.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(handler->opaque, reply->value, reply->value_size); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:146: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(hdr->ms_length, &length, sizeof(uint16_t)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:154:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr, reply->vp_octets, reply->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:156:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy((ptr + reply->vp_length), inst->identity, strlen(inst->identity)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:186: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((eap_ds->request->type.data + 2), &length, sizeof(uint16_t)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:187: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((eap_ds->request->type.data + 4), reply->vp_strvalue + 1, 42); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:205: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((eap_ds->request->type.data + 2), &length, sizeof(uint16_t)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:209: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((eap_ds->request->type.data + 4), data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.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(data->challenge, challenge->vp_octets, MSCHAPV2_CHALLENGE_LEN); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:437: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 + 2, eap_ds->response->type.data + 520, 66); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:458: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 + 4, eap_ds->response->type.data + 4 + copied, to_copy); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:591: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 + 2, &eap_ds->response->type.data[5], MSCHAPV2_RESPONSE_LEN - 2); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:601: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(q, &eap_ds->response->type.data[4 + MSCHAPV2_RESPONSE_LEN], name->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:702: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 buf[34]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_peap/peap.c:301: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 + EAP_HEADER_LEN, data, total); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_peap/peap.c:306: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, data, total); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_peap/peap.c:944: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(q + EAP_HEADER_LEN + 1, data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/eap_pwd.c:93: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(result + len, digest, resultbytelen - len); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/eap_pwd.c:95: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(result + len, digest, mdlen); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/eap_pwd.c:730: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(msk, msk_emsk, 64); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/eap_pwd.c:731: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(emsk, msk_emsk + 64, 64); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/eap_pwd.h:84: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 peer_id[MAX_STRING_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c:130: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(hdr->data, (char *)&totlen, sizeof(totlen)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.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(hdr->data + sizeof(uint16_t), data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c:139: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(hdr->data, session->out + session->out_pos, (session->mtu - sizeof(pwd_hdr))); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c:147: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(hdr->data, session->out + session->out_pos, data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c:248: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(packet->token, (char *)&session->token, 4); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c:250: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(packet->identity, inst->server_id, session->out_len - sizeof(pwd_id_packet_t) ); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c:342: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(session->in + session->in_pos, in, in_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c:369: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(session->in + session->in_pos, in, in_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c:402:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(ptr, (char *)&packet->group_num, sizeof(uint16_t)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c:414: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(session->peer_id, packet->identity, session->peer_id_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c:568: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(session->out, session->my_confirm, SHA256_DIGEST_LENGTH); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:86: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(ess->keys.versionlist, words + 1, ess->keys.versionlistlen); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:159: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 buffer[33]; /* 32 hexits (16 bytes) + 1 */ data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:167: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. p += sprintf(p, "%02x", ess->keys.rand[idx][i]); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:173: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. p += sprintf(p, "%02x", ess->keys.sres[idx][i]); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:179: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. p += sprintf(p, "%02x", ess->keys.Kc[idx][i]); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.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(ess->keys.rand[idx], vp->vp_strvalue, EAPSIM_RAND_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:224: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(ess->keys.sres[idx], vp->vp_strvalue, EAPSIM_SRES_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:242: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(ess->keys.Kc[idx], vp->vp_strvalue, EAPSIM_KC_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.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(p, ess->keys.rand[0], EAPSIM_RAND_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:304: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, ess->keys.rand[1], EAPSIM_RAND_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:306: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, ess->keys.rand[2], EAPSIM_RAND_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:320: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(ess->keys.identity, handler->identity, ess->keys.identitylen); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:329: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(&len, newvp->vp_octets, sizeof(uint16_t)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:333: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(ess->keys.identity, newvp->vp_octets + 2, ess->keys.identitylen); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:540: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(ess->keys.nonce_mt, nonce_vp->vp_strvalue + 2, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:567: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, ess->keys.sres[0], EAPSIM_SRES_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:569: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, ess->keys.sres[1], EAPSIM_SRES_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:571: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, ess->keys.sres[2], EAPSIM_SRES_SIZE); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:580: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 macline[20*3]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:591: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(m, "%02x", calcmac[i]); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_tls/rlm_eap_tls.c:223: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. unsigned char buffer[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_tnc/rlm_eap_tnc.c:138: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 buff[71]; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_tnc/rlm_eap_tnc.c:215: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(handler->opaque, &conn_id, sizeof(TNC_ConnectionID)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_tnc/rlm_eap_tnc.c:340: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(handler->eap_ds->request->type.data, data, datalen); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:253: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(buffer + 2, data, size); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:311: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(&vp->vp_integer, data, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:321: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(&vp->vp_integer64, data, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:337: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(&vp->vp_ipaddr, data, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:356: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(&vp->vp_signed, data, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:362: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(&vp->vp_ipv6addr, data, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:367: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(vp->vp_ipv6prefix, data, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:506: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, &attr, sizeof(attr)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:516: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, &length, sizeof(length)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:521: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, &vendor, sizeof(vendor)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:526: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, &length, sizeof(length)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:535: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, &attr, sizeof(attr)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:541: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, &attr64, sizeof(attr64)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:546: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, &vp->vp_ipaddr, 4); /* network order */ data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:553: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, vp->vp_strvalue, vp->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_exec/rlm_exec.c:297: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 out[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_exec/rlm_exec.c:375: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 out[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_exec/rlm_exec.c:430: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 out[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_expiration/rlm_expiration.c:38: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 date[50]; data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/paircmp.c:48: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 rest[MAX_STRING_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/paircmp.c:157:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char name[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/paircmp.c:158: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 value[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:530:11: [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). result = atoi(fmt); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:835:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(out, p, chr_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:1084: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_ref[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:1130: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_ref[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:1456: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(buff, p, q - p); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:1466: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(buff, p, q - p); data/freeradius-3.0.21+dfsg/src/modules/rlm_files/rlm_files.c:354: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[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:97: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 cli[32]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:104: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 key[16]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:159: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 str[32]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:160: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 init_str[17]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:245: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(init_str,"%016d",j); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:247: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(key.key, init_str,16); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:289: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(&num, data_datum.dptr, sizeof(int)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:335: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 str[32]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:337: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 hex_str[35]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:338: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 xlat_str[MAX_STRING_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:364: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(key.key, key_str, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:391: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(&entry, data_datum.dptr, sizeof(ippool_info)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:447: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 str[32]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:449: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 hex_str[35]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:450: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 xlat_str[MAX_STRING_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:502: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.key, key_str, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:516: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(&entry, data_datum.dptr, sizeof(ippool_info)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:582: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(&entry,data_datum.dptr, sizeof(ippool_info)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:605: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(&entry,data_datum.dptr, sizeof(ippool_info)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:631: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(&num,data_datum.dptr, sizeof(int)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:674: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(key_tmp.key,key_str,16); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:739: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(key.key, key_str, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:756: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(&num,data_datum.dptr,sizeof(int)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:76: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 cli[32]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:84: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 nas[MAX_NAS_NAME_SIZE]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c: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 key[16]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:118: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 hex_str[35]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:157: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 md5_input_str[MAX_STRING_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:166: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(key.key, key_str, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:177: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(&entry, data_datum.dptr, sizeof(ippool_info)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:206: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(&num, data_datum.dptr, sizeof(int)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:235: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(&entry, data_datum.dptr, sizeof(ippool_info)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:244: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(&num, data_datum.dptr, sizeof(int)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:275: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(key_tmp.key, key_str, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:309: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(key.key, key_str, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:327: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(&num, data_datum.dptr, sizeof(int)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:366: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 hex_str[35]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:384: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 md5_input_str[MAX_STRING_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:387: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(&old_key, key_datum.dptr, sizeof(struct old_ippool_key)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:395: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(key.key, key_str, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:436: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 hex_str[35]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:462: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(&old_key, key_datum.dptr, sizeof(struct old_ippool_key)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:464: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(&key, key_datum.dptr, sizeof(struct ippool_key)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:472: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(&info, data_datum.dptr, sizeof(struct ippool_info)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:473: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(&ipaddr, &info.ipaddr, 4); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:482: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(key_str, key.key, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:521: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(&num, data_datum.dptr, sizeof(int)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:547: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(&num, data_datum.dptr, sizeof(int)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:560: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(key_str, key.key, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_krb5/rlm_krb5.c:68: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 keytab_name[200]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/attrmap.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 attr_buff[1024 + 1]; /* X.501 says we need to support at least 1024 chars for attr names */ data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/edir.c:173: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[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/edir.c:223: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(password, buffer, bufsize); data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/groups.c:61: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 base_dn_buff[LDAP_MAX_DN_STR_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/groups.c:62: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[LDAP_MAX_GROUP_NAME_LEN + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/groups.c:274: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 *group_name[LDAP_MAX_CACHEABLE + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/groups.c:277: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 *group_dn[LDAP_MAX_CACHEABLE + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/groups.c:428: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 base_dn_buff[LDAP_MAX_DN_STR_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/groups.c:431: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 filter[LDAP_MAX_FILTER_STR_LEN + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/groups.c:542: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 base_dn_buff[LDAP_MAX_DN_STR_LEN + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/groups.c:543: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 filter[LDAP_MAX_FILTER_STR_LEN + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/groups.c:577:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char name_filter[LDAP_MAX_FILTER_STR_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/ldap.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(out, in->bv_val, in->bv_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/ldap.c:355: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[LDAP_MAX_FILTER_STR_LEN + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/ldap.c:844: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(&search_attrs, &attrs, sizeof(attrs)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/ldap.c:1080: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 filter_buff[LDAP_MAX_FILTER_STR_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/ldap.c:1082: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 base_dn_buff[LDAP_MAX_DN_STR_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/ldap.h:322: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 const *attrs[LDAP_MAX_ATTRMAP + LDAP_MAP_RESERVED + 1]; //!< Reserve some space for access attributes data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c:342: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(out, values[0]->bv_val, values[0]->bv_len + 1); /* +1 as strlcpy expects buffer size */ data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c:579: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c:1254: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 sasl_mech_buff[LDAP_MAX_DN_STR_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c:1255: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 sasl_proxy_buff[LDAP_MAX_DN_STR_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c:1256: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 sasl_realm_buff[LDAP_MAX_DN_STR_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c:1392: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 filter_buff[LDAP_MAX_FILTER_STR_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c:1542: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 password[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c:1613: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 profile_buff[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c:1697: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 *passed[LDAP_MAX_ATTRMAP * 2]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c:1700: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 *expanded[LDAP_MAX_ATTRMAP]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c:1715: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[MAX_STRING_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c:1816: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(&(passed[last_pass]), &value, sizeof(passed[last_pass])); data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c:1859: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(&(mod_s[total].mod_type), &attr, sizeof(mod_s[total].mod_type)); data/freeradius-3.0.21+dfsg/src/modules/rlm_linelog/rlm_linelog.c:191: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[2048]; data/freeradius-3.0.21+dfsg/src/modules/rlm_linelog/rlm_linelog.c:192: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/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/rlm_logintime.c:108:9: [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). scan = atoi(p); data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/rlm_logintime.c:118:9: [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). scan = atoi(p); data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/rlm_logintime.c:128:10: [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). scan = atoi(p + 1); data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/timestr.c:90:44: [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). end = 600 * val(p[0]) + 60 * val(p[1]) + atoi(p + 2); data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/timestr.c:98:48: [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). start = 600 * val(tm[0]) + 60 * val(tm[1]) + atoi(tm + 2); data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/timestr.c:180: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[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/timestr.c:202: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 bitmap[WEEKMIN / 8]; data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/timestr.c:208: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 null[8]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/auth_wbclient.c:95: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 user_name_buf[500]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/auth_wbclient.c:96: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 domain_name_buf[500]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/auth_wbclient.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(resp, response, NT_LENGTH); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/auth_wbclient.c:213: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(nthashhash, info->user_session_key, NT_DIGEST_LENGTH); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/mschap.c:83: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(challenge, hash, 8); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:142: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(pUserLocation, pValueEntry->fAttributeValueData.fBufferData, pValueEntry->fAttributeValueData.fBufferLength); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:149: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(*outUserName, pValueEntry->fAttributeValueData.fBufferData, pValueEntry->fAttributeValueData.fBufferLength); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:309: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(&(tDataBuff->fBufferData[uiCurr]), &uiLen, sizeof(uiLen)); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.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(&(tDataBuff->fBufferData[uiCurr]), shortUserName, uiLen); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:324: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(&(tDataBuff->fBufferData[uiCurr]), &uiLen, sizeof(uiLen)); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:326: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(&(tDataBuff->fBufferData[uiCurr]), &(challenge->vp_strvalue[0]), data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:340: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(&(tDataBuff->fBufferData[uiCurr]), &uiLen, sizeof(uiLen)); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:342: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(&(tDataBuff->fBufferData[uiCurr]), &(response->vp_strvalue[2]), data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:357: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(&(tDataBuff->fBufferData[uiCurr]), &uiLen, sizeof(uiLen)); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:359: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(&(tDataBuff->fBufferData[uiCurr]), &(response->vp_strvalue[26]), data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:365: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(&(tDataBuff->fBufferData[uiCurr]), &uiLen, sizeof(uiLen)); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:367: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(&(tDataBuff->fBufferData[uiCurr]), username_string, uiLen); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:380: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 mschap_reply[42] = { '\0' }; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:383: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(&(mschap_reply[2]), &(pStepBuff->fBufferData[4]), len); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:498: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(out + (2 * i), "%02x", data[i]); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:700: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 + 1, value, len); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:706: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 + 1, value, len); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:781: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[2048]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:836: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. len = sprintf(buf, "new-nt-password-blob: "); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:846: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. len = sprintf(buf, "old-nt-hash-blob: "); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:860: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. len = sprintf(buf, "new-lm-password-blob: %01032i\n", 0); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:865: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. len = sprintf(buf, "old-lm-hash-blob: %032i\n", 0); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:943: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 result[253]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:1147: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:1339:8: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(masterkey,digest,16); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:1365:8: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(sesskey,digest,keylen); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:1397: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 (sendkey, enckey1, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:1398: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 (recvkey, enckey2, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:1452: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 new_challenge[33], buffer[128]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:1561: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 msch2resp[42]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:1742: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(new_nt_encrypted + new_nt_enc_len, nt_enc->vp_octets + 4, nt_enc->vp_length - 4); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:1772: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 buffer[128]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:1808: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 + 2, cpw->vp_octets + 18, 48); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:2030: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(mppe_sendkey + 8, nthashhash, NT_DIGEST_LENGTH); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:56:24: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. #define uchar unsigned char data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:166: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 out[64]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:192: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 pk1[56]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:193: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 c[28]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:194: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 d[28]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:195: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 cd[56]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.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 ki[16][48]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:197: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 pd1[64]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:198: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 l[32], r[32]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.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 rl[64]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:224: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 er[48]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:225: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 erk[48]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:226: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 b[8][6]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:227: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 cb[32]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:228: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 pcb[32]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:229: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 r2[32]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:289: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 outb[64]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:290: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 inb[64]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:291: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 keyb[64]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:292:11: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char key2[8]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbdes.c:344: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(p21, win_password, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbencrypt.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 password[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbencrypt.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 ntpass[33]; data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbencrypt.c:68: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 lmpass[33]; data/freeradius-3.0.21+dfsg/src/modules/rlm_opendirectory/rlm_opendirectory.c:151: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( pUserLocation, pValueEntry->fAttributeValueData.fBufferData, pValueEntry->fAttributeValueData.fBufferLength ); data/freeradius-3.0.21+dfsg/src/modules/rlm_opendirectory/rlm_opendirectory.c:161: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( pUserName, pValueEntry->fAttributeValueData.fBufferData, pValueEntry->fAttributeValueData.fBufferLength ); data/freeradius-3.0.21+dfsg/src/modules/rlm_opendirectory/rlm_opendirectory.c:208: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( &(tDataBuff->fBufferData[ uiCurr ]), &uiLen, sizeof(uiLen) ); data/freeradius-3.0.21+dfsg/src/modules/rlm_opendirectory/rlm_opendirectory.c:210: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( &(tDataBuff->fBufferData[ uiCurr ]), pUserName, uiLen ); data/freeradius-3.0.21+dfsg/src/modules/rlm_opendirectory/rlm_opendirectory.c:215: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( &(tDataBuff->fBufferData[ uiCurr ]), &pwLen, sizeof(pwLen) ); data/freeradius-3.0.21+dfsg/src/modules/rlm_opendirectory/rlm_opendirectory.c:217: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( &(tDataBuff->fBufferData[ uiCurr ]), password, pwLen ); data/freeradius-3.0.21+dfsg/src/modules/rlm_opendirectory/rlm_opendirectory.c:352: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 host_ipaddr[128] = {0}; data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/extern.h:73:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char const [OTP_MAX_CHALLENGE_LEN], data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp.h: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 passcode[OTP_MAX_PASSCODE_LEN + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp.h:77: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 username[OTP_MAX_USERNAME_LEN + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp.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 challenge[OTP_MAX_CHALLENGE_LEN + 1]; //!< USER challenge. data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp.h:98: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 passcode[OTP_MAX_PASSCODE_LEN + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:88: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 mppe_keys_string[2 + (2 * sizeof(mppe_keys)) + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:117: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. (void) sprintf(&mppe_keys_string[i*2+2], "%02X", mppe_keys[i]); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:149: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 auth_md_string[2 + (2 * sizeof(auth_md)) + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:157: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 auth_octet_string[2 + 2 + (2 * sizeof(auth_md_string))]; data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:220: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. (void) sprintf(&auth_md_string[i * 2 + 2], "%02X", auth_md[i]); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:226: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. (void) sprintf(&auth_octet_string[2], "%02X", rvp->vp_strvalue[0]); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:228: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. (void) sprintf(&auth_octet_string[i * 2 +4], "%02X", auth_md_string[i]); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:319: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 mppe_key_string[2 + (2 * sizeof(MasterKey)) + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:327:11: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. (void) memcpy(MasterKey, sha_md, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:336:11: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. (void) memcpy(MasterSendKey, sha_md, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:345:11: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. (void) memcpy(MasterReceiveKey, sha_md, 16); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:353: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. (void) sprintf(&mppe_key_string[i*2+2], "%02X", MasterSendKey[i]); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:364: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. (void) sprintf(&mppe_key_string[i*2+2], "%02X", MasterReceiveKey[i]); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.h:38:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 const *otp_mppe_policy[3] = { data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.h:43:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 const *otp_mppe_types[3] = { data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pw_valid.c:71:45: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. int otp_pw_valid(REQUEST *request, int pwe, char const *challenge, data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pw_valid.c:73: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 passcode[OTP_MAX_PASSCODE_LEN + 1]) data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pw_valid.c:147:10: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. (void) memcpy(otp_request.pwe.u.chap.challenge, cvp->vp_octets, data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pw_valid.c:151:10: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. (void) memcpy(otp_request.pwe.u.chap.response, rvp->vp_octets, data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pw_valid.c:171:10: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. (void) memcpy(otp_request.pwe.u.chap.challenge, data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pw_valid.c:176:10: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. (void) memcpy(otp_request.pwe.u.chap.response, data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pw_valid.c:197:10: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. (void) memcpy(otp_request.pwe.u.chap.challenge, cvp->vp_octets, data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pw_valid.c:202:10: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. (void) memcpy(otp_request.pwe.u.chap.response, rvp->vp_octets, data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_radstate.c:108:22: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. size_t otp_gen_state(char state[OTP_MAX_RADSTATE_LEN], data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_radstate.c:109:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char const challenge[OTP_MAX_CHALLENGE_LEN], data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_util.c:49: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(rnd_data + bytes_read, &r, n); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_util.c:63: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. void otp_async_challenge(char challenge[OTP_MAX_CHALLENGE_LEN + 1], data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/rlm_otp.c:129: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 challenge[OTP_MAX_CHALLENGE_LEN + 1]; /* +1 for '\0' terminator */ data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/rlm_otp.c:209: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 gen_state[OTP_MAX_RADSTATE_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/rlm_otp.c:301: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 challenge[OTP_MAX_CHALLENGE_LEN]; /* cf. authorize() */ data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/rlm_otp.c:302: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 passcode[OTP_MAX_PASSCODE_LEN + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/rlm_otp.c:329: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 gen_state[OTP_MAX_RADSTATE_LEN]; //!< State as hexits data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/rlm_otp.c:367: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(challenge, bin_state, inst->challenge_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/rlm_otp.c:372: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(&then, bin_state + inst->challenge_len + 4, 4); data/freeradius-3.0.21+dfsg/src/modules/rlm_pap/rlm_pap.c:213: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[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_pap/rlm_pap.c:243: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(buffer, p, hlen); data/freeradius-3.0.21+dfsg/src/modules/rlm_pap/rlm_pap.c:864: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 charbuf[32 + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_pap/rlm_pap.c:929: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, &vp->vp_octets[32], 32); data/freeradius-3.0.21+dfsg/src/modules/rlm_pap/rlm_pap.c:932: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, (uint8_t const *)request->password->vp_strvalue, request->password->vp_length); data/freeradius-3.0.21+dfsg/src/modules/rlm_pap/rlm_pap.c:935: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, &vp->vp_octets[32], 32); data/freeradius-3.0.21+dfsg/src/modules/rlm_passwd/rlm_passwd.c:33: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 *field[1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_passwd/rlm_passwd.c:44: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[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_passwd/rlm_passwd.c:98: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 (str, string, len); data/freeradius-3.0.21+dfsg/src/modules/rlm_passwd/rlm_passwd.c:172: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[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_passwd/rlm_passwd.c:192:16: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). if(!(ht->fp = fopen(file,"r"))) { data/freeradius-3.0.21+dfsg/src/modules/rlm_passwd/rlm_passwd.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 buffer[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_passwd/rlm_passwd.c:337: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). if (!(ht->fp=fopen(ht->filename, "r"))) return NULL; data/freeradius-3.0.21+dfsg/src/modules/rlm_passwd/rlm_passwd.c:479: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(inst->pwdfmt->listflag, lf, nfields); data/freeradius-3.0.21+dfsg/src/modules/rlm_passwd/rlm_passwd.c:543: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[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_perl/rlm_perl.c:628: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[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_perl/rlm_perl.c:689: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 namebuf[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_preprocess/rlm_preprocess.c:109: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 newattr[MAX_STRING_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_preprocess/rlm_preprocess.c:279: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 newname[MAX_STRING_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_preprocess/rlm_preprocess.c:498: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(&nas->vp_ipv6addr, &request->packet->src_ipaddr.ipaddr, data/freeradius-3.0.21+dfsg/src/modules/rlm_preprocess/rlm_preprocess.c:631: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[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_preprocess/rlm_preprocess.c:713: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[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_python/rlm_python.c:379: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/freeradius-3.0.21+dfsg/src/modules/rlm_python/rlm_python.c:1055: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, &inst->python_path, sizeof(path)); data/freeradius-3.0.21+dfsg/src/modules/rlm_python3/rlm_python3.c:376: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/freeradius-3.0.21+dfsg/src/modules/rlm_python3/rlm_python3.c:1164: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, &inst->python_path, sizeof(path)); data/freeradius-3.0.21+dfsg/src/modules/rlm_radutmp/rlm_radutmp.c:84: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(filename, O_RDWR); data/freeradius-3.0.21+dfsg/src/modules/rlm_radutmp/rlm_radutmp.c: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 ip_name[32]; /* 255.255.255.255 */ data/freeradius-3.0.21+dfsg/src/modules/rlm_radutmp/rlm_radutmp.c:387: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(filename, O_RDWR|O_CREAT, inst->permission); data/freeradius-3.0.21+dfsg/src/modules/rlm_radutmp/rlm_radutmp.c:574: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(expanded, O_RDWR); data/freeradius-3.0.21+dfsg/src/modules/rlm_radutmp/rlm_radutmp.c:665: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 session_id[sizeof(u.session_id) + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_radutmp/rlm_radutmp.c:666: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 utmp_login[sizeof(u.login) + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_radutmp/rlm_radutmp.c:689: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(utmp_login, u.login, sizeof(u.login)); data/freeradius-3.0.21+dfsg/src/modules/rlm_realm/trustrouter.c:40: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 err_msg[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_realm/trustrouter.c:385: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 addr_buf[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_realm/trustrouter.c:420: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 nametemp[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_redis/rlm_redis.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 buffer[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_redis/rlm_redis.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 buffer[21]; data/freeradius-3.0.21+dfsg/src/modules/rlm_redis/rlm_redis.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 const *argv[MAX_REDIS_ARGS]; data/freeradius-3.0.21+dfsg/src/modules/rlm_redis/rlm_redis.c:231: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 argv_buf[MAX_QUERY_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_replicate/rlm_replicate.c:167: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, request->packet->vector, AUTH_VECTOR_LEN); data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rest.c:1620:15: [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). ctx->code = atoi(p); data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rest.c:1720: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 escaped[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rest.c:1802: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(ctx->buffer, tmp, ctx->used); data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rest.c:1985: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[512]; data/freeradius-3.0.21+dfsg/src/modules/rlm_ruby/rlm_ruby.c:205: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]; /* same size as vp_print buffer */ data/freeradius-3.0.21+dfsg/src/modules/rlm_securid/rlm_securid.c: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 new_pin[10]; data/freeradius-3.0.21+dfsg/src/modules/rlm_securid/rlm_securid.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 format[30]; data/freeradius-3.0.21+dfsg/src/modules/rlm_securid/rlm_securid.c:162:6: [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(format, "alphanumeric characters"); data/freeradius-3.0.21+dfsg/src/modules/rlm_securid/rlm_securid.c:164:6: [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(format, "digits"); data/freeradius-3.0.21+dfsg/src/modules/rlm_securid/rlm_securid.c:254:6: [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(format, "alphanumeric characters"); data/freeradius-3.0.21+dfsg/src/modules/rlm_securid/rlm_securid.c:256:6: [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(format, "digits"); data/freeradius-3.0.21+dfsg/src/modules/rlm_securid/rlm_securid.c:385:6: [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(format, "alphanumeric characters"); data/freeradius-3.0.21+dfsg/src/modules/rlm_securid/rlm_securid.c:387:6: [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(format, "digits"); data/freeradius-3.0.21+dfsg/src/modules/rlm_securid/rlm_securid.c:458: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[MAX_STRING_LEN]=""; data/freeradius-3.0.21+dfsg/src/modules/rlm_securid/rlm_securid.h:44: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[SECURID_STATE_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_smsotp/rlm_smsotp.c:194: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[1000]; data/freeradius-3.0.21+dfsg/src/modules/rlm_smsotp/rlm_smsotp.c:195: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 output[1000]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_db2/rlm_sql_db2.c:112: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(&db2_query, &query, sizeof(query)); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_db2/rlm_sql_db2.c:201: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[6]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_db2/rlm_sql_db2.c:202: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 errbuff[1024]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:147: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 vary_string[1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:183:4: [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(conn->row[i], "NULL"); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:255: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(p, "%*lld.%0*lld", data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:261: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 (p, "%*lld.%0*lld", data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:271: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, "%*lld%0*d", field_width, data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:274: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, "%*lld", field_width, data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:427: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 info_buffer[128]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:505: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 info_buffer[128]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_freetds/rlm_sql_freetds.c:694: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 database[128]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_mongo/rlm_sql_mongo.c:220: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[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_mongo/rlm_sql_mongo.c:221: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 command[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_oracle/rlm_sql_oracle.c:100: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 errbuff[512]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_oracle/rlm_sql_oracle.c:116: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 errbuff[512]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_oracle/rlm_sql_oracle.c:142: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 errbuff[512]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_postgresql/rlm_sql_postgresql.c:84: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 application_name[NAMEDATALEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_postgresql/rlm_sql_postgresql.c:193:9: [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). return atoi(PQcmdTuples(result)); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_sqlite/rlm_sql_sqlite.c:247:6: [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(filename, "r"); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_sqlite/rlm_sql_sqlite.c:703: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(row[i], p, len); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/rlm_sql.c:187: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 buffer[21]; /* 64bit max is 20 decimal chars + null byte */ data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/rlm_sql.c:226:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(out, buffer, len + 1); /* we did bounds checking above */ data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/rlm_sql.c:395: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(out, in, utf8_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/rlm_sql.c:906: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 buffer[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/rlm_sql.c:1405: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[MAX_STRING_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/rlm_sql.c:1644: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). request->simul_count = atoi(row[0]); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/rlm_sql.c:1720:15: [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). nas_port = atoi(row[4]); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/rlm_sql.c:1742:18: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). sess_time = atoi(row[8]); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/sql.c:68: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[MAX_STRING_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:113: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 sCurrentTime[40], sNextTime[40]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:132:9: [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). num = atoi(inst->reset); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:197: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 sCurrentTime[40], sPrevTime[40]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:213:9: [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). num = atoi(inst->reset); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:275: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 tmpdt[40]; /* For temporary storing of dates */ data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:366: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 query[MAX_QUERY_LEN], subst[MAX_QUERY_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:517: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 msg[128]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:519: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 query[MAX_QUERY_LEN], subst[MAX_QUERY_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlhpwippool/rlm_sqlhpwippool.c:91: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 pfmt[4096]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlhpwippool/rlm_sqlhpwippool.c: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 query[MAX_QUERY_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlhpwippool/rlm_sqlhpwippool.c:654: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 nasipstr[16]; /* NAS IP in string format */ data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlippool/rlm_sqlippool.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 tmp[40]; /* For temporary storing of integers */ data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlippool/rlm_sqlippool.c:261: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(q, param, param_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlippool/rlm_sqlippool.c:267: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(tmp, "%d", data->lease_duration); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlippool/rlm_sqlippool.c:305: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 query[MAX_QUERY_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlippool/rlm_sqlippool.c:358: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 query[MAX_QUERY_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlippool/rlm_sqlippool.c:537: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 allocation[MAX_STRING_LEN]; data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:149:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(out + offset, rr, count); data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:377: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/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:436: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 k[64]; /* To silence const warns until newer unbound in distros */ data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:530:4: [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(k, "logfile:"); data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:564: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(k, "use-syslog"); data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:569: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 v[3]; data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:574:3: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(k, "use-syslog:"); data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:575:3: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(v, "no"); data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:583:4: [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(k, "logfile:"); data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:592:3: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(k, "logfile"); data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:705: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(k, "notar33lsite.foo123.nottld A 127.0.0.1"); data/freeradius-3.0.21+dfsg/src/modules/rlm_unix/rlm_unix.c:58:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (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 trans[64] = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; data/freeradius-3.0.21+dfsg/src/modules/rlm_unix/rlm_unix.c:332:18: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. static unsigned char res[7]; data/freeradius-3.0.21+dfsg/src/modules/rlm_unix/rlm_unix.c:363: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/freeradius-3.0.21+dfsg/src/modules/rlm_unix/rlm_unix.c:521: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 ((fp = fopen(inst->radwtmp, "a")) != NULL) { data/freeradius-3.0.21+dfsg/src/modules/rlm_unpack/rlm_unpack.c:52: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[256]; data/freeradius-3.0.21+dfsg/src/modules/rlm_unpack/rlm_unpack.c:180: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(out, input + offset, to_copy); data/freeradius-3.0.21+dfsg/src/modules/rlm_unpack/rlm_unpack.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(&(cast->data), input + offset, dict_attr_sizes[type][0]); data/freeradius-3.0.21+dfsg/src/modules/rlm_wimax/rlm_wimax.c:74: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(buffer, vp->vp_strvalue, 6); data/freeradius-3.0.21+dfsg/src/modules/rlm_wimax/rlm_wimax.c:155: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(usage_data, "miprk@wimaxforum.org", 21); /* with trailing \0 */ data/freeradius-3.0.21+dfsg/src/modules/rlm_wimax/rlm_wimax.c:178: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(mip_rk, mip_rk_1, rk1_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_wimax/rlm_wimax.c:179: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(mip_rk + rk1_len, mip_rk_2, rk2_len); data/freeradius-3.0.21+dfsg/src/modules/rlm_wimax/rlm_wimax.c:200: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 buffer[512]; data/freeradius-3.0.21+dfsg/src/modules/rlm_yubikey/decrypt.c:27: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 private_id[(YUBIKEY_UID_SIZE * 2) + 1]; data/freeradius-3.0.21+dfsg/src/modules/rlm_yubikey/validate.c:61: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 prefix[100]; data/freeradius-3.0.21+dfsg/src/tests/map/map_unit.c:97: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[8192]; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:502: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). size += strlen(cc->vals[i]) + 1; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:516:18: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen(newval); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:533: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). cmd = (char *)lt_malloc(2 * strlen(str) + 3); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:720:3: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(var, arg, equal_pos - arg); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:722: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). if (strlen(equal_pos + 1) >= sizeof(var)) { data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:727:3: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(var, arg, sizeof(var) - 1); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:908:14: [1] (access) umask: Ensure that umask is given most restrictive possible setting (e.g., 066 or 077) (CWE-732). old_umask = umask(0); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:909:2: [1] (access) umask: Ensure that umask is given most restrictive possible setting (e.g., 066 or 077) (CWE-732). umask(old_umask); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:962:3: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(trimmed, name, ext - name); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1033: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). memmove(name + 6, name, strlen(name)); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1041: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). newarg = (char *)calloc(strlen(name) + 11, 1); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1135:29: [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). newarg = (char *)lt_malloc(strlen(arg) + 10); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1216: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). if (path[strlen(path)-1] == '\n') { data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1217: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). path[strlen(path)-1] = '\0'; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1236:29: [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). newarg = (char *)lt_malloc(strlen(arg) + 10); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1299:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size = strlen(LINKER_FLAG_PREFIX); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1301:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size = size + strlen(path) + strlen(RPATH) + 2; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1301:31: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size = size + strlen(path) + strlen(RPATH) + 2; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1311:2: [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(tmp, "="); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1358: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). i_p_len = strlen(install_path); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1359: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). c_p_len = strlen(current_path); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1373:2: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(exp_argument+cur_len, name, extlen-pathlen); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1381:2: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(exp_argument+cur_len, name, extlen-pathlen); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1407:22: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). newarg = lt_malloc(strlen(file) + 3); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1424: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). newarg = (char*)lt_malloc(strlen(arg) + sizeof(LINKER_FLAG_PREFIX) + 1); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1665: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). char *tmp = lt_malloc(strlen(arg) + 4); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1705: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). newarg = (char *)lt_malloc(strlen(arg) + 5); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1733: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). newname = lt_malloc(strlen(cmd->static_name.normal) + 1); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1769: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). newname = lt_malloc(strlen(cmd->static_name.normal) + 1); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1801: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). newname = lt_malloc(strlen(cmd->shared_name.normal) + 1); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1823: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). newarg = (char *)lt_malloc(strlen(arg) + 2); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1895:17: [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). cmd_size += strlen(cmd->obj_files[a]) + 1; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1898:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). cmd_size += strlen(GEN_EXPORTS) + strlen(def_file) + 3; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1898: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). cmd_size += strlen(GEN_EXPORTS) + strlen(def_file) + 3; data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1903:5: [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(cmd, " "); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1930: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(implib_file, "."); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1949:29: [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). newpath = (char*)lt_malloc(strlen(foo)+strlen(relpath)+2); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1949: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). newpath = (char*)lt_malloc(strlen(foo)+strlen(relpath)+2); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:1951:2: [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(newpath, "/"); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:2131: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). len1 = strlen(cmd->arglist->vals[cmd->arglist->num - 1]); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:2134: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). len2 = strlen(static_lib_name); data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:2233: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). if (strlen(cmd->arglist->vals[0]) >= PATH_MAX) { data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:2283: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). if ((strlen(dirname) + 1 + sizeof(entry->d_name)) >= sizeof(fullname)) { data/freeradius-3.0.21+dfsg/scripts/jlibtool.c:2293: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(fullname, "/"); data/freeradius-3.0.21+dfsg/src/lib/debug.c:242:11: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). while ((read(from_child[0], &ret, sizeof(ret)) < 0) && (errno == EINTR)); data/freeradius-3.0.21+dfsg/src/lib/debug.c:769:6: [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(p) >= left) goto oob; data/freeradius-3.0.21+dfsg/src/lib/debug.c:983: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). if (strlen(p) >= left) goto oob; data/freeradius-3.0.21+dfsg/src/lib/dict.c:549:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if ((length = strlen(name)) >= DICT_VENDOR_MAX_NAME_LEN) { data/freeradius-3.0.21+dfsg/src/lib/dict.c:731: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). namelen = strlen(name); data/freeradius-3.0.21+dfsg/src/lib/dict.c:1185:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if ((length = strlen(namestr)) >= DICT_VALUE_MAX_NAME_LEN) { data/freeradius-3.0.21+dfsg/src/lib/dict.c:2038: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). if ((strlen(p) < 3) || data/freeradius-3.0.21+dfsg/src/lib/dict.c:2248: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). if ((strlen(parent) + 3 + strlen(filename)) > sizeof(dir)) { data/freeradius-3.0.21+dfsg/src/lib/dict.c:2248: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 ((strlen(parent) + 3 + strlen(filename)) > sizeof(dir)) { data/freeradius-3.0.21+dfsg/src/lib/event.c:771:4: [1] (obsolete) usleep: This C routine is considered obsolete (as opposed to the shell command by the same name). The interaction of this function with SIGALRM and other timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead. usleep(delay); data/freeradius-3.0.21+dfsg/src/lib/filters.c:393:54: [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). token = fr_hex2bin(net->node, IPX_NODE_ADDR_LEN, p, strlen(p)); data/freeradius-3.0.21+dfsg/src/lib/filters.c:664: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). if (strspn(str, "0123456789") == strlen(str)) { data/freeradius-3.0.21+dfsg/src/lib/filters.c:803: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). if (strspn(argv[0], "0123456789") == strlen(argv[0])) { data/freeradius-3.0.21+dfsg/src/lib/filters.c:883:39: [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 (strspn(argv[0], "0123456789") != strlen(argv[0])) return -1; data/freeradius-3.0.21+dfsg/src/lib/filters.c:891:66: [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). rcode = fr_hex2bin(filter->mask, sizeof(filter->mask), argv[1], strlen(argv[1])); data/freeradius-3.0.21+dfsg/src/lib/filters.c:894:68: [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). token = fr_hex2bin(filter->value, sizeof(filter->value), argv[2], strlen(argv[2])); data/freeradius-3.0.21+dfsg/src/lib/filters.c:1220:3: [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, " "); data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:89: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(from->h_name) + 1; data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:99:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(from->h_aliases[i])+1; data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:391: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). if (strlen(tmpserv) > servlen) return EAI_MEMORY; data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:399:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (strlen(inet_ntoa(sin->sin_addr)) >= hostlen) return EAI_MEMORY; data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:423:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (strlen(hp->h_name) >= hostlen) return EAI_MEMORY; data/freeradius-3.0.21+dfsg/src/lib/getaddrinfo.c:430: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(inet_ntoa(sin->sin_addr)) >= hostlen) return EAI_MEMORY; data/freeradius-3.0.21+dfsg/src/lib/hmacmd5.c:179: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). key_len = strlen(key); data/freeradius-3.0.21+dfsg/src/lib/hmacmd5.c:182: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). text_len = strlen(text); data/freeradius-3.0.21+dfsg/src/lib/hmacsha1.c:209: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). key_len = strlen(key); data/freeradius-3.0.21+dfsg/src/lib/hmacsha1.c:212: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). text_len = strlen(text); data/freeradius-3.0.21+dfsg/src/lib/misc.c:527:39: [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 = (inlen >= 0) ? (size_t)inlen : strlen(value); data/freeradius-3.0.21+dfsg/src/lib/misc.c:673:39: [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 = (inlen >= 0) ? (size_t)inlen : strlen(value); data/freeradius-3.0.21+dfsg/src/lib/missing.c:73: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). l1 = strlen(s1); data/freeradius-3.0.21+dfsg/src/lib/missing.c:74: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). l2 = strlen(s2); data/freeradius-3.0.21+dfsg/src/lib/pair.c:536:30: [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. if (!match || !check) goto mismatch; data/freeradius-3.0.21+dfsg/src/lib/pair.c:543:41: [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. if (!ATTRIBUTE_EQ(check, match)) goto mismatch; data/freeradius-3.0.21+dfsg/src/lib/pair.c:552:44: [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. if (fr_pair_cmp(check, match) != 1) goto mismatch; data/freeradius-3.0.21+dfsg/src/lib/pair.c:560:1: [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. mismatch: data/freeradius-3.0.21+dfsg/src/lib/pair.c:612:10: [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. goto mismatch; data/freeradius-3.0.21+dfsg/src/lib/pair.c:628:41: [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. if (!fr_pair_cmp(check, match)) goto mismatch; data/freeradius-3.0.21+dfsg/src/lib/pair.c:634:1: [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. mismatch: data/freeradius-3.0.21+dfsg/src/lib/pair.c:1343:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size = strlen(value + 2); data/freeradius-3.0.21+dfsg/src/lib/pair.c:1531:43: [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). slen = regex_compile(ctx, &preg, value, strlen(value), false, false, false, true); data/freeradius-3.0.21+dfsg/src/lib/print.c:189:25: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (inlen < 0) inlen = strlen(in); data/freeradius-3.0.21+dfsg/src/lib/radius.c:525:52: [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). fr_md5_update(&context, (uint8_t const *) secret, strlen(secret)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:565:52: [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). fr_md5_update(&context, (uint8_t const *) secret, strlen(secret)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:656:52: [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). fr_md5_update(&context, (uint8_t const *) secret, strlen(secret)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2002: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). (uint8_t const *) secret, strlen(secret)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2037: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(secret)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2160:52: [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). fr_md5_update(&context, (uint8_t const *) secret, strlen(secret)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2199:52: [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). fr_md5_update(&context, (uint8_t const *) secret, strlen(secret)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:2795: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). (uint8_t const *) secret, strlen(secret)); data/freeradius-3.0.21+dfsg/src/lib/radius.c:3750:15: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). datalen = strlen((char *) buffer); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4385: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). secretlen = strlen(secret); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4441: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). secretlen = strlen(secret); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4477:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(passwd); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4544: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). secretlen = strlen(secret); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4609: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). secretlen = strlen(secret); data/freeradius-3.0.21+dfsg/src/lib/radius.c:4755:12: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). this = read(fd, fr_rand_pool.randrsl, data/freeradius-3.0.21+dfsg/src/lib/regex.c:273: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). p += strlen(pattern); data/freeradius-3.0.21+dfsg/src/lib/regex.c:345: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). p += strlen(subject); data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:262: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). p->width -= strlen(tmp); data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:286: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). p->width -= strlen(tmp); data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:310: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). p->width -= strlen(tmp); data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:334:6: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). i = strlen(tmp); data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:366:4: [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(tmp) - p->precision - 1; data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:377: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). for (i = strlen(tmp2) - 1; i >= 0 && tmp2[i] == '0'; i--) data/freeradius-3.0.21+dfsg/src/lib/snprintf.c:419: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). for (i = strlen(tmp2) - 1; i >= 0 && tmp2[i] == '0'; i--) data/freeradius-3.0.21+dfsg/src/lib/socket.c:32:68: [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 SUN_LEN(su) (sizeof(*(su)) - sizeof((su)->sun_path) + strlen((su)->sun_path)) data/freeradius-3.0.21+dfsg/src/lib/socket.c:68: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(path); data/freeradius-3.0.21+dfsg/src/lib/strlcat.c:54:17: [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). return(dlen + strlen(s)); data/freeradius-3.0.21+dfsg/src/lib/token.c:199:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). p += strlen(t->name); data/freeradius-3.0.21+dfsg/src/lib/token.c:437: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). tlen = strlen(this->name); data/freeradius-3.0.21+dfsg/src/lib/udpfromto.c:492:4: [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(100000); data/freeradius-3.0.21+dfsg/src/lib/value.c:431: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). len = (src_len < 0) ? strlen(src) : (size_t)src_len; data/freeradius-3.0.21+dfsg/src/lib/value.c:1803: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). len = strlen(a); data/freeradius-3.0.21+dfsg/src/lib/value.c:1834:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(buf); data/freeradius-3.0.21+dfsg/src/lib/value.c:1841:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(buf); data/freeradius-3.0.21+dfsg/src/lib/value.c:1913:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(buf); data/freeradius-3.0.21+dfsg/src/lib/value.c:1918:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(buf); data/freeradius-3.0.21+dfsg/src/lib/value.c:1934: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). len = strlen(buf); data/freeradius-3.0.21+dfsg/src/lib/value.c:1954: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). len = strlen(buf); data/freeradius-3.0.21+dfsg/src/main/cb.c:153:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return(strlen((char *)userdata)); data/freeradius-3.0.21+dfsg/src/main/channel.c:42:7: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). r = read(fd, p + total, buflen - total); data/freeradius-3.0.21+dfsg/src/main/collectd.c:196:25: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). conf->stats.prefix, strlen(conf->stats.prefix), '\0'); data/freeradius-3.0.21+dfsg/src/main/collectd.c:205:22: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). plugin_instance, strlen(plugin_instance), '\0'); data/freeradius-3.0.21+dfsg/src/main/collectd.c:214: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). type, strlen(type), '\0'); data/freeradius-3.0.21+dfsg/src/main/collectd.c:220: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). type_instance, strlen(type_instance), '\0'); data/freeradius-3.0.21+dfsg/src/main/command.c:39:64: [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 SUN_LEN(su) (sizeof(*(su)) - sizeof((su)->sun_path) + strlen((su)->sun_path)) data/freeradius-3.0.21+dfsg/src/main/command.c:168: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(path); data/freeradius-3.0.21+dfsg/src/main/command.c:589: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(name); data/freeradius-3.0.21+dfsg/src/main/command.c:591: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(path); data/freeradius-3.0.21+dfsg/src/main/command.c:1375: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). slen = -strlen(argv[0]); data/freeradius-3.0.21+dfsg/src/main/command.c:3206: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(sock->client->secret), data/freeradius-3.0.21+dfsg/src/main/conffile.c:1154: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). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/conffile.c:1183: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). if (p + strlen(cp->value) >= output + outsize) { data/freeradius-3.0.21+dfsg/src/main/conffile.c:1190: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). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/conffile.c:1270: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). if (p + strlen(env) >= output + outsize) { data/freeradius-3.0.21+dfsg/src/main/conffile.c:1277:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/conffile.c:1312:61: [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 (strspn(value, ".0123456789abdefABCDEF:%[]/") == strlen(value)) { data/freeradius-3.0.21+dfsg/src/main/conffile.c:1542:50: [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). vpt = tmpl_alloc(cs, TMPL_TYPE_LITERAL, value, strlen(value)); data/freeradius-3.0.21+dfsg/src/main/conffile.c:1739: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). len = strlen(end + 1); data/freeradius-3.0.21+dfsg/src/main/conffile.c:2253:17: [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 ((dirsize + strlen(filename)) >= bufsize) { data/freeradius-3.0.21+dfsg/src/main/conffile.c:2307:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(cbuf); data/freeradius-3.0.21+dfsg/src/main/conffile.c:2478: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 (value[strlen(value) - 1] == '/') { data/freeradius-3.0.21+dfsg/src/main/detail.c:385:10: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). rcode = read(data->master_pipe[0], &packet, sizeof(packet)); data/freeradius-3.0.21+dfsg/src/main/detail.c:625:8: [1] (buffer) sscanf: 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 (sscanf(buffer, "%255s %7s %1023s", key, op, value) != 3) { data/freeradius-3.0.21+dfsg/src/main/detail.c:956:9: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). ret = read(data->master_pipe[0], &arg, sizeof(arg)); data/freeradius-3.0.21+dfsg/src/main/detail.c:1080:4: [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(detail_delay(data)); data/freeradius-3.0.21+dfsg/src/main/detail.c:1107:8: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (read(data->child_pipe[0], &c, 1) < 0) { data/freeradius-3.0.21+dfsg/src/main/detail.c:1113:30: [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. if (data->delay_time > 0) usleep(data->delay_time); data/freeradius-3.0.21+dfsg/src/main/detail.c:1212:21: [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). sizeof(buffer) - strlen(buffer)); data/freeradius-3.0.21+dfsg/src/main/exec.c:161: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). n = strlen(buffer); data/freeradius-3.0.21+dfsg/src/main/exec.c:440:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). status = read(fd, answer + done, left); data/freeradius-3.0.21+dfsg/src/main/exec.c:446:13: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). status = read(fd, answer + done, 1); data/freeradius-3.0.21+dfsg/src/main/files.c:178:21: [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 = newfile + strlen(newfile); data/freeradius-3.0.21+dfsg/src/main/listen.c:789:23: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). #define FORWARD len = strlen(buffer); if (len >= (bufsize + 1)) return 0;buffer += len;bufsize -= len data/freeradius-3.0.21+dfsg/src/main/log.c:410: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). len = strlen(buffer); data/freeradius-3.0.21+dfsg/src/main/log.c:431: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). len += strlen(buffer + len); data/freeradius-3.0.21+dfsg/src/main/log.c:510: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). return write(default_log.fd, buffer, strlen(buffer)); data/freeradius-3.0.21+dfsg/src/main/log.c:916:6: [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(value) > 100) { data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:365:15: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (outlen > strlen(value)) { data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:366: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). outlen = strlen(value) + 1; data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:371:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:406:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:448: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). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:455:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:486: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). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:491: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). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/mainconfig.c:519:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/map.c:93: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(rhs + 2); data/freeradius-3.0.21+dfsg/src/main/map.c:163: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). vpt->len = strlen(vpt->name); data/freeradius-3.0.21+dfsg/src/main/map.c:276: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). slen = tmpl_afrom_str(map, &map->rhs, value, strlen(value), type, src_request_def, src_list_def, true); data/freeradius-3.0.21+dfsg/src/main/map.c:441:45: [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). slen = tmpl_afrom_str(map, &map->lhs, lhs, strlen(lhs), lhs_type, dst_request_def, dst_list_def, true); data/freeradius-3.0.21+dfsg/src/main/map.c:456:45: [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). slen = tmpl_afrom_str(map, &map->rhs, rhs, strlen(rhs), rhs_type, src_request_def, src_list_def, true); data/freeradius-3.0.21+dfsg/src/main/map.c:1538: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(p); data/freeradius-3.0.21+dfsg/src/main/map.c:1547: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). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/modcall.c:196: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). else if (strspn(value, "0123456789")==strlen(value)) { data/freeradius-3.0.21+dfsg/src/main/modcall.c:1782: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). slen = tmpl_afrom_str(cs, &vpt, name2, strlen(name2), type, REQUEST_CURRENT, PAIR_LIST_REQUEST, true); data/freeradius-3.0.21+dfsg/src/main/modcall.c:1888: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). slen = tmpl_afrom_str(cs, &vpt, name2, strlen(name2), type, REQUEST_CURRENT, PAIR_LIST_REQUEST, true); data/freeradius-3.0.21+dfsg/src/main/modcall.c:1978: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). slen = tmpl_afrom_str(cs, &vpt, name2, strlen(name2), type, REQUEST_CURRENT, PAIR_LIST_REQUEST, true); data/freeradius-3.0.21+dfsg/src/main/modcall.c:3643:52: [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). slen = tmpl_afrom_str(g->cs, &g->vpt, c->name, strlen(c->name), data/freeradius-3.0.21+dfsg/src/main/modcall.c:3697:49: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). slen = tmpl_afrom_str(g->cs, &vpt, c->name, strlen(c->name), cf_section_name2_type(g->cs), data/freeradius-3.0.21+dfsg/src/main/modcall.c:3750:52: [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). slen = tmpl_afrom_str(g->cs, &g->vpt, c->name, strlen(c->name), data/freeradius-3.0.21+dfsg/src/main/modcall.c:3861:51: [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). slen = tmpl_afrom_str(g->cs, &g->vpt, c->name, strlen(c->name), cf_section_name2_type(g->cs), data/freeradius-3.0.21+dfsg/src/main/parser.c:85:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/parser.c:100:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/parser.c:120: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). return strlen(buffer); data/freeradius-3.0.21+dfsg/src/main/parser.c:124: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). return strlen(buffer); data/freeradius-3.0.21+dfsg/src/main/parser.c:139: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). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/parser.c:143: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). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/parser.c:182: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). *out = talloc_array(ctx, char, strlen(start) - 1); /* + 2 - 1 */ data/freeradius-3.0.21+dfsg/src/main/process.c:5473:10: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). rcode = read(self_pipe[0], buffer, sizeof(buffer)); data/freeradius-3.0.21+dfsg/src/main/process.c:5496:10: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). rcode = read(self_pipe[0], buffer, sizeof(buffer)); data/freeradius-3.0.21+dfsg/src/main/radattr.c:679: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). outlen = strlen(output); data/freeradius-3.0.21+dfsg/src/main/radattr.c:807: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). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/radattr.c:891: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). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/radclient.c:1301:21: [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 = filesecret + strlen(filesecret) - 1; data/freeradius-3.0.21+dfsg/src/main/radclient.c:1308: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(filesecret) < 2) { data/freeradius-3.0.21+dfsg/src/main/radiusd.c:455:9: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if ((read(from_child[0], &ret, 1) < 0)) { data/freeradius-3.0.21+dfsg/src/main/radmin.c:176:51: [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). fr_hmac_md5(challenge, (uint8_t const *) secret, strlen(secret), data/freeradius-3.0.21+dfsg/src/main/radmin.c:208:58: [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). r = fr_channel_write(sockfd, FR_CHANNEL_STDIN, command, strlen(command)); data/freeradius-3.0.21+dfsg/src/main/radsniff.c:236: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). inlen = strlen(in); data/freeradius-3.0.21+dfsg/src/main/radsniff.c:585:49: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). INFO("\t%s%*s: %.3lf/s", in->name, (int) (10 - strlen(in->name)), "", data/freeradius-3.0.21+dfsg/src/main/radsniff.c:1857:8: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). ret = read(fd, &sig, sizeof(sig)); data/freeradius-3.0.21+dfsg/src/main/radwho.c:405: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). (strncasecmp(rt.login, user, strlen(user)) != 0)) || data/freeradius-3.0.21+dfsg/src/main/radwho.c:407: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). (strncmp(rt.login, user, strlen(user)) != 0))) { data/freeradius-3.0.21+dfsg/src/main/realms.c:227:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/realms.c:277: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). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/realms.c:315: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). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/realms.c:2051:52: [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). slen = regex_compile(rr, &rr->preg, r->name + 1, strlen(r->name) - 1, true, false, false, false); data/freeradius-3.0.21+dfsg/src/main/realms.c:2321:43: [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). compare = regex_exec(this->preg, name, strlen(name), NULL, NULL); data/freeradius-3.0.21+dfsg/src/main/threads.c:1524: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(100000); /* sleep for 1/10 of a second */ data/freeradius-3.0.21+dfsg/src/main/tls.c:427: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). psk_len = strlen(conf->psk_password); data/freeradius-3.0.21+dfsg/src/main/tls.c:444: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). psk_len = strlen(conf->psk_password); data/freeradius-3.0.21+dfsg/src/main/tls.c:1517: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). char const *p = asn1, *end = p + strlen(p); data/freeradius-3.0.21+dfsg/src/main/tls.c:1641:9: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). rv = read(fd, q, todo); data/freeradius-3.0.21+dfsg/src/main/tls.c:1867: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). if ((strlen(host) + strlen(port) + 2) > sizeof(hostheader)) { data/freeradius-3.0.21+dfsg/src/main/tls.c:1867:22: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if ((strlen(host) + strlen(port) + 2) > sizeof(hostheader)) { data/freeradius-3.0.21+dfsg/src/main/tls.c:2873:59: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (strncmp(conf->private_key_password, special_string, strlen(special_string)) == 0) { data/freeradius-3.0.21+dfsg/src/main/tls.c:2902: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). password[strlen(password) - 1] = '\0'; data/freeradius-3.0.21+dfsg/src/main/tls.c:2989: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). psk_len = strlen(conf->psk_password); data/freeradius-3.0.21+dfsg/src/main/tls.c:2990: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). if (strlen(conf->psk_password) > (2 * PSK_MAX_PSK_LEN)) { data/freeradius-3.0.21+dfsg/src/main/tls.c:3424:28: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). (unsigned int) strlen(conf->session_context_id)); data/freeradius-3.0.21+dfsg/src/main/tls_listen.c:203:10: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). rcode = read(request->packet->sockfd, data/freeradius-3.0.21+dfsg/src/main/tmpl.c:502: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). vpt->len = len < 0 ? strlen(name) : data/freeradius-3.0.21+dfsg/src/main/tmpl.c:529:52: [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). vpt->name = talloc_bstrndup(vpt, name, len < 0 ? strlen(name) : (size_t)len); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1334: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). slen = strlen(buff); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1356: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). slen = strlen(buff); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1503: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). slen = strlen(buff); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1517: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). slen = strlen(*out); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1528: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). slen = strlen(*out); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1675: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). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1695:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(out); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1716:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(out); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1726: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). len = strlen(q); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1737: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). len = strlen(q); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1743: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). len = strlen(q); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1749: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). len = strlen(q); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1755: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). len = strlen(q); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1780:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(out); data/freeradius-3.0.21+dfsg/src/main/tmpl.c:1791: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). len = strlen(q); data/freeradius-3.0.21+dfsg/src/main/util.c:932:6: [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(cmd) > (argv_buflen - 1)) { data/freeradius-3.0.21+dfsg/src/main/util.c:940: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). if (cmd[strlen(cmd) - 1] == '\\') { data/freeradius-3.0.21+dfsg/src/main/version.c:62:66: [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. if ((ssl_linked & 0xfff00000) != (ssl_built & 0xfff00000)) goto mismatch; data/freeradius-3.0.21+dfsg/src/main/version.c:81:2: [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. mismatch: data/freeradius-3.0.21+dfsg/src/main/version.c:96:66: [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. (ssl_built & 0x00000ff0) > (ssl_linked & 0x00000ff0)) goto mismatch; data/freeradius-3.0.21+dfsg/src/main/version.c:101:73: [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. } else if ((ssl_built & 0xfffff000) != (ssl_linked & 0xfffff000)) goto mismatch; data/freeradius-3.0.21+dfsg/src/main/xlat.c:96:45: [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). snprintf(out, outlen, "%u", (unsigned int) strlen(fmt)); data/freeradius-3.0.21+dfsg/src/main/xlat.c:97:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/xlat.c:115:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/xlat.c:348:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(vp->da->name); data/freeradius-3.0.21+dfsg/src/main/xlat.c:475:21: [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 ((pad = (11 - strlen(type->name))) < 0) { data/freeradius-3.0.21+dfsg/src/main/xlat.c:532:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/xlat.c:694:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/main/xlat.c:721: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). my_xlat.length = strlen(my_xlat.name); data/freeradius-3.0.21+dfsg/src/main/xlat.c:779:17: [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). XLAT_REGISTER(strlen); data/freeradius-3.0.21+dfsg/src/main/xlat.c:806: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). my_xlat.length = strlen(my_xlat.name); data/freeradius-3.0.21+dfsg/src/main/xlat.c:828: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). c->length = strlen(c->name); data/freeradius-3.0.21+dfsg/src/main/xlat.c:866: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). my_xlat.length = strlen(my_xlat.name); data/freeradius-3.0.21+dfsg/src/main/xlat.c:1117:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(fmt); data/freeradius-3.0.21+dfsg/src/main/xlat.c:1655:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/xlat.c:1674:23: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). memmove(p, p + 1, strlen(p + 1) + 1); data/freeradius-3.0.21+dfsg/src/main/xlat.c:1676:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/xlat.c:1682:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/xlat.c:1689:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/xlat.c:1697:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). p += strlen(p); data/freeradius-3.0.21+dfsg/src/main/xlat.c:2443: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). return strlen(answer); data/freeradius-3.0.21+dfsg/src/main/xlat.c:2460: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). if (array[i]) total += strlen(array[i]); /* FIXME: calculate strlen once */ data/freeradius-3.0.21+dfsg/src/main/xlat.c:2476: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). len = strlen(array[i]); data/freeradius-3.0.21+dfsg/src/main/xlat.c:2516: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(buff); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/dhcp.c:1764:21: [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). vp->vp_length = strlen(vp->vp_strvalue); data/freeradius-3.0.21+dfsg/src/modules/proto_dhcp/rlm_dhcp.c:108:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_cache/drivers/rlm_cache_memcached/rlm_cache_memcached.c:182:50: [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). from_store = memcached_get(mandle->handle, key, strlen(key), &len, &flags, &mret); data/freeradius-3.0.21+dfsg/src/modules/rlm_cache/serialize.c:144:25: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (inlen < 0) inlen = strlen(in); data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/couchbase.c:257: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). cmd.v.v0.nname = strlen(cmd.v.v0.name); data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/couchbase.c:291: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). cmd.v.v0.nkey = strlen(cmd.v.v0.key); data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/couchbase.c:293: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). cmd.v.v0.nbytes = strlen(cmd.v.v0.bytes); data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/couchbase.c:331: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). cmd.v.v0.nkey = strlen(cmd.v.v0.key); data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/couchbase.c:382: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). cmd.v.v0.npath = strlen(cmd.v.v0.path); data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/couchbase.c:384: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). cmd.v.v0.nbody = post ? strlen(post) : 0; data/freeradius-3.0.21+dfsg/src/modules/rlm_couchbase/jsonc_missing.c:43: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). return (int)strlen(json_object_get_string(obj)); data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c:193: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). key_datum.dsize = strlen(key_datum.dptr); data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c:204: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). key_datum.dsize = strlen(key_datum.dptr); data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c:205: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). key_datum.dsize = strlen(default2); data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c:275:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(inst->reset); data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c:484: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). key_datum.dsize = strlen(key_datum.dptr); data/freeradius-3.0.21+dfsg/src/modules/rlm_counter/rlm_counter.c:506:21: [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). key_datum.dsize = strlen(key_datum.dptr); data/freeradius-3.0.21+dfsg/src/modules/rlm_cram/rlm_cram.c:57:54: [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). fr_md5_update(&context, (uint8_t const *) password, strlen(password)); data/freeradius-3.0.21+dfsg/src/modules/rlm_dynamic_clients/rlm_dynamic_clients.c:69: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). length = strlen(value); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/comp128.c:410: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(argv[1]) != 34) || (strlen(argv[2]) != 34) || data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/comp128.c:410: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). (strlen(argv[1]) != 34) || (strlen(argv[2]) != 34) || data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c:94:20: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t prf_size = strlen(prf_label); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c:159: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). prf_size = strlen(prf_label); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/libeap/mppe_keys.c:264: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(prf_label); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:901: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). idlen = strlen(vp->vp_strvalue); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1293:61: [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). fr_md5_update(&context, (uint8_t *) eap_context->password, strlen(eap_context->password)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1990:27: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). p = filesecret + strlen(filesecret) - 1; data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/radeapclient.c:1997: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 (strlen(filesecret) < 2) { data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_gtc/rlm_eap_gtc.c:98: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). length = strlen(challenge_str); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:74:25: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (inst->identity && (strlen(inst->identity) > 255)) { data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:129:59: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). length = MSCHAPV2_HEADER_LEN + MSCHAPV2_CHALLENGE_LEN + strlen(inst->identity); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:156:52: [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((ptr + reply->vp_length), inst->identity, strlen(inst->identity)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:714:8: [1] (buffer) sscanf: 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. n = sscanf(response->vp_strvalue, "%*cE=%d R=%d C=%32s", &err, &retry, &buf[0]); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_mschapv2/rlm_eap_mschapv2.c:718: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). fr_hex2bin(data->challenge, 16, buf, strlen(buf)); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/eap_pwd.c:216: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("EAP-pwd Hunting And Pecking"), prfbuf, primebitlen) != 0) { data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c:238:47: [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). session->out_len = sizeof(pwd_id_packet_t) + strlen(inst->server_id); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c:477: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). pw->data.strvalue, strlen(pw->data.strvalue), data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c:478: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). inst->server_id, strlen(inst->server_id), data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_pwd/rlm_eap_pwd.c:479:29: [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). session->peer_id, strlen(session->peer_id), data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:319: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). ess->keys.identitylen = strlen(handler->identity); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_sim/rlm_eap_sim.c:592: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). m = m + strlen(m); data/freeradius-3.0.21+dfsg/src/modules/rlm_eap/types/rlm_eap_ttls/ttls.c:372: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). vp->vp_length = strlen(vp->vp_strvalue); /* embedded zeros are NOT allowed */ data/freeradius-3.0.21+dfsg/src/modules/rlm_exec/rlm_exec.c:193:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_exec/rlm_exec.c:348:46: [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). rcode = rlm_exec_status2rcode(request, out, strlen(out), status); data/freeradius-3.0.21+dfsg/src/modules/rlm_exec/rlm_exec.c:397:46: [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). rcode = rlm_exec_status2rcode(request, out, strlen(out), status); data/freeradius-3.0.21+dfsg/src/modules/rlm_exec/rlm_exec.c:454:45: [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). return rlm_exec_status2rcode(request, out, strlen(out), status); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/paircmp.c:66: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(check->vp_strvalue); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/paircmp.c:74: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). namelen = strlen(name); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:519:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:545:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:903:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:927:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:970:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:1013:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:1060:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:1230: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(p); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:1236:2: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(out, p, outlen); data/freeradius-3.0.21+dfsg/src/modules/rlm_expr/rlm_expr.c:1346:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). ssize_t len = strlen(fmt); data/freeradius-3.0.21+dfsg/src/modules/rlm_idn/rlm_idn.c:115: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(idna); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:356:52: [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). fr_md5_update(&md5_context, (uint8_t *)xlat_str, strlen(xlat_str)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool.c:495:51: [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). fr_md5_update(&md5_context, (uint8_t *)xlat_str, strlen(xlat_str)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:163:58: [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). fr_md5_update(&md5_context, (uint8_t *) md5_input_str, strlen(md5_input_str)); data/freeradius-3.0.21+dfsg/src/modules/rlm_ippool/rlm_ippool_tool.c:392:58: [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). fr_md5_update(&md5_context, (uint8_t *) md5_input_str, strlen(md5_input_str)); data/freeradius-3.0.21+dfsg/src/modules/rlm_krb5/rlm_krb5.c:128: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). len = strlen(inst->service_princ); data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/edir.c:87:66: [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). rc = ber_printf(request_ber, "{io}", NMAS_LDAP_EXT_VERSION, dn, strlen(dn) + 1); data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/ldap.c:320: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). f_len = strlen(full); data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/ldap.c:326: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). p_len = strlen(part); data/freeradius-3.0.21+dfsg/src/modules/rlm_ldap/rlm_ldap.c:1047: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). len = strlen(value); data/freeradius-3.0.21+dfsg/src/modules/rlm_linelog/rlm_linelog.c:278:2: [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(line, "\n"); data/freeradius-3.0.21+dfsg/src/modules/rlm_linelog/rlm_linelog.c:280:22: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (write(fd, line, strlen(line)) < 0) { data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/rlm_logintime.c:95:52: [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 (strspn(check->vp_strvalue, "0123456789: ") != strlen(check->vp_strvalue)) { data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/timestr.c:57: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). l = strlen(days[i]); data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/timestr.c:58: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). if (l > strlen(*str)) data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/timestr.c:88:22: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (p - tm != 5 || strlen(p) < 4 || !isdigit((int) *p)) data/freeradius-3.0.21+dfsg/src/modules/rlm_logintime/timestr.c:96: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). if (strlen(tm) < 4 || !isdigit((int) *tm)) data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/mschap.c:55:72: [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 = fr_utf8_to_ucs2(ucs2_password, sizeof(ucs2_password), password, strlen(password)); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/mschap.c:81:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). strlen(user_name)); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:176:45: [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(pUserLocation, kActiveDirLoc, strlen(kActiveDirLoc)) == 0) { data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:304: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). uiLen = (uint32_t)(shortUserName ? strlen(shortUserName) : 0); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/opendir.c:364:21: [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). uiLen = (uint32_t)strlen(username_string); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:378: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). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:430: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). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:840:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(buf); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:850:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(buf); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:1248:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(buffer + 8); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:1529:60: [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). mschap_add_reply(request, ident, "MS-CHAP-Error", buffer, strlen(buffer)); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/rlm_mschap.c:1777:74: [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). mschap_add_reply(request, cpw->vp_octets[1], "MS-CHAP-Error", buffer, strlen(buffer)); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbencrypt.c:54:72: [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 = fr_utf8_to_ucs2(ucs2_password, sizeof(ucs2_password), password, strlen(password)); data/freeradius-3.0.21+dfsg/src/modules/rlm_mschap/smbencrypt.c:75: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). l = strlen(password); data/freeradius-3.0.21+dfsg/src/modules/rlm_opendirectory/rlm_opendirectory.c:207:21: [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). uiLen = (uint32_t)strlen( pUserName ); data/freeradius-3.0.21+dfsg/src/modules/rlm_opendirectory/rlm_opendirectory.c:214:21: [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). pwLen = (uint32_t)strlen( password ); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:100: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). passcode_len = strlen(passcode); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_mppe.c:184: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). passcode_len = strlen(passcode); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pw_valid.c:305:7: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). n = read(fdp->fd, &buf[nread], len - nread); data/freeradius-3.0.21+dfsg/src/modules/rlm_otp/otp_pw_valid.c:369: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). sp_len = strlen(path); data/freeradius-3.0.21+dfsg/src/modules/rlm_pam/rlm_pam.c:109: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). memset(reply[count].resp, 0, strlen(reply[count].resp)); data/freeradius-3.0.21+dfsg/src/modules/rlm_passwd/rlm_passwd.c:72:88: [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=sizeof (struct mypasswd) + nfields * sizeof (char*) + nfields * sizeof (char ) + strlen(buffer) + 1; data/freeradius-3.0.21+dfsg/src/modules/rlm_passwd/rlm_passwd.c:87: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(string); data/freeradius-3.0.21+dfsg/src/modules/rlm_passwd/rlm_passwd.c:366: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). buffer[strlen(buffer)-1] = 0; data/freeradius-3.0.21+dfsg/src/modules/rlm_passwd/rlm_passwd.c:433:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). memset(lf, 0, strlen(inst->format)); data/freeradius-3.0.21+dfsg/src/modules/rlm_perl/rlm_perl.c:404: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). XPUSHs(sv_2mortal(newSVpvn(p, strlen(p)))); data/freeradius-3.0.21+dfsg/src/modules/rlm_perl/rlm_perl.c:418: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). ret = strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_perl/rlm_perl.c:461:31: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (hv_exists(rad_hv, key, strlen(key))) { data/freeradius-3.0.21+dfsg/src/modules/rlm_perl/rlm_perl.c:469:32: [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). (void)hv_store(rad_hv, key, strlen(key), ref, 0); data/freeradius-3.0.21+dfsg/src/modules/rlm_perl/rlm_perl.c:483:31: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (hv_exists(rad_hv, key, strlen(key))) { data/freeradius-3.0.21+dfsg/src/modules/rlm_perl/rlm_perl.c:488:32: [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). (void)hv_store(rad_hv, key, strlen(key), newSVpvn(value, strlen(value)), 0); data/freeradius-3.0.21+dfsg/src/modules/rlm_perl/rlm_perl.c:488:61: [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). (void)hv_store(rad_hv, key, strlen(key), newSVpvn(value, strlen(value)), 0); data/freeradius-3.0.21+dfsg/src/modules/rlm_perl/rlm_perl.c:718: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). (void)hv_store(rad_hv, name, strlen(name), newRV_noinc((SV *)av), 0); data/freeradius-3.0.21+dfsg/src/modules/rlm_perl/rlm_perl.c:730: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). (void)hv_store(rad_hv, name, strlen(name), newSVpvn(vp->vp_strvalue, vp->vp_length), 0); data/freeradius-3.0.21+dfsg/src/modules/rlm_perl/rlm_perl.c:737: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). (void)hv_store(rad_hv, name, strlen(name), data/freeradius-3.0.21+dfsg/src/modules/rlm_preprocess/rlm_preprocess.c:303: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(namepair->vp_strvalue) > 10) && data/freeradius-3.0.21+dfsg/src/modules/rlm_python/rlm_python.c:1001:56: [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). inst->wide_name = Py_DecodeLocale(main_config.name, strlen(main_config.name)); data/freeradius-3.0.21+dfsg/src/modules/rlm_radutmp/rlm_radutmp.c:102:9: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). while (read(fd, &u, sizeof(u)) == sizeof(u)) { data/freeradius-3.0.21+dfsg/src/modules/rlm_radutmp/rlm_radutmp.c:417:9: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). while (read(fd, &u, sizeof(u)) == sizeof(u)) { data/freeradius-3.0.21+dfsg/src/modules/rlm_radutmp/rlm_radutmp.c:620:9: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). while (read(fd, &u, sizeof(u)) == sizeof(u)) { data/freeradius-3.0.21+dfsg/src/modules/rlm_radutmp/rlm_radutmp.c:662:9: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). while (read(fd, &u, sizeof(u)) == sizeof(u)) { data/freeradius-3.0.21+dfsg/src/modules/rlm_realm/rlm_realm.c:390:6: [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(inst->delim) != 1) { data/freeradius-3.0.21+dfsg/src/modules/rlm_realm/trustrouter.c:398: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). sl = strlen(addr_buf); data/freeradius-3.0.21+dfsg/src/modules/rlm_redis/rlm_redis.c:179:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). ret = strlen(buffer_ptr); data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rest.c:547: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). escaped = curl_escape(vp->da->name, strlen(vp->da->name)); data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rest.c:553: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). len = strlen(escaped); data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rest.c:586: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). len = strlen(escaped); data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rest.c:1209: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). RDEBUG3("Length : %zu", strlen(value)); data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rest.c:2456:29: [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). escaped = curl_escape(raw, strlen(raw)); data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rest.c:2460:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_rest/rlm_rest.c:245: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). p += strlen(http_method_table[method].name); data/freeradius-3.0.21+dfsg/src/modules/rlm_smsotp/rlm_smsotp.c:102:7: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). n = read(*fdp, &buf[total], len - total); data/freeradius-3.0.21+dfsg/src/modules/rlm_smsotp/rlm_smsotp.c:168:6: [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(inst->socket) > (sizeof(sa.sun_path) - 1)) { data/freeradius-3.0.21+dfsg/src/modules/rlm_smsotp/rlm_smsotp.c:218: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). WRITE_ALL(fdp, output, strlen(output)); data/freeradius-3.0.21+dfsg/src/modules/rlm_smsotp/rlm_smsotp.c:225: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). WRITE_ALL(fdp, output, strlen(output)); data/freeradius-3.0.21+dfsg/src/modules/rlm_smsotp/rlm_smsotp.c:232: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). WRITE_ALL(fdp, output, strlen(output)); data/freeradius-3.0.21+dfsg/src/modules/rlm_smsotp/rlm_smsotp.c:257:25: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). WRITE_ALL(fdp, output, strlen(output)); data/freeradius-3.0.21+dfsg/src/modules/rlm_soh/rlm_soh.c:91: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). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:54:6: [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). l = strlen(value); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:357: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). conn->dpb_len+= strlen(config->sql_login) + 2; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:361: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). conn->dpb_len += strlen(config->sql_password) + 2; data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:389: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 ls = strlen(config->sql_server); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_firebird/sql_fbapi.c:390: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 ld = strlen(config->sql_db); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_freetds/rlm_sql_freetds.c:697:58: [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 (ct_con_props(conn->db, CS_SET, CS_USERNAME, login, strlen(config->sql_login), NULL) != CS_SUCCEED) { data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_freetds/rlm_sql_freetds.c:705:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). password, strlen(config->sql_password), NULL) != CS_SUCCEED) { data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_freetds/rlm_sql_freetds.c:715:36: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (ct_connect(conn->db, server, strlen(config->sql_server)) != CS_SUCCEED) { data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_mysql/rlm_sql_mysql.c:821: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). inlen = strlen(in); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_oracle/rlm_sql_oracle.c:181:44: [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). (OraText const *)config->sql_login, strlen(config->sql_login), data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_oracle/rlm_sql_oracle.c:182:47: [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). (OraText const *)config->sql_password, strlen(config->sql_password), data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_oracle/rlm_sql_oracle.c:183: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). (OraText const *)config->sql_db, strlen(config->sql_db))) { data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_oracle/rlm_sql_oracle.c:220:61: [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 (OCIStmtPrepare(conn->query, conn->error, oracle_query, strlen(query), data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_oracle/rlm_sql_oracle.c:260:61: [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 (OCIStmtPrepare(conn->query, conn->error, oracle_query, strlen(query), OCI_NTV_SYNTAX, data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_postgresql/rlm_sql_postgresql.c:564: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). inlen = strlen(in); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_sqlite/rlm_sql_sqlite.c:584:47: [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). status = sqlite3_prepare_v2(conn->db, query, strlen(query), &conn->statement, &z_tail); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_sqlite/rlm_sql_sqlite.c:586:44: [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). status = sqlite3_prepare(conn->db, query, strlen(query), &conn->statement, &z_tail); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_sqlite/rlm_sql_sqlite.c:604:47: [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). status = sqlite3_prepare_v2(conn->db, query, strlen(query), &conn->statement, &z_tail); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_sqlite/rlm_sql_sqlite.c:606:44: [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). status = sqlite3_prepare(conn->db, query, strlen(query), &conn->statement, &z_tail); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_unixodbc/rlm_sql_unixodbc.c:100: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). odbc_server, strlen(config->sql_server), data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_unixodbc/rlm_sql_unixodbc.c:101: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). odbc_login, strlen(config->sql_login), data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_unixodbc/rlm_sql_unixodbc.c:102:21: [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). odbc_password, strlen(config->sql_password)); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/drivers/rlm_sql_unixodbc/rlm_sql_unixodbc.c:131:54: [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). err_handle = SQLExecDirect(conn->stmt, odbc_query, strlen(query)); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/rlm_sql.c:216:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(buffer); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/rlm_sql.c:260: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(row[0]); data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/sql.c:116: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). (row[3][0] == row[3][strlen(row[3])-1])) { data/freeradius-3.0.21+dfsg/src/modules/rlm_sql/sql.c:498: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(query); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:124:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(inst->reset); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:207:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(inst->reset); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:323: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 += strlen(q); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:329: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 += strlen(q); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:335: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 += strlen(q); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlcounter/rlm_sqlcounter.c:353:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlippool/rlm_sqlippool.c:252: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 += strlen(q); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlippool/rlm_sqlippool.c:258: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). q += strlen(q); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlippool/rlm_sqlippool.c:269: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 += strlen(q); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlippool/rlm_sqlippool.c:285:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_sqlippool/rlm_sqlippool.c:402:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). rlen = strlen((*handle)->row[0]); data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:129:21: [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 (count > 63 || strlen(rr + offset) < count) { data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:168:4: [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(inst->timeout * 1000 - waited); data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:173: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(iv); data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:252: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). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:295: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). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.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). return strlen(out); data/freeradius-3.0.21+dfsg/src/modules/rlm_unbound/rlm_unbound.c:597:17: [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 (optval && strlen(optval)) { data/freeradius-3.0.21+dfsg/src/modules/rlm_unix/rlm_unix.c:237: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 ((!encrypted_pass) || (strlen(encrypted_pass) < 10)) { data/freeradius-3.0.21+dfsg/src/modules/rlm_unix/rlm_unix.c:504:3: [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(ut.ut_id, "P"); data/freeradius-3.0.21+dfsg/src/modules/rlm_unix/rlm_unix.c:506:3: [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(ut.ut_id, "S"); data/freeradius-3.0.21+dfsg/src/modules/rlm_unix/rlm_unix.c:508:3: [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(ut.ut_id, "T"); data/freeradius-3.0.21+dfsg/src/modules/rlm_unpack/rlm_unpack.c:109:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(data_name + 2); data/freeradius-3.0.21+dfsg/src/modules/rlm_yubikey/rlm_yubikey.c:111:15: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (outlen < strlen(fmt)) { data/freeradius-3.0.21+dfsg/src/modules/rlm_yubikey/rlm_yubikey.c:119: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). len = modhex2hex(fmt, (uint8_t *) out, strlen(fmt)); ANALYSIS SUMMARY: Hits = 1964 Lines analyzed = 189331 in approximately 4.62 seconds (41002 lines/second) Physical Source Lines of Code (SLOC) = 113850 Hits@level = [0] 1082 [1] 457 [2] 1304 [3] 34 [4] 164 [5] 5 Hits@level+ = [0+] 3046 [1+] 1964 [2+] 1507 [3+] 203 [4+] 169 [5+] 5 Hits/KSLOC@level+ = [0+] 26.7545 [1+] 17.2508 [2+] 13.2367 [3+] 1.78305 [4+] 1.48441 [5+] 0.0439174 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.