|
Tor 0.4.9.8
|
Macros to manage assertions, fatal and non-fatal. More...
#include "orconfig.h"#include "lib/cc/compat_compiler.h"#include "lib/log/log.h"#include "lib/smartlist_core/smartlist_core.h"#include "lib/testsupport/testsupport.h"Go to the source code of this file.
Macros | |
| #define | ASSERT_PREDICT_UNLIKELY_(e) |
| #define | ASSERT_PREDICT_LIKELY_(e) |
| #define | tor_assert(expr) |
| #define | tor_assertf(expr, fmt, ...) |
| #define | tor_assert_unreached() |
| #define | tor_assert_nonfatal_unreached() |
| #define | tor_assert_nonfatal(cond) |
| #define | tor_assertf_nonfatal(cond, fmt, ...) |
| #define | tor_assert_nonfatal_unreached_once() |
| #define | tor_assert_nonfatal_once(cond) |
| #define | BUG(cond) |
| #define | IF_BUG_ONCE__(cond, var) |
| #define | IF_BUG_ONCE_VARNAME_(a) |
| #define | IF_BUG_ONCE_VARNAME__(a) |
| #define | IF_BUG_ONCE(cond) |
| #define | FALLTHROUGH_UNLESS_ALL_BUGS_ARE_FATAL FALLTHROUGH |
| #define | tor_fragile_assert() |
| #define | SHORT_FILE__ (__FILE__) |
| #define | tor_fix_source_file(s) |
Functions | |
| void | tor_assertion_failed_ (const char *fname, unsigned int line, const char *func, const char *expr, const char *fmt,...) |
| void | tor_bug_increment_count_ (void) |
| size_t | tor_bug_get_count (void) |
| void | tor_bug_occurred_ (const char *fname, unsigned int line, const char *func, const char *expr, int once, const char *fmt,...) |
| void | tor_abort_ (void) ATTR_NORETURN |
| void | tor_bug_init_counter (void) |
Macros to manage assertions, fatal and non-fatal.
Guidelines: All the different kinds of assertion in this file are for bug-checking only. Don't write code that can assert based on bad inputs.
We provide two kinds of assertion here: "fatal" and "nonfatal". Use nonfatal assertions for any bug you can reasonably recover from – and please, try to recover! Many severe bugs in Tor have been caused by using a regular assertion when a nonfatal assertion would have been better.
If you need to check a condition with a nonfatal assertion, AND recover from that same condition, consider using the BUG() macro inside a conditional. For example:
// wrong – use tor_assert_nonfatal() if you just want an assertion. BUG(ptr == NULL);
// okay, but needlessly verbose tor_assert_nonfatal(ptr != NULL); if (ptr == NULL) { ... }
// this is how we do it: if (BUG(ptr == NULL)) { ... }
Definition in file util_bug.h.
| #define ASSERT_PREDICT_LIKELY_ | ( | e | ) |
Definition at line 86 of file util_bug.h.
| #define ASSERT_PREDICT_UNLIKELY_ | ( | e | ) |
Definition at line 85 of file util_bug.h.
| #define BUG | ( | cond | ) |
Definition at line 211 of file util_bug.h.
| #define FALLTHROUGH_UNLESS_ALL_BUGS_ARE_FATAL FALLTHROUGH |
Use this macro after a nonfatal assertion, and before a case statement where you would want to fall through.
Definition at line 268 of file util_bug.h.
Referenced by channel_tls_handle_var_cell(), circuit_purpose_to_controller_hs_state_string(), and entry_guards_note_guard_success().
| #define IF_BUG_ONCE | ( | cond | ) |
This macro behaves as 'if (BUG(x))', except that it only logs its warning once, no matter how many times it triggers.
Definition at line 254 of file util_bug.h.
Referenced by buf_flush_to_tls(), buf_read_from_tls(), channel_matches_target_addr_for_extend(), choose_good_exit_server_general(), circuit_extend(), connection_describe(), connection_describe_peer_internal(), connection_or_finished_flushing(), describe_relay_port(), download_status_schedule_get_delay(), encode_v0_cell(), encode_v1_cell(), extend_info_any_orport_addr_is_internal(), extend_info_has_orport(), extend_info_is_a_configured_bridge(), extend_info_pick_orport(), fmt_addr32(), fmt_addr_family(), geoip_add_entry(), geoip_note_client_seen(), onion_skin_create(), onionskin_answer(), router_addr_is_my_published_addr(), router_parse_entry_from_string(), scheduler_channel_doesnt_want_writes(), scheduler_channel_has_waiting_cells(), scheduler_channel_wants_writes(), tor_addr_copy_ipv6_bytes(), tor_tls_get_last_error_msg(), trn_extension_find(), and write_short_http_response().
| #define IF_BUG_ONCE__ | ( | cond, | |
| var ) |
Definition at line 232 of file util_bug.h.
| #define IF_BUG_ONCE_VARNAME_ | ( | a | ) |
Definition at line 245 of file util_bug.h.
| #define IF_BUG_ONCE_VARNAME__ | ( | a | ) |
Definition at line 247 of file util_bug.h.
| #define SHORT_FILE__ (__FILE__) |
Definition at line 298 of file util_bug.h.
| #define tor_assert | ( | expr | ) |
Like assert(3), but send assertion failures to the log as well as to stderr.
Definition at line 103 of file util_bug.h.
Referenced by accounting_parse_options(), accounting_set_wakeup_time(), add_cell_ewma(), add_certs_cell_cert_helper(), add_connection_to_closeable_list(), add_ed25519_to_dir(), add_laplace_noise(), add_metric_with_labels(), add_rsa_fingerprint_to_dir(), add_transport_to_proxy(), add_trusted_dir_to_nodelist_addr_set(), addr_is_a_configured_bridge(), addr_policy_append_reject_addr(), addr_policy_append_reject_addr_list(), addr_policy_append_reject_addr_list_filter(), addr_policy_free_(), addr_policy_get_canonical_entry(), address_can_be_used(), address_is_in_virtual_range(), addressmap_get_virtual_address(), addressmap_register(), addressmap_register_virtual_address(), aes_raw_decrypt(), aes_raw_encrypt(), aes_raw_new(), aes_raw_set_key(), alloc_chunk(), assert_circuit_ok(), assert_connection_edge_not_dns_pending(), assert_connection_ok(), assert_identity_keys_ok(), assert_resolve_ok(), assert_unconfigured_count_ok(), assign_onionskin_to_cpuworker(), auth_key_filename_is_valid(), authdir_wants_to_reject_router(), authority_cert_dup(), authority_cert_get_all(), authority_cert_parse_from_string(), base16_decode(), base16_encode(), base32_decode(), base32_encode(), base64_decode(), base64_decode_maxsize(), base64_encode(), base64_encode_nopad(), base64_encode_size(), bignum_from_hex(), bloomfilt_new(), bridge_add_from_config(), bridge_get_addr_port(), bridge_get_rsa_id_digest(), bridge_passes_guard_filter(), bridget_get_transport_name(), btc_evtype_better(), bto_find_or_new(), bto_update(), bto_update_bests(), buf_add(), buf_add_chunk_with_capacity(), buf_add_vprintf(), buf_assert_ok(), buf_drain(), buf_extract(), buf_find_offset_of_char(), buf_find_pos_of_char(), buf_find_string_offset(), buf_flush_to_fd(), buf_flush_to_tls(), buf_get_bytes(), buf_http_find_content_length(), buf_move_all(), buf_move_to_buf(), buf_peek(), buf_pos_inc(), buf_preferred_chunk_size(), buf_pullup(), buf_read_from_fd(), buf_read_from_tls(), build_blinded_key_param(), build_desc_intro_points(), build_desc_signing_key_cert(), build_descriptor_cookie_keys(), build_descriptors_for_new_service(), build_encrypted(), build_establish_intro_dos_extension(), build_establish_intro_dos_param(), build_establish_intro_extensions(), build_hs_address(), build_hs_checksum(), build_introduce_pow_extension(), build_kdf_key(), build_mac(), build_plaintext_padding(), build_secret_data(), build_secret_input(), build_secret_key_iv_mac(), build_service_desc_encrypted(), build_service_desc_keys(), build_service_desc_plaintext(), build_service_desc_superencrypted(), build_service_descriptor(), build_subcredential(), bwhist_fill_bandwidth_history(), bwhist_load_state(), cache_clean_v3_as_dir(), cache_client_desc_new(), cache_client_intro_state_add(), cache_client_intro_state_clean(), cache_client_intro_state_lookup(), cache_client_intro_state_note(), cache_dir_desc_new(), cache_lookup_v3_as_dir(), cache_store_as_client(), cache_store_v3_as_dir(), can_client_refetch_desc(), can_process_netinfo_cell(), can_relaunch_service_rendezvous_point(), can_service_launch_intro_circuit(), cdm_cache_init(), cell_ewma_to_circuit(), cert_is_valid(), cert_parse_and_validate(), cfx_add_leg(), cfx_del_leg(), cgo_crypt_new(), cgo_key_material_len(), cgo_uiv_init(), channel_add_to_digest_map(), channel_change_state(), channel_change_state_(), channel_clear_client(), channel_clear_identity_digest(), channel_clear_remote_end(), channel_close_for_error(), channel_close_from_lower_layer(), channel_closed(), channel_describe_peer(), channel_describe_transport(), channel_do_open_actions(), channel_dump_statistics(), channel_dump_transport_statistics(), channel_find_by_global_id(), channel_find_by_remote_identity(), channel_flush_from_first_active_circuit(), channel_flush_some_cells(), channel_force_xfree(), channel_free_(), channel_free_list(), channel_get_addr_if_possible(), channel_get_cell_handler(), channel_get_for_extend(), channel_has_queued_writes(), channel_init(), channel_init_listener(), channel_is_bad_for_new_circs(), channel_is_better(), channel_is_canonical(), channel_is_client(), channel_is_incoming(), channel_is_local(), channel_is_outgoing(), channel_listener_change_state(), channel_listener_describe_transport(), channel_listener_dump_statistics(), channel_listener_dump_transport_statistics(), channel_listener_force_xfree(), channel_listener_free_(), channel_listener_free_list(), channel_listener_mark_for_close(), channel_listener_process_incoming(), channel_listener_queue_incoming(), channel_listener_register(), channel_listener_set_listener_fn(), channel_listener_timestamp_accepted(), channel_listener_timestamp_active(), channel_listener_timestamp_created(), channel_listener_unregister(), channel_mark_bad_for_new_circs(), channel_mark_client(), channel_mark_for_close(), channel_mark_incoming(), channel_mark_local(), channel_mark_outgoing(), channel_mark_remote(), channel_matches_extend_info(), channel_matches_target_addr_for_extend(), channel_more_to_flush(), channel_next_with_rsa_identity(), channel_notify_flushed(), channel_num_cells_writeable(), channel_num_circuits(), channel_process_cell(), channel_register(), channel_remove_from_digest_map(), channel_rsa_id_group_set_badness(), channel_send_destroy(), channel_set_cell_handlers(), channel_set_circid_type(), channel_set_identity_digest(), channel_timestamp_active(), channel_timestamp_client(), channel_timestamp_created(), channel_timestamp_recv(), channel_timestamp_xmit(), channel_tls_close_method(), channel_tls_common_init(), channel_tls_describe_peer_method(), channel_tls_describe_transport_method(), channel_tls_free_all(), channel_tls_free_method(), channel_tls_from_base(), channel_tls_get_overhead_estimate_method(), channel_tls_get_remote_addr_method(), channel_tls_get_transport_name_method(), channel_tls_handle_cell(), channel_tls_handle_incoming(), channel_tls_handle_state_change_on_orconn(), channel_tls_handle_var_cell(), channel_tls_has_queued_writes_method(), channel_tls_is_canonical_method(), channel_tls_listener_close_method(), channel_tls_listener_describe_transport_method(), channel_tls_matches_extend_info_method(), channel_tls_matches_target_method(), channel_tls_num_bytes_queued_method(), channel_tls_num_cells_writeable_method(), channel_tls_process_auth_challenge_cell(), channel_tls_process_authenticate_cell(), channel_tls_process_certs_cell(), channel_tls_process_netinfo_cell(), channel_tls_process_padding_negotiate_cell(), channel_tls_process_versions_cell(), channel_tls_update_marks(), channel_tls_write_cell_method(), channel_tls_write_packed_cell_method(), channel_tls_write_var_cell_method(), channel_unlink_all_circuits(), channel_unregister(), channel_when_created(), channel_when_last_client(), channel_when_last_xmit(), channel_write_packed_cell(), channelpadding_get_circuits_available_timeout(), channelpadding_schedule_padding(), channelpadding_send_disable_command(), channelpadding_send_enable_command(), channelpadding_send_padding_callback(), check_extended_cell(), check_private_dir(), check_signature_token(), choose_array_element_by_weight(), choose_good_entry_server(), choose_good_middle_server(), choose_guard_selection(), chunk_grow(), circ_state_has_higher_priority(), circpad_machine_sample_delay(), circpad_machine_schedule_padding(), circuit_add_to_origin_circuit_list(), circuit_all_predicted_ports_handled(), circuit_append_new_exit(), circuit_build_failed(), circuit_build_times_calculate_timeout(), circuit_build_times_get_xm(), circuit_build_times_new_consensus_params(), circuit_build_times_update_alpha(), circuit_ccontrol(), circuit_change_purpose(), circuit_clear_cell_queue(), circuit_close_all_marked(), circuit_count_pending_on_channel(), circuit_deliver_create_cell(), circuit_describe_status_for_controller(), circuit_detach_stream(), circuit_discard_optional_exit_enclaves(), circuit_establish_circuit_conflux(), circuit_event_status(), circuit_extend(), circuit_find_to_cannibalize(), circuit_finish_handshake(), circuit_free_(), circuit_free_all(), circuit_get_all_pending_on_channel(), circuit_get_best(), circuit_get_by_edge_conn(), circuit_get_next_by_purpose(), circuit_get_open_circ_or_launch(), circuit_handle_first_hop(), circuit_is_acceptable(), circuit_is_queue_full(), circuit_is_suitable_for_introduce1(), circuit_is_suitable_intro_point(), circuit_launch_by_extend_info(), circuit_list_path_impl(), circuit_mark_for_close_(), circuit_n_chan_done(), circuit_receive_relay_cell(), circuit_remove_from_origin_circuit_list(), circuit_remove_handled_ports(), circuit_send_next_onion_skin(), circuit_sent_cell_for_sendme(), circuit_set_state(), circuit_state_publish(), circuit_truncated(), circuitmux_attach_circuit(), circuitmux_attached_circuit_direction(), circuitmux_clear_policy(), circuitmux_compare_muxes(), circuitmux_detach_all_circuits(), circuitmux_detach_circuit(), circuitmux_find_map_entry(), circuitmux_free_(), circuitmux_get_first_active_circuit(), circuitmux_get_policy(), circuitmux_is_circuit_active(), circuitmux_make_circuit_active(), circuitmux_make_circuit_inactive(), circuitmux_notify_xmit_cells(), circuitmux_notify_xmit_destroy(), circuitmux_num_active_circuits(), circuitmux_num_cells(), circuitmux_num_cells_for_circuit(), circuitmux_num_circuits(), circuitmux_set_num_cells(), circuitmux_set_policy(), cleanup_intro_points(), cleanup_on_close_client_circ(), cleanup_on_free_client_circ(), clear_pending_onions(), client_circ_negotiation_message(), client_desc_has_arrived(), client_desc_missing_bad_client_auth(), client_dir_fetch_200(), client_dir_fetch_400(), client_dir_fetch_404(), client_dir_fetch_unexpected(), client_dns_set_addressmap(), client_dns_set_addressmap_impl(), client_filename_is_valid(), client_get_random_intro(), client_intro_circ_has_opened(), client_rendezvous_circ_has_opened(), close_directory_connections(), close_intro_circuits(), close_or_reextend_intro_circ(), close_service_circuits(), close_service_intro_circuits(), close_service_rp_circuits(), command_handle_incoming_channel(), command_process_create_cell(), command_setup_channel(), command_setup_listener(), commit_add_to_state(), commit_decode(), commit_encode(), commit_is_authoritative(), commit_log(), commit_new(), commitments_are_the_same(), compare_tor_addr_to_short_policy(), compare_vote_rs(), compute_consensus_method(), compute_disaster_srv(), compute_introduce_mac(), compute_num_cpus(), compute_padded_plaintext_length(), compute_routerstatus_consensus(), compute_subcredentials(), compute_weighted_bandwidths(), config_assign_line(), config_assign_value(), config_check_immutable_flags(), config_dump(), config_free_(), config_generic_service(), config_get_assigned_option(), config_has_invalid_options(), config_learn_service_version(), config_line_append(), config_line_prepend(), config_mark_lists_fragile(), config_mgr_add_format(), config_mgr_assert_magic_ok(), config_mgr_get_obj_mutable(), config_mgr_list_deprecated_vars(), config_mgr_list_vars(), config_new(), config_parse_units(), config_service(), config_service_v3(), config_validate_service(), config_validate_single(), configure_proxy(), conflux_add_guards_to_exclude_list(), conflux_add_middles_to_exclude_list(), conflux_can_exclude_used_bridges(), conflux_cell_parse_switch(), conflux_circuit_about_to_free(), conflux_circuit_has_opened(), conflux_clear_ooo_q(), conflux_decide_circ_cwndrtt(), conflux_decide_circ_for_send(), conflux_decide_circ_lowrtt(), conflux_decide_circ_minrtt(), conflux_decide_next_circ(), conflux_get_circ_for_conn(), conflux_get_leg(), conflux_launch_leg(), conflux_pick_first_leg(), conflux_process_link(), conflux_process_linked(), conflux_process_linked_ack(), conflux_process_switch_command(), conflux_queue_cmp(), conflux_send_switch_command(), conflux_sync_circ_fields(), conflux_update_half_streams(), conflux_update_n_streams(), conflux_update_p_streams(), conflux_update_resolving_streams(), conflux_validate_legs(), conflux_validate_stream_lists(), congestion_control_build_ext_response(), congestion_control_get_package_window(), congestion_control_note_cell_sent(), congestion_control_update_circuit_bdp(), congestion_control_update_circuit_rtt(), congestion_control_vegas_process_sendme(), congestion_control_vegas_set_params(), conn_get_proxy_type(), conn_stats_format(), connected_cell_format_payload(), connection_about_to_close_connection(), connection_add_impl(), connection_ap_attach_pending(), connection_ap_can_use_exit(), connection_ap_handle_onion(), connection_ap_handshake_attach_chosen_circuit(), connection_ap_handshake_attach_circuit(), connection_ap_handshake_process_socks(), connection_ap_handshake_rewrite_and_attach(), connection_ap_handshake_send_begin(), connection_ap_handshake_send_resolve(), connection_ap_handshake_socks_got_resolved_cell(), connection_ap_handshake_socks_reply(), connection_ap_make_link(), connection_ap_mark_as_pending_circuit_(), connection_ap_mark_as_waiting_for_renddesc(), connection_ap_process_http_connect(), connection_ap_process_natd(), connection_ap_process_transparent(), connection_ap_rescan_and_attach_pending(), connection_buf_add_buf(), connection_check_oos(), connection_connect(), connection_connect_sockaddr(), connection_control_closed(), connection_control_finished_flushing(), connection_control_process_inbuf(), connection_control_reached_eof(), connection_dir_bridge_routerdesc_failed(), connection_dir_download_cert_failed(), connection_dir_download_routerdesc_failed(), connection_dir_finished_connecting(), connection_dir_finished_flushing(), connection_dir_is_anonymous(), connection_dir_process_inbuf(), connection_dirserv_flushed_some(), connection_dns_remove(), connection_edge_end_errno(), connection_edge_finished_connecting(), connection_edge_finished_flushing(), connection_edge_is_rendezvous_stream(), connection_edge_package_raw_inbuf(), connection_edge_process_inbuf(), connection_edge_process_relay_cell(), connection_edge_process_relay_cell_not_open(), connection_edge_process_resolved_cell(), connection_edge_send_command(), connection_exit_begin_conn(), connection_exit_connect(), connection_expire_held_open(), connection_ext_or_process_inbuf(), connection_ext_or_transition(), connection_finished_connecting(), connection_finished_flushing(), connection_flushed_some(), connection_free_(), connection_free_minimal(), connection_half_edge_compare_bsearch(), connection_handle_listener_read(), connection_handle_read_impl(), connection_handle_write_impl(), connection_https_proxy_connect(), connection_is_reading(), connection_is_writing(), connection_link_connections(), connection_listener_new(), connection_listener_new_for_port(), connection_mark_for_close_(), connection_mark_for_close_internal_(), connection_mark_unattached_ap_(), connection_or_change_state(), connection_or_clear_identity(), connection_or_client_learned_peer_id(), connection_or_client_used(), connection_or_close_for_error(), connection_or_close_normally(), connection_or_compute_authenticate_cell_body(), connection_or_connect(), connection_or_finished_connecting(), connection_or_finished_flushing(), connection_or_get_num_circuits(), connection_or_get_state_description(), connection_or_is_bad_for_new_circs(), connection_or_launch_v3_or_handshake(), connection_or_nonopen_was_started_here(), connection_or_notify_error(), connection_or_num_cells_writeable(), connection_or_process_inbuf(), connection_or_reached_eof(), connection_or_send_auth_challenge_cell(), connection_or_send_certs_cell(), connection_or_send_netinfo(), connection_or_send_versions(), connection_or_set_identity_digest(), connection_or_write_cell_to_buf(), connection_or_write_var_cell_to_buf(), connection_printf_to_buf(), connection_process_inbuf(), connection_proxy_connect(), connection_read_proxy_handshake(), connection_remove(), connection_socks4_proxy_connect(), connection_socks5_proxy_connect(), connection_start_reading(), connection_start_reading_from_linked_conn(), connection_start_writing(), connection_state_is_connecting(), connection_state_is_open(), connection_stop_reading(), connection_stop_reading_from_linked_conn(), connection_stop_writing(), connection_tls_continue_handshake(), connection_tls_start_handshake(), connection_write_ext_or_command(), consdiffmgr_find_consensus(), consdiffmgr_rescan_flavor_(), consdiffmgr_validate(), consensus_cache_entry_get_fresh_until(), consensus_cache_entry_get_valid_after(), consensus_cache_entry_get_valid_until(), consensus_cache_entry_get_voter_id_digests(), consensus_cache_get_n_filenames_available(), consensus_compress_worker_replyfn(), consensus_diff_queue_diff_work(), consensus_diff_worker_replyfn(), consensus_diff_worker_threadfn(), consensus_join_lines(), consensus_queue_compression_work(), consider_adding_dir_servers(), consider_hibernation(), consider_sending_introduce1(), control_cmd_parse_args(), control_event_bootstrap_problem(), control_event_circ_bandwidth_used_for_circ(), control_event_circuit_status(), control_event_circuit_status_minor(), control_event_logmsg_pending(), control_event_stream_status(), control_reply_append_kv(), control_split_incoming_command(), control_vprintf_reply(), control_write_reply_line(), copy_ipv6_address(), count_desc_circuit_established(), count_opened_desc_intro_point_circuits(), countbytes_close_fn(), countbytes_read_fn(), countbytes_recv_fn(), countbytes_send_fn(), countbytes_write_fn(), countbytes_writev_fn(), cpath_assert_layer_ok(), cpath_assert_ok(), cpath_init_circuit_crypto(), cpuworker_cancel_circ_handshake(), cpuworker_consensus_has_changed(), cpuworker_init(), cpuworker_onion_handshake_replyfn(), cpuworker_onion_handshake_threadfn(), cpuworker_queue_work(), create_cell_format_impl(), create_initial_guard_context(), create_intro_circuit_identifier(), create_rp_circuit_identifier(), created_cell_format(), crypto_add_spaces_to_fp(), crypto_cipher_crypt_inplace(), crypto_cipher_decrypt(), crypto_cipher_decrypt_with_iv(), crypto_cipher_encrypt(), crypto_cipher_encrypt_with_iv(), crypto_cipher_new_with_iv_and_bits(), crypto_common_digests(), crypto_dh_compute_secret(), crypto_dh_dup(), crypto_dh_free_(), crypto_dh_generate_public(), crypto_dh_get_bytes(), crypto_dh_get_public(), crypto_dh_get_public(), crypto_dh_handshake(), crypto_dh_init_openssl(), crypto_dh_new(), crypto_digest(), crypto_digest256(), crypto_digest256_new(), crypto_digest512(), crypto_digest512_new(), crypto_digest_add_bytes(), crypto_digest_algorithm_get_length(), crypto_digest_alloc_bytes(), crypto_digest_alloc_bytes(), crypto_digest_assign(), crypto_digest_checkpoint(), crypto_digest_dup(), crypto_digest_get_digest(), crypto_digest_restore(), crypto_expand_key_material_rfc5869_sha256(), crypto_expand_key_material_rfc5869_sha256_legacy(), crypto_expand_key_material_TAP(), crypto_fast_rng_get_uint(), crypto_fast_rng_get_uint64(), crypto_fast_rng_getbytes_impl(), crypto_get_rsa_padding_overhead(), crypto_hmac_sha256(), crypto_mac_sha3_256(), crypto_options_validate(), crypto_pk_asn1_decode(), crypto_pk_asn1_decode_private(), crypto_pk_asn1_encode(), crypto_pk_asn1_encode_private(), crypto_pk_cmp_keys(), crypto_pk_generate_key_with_bits(), crypto_pk_keysize(), crypto_pk_num_bits(), crypto_pk_obsolete_private_hybrid_decrypt(), crypto_pk_obsolete_public_hybrid_encrypt(), crypto_pk_private_decrypt(), crypto_pk_private_sign(), crypto_pk_public_checksig(), crypto_pk_public_checksig_digest(), crypto_pk_public_encrypt(), crypto_pwbox(), crypto_rand_int(), crypto_rand_int_range(), crypto_rand_time_range(), crypto_rand_uint(), crypto_rand_uint64(), crypto_rand_uint64_range(), crypto_rand_unmocked(), crypto_seed_rng(), crypto_set_dh_generator(), crypto_strongest_rand_(), crypto_strongest_rand_raw(), crypto_strongest_rand_syscall(), crypto_xof(), crypto_xof_add_bytes(), crypto_xof_new(), crypto_xof_squeeze_bytes(), curve25519_public_to_base64(), cwnd_available(), cwnd_sendable(), decode_auth_client(), decode_auth_type(), decode_create2_list(), decode_hashed_passwords(), decode_intro_legacy_key(), decode_intro_points(), decode_introduction_point(), decode_link_specifiers(), decode_pow_params(), decode_qstring(), decrypt_desc_layer(), decrypt_descriptor_cookie(), decrypt_introduce2(), desc_decode_encrypted_v3(), desc_decode_plaintext_v3(), desc_decode_superencrypted_v3(), desc_decrypt_encrypted(), desc_decrypt_superencrypted(), desc_encode_v3(), desc_intro_point_to_extend_info(), desc_sig_is_valid(), digest256_to_base64(), digest_nss_internal(), digest_to_base64(), dir_routerdesc_download_failed(), dir_server_new(), dir_split_resource_into_fingerprints(), dir_split_resource_into_spoolable(), dirauth_sched_recalculate_timing(), dircollator_add_routerstatus(), dircollator_add_vote(), dircollator_collate(), dircollator_collate_by_ed25519(), dircollator_get_votes_for_router(), dircollator_n_routers(), dircollator_new(), directory_all_unreachable(), directory_command_should_use_begindir(), directory_get_from_all_authorities(), directory_handle_command(), directory_handle_command_post(), directory_initiate_request(), directory_launch_v3_desc_fetch(), directory_post_to_dirservers(), directory_request_fetch_set_hs_ident(), directory_request_new(), directory_request_set_dir_from_routerstatus(), directory_request_set_payload(), directory_request_set_router_purpose(), directory_request_upload_set_hs_ident(), directory_send_command(), dirserv_add_extrainfo(), dirserv_add_multiple_descriptors(), dirserv_cache_measured_bw(), dirserv_compute_performance_thresholds(), dirserv_generate_networkstatus_vote_obj(), dirserv_get_credible_bandwidth_kb(), dirserv_orconn_tls_done(), dirserv_set_router_is_running(), dirserv_set_routerstatus_flags(), dirserv_set_routerstatus_testing(), dirserv_single_reachability_test(), dirvote_add_signatures_to_all_pending_consensuses(), dirvote_add_signatures_to_pending_consensus(), dirvote_add_vote(), dirvote_compute_consensuses(), dirvote_compute_params(), dirvote_format_microdesc_vote_line(), dirvote_get_pending_consensus(), dirvote_get_preferred_voting_intervals(), dirvote_publish_consensus(), disk_state_parse(), disk_state_parse_commits(), disk_state_parse_sr_values(), disk_state_parse_srv(), disk_state_put_commit_line(), disk_state_put_srv_line(), disk_state_set(), disk_state_validate(), dispatcher_run_msg_cbs(), dns_cancel_pending_resolve(), dns_found_answer(), dns_resolve(), dns_resolve_impl(), dnsserv_close_listener(), dnsserv_configure_listener(), do_list_fingerprint(), do_main_loop(), download_status_increment_attempt(), download_status_increment_failure(), download_status_is_ready_by_sk_in_cl(), download_status_reset_by_sk_in_cl(), download_status_schedule_get_delay(), dump_desc(), dump_desc_fifo_add_and_clean(), dump_desc_fifo_bump_hash(), dump_desc_fifo_cleanup(), dump_desc_populate_fifo_from_directory(), dump_desc_populate_one_file(), dup_onion_keys(), ed25519_checksig_batch(), ed25519_keypair_blind(), ed25519_keypair_from_curve25519_keypair(), ed25519_pubkey_copy(), ed25519_pubkey_eq(), ed25519_sign_prefixed(), ed25519_signature_to_base64(), ed_key_init_from_file(), ed_key_new(), edge_connection_new(), edge_of_accounting_period_containing(), EDGE_TO_ENTRY_CONN(), enable_control_logging(), encode_client_auth_cred_for_control_port(), encode_enc_key(), encode_intro_point(), encode_legacy_key(), encode_link_specifiers(), encode_onion_key(), encode_superencrypted_data(), encrypt_desc_data_and_base64(), encrypt_descriptor_data(), enqueue_rend_request(), enter_v3_handshake_with_cell(), entry_connection_new(), entry_guard_add_bridge_to_sample(), entry_guard_add_to_sample_impl(), entry_guard_encode_for_state(), entry_guard_find_node(), entry_guard_has_higher_priority(), entry_guard_obeys_restriction(), entry_guard_pick_for_circuit(), entry_guard_restriction_is_reachability(), entry_guards_all_primary_guards_are_down(), entry_guards_changed_for_guard_selection(), entry_guards_expand_sample(), entry_guards_load_guards_from_state(), entry_guards_note_guard_failure(), entry_guards_note_guard_success(), entry_guards_update_primary(), entry_guards_upgrade_waiting_circuits(), entry_has_decrypted_descriptor(), esc_for_log(), evdns_log_cb(), evdns_server_callback(), ewma_alloc_circ_data(), ewma_alloc_cmux_data(), ewma_cmp_cmux(), ewma_free_circ_data(), ewma_free_cmux_data(), ewma_notify_circ_active(), ewma_notify_circ_inactive(), ewma_notify_xmit_cells(), ewma_pick_active_circuit(), exit_policy_is_general_exit_helper(), exit_policy_remove_redundancies(), expand_filename(), extend_cell_parse(), extend_info_addr_is_allowed(), extend_info_dup(), extend_info_supports_ntor_v3(), extended_cell_parse(), extract_shared_random_commits(), extrainfo_get_by_descriptor_digest(), extrainfo_insert(), extrainfo_parse_entry_from_string(), fdopen_file(), fetch_from_buf_http(), fetch_from_buf_socks(), fetch_from_buf_socks_client(), fetch_v3_desc(), finalize_rend_circuit(), find_and_remove_client_auth_creds_file(), find_by_keyword_(), find_desc_intro_point_by_ident(), find_desc_intro_point_by_legacy_id(), find_dl_min_delay(), find_my_address(), find_service(), find_single_ipv6_orport(), find_start_of_next_router_or_extrainfo(), first_reachable_filtered_entry_guard(), flag_all_conn_wait_desc(), flush_chunk(), flush_chunk_tls(), format_histogram(), format_iso_time_nospace_usec(), format_networkstatus_vote(), format_rfc1123_time(), fp_pair_map_assert_ok(), fp_pair_map_entry_hash(), fp_pair_map_free_(), fp_pair_map_get(), fp_pair_map_get_by_digests(), fp_pair_map_isempty(), fp_pair_map_iter_get(), fp_pair_map_iter_init(), fp_pair_map_iter_next(), fp_pair_map_iter_next_rmv(), fp_pair_map_remove(), fp_pair_map_set(), fp_pair_map_set_by_digests(), fp_pair_map_size(), generate_srv(), geoip_add_entry(), geoip_db_digest(), geoip_format_dirreq_stats(), geoip_format_entry_stats(), geoip_get_client_history(), geoip_is_loaded(), geoip_load_file(), geoip_note_ns_response(), get_address_from_config(), get_address_from_hostname(), get_address_from_interface(), get_address_from_orport(), get_all_auth_client_lines(), get_auth_key_from_cell(), get_bindaddr_for_server_proxy(), get_circuit_with_token(), get_client_ux(), get_counts(), get_exit_for_nonce(), get_extend_info_from_intro_point(), get_id_hash(), get_inner_encrypted_layer_plaintext(), get_interface_address6(), get_intro_secret_hs_input(), get_introduce1_key_material(), get_introduce2_key_material(), get_link_spec_by_type(), get_majority_srv_from_votes(), get_max_intro_circ_per_period(), get_my_roles(), get_net_param_from_list(), get_next_token(), get_node_from_intro_point(), get_objects_from_ident(), get_onion_key(), get_onion_public_key(), get_options_mgr(), get_options_mutable(), get_or_state(), get_outer_encrypted_layer_plaintext(), get_output(), get_parent_directory(), get_phase_str(), get_proxy_addrport(), get_random_virtual_addr(), get_rend_secret_hs_input(), get_rendezvous1_key_material(), get_sampled_guard_with_id(), get_srv_element_from_commit(), get_state_mgr(), get_time_period_length(), get_tlsclient_identity_key(), get_transport_in_state_by_name(), get_transport_options_for_server_proxy(), get_transport_proxy_ports(), get_unique_circ_id_by_chan(), get_user_homedir(), get_vote_line_from_commit(), get_voter(), get_voting_interval(), getinfo_helper_dir(), getinfo_helper_downloads(), getinfo_helper_entry_guards(), getinfo_helper_events(), guards_choose_dirguard(), guards_choose_guard(), guards_update_all(), handle_control_add_onion(), handle_control_authchallenge(), handle_control_authenticate(), handle_control_closestream(), handle_control_command(), handle_control_del_onion(), handle_control_onion_client_auth_add(), handle_control_onion_client_auth_remove(), handle_control_onion_client_auth_view(), handle_control_signal(), handle_establish_intro(), handle_establish_intro_cell_dos_extension(), handle_establish_intro_cell_extensions(), handle_finished_proxy(), handle_get_hs_descriptor_v3(), handle_getinfo_helper(), handle_hs_exit_conn(), handle_introduce1(), handle_introduce2_encrypted_cell_pow_extension(), handle_introduce_ack(), handle_introduce_ack_bad(), handle_introduce_ack_success(), handle_methods_done(), handle_proxy_line(), handle_relay_msg(), handle_rendezvous2(), handle_response_fetch_certificate(), handle_response_fetch_consensus(), handle_response_fetch_desc(), handle_response_fetch_detached_signatures(), handle_response_fetch_hsdesc_v3(), handle_response_fetch_microdesc(), handle_response_fetch_status_vote(), handle_response_upload_dir(), handle_response_upload_hsdesc(), handle_response_upload_signatures(), handle_response_upload_vote(), handle_single_control_command(), have_room_for_onionskin(), helper_parse_circuit_id_protocol(), hex_digest_nickname_decode(), hibernate_end(), host_header_is_localhost(), hs_build_address(), hs_build_blinded_keypair(), hs_build_blinded_pubkey(), hs_build_hs_index(), hs_build_hsdir_index(), hs_cache_client_intro_state_note(), hs_cache_handle_oom(), hs_cache_init(), hs_cache_lookup_as_client(), hs_cache_lookup_as_dir(), hs_cache_lookup_encoded_as_client(), hs_cache_mark_dowloaded_as_dir(), hs_cache_remove_as_client(), hs_cache_store_as_client(), hs_cache_store_as_dir(), hs_cell_build_establish_intro(), hs_cell_build_establish_rendezvous(), hs_cell_build_introduce1(), hs_cell_build_rendezvous1(), hs_cell_parse_intro_established(), hs_cell_parse_introduce2(), hs_cell_parse_introduce_ack(), hs_cell_parse_rendezvous2(), hs_check_service_private_dir(), hs_circ_cleanup_on_close(), hs_circ_cleanup_on_free(), hs_circ_cleanup_on_repurpose(), hs_circ_handle_intro_established(), hs_circ_handle_introduce2(), hs_circ_is_rend_sent_in_intro1(), hs_circ_launch_intro_point(), hs_circ_retry_service_rendezvous_point(), hs_circ_send_establish_rendezvous(), hs_circ_send_introduce1(), hs_circ_service_get_established_intro_circ(), hs_circ_service_get_intro_circ(), hs_circ_service_intro_has_opened(), hs_circ_service_rp_has_opened(), hs_circ_setup_congestion_control(), hs_circuit_hash_token(), hs_circuitmap_get_circuit_impl(), hs_circuitmap_get_or_circuit(), hs_circuitmap_get_origin_circuit(), hs_circuitmap_init(), hs_circuitmap_register_circuit(), hs_circuitmap_register_impl(), hs_circuitmap_remove_circuit(), hs_circuits_have_same_token(), hs_client_any_intro_points_usable(), hs_client_circuit_cleanup_on_close(), hs_client_circuit_cleanup_on_free(), hs_client_circuit_has_opened(), hs_client_close_intro_circuits_from_desc(), hs_client_decode_descriptor(), hs_client_dir_fetch_done(), hs_client_get_random_intro_from_edge(), hs_client_launch_v3_desc_fetch(), hs_client_note_connection_attempt_succeeded(), hs_client_receive_introduce_ack(), hs_client_receive_rendezvous2(), hs_client_receive_rendezvous_acked(), hs_client_reextend_intro_circuit(), hs_client_refetch_hsdesc(), hs_client_register_auth_credentials(), hs_client_setup_intro_circ_auth_key(), hs_config_client_authorization(), hs_config_service_all(), hs_control_desc_event_content(), hs_control_desc_event_created(), hs_control_desc_event_failed(), hs_control_desc_event_received(), hs_control_desc_event_requested(), hs_control_desc_event_upload(), hs_control_desc_event_uploaded(), hs_control_hsfetch_command(), hs_control_hspost_command(), hs_dec_rdv_stream_counter(), hs_desc_build_authorized_client(), hs_desc_decode_descriptor(), hs_desc_decode_encrypted(), hs_desc_decode_plaintext(), hs_desc_decode_superencrypted(), hs_desc_encode_descriptor(), hs_desc_encrypted_obj_size(), hs_desc_plaintext_obj_size(), hs_desc_supports_congestion_control(), hs_descriptor_clear_intro_points(), hs_dos_can_send_intro2(), hs_dos_setup_default_intro2_defenses(), hs_get_responsible_hsdirs(), hs_get_subcredential(), hs_get_time_period_num(), hs_hsdir_requery_period(), hs_ident_dir_conn_init(), hs_inc_rdv_stream_counter(), hs_intro_received_establish_intro(), hs_intro_received_introduce1(), hs_intro_send_intro_established_cell(), hs_metrics_service_free(), hs_metrics_service_init(), hs_metrics_update_by_service(), hs_ntor_circuit_key_expansion(), hs_ntor_client_rendezvous2_mac_is_good(), hs_ntor_service_get_introduce1_keys_multi(), hs_ob_parse_config_file(), hs_ob_refresh_keys(), hs_opts_new(), hs_parse_address_impl(), hs_parse_address_no_log(), hs_path_from_filename(), hs_pick_hsdir(), hs_pow_free_service_state(), hs_pow_queue_work(), hs_pow_solve(), hs_pow_verify(), hs_service_add_ephemeral(), hs_service_circuit_cleanup_on_close(), hs_service_circuit_has_opened(), hs_service_del_ephemeral(), hs_service_find(), hs_service_get_version_from_key(), hs_service_ht_eq(), hs_service_ht_hash(), hs_service_init(), hs_service_lists_fnames_for_sandbox(), hs_service_lookup_current_desc(), hs_service_new_consensus_params(), hs_service_receive_intro_established(), hs_service_receive_introduce2(), hs_service_requires_uptime_circ(), hs_service_set_conn_addr_port(), hs_service_stage_services(), hs_service_upload_desc_to_dir(), hs_set_conn_addr_port(), hs_token_new(), inform_pending_connections(), init_curve25519_keypair_from_file(), init_key_from_file(), init_libevent(), init_store(), intro_circ_is_ok(), intro_point_is_usable(), intro_point_should_expire(), intro_points_all_timed_out(), introduce1_encrypt_and_encode(), introduce1_set_auth_key(), introduce1_set_encrypted(), introduce1_set_encrypted_link_spec(), introduce1_set_encrypted_onion_key(), introduce1_set_encrypted_padding(), is_legal_hexdigest(), is_legal_nickname(), keypin_add_or_replace_entry_in_map(), keypin_check_and_add_impl(), kvline_encode(), kvline_parse(), launch_descriptor_downloads(), launch_intro_point_circuits(), launch_managed_proxy(), launch_proxy_ev(), launch_rendezvous_point_circuit(), launch_resolve(), launch_test_addresses(), launch_wildcard_check(), lcs_lengths(), learned_bridge_descriptor(), line_starts_with_str(), line_str_eq(), link_apconn_to_circ(), link_circuit(), linked_circuit_closed(), linked_circuit_free(), linked_nullify_streams(), linked_pool_add(), linked_pool_del(), linked_pool_get(), linked_update_stream_backpointers(), list_pending_downloads(), list_pending_fpsk_downloads(), load_client_keys(), load_downloaded_routers(), load_ed_keys(), load_service_keys(), log_cant_upload_desc(), log_master_signing_key_cert_expiration(), lookup_type_def(), lookup_v3_desc_as_client(), lookup_v3_desc_as_dir(), mainloop_event_activate(), mainloop_event_new_impl(), mainloop_event_schedule(), make_consensus_method_list(), make_path_absolute(), managed_proxy_exit_callback(), managed_proxy_has_argv(), managed_proxy_has_transport(), managed_proxy_outbound_address(), managed_proxy_severity_parse(), managed_proxy_stderr_callback(), managed_proxy_stdout_callback(), mark_cdm_cache_dirty(), mark_channel_tls_endpoint_as_client(), mark_circuit_unusable_for_new_conns(), mark_conn_as_waiting_for_circuit(), mark_primary_guards_maybe_reachable(), memarea_alloc(), memarea_assert_ok(), memarea_get_stats(), memarea_strndup(), memoize_protover_summary(), memwipe(), metrics_connection_finished_flushing(), metrics_connection_process_inbuf(), metrics_connection_reached_eof(), metrics_parse_ports(), metrics_request_allowed(), metrics_store_add(), metrics_store_entry_add_label(), metrics_store_entry_get_value(), metrics_store_entry_has_label(), metrics_store_entry_new(), metrics_store_entry_reset(), metrics_store_entry_update(), metrics_store_find_entry_with_label(), metrics_store_get_all(), metrics_store_get_output(), metrics_store_hist_entry_get_count(), metrics_store_hist_entry_get_sum(), metrics_store_hist_entry_get_value(), microdesc_cache_rebuild(), microdesc_check_counts(), microdesc_list_missing_digest256(), microdesc_note_outdated_dirserver(), microdesc_parse_fields(), monitor_owning_controller_process(), move_descriptors(), move_ephemeral_services(), move_hs_state(), munge_extrainfo_into_routerinfo(), namemap_get_id_unchecked(), networkstatus_add_detached_signatures(), networkstatus_check_consensus_signature(), networkstatus_check_required_protocols(), networkstatus_compute_bw_weights_v10(), networkstatus_compute_consensus(), networkstatus_consensus_can_use_extra_fallbacks(), networkstatus_consensus_download_failed(), networkstatus_get_detached_signatures(), networkstatus_get_latest_consensus_by_flavor(), networkstatus_parse_detached_signatures(), networkstatus_parse_vote_from_string(), networkstatus_set_current_consensus(), networkstatus_verify_bw_weights(), new_route_len(), next_router(), node_add_to_ed25519_map(), node_free_(), node_get_nickname(), node_get_pref_dirport(), node_get_pref_ipv6_dirport(), node_get_pref_ipv6_orport(), node_get_pref_orport(), node_get_prim_dirport(), node_get_prim_orport(), node_get_rsa_id_digest(), node_handles_some_port(), node_has_hsdir_index(), node_is_possible_guard(), node_remove_from_ed25519_map(), node_supports_accepting_ipv6_extends(), node_supports_conflux(), node_supports_ed25519_hs_intro(), node_supports_establish_intro_dos_extension(), node_supports_initiating_ipv6_extends(), node_supports_v3_hsdir(), node_supports_v3_rendezvous_point(), nodefamily_from_members(), nodelist_add_node_and_family(), nodelist_assert_ok(), nodelist_drop_node(), nodelist_ensure_freshness(), nodelist_set_consensus(), nodelist_set_routerinfo(), note_connection_attempt_succeeded(), ob_option_parse(), onion_consensus_has_changed(), onion_next_task(), onion_populate_cpath(), onion_skin_ntor3_create_nokeygen(), onion_skin_ntor3_server_handshake_part1(), onion_skin_ntor3_server_handshake_part2_nokeygen(), onion_skin_ntor_client_handshake(), onion_skin_ntor_create(), onion_skin_ntor_server_handshake(), onion_skin_server_handshake(), oos_victim_comparator(), ope_get_cipher(), options_act_reversible(), options_commit_listener_transaction(), options_commit_log_transaction(), options_get_dir_fname2_suffix(), options_init_from_string(), options_init_from_torrc(), options_start_listener_transaction(), options_switch_id(), options_transition_affects_dirauth_timing(), options_transition_affects_guards(), options_validate_and_set(), options_validate_cb(), or_connection_new(), or_handshake_certs_check_both(), or_state_save(), or_state_set(), orconn_target_get_name(), parse_accept_encoding_header(), parse_auth_file_content(), parse_authorized_client(), parse_bridge_line(), parse_config_line_from_str_verbose(), parse_dirauth_dirport(), parse_http_response(), parse_http_time(), parse_introduce2_cell(), parse_introduce2_encrypted(), parse_introduce_cell_extension(), parse_log_line(), parse_method_line_helper(), parse_port_range(), parse_private_key_from_control_port(), parse_rfc1123_time(), parse_short_policy(), parse_single_entry(), parse_socks4_request(), parse_socks5_client_request(), parse_socks5_methods_request(), parse_socks5_userpass_auth(), parse_socks_client(), parse_status_line(), parse_tcp_proxy_line(), parse_version_range(), pathbias_check_probe_response(), pathbias_get_scale_ratio(), pathbias_send_usable_probe(), pem_encode(), periodic_event_connect(), periodic_event_disable(), periodic_event_dispatch(), periodic_event_enable(), periodic_event_launch(), periodic_event_schedule_and_disable(), periodic_event_set_interval(), periodic_timer_disable(), periodic_timer_launch(), periodic_timer_new(), pick_hsdir_v3(), pick_needed_intro_points(), pick_oos_victims(), pick_restricted_middle_node(), policies_log_first_redundant_entry(), policies_parse_exit_policy_reject_private(), policy_summarize(), policy_summary_accept(), policy_summary_add_item(), policy_summary_item_split(), policy_summary_reject(), pop_first_cell_ewma(), port_cfg_eq(), port_cfg_line_extract_addrport(), port_cfg_new(), pow_worker_replyfn(), process_append_argument(), process_environment_make(), process_exec(), process_get_arguments(), process_get_argv(), process_get_command(), process_get_data(), process_get_environment(), process_get_pid(), process_get_protocol(), process_get_status(), process_get_unix_process(), process_new(), process_notify_event_exit(), process_notify_event_stderr(), process_notify_event_stdin(), process_notify_event_stdout(), process_printf(), process_read_buffer(), process_read_data(), process_read_lines(), process_read_stderr(), process_read_stdout(), process_reset_environment(), process_sendme_cell(), process_set_data(), process_set_environment(), process_set_exit_callback(), process_set_status(), process_set_stderr_read_callback(), process_set_stdout_read_callback(), process_socks5_methods_request(), process_socks5_userpass_auth(), process_terminate(), process_unix_close_file_descriptors(), process_unix_get_pid(), process_unix_read_handle(), process_unix_read_stderr(), process_unix_read_stdout(), process_unix_setup_handle(), process_unix_start_reading(), process_unix_start_writing(), process_unix_stop_reading(), process_unix_stop_writing(), process_unix_terminate(), process_unix_waitpid_callback(), process_unix_write(), process_vprintf(), process_write(), process_write_stdin(), prometheus_format_store_entry(), protover_compute_vote(), proxy_needs_restart(), proxy_type_to_string(), pt_configure_remaining_proxies(), pt_get_extra_info_descriptor_string(), pt_parse_transport_line(), pt_prepare_proxy_list_for_config_read(), pt_stringify_socks_args(), pt_update_bridge_lines(), pubsub_adjmap_add(), pubsub_cfg_dump(), pubsub_connector_for_subsystem(), pubsub_connector_free_(), pubsub_install(), purge_expired_resolves(), purge_hid_serv_request(), push(), queue_control_event_string(), randomize_time(), reachable_addr_allows_ap(), reachable_addr_choose_base(), reachable_addr_choose_from_dir_server(), reachable_addr_choose_from_ls(), reachable_addr_choose_from_node(), reachable_addr_choose_from_rs(), read_file_to_str_until_eof(), read_to_chunk(), read_to_chunk_tls(), reasonably_live_consensus_is_missing(), record_rtt(), record_rtt_client(), record_rtt_exit(), register_all_services(), register_client_proxy(), register_intro_circ(), register_server_proxy(), register_service(), relay_address_new_suggestion(), relay_crypt_from_last_hop(), relay_crypto_get_sendme_tag(), relay_crypto_sendme_tag_len(), relay_decrypt_cell(), relay_encrypt_cell_inbound(), relay_find_addr_to_publish(), relay_msg_clear(), relay_msg_copy(), relay_send_command_from_edge_(), remember_failing_intro_point(), remove_all_entry_guards_for_guard_selection(), remove_cell_ewma(), remove_duplicate_orports(), remove_expired_failing_intro(), remove_service(), remove_v3_desc_as_client(), remove_v3_desc_as_dir(), rend_pqueue_clear(), rep_hist_desc_stats_write(), rep_hist_format_buffer_stats(), rep_hist_format_exit_stats(), rep_hist_get_conn_created(), rep_hist_get_conn_opened(), rep_hist_get_conn_rejected(), rep_hist_get_predicted_ports(), rep_hist_make_router_pessimal(), rep_hist_note_conn_closed(), rep_hist_note_conn_opened(), rep_hist_note_conn_rejected(), rep_hist_note_router_reachable(), rep_hist_note_router_unreachable(), rep_hist_note_used_port(), rescan_periodic_events(), reschedule_directory_downloads(), resolved_addr_set_last(), resolved_cell_parse(), retry_all_listeners(), retry_service_rendezvous_point(), reveal_decode(), reveal_encode(), router_add_to_routerlist(), router_differences_are_cosmetic(), router_dump_router_to_string(), router_get_all_orports(), router_get_by_descriptor_digest(), router_get_by_extrainfo_digest(), router_get_mutable_by_digest(), router_get_my_descriptor(), router_get_networkstatus_v3_sha3_as_signed(), router_get_orport(), router_load_single_router(), router_parse_addr_policy(), router_parse_addr_policy_item_from_string(), router_parse_entry_from_string(), router_parse_list_from_string(), router_pick_directory_server(), router_pick_dirserver_generic(), router_purpose_to_string(), router_set_status(), router_should_be_dirserver(), routerconf_find_ipv6_or_ap(), routerinfo_incompatible_with_extrainfo(), routerlist_assert_ok(), routerlist_descriptors_added(), routerlist_find_elt_(), routerlist_insert(), routerlist_insert_old(), routerlist_remove(), routerlist_remove_old(), routerlist_remove_old_cached_routers_with_id(), routerlist_replace(), routerset_contains_bridge(), routerset_equal(), routerset_get_all_nodes(), routerset_refresh_countries(), routerset_subtract_nodes(), routerset_union(), routerstatus_format_entry(), routerstatus_has_visibly_changed(), rsa_ed25519_crosscert_check(), run_connection_housekeeping(), safe_str_client_opts(), safe_str_opts(), safe_timer_diff(), sample_laplace_distribution(), sampled_guards_prune_obsolete_entries(), sampled_guards_update_consensus_presence(), sampled_guards_update_from_consensus(), save_commit_during_reveal_phase(), save_commit_to_state(), scale_active_circuits(), scheduler_compare_channels(), scheduler_ev_active(), scheduler_ev_add(), scheduler_evt_callback(), secret_to_key_check(), secret_to_key_rfc2440(), select_entry_guard_for_circuit(), send_control_event_string(), send_establish_intro(), send_introduce_ack_cell(), send_resolved_cell(), sendme_connection_edge_consider_sending(), service_add_fnames_to_list(), service_authorized_client_cmp(), service_authorized_client_config_equal(), service_authorized_client_dup(), service_desc_find_by_intro(), service_encode_descriptor(), service_handle_intro_established(), service_handle_introduce2(), service_intro_circ_has_opened(), service_intro_point_add(), service_intro_point_find(), service_intro_point_remove(), service_is_duplicate_in_list(), service_key_on_disk(), service_rendezvous_circ_has_opened(), set_changed(), set_circuit_blocked_on_chan(), set_descriptor_revision_counter(), set_exitconn_info_from_resolve(), set_expiry(), set_intro_point_onion_key(), set_max_file_descriptors(), set_options(), set_rotation_time(), set_scheduler(), set_server_identity_key(), set_service_default_config(), setup_desc_intro_point(), setup_intro_point_exclude_list(), setup_introduce1_data(), setup_rendezvous_circ_congestion_control(), short_policy_is_reject_star(), should_keep_commit(), should_remove_intro_point(), should_rotate_descriptors(), should_service_upload_descriptor(), should_use_create_fast_for_circuit(), signed_descriptor_from_routerinfo(), signed_descriptor_get_body_impl(), signed_descriptor_move(), signed_descriptor_reset(), smartlist_add_vasprintf(), smartlist_bsearch_idx(), smartlist_join_strings2(), smartlist_pqueue_assert_ok(), smartlist_pqueue_pop(), smartlist_pqueue_remove(), smartlist_reverse(), smartlist_slice(), smartlist_string_remove(), socks_mark_introduction_failed(), socks_mark_rend_circuit_timed_out(), socks_request_set_socks5_error(), spooled_resource_lookup_body(), spooled_resource_lookup_cached_dir(), sr_generate_our_commit(), sr_get_string_for_consensus(), sr_handle_received_commits(), sr_parse_srv(), sr_srv_encode(), sr_state_add_commit(), sr_state_copy_reveal_info(), sr_state_get_commit(), sr_state_get_commits(), sr_state_get_phase(), sr_state_init(), srv_to_control_string(), srv_to_ns_string(), stage_services(), start_writing_to_file(), state_query(), state_query_del_(), state_query_del_all_(), state_query_get_(), state_query_get_commit(), state_query_put_(), state_set(), stderr_read_callback(), stdin_write_callback(), stdout_read_callback(), storage_dir_map_labeled(), storage_dir_read(), store_permanent_client_auth_credentials(), store_v3_desc_as_client(), store_v3_desc_as_dir(), string_is_key_value(), struct_check_magic(), struct_get_mptr(), struct_get_ptr(), struct_set_magic(), subsystems_register_options_formats(), subsystems_register_state_formats(), sum_up_cell_stats_by_command(), summarize_protover_flags(), switch_id(), threadpool_get_n_threads(), threadpool_queue_work_priority(), threadpool_register_reply_event(), timers_initialize(), TO_CONTROL_CONN(), TO_DIR_CONN(), TO_EDGE_CONN(), TO_ENTRY_CONN(), TO_LISTENER_CONN(), TO_OR_CIRCUIT(), TO_OR_CONN(), TO_ORIGIN_CIRCUIT(), tokenize_string(), top_of_rend_pqueue_is_worthwhile(), tor1_crypt_assert_ok(), tor1_crypt_init(), tor_addr_compare_masked(), tor_addr_copy(), tor_addr_copy_ipv6_bytes(), tor_addr_copy_tight(), tor_addr_from_ipv4n(), tor_addr_from_ipv6_bytes(), tor_addr_from_netinfo_addr(), tor_addr_from_sockaddr(), tor_addr_is_internal_(), tor_addr_is_loopback(), tor_addr_is_null(), tor_addr_is_v4(), tor_addr_is_v6(), tor_addr_lookup(), tor_addr_parse_impl(), tor_addr_parse_mask_ports(), tor_addr_port_copy(), tor_addr_port_lookup(), tor_addr_port_parse(), tor_addr_port_split(), tor_addr_to_in6_assert(), tor_addr_to_mapped_ipv4h(), tor_addr_to_PTR_name(), tor_addr_to_str(), tor_cert_create_raw(), tor_cert_eq(), tor_cert_get_checkable_sig(), tor_check_dh_key(), tor_compress_process(), tor_compress_state_size(), tor_escape_str_for_pt_args(), tor_get_prfiledesc_byte_counts(), tor_getpass(), tor_inet_pton(), tor_libevent_get_base(), tor_libevent_initialize(), tor_lockfile_unlock(), tor_lzma_compress_new(), tor_lzma_compress_process(), tor_lzma_compress_state_size(), tor_mainloop_connect_pubsub_events(), tor_make_rsa_ed25519_crosscert(), tor_nss_countbytes_init(), tor_process_monitor_new(), tor_process_monitor_poll_cb(), tor_threadlocal_set(), tor_threads_init(), tor_timegm_impl(), tor_tls_cert_get_key(), tor_tls_cert_is_valid(), tor_tls_context_decref(), tor_tls_context_init(), tor_tls_context_new(), tor_tls_create_certificate(), tor_tls_export_key_material(), tor_tls_free_(), tor_tls_get_buffer_sizes(), tor_tls_get_forced_write_size(), tor_tls_get_n_raw_bytes(), tor_tls_get_own_cert(), tor_tls_get_pending_bytes(), tor_tls_handshake(), tor_tls_is_server(), tor_tls_read(), tor_tls_set_logged_address(), tor_tls_write(), tor_validate_process_specifier(), tor_version_as_new_as(), tor_version_compare(), tor_version_is_obsolete(), tor_version_parse(), tor_version_same_series(), tor_wrap_prfiledesc_with_byte_counter(), tor_x509_cert_decode(), tor_x509_cert_decode_internal(), tor_x509_cert_dup(), tor_x509_cert_get_der(), tor_zlib_compress_process(), tor_zlib_compress_state_size(), tor_zstd_compress_new(), tor_zstd_compress_process(), tor_zstd_compress_state_size(), transport_add(), transport_copy(), transport_get_by_name(), trusted_dir_server_add_dirport(), trusted_dir_server_get_dirport_exact(), try_finalize_set(), typed_var_assign(), typed_var_encode(), unlinked_circuit_closed(), unlinked_circuit_free(), unlinked_close_all_legs(), unlinked_free(), unlinked_leg_add(), unlinked_pool_add(), unlinked_pool_del(), unlinked_pool_del_and_free(), unlinked_pool_get(), update_circuit_on_cmux_(), update_consensus_bootstrap_attempt_downloads(), update_consensus_networkstatus_downloads(), update_consensus_networkstatus_fetch_time_impl(), update_consensus_router_descriptor_downloads(), update_guard_selection_choice(), update_microdescs_from_networkstatus(), update_service_descriptor_intro_points(), update_total_bandwidth_weights(), upload_descriptor_to_all(), upload_descriptor_to_hsdir(), validate_introduce1_parsed_cell(), validate_ports_csv(), validate_recommended_package_line(), validate_transport_socks_arguments(), validate_transports_in_state(), validate_unlinked_legs(), verify_commit_and_reveal(), warn_about_relative_paths(), write_address_to_file(), write_escaped_data(), write_http_response_header_impl(), and write_packed_cell().
| #define tor_assert_nonfatal | ( | cond | ) |
Definition at line 180 of file util_bug.h.
| #define tor_assert_nonfatal_once | ( | cond | ) |
Definition at line 201 of file util_bug.h.
| #define tor_assert_nonfatal_unreached | ( | ) |
Define ALL_BUGS_ARE_FATAL if you want Tor to crash when any problem comes up, so you can get a coredump and track things down.
Definition at line 177 of file util_bug.h.
Referenced by alert_sockets_create(), auth_dirport_usage_for_purpose(), cache_client_intro_state_note(), circpad_distribution_sample(), circpad_is_token_removal_supported(), circpad_machine_remove_token(), client_desc_missing_bad_client_auth(), config_assign_line(), config_has_invalid_options(), config_service(), conflux_choose_algorithm(), connection_ap_handshake_rewrite_and_attach(), connection_buckets_decrement(), connection_dir_client_reached_eof(), consensus_cache_register_with_sandbox(), dirvote_act(), dirvote_callback(), encode_client_auth_cred_for_control_port(), end_reason_to_http_connect_response_line(), entry_guard_obeys_restriction(), entry_guards_note_guard_success(), get_retry_schedule(), handle_control_add_onion(), handle_control_hsfetch(), handle_control_hspost(), handle_control_onion_client_auth_add(), handle_control_onion_client_auth_remove(), handle_hs_exit_conn(), hs_circ_is_rend_sent_in_intro1(), hs_client_circuit_has_opened(), hs_dec_rdv_stream_counter(), hs_inc_rdv_stream_counter(), hs_pow_solve(), log_buggy_rs_source(), networkstatus_set_current_consensus(), nodefamily_add_nodes_to_smartlist(), nodefamily_format(), onion_skin_ntor_create(), parse_dirauth_dirport(), parse_iso_time_(), parse_rfc1123_time(), pick_vanguard_middle_node(), purpose_needs_anonymity(), resolved_addr_method_to_str(), router_get_orport(), router_orport_found_reachable(), spooled_resource_lookup_body(), stream_end_reason_to_socks5_response(), threadpool_new(), threadpool_start_threads(), tor_compress_impl(), unescape_string(), and workerthread_new().
| #define tor_assert_nonfatal_unreached_once | ( | ) |
Definition at line 193 of file util_bug.h.
| #define tor_assert_unreached | ( | ) |
Definition at line 114 of file util_bug.h.
| #define tor_assertf | ( | expr, | |
| fmt, | |||
| ... ) |
Definition at line 105 of file util_bug.h.
| #define tor_assertf_nonfatal | ( | cond, | |
| fmt, | |||
| ... ) |
Definition at line 186 of file util_bug.h.
| #define tor_fix_source_file | ( | s | ) |
Definition at line 299 of file util_bug.h.
| #define tor_fragile_assert | ( | ) |
In older code, we used tor_fragile_assert() to mark optional failure points. At these points, we could make some debug builds fail. (But release builds would continue.)
To get the same behaviour in recent tor versions, define ALL_BUGS_ARE_FATAL, and use any non-fatal assertion or *BUG() macro.
Definition at line 278 of file util_bug.h.
Referenced by base64_encode(), build_addr_port_item(), choose_good_exit_server(), circpad_send_padding_callback(), circuit_build_times_add_time(), circuit_deliver_create_cell(), circuit_detach_stream(), circuit_expire_building(), circuit_launch_by_extend_info(), circuit_purpose_to_controller_hs_state_string(), conn_read_callback(), conn_write_callback(), connection_ap_handshake_attach_circuit(), connection_ap_handshake_rewrite_and_attach(), connection_close_immediate(), connection_connect_sockaddr(), connection_control_closed(), connection_dir_finished_flushing(), connection_edge_about_to_close(), connection_edge_end(), connection_edge_finished_flushing(), connection_edge_process_inbuf(), connection_finished_connecting(), connection_finished_flushing(), connection_handle_read_impl(), connection_mark_for_close_internal_(), connection_or_finished_flushing(), connection_process_inbuf(), connection_proxy_connect(), connection_reached_eof(), connection_read_proxy_handshake(), control_event_circuit_status(), control_event_circuit_status_minor(), crypto_digest_add_bytes(), crypto_digest_algorithm_get_name(), disk_state_parse_commits(), dns_cancel_pending_resolve(), dns_resolve_impl(), evdns_get_orig_address(), getinfo_helper_events(), handle_control_del_onion(), make_specifier(), microdesc_free_(), networkstatus_get_flavor_name(), node_exit_policy_is_exact(), onion_handshake_state_release(), onion_skin_client_handshake(), onion_skin_create(), onion_skin_server_handshake(), pathbias_should_count(), relay_cell_max_payload_size(), relay_encrypt_cell_inbound(), relay_msg_decode_cell_in_place(), relay_msg_encode_cell(), rend_process_relay_cell(), secret_to_key_key_len(), tor_addr_compare_masked(), tor_addr_copy_tight(), tor_addr_hash(), tor_addr_is_internal_(), tor_addr_is_loopback(), tor_addr_keyed_hash(), and unescape_string().
| void tor_abort_ | ( | void | ) |
Call the tor_raw_abort_() function to close raw logs, then kill the current process with a fatal error. But first, close the file-based log file descriptors, so error messages are written before process termination.
(This is a separate function so that we declare it in util_bug.h without including torerr.h in all the users of util_bug.h)
Definition at line 198 of file util_bug.c.
| void tor_assertion_failed_ | ( | const char * | fname, |
| unsigned int | line, | ||
| const char * | func, | ||
| const char * | expr, | ||
| const char * | fmt, | ||
| ... ) |
Helper for tor_assert: report the assertion failure.
Definition at line 75 of file util_bug.c.
| size_t tor_bug_get_count | ( | void | ) |
Definition at line 121 of file util_bug.c.
| void tor_bug_increment_count_ | ( | void | ) |
Helper to update BUG count in metrics.
Definition at line 115 of file util_bug.c.
Referenced by log_fn_(), and tor_bug_occurred_().
| void tor_bug_init_counter | ( | void | ) |
Definition at line 108 of file util_bug.c.
| void tor_bug_occurred_ | ( | const char * | fname, |
| unsigned int | line, | ||
| const char * | func, | ||
| const char * | expr, | ||
| int | once, | ||
| const char * | fmt, | ||
| ... ) |
Helper for tor_assert_nonfatal: report the assertion failure.
Definition at line 128 of file util_bug.c.