reasons.h 991 B

12345678910111213141516171819202122232425262728293031
  1. /* Copyright (c) 2001 Matej Pfajfar.
  2. * Copyright (c) 2001-2004, Roger Dingledine.
  3. * Copyright (c) 2004-2006, Roger Dingledine, Nick Mathewson.
  4. * Copyright (c) 2007-2016, The Tor Project, Inc. */
  5. /* See LICENSE for licensing information */
  6. /**
  7. * \file reasons.h
  8. * \brief Header file for reasons.c.
  9. **/
  10. #ifndef TOR_REASONS_H
  11. #define TOR_REASONS_H
  12. const char *stream_end_reason_to_control_string(int reason);
  13. const char *stream_end_reason_to_string(int reason);
  14. socks5_reply_status_t stream_end_reason_to_socks5_response(int reason);
  15. uint8_t errno_to_stream_end_reason(int e);
  16. const char *orconn_end_reason_to_control_string(int r);
  17. int tls_error_to_orconn_end_reason(int e);
  18. int errno_to_orconn_end_reason(int e);
  19. const char *circuit_end_reason_to_control_string(int reason);
  20. const char *socks4_response_code_to_string(uint8_t code);
  21. const char *socks5_response_code_to_string(uint8_t code);
  22. const char *bandwidth_weight_rule_to_string(enum bandwidth_weight_rule_t rule);
  23. #endif