exceptions.txt 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289
  1. # Welcome to the exceptions file for Tor's best-practices tracker!
  2. #
  3. # Each line of this file represents a single violation of Tor's best
  4. # practices -- typically, a violation that we had before practracker.py
  5. # first existed.
  6. #
  7. # There are three kinds of problems that we recognize right now:
  8. # function-size -- a function of more than 100 lines.
  9. # file-size -- a file of more than 3000 lines.
  10. # include-count -- a file with more than 50 #includes.
  11. #
  12. # Each line below represents a single exception that practracker should
  13. # _ignore_. Each line has four parts:
  14. # 1. The word "problem".
  15. # 2. The kind of problem.
  16. # 3. The location of the problem: either a filename, or a
  17. # filename:functionname pair.
  18. # 4. The magnitude of the problem to ignore.
  19. #
  20. # So for example, consider this line:
  21. # problem file-size /src/core/or/connection_or.c 3200
  22. #
  23. # It tells practracker to allow the mentioned file to be up to 3200 lines
  24. # long, even though ordinarily it would warn about any file with more than
  25. # 3000 lines.
  26. #
  27. # You can either edit this file by hand, or regenerate it completely by
  28. # running `make practracker-regen`.
  29. #
  30. # Remember: It is better to fix the problem than to add a new exception!
  31. problem file-size /src/app/config/config.c 8518
  32. problem include-count /src/app/config/config.c 87
  33. problem function-size /src/app/config/config.c:options_act_reversible() 296
  34. problem function-size /src/app/config/config.c:options_act() 589
  35. problem function-size /src/app/config/config.c:resolve_my_address() 192
  36. problem function-size /src/app/config/config.c:options_validate() 1217
  37. problem function-size /src/app/config/config.c:options_init_from_torrc() 207
  38. problem function-size /src/app/config/config.c:options_init_from_string() 173
  39. problem function-size /src/app/config/config.c:options_init_logs() 146
  40. problem function-size /src/app/config/config.c:parse_bridge_line() 104
  41. problem function-size /src/app/config/config.c:parse_transport_line() 191
  42. problem function-size /src/app/config/config.c:parse_dir_authority_line() 151
  43. problem function-size /src/app/config/config.c:parse_dir_fallback_line() 102
  44. problem function-size /src/app/config/config.c:parse_port_config() 452
  45. problem function-size /src/app/config/config.c:parse_ports() 170
  46. problem function-size /src/app/config/config.c:getinfo_helper_config() 116
  47. problem function-size /src/app/config/confparse.c:config_assign_value() 205
  48. problem function-size /src/app/config/confparse.c:config_get_assigned_option() 129
  49. problem include-count /src/app/main/main.c 67
  50. problem function-size /src/app/main/main.c:dumpstats() 102
  51. problem function-size /src/app/main/main.c:tor_init() 137
  52. problem function-size /src/app/main/main.c:sandbox_init_filter() 291
  53. problem function-size /src/app/main/main.c:run_tor_main_loop() 105
  54. problem function-size /src/app/main/ntmain.c:nt_service_install() 125
  55. problem file-size /src/core/mainloop/connection.c 5569
  56. problem include-count /src/core/mainloop/connection.c 62
  57. problem function-size /src/core/mainloop/connection.c:connection_free_minimal() 185
  58. problem function-size /src/core/mainloop/connection.c:connection_listener_new() 328
  59. problem function-size /src/core/mainloop/connection.c:connection_handle_listener_read() 161
  60. problem function-size /src/core/mainloop/connection.c:connection_connect_sockaddr() 103
  61. problem function-size /src/core/mainloop/connection.c:connection_proxy_connect() 148
  62. problem function-size /src/core/mainloop/connection.c:connection_read_proxy_handshake() 153
  63. problem function-size /src/core/mainloop/connection.c:retry_listener_ports() 116
  64. problem function-size /src/core/mainloop/connection.c:connection_handle_read_impl() 111
  65. problem function-size /src/core/mainloop/connection.c:connection_buf_read_from_socket() 181
  66. problem function-size /src/core/mainloop/connection.c:connection_handle_write_impl() 241
  67. problem function-size /src/core/mainloop/connection.c:assert_connection_ok() 143
  68. problem include-count /src/core/mainloop/mainloop.c 63
  69. problem function-size /src/core/mainloop/mainloop.c:conn_close_if_marked() 108
  70. problem function-size /src/core/mainloop/mainloop.c:run_connection_housekeeping() 123
  71. problem file-size /src/core/or/channel.c 3487
  72. problem function-size /src/core/or/channeltls.c:channel_tls_handle_var_cell() 160
  73. problem function-size /src/core/or/channeltls.c:channel_tls_process_versions_cell() 170
  74. problem function-size /src/core/or/channeltls.c:channel_tls_process_netinfo_cell() 214
  75. problem function-size /src/core/or/channeltls.c:channel_tls_process_certs_cell() 246
  76. problem function-size /src/core/or/channeltls.c:channel_tls_process_authenticate_cell() 202
  77. problem include-count /src/core/or/circuitbuild.c 54
  78. problem function-size /src/core/or/circuitbuild.c:get_unique_circ_id_by_chan() 128
  79. problem function-size /src/core/or/circuitbuild.c:circuit_extend() 147
  80. problem function-size /src/core/or/circuitbuild.c:choose_good_exit_server_general() 206
  81. problem include-count /src/core/or/circuitlist.c 55
  82. problem function-size /src/core/or/circuitlist.c:HT_PROTOTYPE() 128
  83. problem function-size /src/core/or/circuitlist.c:circuit_free_() 143
  84. problem function-size /src/core/or/circuitlist.c:circuit_find_to_cannibalize() 102
  85. problem function-size /src/core/or/circuitlist.c:circuit_about_to_free() 120
  86. problem function-size /src/core/or/circuitlist.c:circuits_handle_oom() 117
  87. problem function-size /src/core/or/circuitmux.c:circuitmux_set_policy() 110
  88. problem function-size /src/core/or/circuitmux.c:circuitmux_attach_circuit() 114
  89. problem file-size /src/core/or/circuitpadding.c 3040
  90. problem function-size /src/core/or/circuitpadding.c:circpad_machine_schedule_padding() 107
  91. problem function-size /src/core/or/circuitpadding.c:circpad_machine_schedule_padding() 113
  92. problem function-size /src/core/or/circuitpadding_machines.c:circpad_machine_relay_hide_intro_circuits() 104
  93. problem function-size /src/core/or/circuitpadding_machines.c:circpad_machine_client_hide_rend_circuits() 112
  94. problem function-size /src/core/or/circuitstats.c:circuit_build_times_parse_state() 124
  95. problem file-size /src/core/or/circuituse.c 3162
  96. problem function-size /src/core/or/circuituse.c:circuit_is_acceptable() 132
  97. problem function-size /src/core/or/circuituse.c:circuit_expire_building() 394
  98. problem function-size /src/core/or/circuituse.c:circuit_log_ancient_one_hop_circuits() 126
  99. problem function-size /src/core/or/circuituse.c:circuit_build_failed() 149
  100. problem function-size /src/core/or/circuituse.c:circuit_launch_by_extend_info() 110
  101. problem function-size /src/core/or/circuituse.c:circuit_get_open_circ_or_launch() 354
  102. problem function-size /src/core/or/circuituse.c:connection_ap_handshake_attach_circuit() 244
  103. problem function-size /src/core/or/command.c:command_process_create_cell() 156
  104. problem function-size /src/core/or/command.c:command_process_relay_cell() 132
  105. problem file-size /src/core/or/connection_edge.c 4595
  106. problem include-count /src/core/or/connection_edge.c 65
  107. problem function-size /src/core/or/connection_edge.c:connection_ap_expire_beginning() 117
  108. problem function-size /src/core/or/connection_edge.c:connection_ap_handshake_rewrite() 192
  109. problem function-size /src/core/or/connection_edge.c:connection_ap_handle_onion() 188
  110. problem function-size /src/core/or/connection_edge.c:connection_ap_handshake_rewrite_and_attach() 423
  111. problem function-size /src/core/or/connection_edge.c:connection_ap_handshake_send_begin() 111
  112. problem function-size /src/core/or/connection_edge.c:connection_ap_handshake_socks_resolved() 106
  113. problem function-size /src/core/or/connection_edge.c:connection_exit_begin_conn() 184
  114. problem function-size /src/core/or/connection_edge.c:connection_exit_connect() 102
  115. problem file-size /src/core/or/connection_or.c 3124
  116. problem include-count /src/core/or/connection_or.c 51
  117. problem function-size /src/core/or/connection_or.c:connection_or_group_set_badness_() 105
  118. problem function-size /src/core/or/connection_or.c:connection_or_client_learned_peer_id() 144
  119. problem function-size /src/core/or/connection_or.c:connection_or_compute_authenticate_cell_body() 235
  120. problem file-size /src/core/or/policies.c 3249
  121. problem function-size /src/core/or/policies.c:policy_summarize() 107
  122. problem function-size /src/core/or/protover.c:protover_all_supported() 117
  123. problem file-size /src/core/or/relay.c 3244
  124. problem function-size /src/core/or/relay.c:circuit_receive_relay_cell() 127
  125. problem function-size /src/core/or/relay.c:relay_send_command_from_edge_() 112
  126. problem function-size /src/core/or/relay.c:connection_ap_process_end_not_open() 194
  127. problem function-size /src/core/or/relay.c:connection_edge_process_relay_cell_not_open() 139
  128. problem function-size /src/core/or/relay.c:connection_edge_process_relay_cell() 430
  129. problem function-size /src/core/or/relay.c:connection_edge_package_raw_inbuf() 129
  130. problem function-size /src/core/or/relay.c:circuit_resume_edge_reading_helper() 148
  131. problem function-size /src/core/or/scheduler_kist.c:kist_scheduler_run() 171
  132. problem function-size /src/core/or/scheduler_vanilla.c:vanilla_scheduler_run() 109
  133. problem function-size /src/core/or/versions.c:tor_version_parse() 104
  134. problem function-size /src/core/proto/proto_socks.c:parse_socks_client() 112
  135. problem function-size /src/feature/client/addressmap.c:addressmap_rewrite() 112
  136. problem function-size /src/feature/client/bridges.c:rewrite_node_address_for_bridge() 126
  137. problem function-size /src/feature/client/circpathbias.c:pathbias_measure_close_rate() 108
  138. problem function-size /src/feature/client/dnsserv.c:evdns_server_callback() 153
  139. problem file-size /src/feature/client/entrynodes.c 3824
  140. problem function-size /src/feature/client/entrynodes.c:entry_guards_upgrade_waiting_circuits() 157
  141. problem function-size /src/feature/client/entrynodes.c:entry_guard_parse_from_state() 246
  142. problem function-size /src/feature/client/transports.c:handle_proxy_line() 108
  143. problem function-size /src/feature/client/transports.c:parse_method_line_helper() 112
  144. problem function-size /src/feature/client/transports.c:create_managed_proxy_environment() 109
  145. problem function-size /src/feature/control/control.c:connection_control_process_inbuf() 136
  146. problem function-size /src/feature/control/control_auth.c:handle_control_authchallenge() 103
  147. problem function-size /src/feature/control/control_auth.c:handle_control_authenticate() 187
  148. problem function-size /src/feature/control/control_cmd.c:handle_control_extendcircuit() 151
  149. problem function-size /src/feature/control/control_cmd.c:handle_control_add_onion() 269
  150. problem function-size /src/feature/control/control_cmd.c:add_onion_helper_keyarg() 125
  151. problem function-size /src/feature/control/control_events.c:control_event_stream_status() 119
  152. problem include-count /src/feature/control/control_getinfo.c 54
  153. problem function-size /src/feature/control/control_getinfo.c:getinfo_helper_misc() 109
  154. problem function-size /src/feature/control/control_getinfo.c:getinfo_helper_dir() 304
  155. problem function-size /src/feature/control/control_getinfo.c:getinfo_helper_events() 236
  156. problem function-size /src/feature/dirauth/bwauth.c:dirserv_read_measured_bandwidths() 124
  157. problem file-size /src/feature/dirauth/dirvote.c 4726
  158. problem include-count /src/feature/dirauth/dirvote.c 53
  159. problem function-size /src/feature/dirauth/dirvote.c:format_networkstatus_vote() 249
  160. problem function-size /src/feature/dirauth/dirvote.c:networkstatus_compute_bw_weights_v10() 235
  161. problem function-size /src/feature/dirauth/dirvote.c:networkstatus_compute_consensus() 962
  162. problem function-size /src/feature/dirauth/dirvote.c:networkstatus_add_detached_signatures() 123
  163. problem function-size /src/feature/dirauth/dirvote.c:dirvote_add_vote() 162
  164. problem function-size /src/feature/dirauth/dirvote.c:dirvote_compute_consensuses() 164
  165. problem function-size /src/feature/dirauth/dirvote.c:dirserv_generate_networkstatus_vote_obj() 293
  166. problem function-size /src/feature/dirauth/dsigs_parse.c:networkstatus_parse_detached_signatures() 196
  167. problem function-size /src/feature/dirauth/guardfraction.c:dirserv_read_guardfraction_file_from_str() 110
  168. problem function-size /src/feature/dirauth/process_descs.c:dirserv_add_descriptor() 125
  169. problem function-size /src/feature/dirauth/shared_random.c:should_keep_commit() 110
  170. problem function-size /src/feature/dirauth/voteflags.c:dirserv_compute_performance_thresholds() 172
  171. problem function-size /src/feature/dircache/consdiffmgr.c:consdiffmgr_cleanup() 115
  172. problem function-size /src/feature/dircache/consdiffmgr.c:consdiffmgr_rescan_flavor_() 111
  173. problem function-size /src/feature/dircache/consdiffmgr.c:consensus_diff_worker_threadfn() 132
  174. problem function-size /src/feature/dircache/dircache.c:handle_get_current_consensus() 166
  175. problem function-size /src/feature/dircache/dircache.c:directory_handle_command_post() 120
  176. problem file-size /src/feature/dirclient/dirclient.c 3215
  177. problem include-count /src/feature/dirclient/dirclient.c 51
  178. problem function-size /src/feature/dirclient/dirclient.c:directory_get_from_dirserver() 131
  179. problem function-size /src/feature/dirclient/dirclient.c:directory_initiate_request() 201
  180. problem function-size /src/feature/dirclient/dirclient.c:directory_send_command() 241
  181. problem function-size /src/feature/dirclient/dirclient.c:dir_client_decompress_response_body() 114
  182. problem function-size /src/feature/dirclient/dirclient.c:connection_dir_client_reached_eof() 189
  183. problem function-size /src/feature/dirclient/dirclient.c:handle_response_fetch_consensus() 105
  184. problem function-size /src/feature/dircommon/consdiff.c:gen_ed_diff() 204
  185. problem function-size /src/feature/dircommon/consdiff.c:apply_ed_diff() 159
  186. problem function-size /src/feature/dirparse/authcert_parse.c:authority_cert_parse_from_string() 182
  187. problem function-size /src/feature/dirparse/microdesc_parse.c:microdescs_parse_from_string() 169
  188. problem function-size /src/feature/dirparse/ns_parse.c:routerstatus_parse_entry_from_string() 286
  189. problem function-size /src/feature/dirparse/ns_parse.c:networkstatus_verify_bw_weights() 389
  190. problem function-size /src/feature/dirparse/ns_parse.c:networkstatus_parse_vote_from_string() 638
  191. problem function-size /src/feature/dirparse/parsecommon.c:tokenize_string() 103
  192. problem function-size /src/feature/dirparse/parsecommon.c:get_next_token() 159
  193. problem function-size /src/feature/dirparse/routerparse.c:router_parse_entry_from_string() 557
  194. problem function-size /src/feature/dirparse/routerparse.c:extrainfo_parse_entry_from_string() 210
  195. problem function-size /src/feature/hibernate/hibernate.c:accounting_parse_options() 109
  196. problem function-size /src/feature/hs/hs_cell.c:hs_cell_build_establish_intro() 115
  197. problem function-size /src/feature/hs/hs_cell.c:hs_cell_parse_introduce2() 154
  198. problem function-size /src/feature/hs/hs_client.c:send_introduce1() 104
  199. problem function-size /src/feature/hs/hs_client.c:hs_config_client_authorization() 108
  200. problem function-size /src/feature/hs/hs_common.c:hs_get_responsible_hsdirs() 104
  201. problem function-size /src/feature/hs/hs_config.c:config_generic_service() 140
  202. problem function-size /src/feature/hs/hs_descriptor.c:desc_encode_v3() 104
  203. problem function-size /src/feature/hs/hs_descriptor.c:decrypt_desc_layer() 110
  204. problem function-size /src/feature/hs/hs_descriptor.c:decode_introduction_point() 122
  205. problem function-size /src/feature/hs/hs_descriptor.c:desc_decode_superencrypted_v3() 109
  206. problem function-size /src/feature/hs/hs_descriptor.c:desc_decode_encrypted_v3() 109
  207. problem file-size /src/feature/hs/hs_service.c 4109
  208. problem function-size /src/feature/keymgt/loadkey.c:ed_key_init_from_file() 333
  209. problem function-size /src/feature/nodelist/authcert.c:trusted_dirs_load_certs_from_string() 124
  210. problem function-size /src/feature/nodelist/authcert.c:authority_certs_fetch_missing() 296
  211. problem function-size /src/feature/nodelist/fmt_routerstatus.c:routerstatus_format_entry() 166
  212. problem function-size /src/feature/nodelist/microdesc.c:microdesc_cache_rebuild() 134
  213. problem include-count /src/feature/nodelist/networkstatus.c 62
  214. problem function-size /src/feature/nodelist/networkstatus.c:networkstatus_check_consensus_signature() 176
  215. problem function-size /src/feature/nodelist/networkstatus.c:networkstatus_set_current_consensus() 293
  216. problem function-size /src/feature/nodelist/node_select.c:router_pick_directory_server_impl() 123
  217. problem function-size /src/feature/nodelist/node_select.c:compute_weighted_bandwidths() 206
  218. problem function-size /src/feature/nodelist/node_select.c:router_pick_trusteddirserver_impl() 114
  219. problem function-size /src/feature/nodelist/nodelist.c:compute_frac_paths_available() 193
  220. problem file-size /src/feature/nodelist/routerlist.c 3238
  221. problem function-size /src/feature/nodelist/routerlist.c:router_rebuild_store() 148
  222. problem function-size /src/feature/nodelist/routerlist.c:router_add_to_routerlist() 169
  223. problem function-size /src/feature/nodelist/routerlist.c:routerlist_remove_old_routers() 121
  224. problem function-size /src/feature/nodelist/routerlist.c:update_consensus_router_descriptor_downloads() 136
  225. problem function-size /src/feature/nodelist/routerlist.c:update_extrainfo_downloads() 103
  226. problem function-size /src/feature/relay/dns.c:dns_resolve_impl() 134
  227. problem function-size /src/feature/relay/dns.c:configure_nameservers() 161
  228. problem function-size /src/feature/relay/dns.c:evdns_callback() 109
  229. problem file-size /src/feature/relay/router.c 3407
  230. problem include-count /src/feature/relay/router.c 56
  231. problem function-size /src/feature/relay/router.c:init_keys() 252
  232. problem function-size /src/feature/relay/router.c:get_my_declared_family() 114
  233. problem function-size /src/feature/relay/router.c:router_build_fresh_unsigned_routerinfo() 136
  234. problem function-size /src/feature/relay/router.c:router_dump_router_to_string() 371
  235. problem function-size /src/feature/relay/router.c:extrainfo_dump_to_string() 206
  236. problem function-size /src/feature/relay/routerkeys.c:load_ed_keys() 294
  237. problem function-size /src/feature/rend/rendcache.c:rend_cache_store_v2_desc_as_client() 193
  238. problem function-size /src/feature/rend/rendclient.c:rend_client_send_introduction() 220
  239. problem function-size /src/feature/rend/rendcommon.c:rend_encode_v2_descriptors() 225
  240. problem function-size /src/feature/rend/rendmid.c:rend_mid_establish_intro_legacy() 104
  241. problem function-size /src/feature/rend/rendparse.c:rend_parse_v2_service_descriptor() 187
  242. problem function-size /src/feature/rend/rendparse.c:rend_decrypt_introduction_points() 104
  243. problem function-size /src/feature/rend/rendparse.c:rend_parse_introduction_points() 131
  244. problem file-size /src/feature/rend/rendservice.c 4511
  245. problem function-size /src/feature/rend/rendservice.c:rend_service_prune_list_impl_() 107
  246. problem function-size /src/feature/rend/rendservice.c:rend_config_service() 164
  247. problem function-size /src/feature/rend/rendservice.c:rend_service_load_auth_keys() 178
  248. problem function-size /src/feature/rend/rendservice.c:rend_service_receive_introduction() 332
  249. problem function-size /src/feature/rend/rendservice.c:rend_service_parse_intro_for_v3() 115
  250. problem function-size /src/feature/rend/rendservice.c:rend_service_decrypt_intro() 115
  251. problem function-size /src/feature/rend/rendservice.c:rend_service_intro_has_opened() 126
  252. problem function-size /src/feature/rend/rendservice.c:rend_service_rendezvous_has_opened() 117
  253. problem function-size /src/feature/rend/rendservice.c:directory_post_to_hs_dir() 108
  254. problem function-size /src/feature/rend/rendservice.c:upload_service_descriptor() 111
  255. problem function-size /src/feature/rend/rendservice.c:rend_consider_services_intro_points() 170
  256. problem function-size /src/feature/stats/rephist.c:rep_hist_load_mtbf_data() 185
  257. problem function-size /src/feature/stats/rephist.c:rep_hist_format_exit_stats() 148
  258. problem function-size /src/lib/compress/compress.c:tor_compress_impl() 133
  259. problem function-size /src/lib/compress/compress_zstd.c:tor_zstd_compress_process() 126
  260. problem function-size /src/lib/container/smartlist.c:smartlist_bsearch_idx() 109
  261. problem function-size /src/lib/crypt_ops/crypto_rand.c:crypto_strongest_rand_syscall() 102
  262. problem function-size /src/lib/encoding/binascii.c:base64_encode() 107
  263. problem function-size /src/lib/encoding/confline.c:parse_config_line_from_str_verbose() 119
  264. problem function-size /src/lib/encoding/cstring.c:unescape_string() 108
  265. problem function-size /src/lib/fs/dir.c:check_private_dir() 231
  266. problem function-size /src/lib/log/log.c:parse_log_severity_config() 101
  267. problem function-size /src/lib/math/prob_distr.c:sample_uniform_interval() 145
  268. problem function-size /src/lib/net/address.c:tor_addr_parse_mask_ports() 198
  269. problem function-size /src/lib/net/address.c:tor_addr_compare_masked() 111
  270. problem function-size /src/lib/net/inaddr.c:tor_inet_pton() 107
  271. problem function-size /src/lib/net/resolve.c:tor_addr_lookup() 110
  272. problem function-size /src/lib/net/socketpair.c:tor_ersatz_socketpair() 102
  273. problem function-size /src/lib/osinfo/uname.c:get_uname() 116
  274. problem function-size /src/lib/process/process_unix.c:process_unix_exec() 220
  275. problem function-size /src/lib/process/process_win32.c:process_win32_exec() 133
  276. problem function-size /src/lib/process/process_win32.c:process_win32_create_pipe() 112
  277. problem function-size /src/lib/process/restrict.c:set_max_file_descriptors() 102
  278. problem function-size /src/lib/process/setuid.c:switch_id() 156
  279. problem function-size /src/lib/sandbox/sandbox.c:prot_strings() 104
  280. problem function-size /src/lib/string/scanf.c:tor_vsscanf() 112
  281. problem function-size /src/lib/tls/tortls_nss.c:tor_tls_context_new() 153
  282. problem function-size /src/lib/tls/tortls_openssl.c:tor_tls_context_new() 171
  283. problem function-size /src/lib/tls/x509_nss.c:tor_tls_create_certificate_internal() 126
  284. problem function-size /src/tools/tor-gencert.c:parse_commandline() 111
  285. problem function-size /src/tools/tor-resolve.c:build_socks5_resolve_request() 104
  286. problem function-size /src/tools/tor-resolve.c:do_resolve() 174
  287. problem function-size /src/tools/tor-resolve.c:main() 112