Data Fields
or_state_t Struct Reference

#include <or_state_st.h>

Data Fields

uint32_t magic_
time_t next_write
time_t LastWritten
time_t AccountingIntervalStart
uint64_t AccountingBytesReadInInterval
uint64_t AccountingBytesWrittenInInterval
int AccountingSecondsActive
int AccountingSecondsToReachSoftLimit
time_t AccountingSoftLimitHitAt
uint64_t AccountingBytesAtSoftLimit
uint64_t AccountingExpectedUsage
struct config_line_tEntryGuards
struct config_line_tGuard
struct config_line_tTransportProxies
struct config_line_tHidServRevCounter
time_t BWHistoryReadEnds
int BWHistoryReadInterval
struct smartlist_tBWHistoryReadValues
struct smartlist_tBWHistoryReadMaxima
time_t BWHistoryWriteEnds
int BWHistoryWriteInterval
struct smartlist_tBWHistoryWriteValues
struct smartlist_tBWHistoryWriteMaxima
time_t BWHistoryDirReadEnds
int BWHistoryDirReadInterval
struct smartlist_tBWHistoryDirReadValues
struct smartlist_tBWHistoryDirReadMaxima
time_t BWHistoryDirWriteEnds
int BWHistoryDirWriteInterval
struct smartlist_tBWHistoryDirWriteValues
struct smartlist_tBWHistoryDirWriteMaxima
struct config_line_tBuildtimeHistogram
int TotalBuildTimes
int CircuitBuildAbandonedCount
char * TorVersion
struct config_line_tExtraLines
time_t LastRotatedOnionKey
int MinutesSinceUserActivity
int Dormant
struct config_suite_tsubstates_

Detailed Description

Persistent state for an onion router, as saved to disk.

Definition at line 21 of file or_state_st.h.

Field Documentation

◆ AccountingIntervalStart

time_t or_state_t::AccountingIntervalStart

Fields for accounting bandwidth use.

Definition at line 32 of file or_state_st.h.

Referenced by accounting_record_bandwidth_usage().

◆ BuildtimeHistogram

struct config_line_t* or_state_t::BuildtimeHistogram

Build time histogram

Definition at line 78 of file or_state_st.h.

◆ BWHistoryReadEnds

time_t or_state_t::BWHistoryReadEnds

These fields hold information on the history of bandwidth usage for servers. The "Ends" fields hold the time when we last updated the bandwidth usage. The "Interval" fields hold the granularity, in seconds, of the entries of Values. The "Values" lists hold decimal string representations of the number of bytes read or written in each interval. The "Maxima" list holds decimal strings describing the highest rate achieved during the interval.

Definition at line 60 of file or_state_st.h.

◆ Dormant

int or_state_t::Dormant

True if we were dormant when we last wrote the file; false if we weren't. "auto" on initial startup.

Definition at line 97 of file or_state_st.h.

◆ EntryGuards

struct config_line_t* or_state_t::EntryGuards

A list of Entry Guard-related configuration lines. (pre-prop271)

Definition at line 42 of file or_state_st.h.

◆ ExtraLines

struct config_line_t* or_state_t::ExtraLines

Holds any unrecognized values we found in the state file, in the order in which we found them.

Definition at line 87 of file or_state_st.h.

◆ Guard

struct config_line_t* or_state_t::Guard

A list of guard-related configuration lines. (post-prop271)

Definition at line 45 of file or_state_st.h.

Referenced by entry_guards_load_guards_from_state().

◆ HidServRevCounter

struct config_line_t* or_state_t::HidServRevCounter

Cached revision counters for active hidden services on this host

Definition at line 50 of file or_state_st.h.

◆ LastRotatedOnionKey

time_t or_state_t::LastRotatedOnionKey

When did we last rotate our onion key? "0" for 'no idea'.

Definition at line 90 of file or_state_st.h.

◆ LastWritten

time_t or_state_t::LastWritten

When was the state last written to disk?

Definition at line 29 of file or_state_st.h.

◆ MinutesSinceUserActivity

int or_state_t::MinutesSinceUserActivity

Number of minutes since the last user-initiated request (as defined by the dormant net-status system.) Set to zero if we are dormant.

Definition at line 94 of file or_state_st.h.

◆ next_write

time_t or_state_t::next_write

The time at which we next plan to write the state to the disk. Equal to TIME_MAX if there are no savable changes, 0 if there are changes that should be saved right away.

Definition at line 26 of file or_state_st.h.

Referenced by or_state_mark_dirty().

◆ substates_

struct config_suite_t* or_state_t::substates_

State objects for individual modules.

Never access this field or its members directly: instead, use the module in question to get its relevant state object if you must.

Definition at line 105 of file or_state_st.h.

◆ TorVersion

char* or_state_t::TorVersion

What version of Tor wrote this state file?

Definition at line 83 of file or_state_st.h.

The documentation for this struct was generated from the following file: