voteflags.h 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637
  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-2019, The Tor Project, Inc. */
  5. /* See LICENSE for licensing information */
  6. /**
  7. * \file voteflags.h
  8. * \brief Header file for voteflags.c
  9. **/
  10. #ifndef TOR_VOTEFLAGS_H
  11. #define TOR_VOTEFLAGS_H
  12. void dirserv_set_router_is_running(routerinfo_t *router, time_t now);
  13. char *dirserv_get_flag_thresholds_line(void);
  14. void dirserv_compute_bridge_flag_thresholds(void);
  15. int running_long_enough_to_decide_unreachable(void);
  16. void set_routerstatus_from_routerinfo(routerstatus_t *rs,
  17. node_t *node,
  18. const routerinfo_t *ri,
  19. time_t now,
  20. int listbadexits);
  21. void dirserv_compute_performance_thresholds(digestmap_t *omit_as_sybil);
  22. void dirserv_set_bridges_running(time_t now);
  23. #ifdef VOTEFLAGS_PRIVATE
  24. /** Any descriptor older than this age causes the authorities to set the
  25. * StaleDesc flag. */
  26. #define DESC_IS_STALE_INTERVAL (18*60*60)
  27. STATIC void dirserv_set_routerstatus_testing(routerstatus_t *rs);
  28. #endif
  29. #endif