mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-12-06 19:41:15 +01:00
Replace ADDR_POLICY_ACCEPT/REJECT with its own enum
svn:r4756
This commit is contained in:
+5
-3
@@ -687,12 +687,14 @@ struct connection_t {
|
||||
|
||||
typedef struct connection_t connection_t;
|
||||
|
||||
#define ADDR_POLICY_ACCEPT 1
|
||||
#define ADDR_POLICY_REJECT 2
|
||||
typedef enum {
|
||||
ADDR_POLICY_ACCEPT=1,
|
||||
ADDR_POLICY_REJECT=2,
|
||||
} addr_policy_action_t;
|
||||
|
||||
/** A linked list of policy rules */
|
||||
typedef struct addr_policy_t {
|
||||
char policy_type; /**< One of ADDR_POLICY_ACCEPT or ADDR_POLICY_REJECT. */
|
||||
addr_policy_action_t policy_type; /**< What to do when the policy matches.*/
|
||||
char *string; /**< String representation of this rule. */
|
||||
uint32_t addr; /**< Base address to accept or reject. */
|
||||
uint32_t msk; /**< Accept/reject all addresses <b>a</b> such that
|
||||
|
||||
Reference in New Issue
Block a user