bridgedb.conf 4.18 KB
Newer Older
1
2
3
4
5
6
7
8

#==========
# General-purpose options.

# We chdir to this directory when we start; all files with relative
# pathnames are created under this directory
RUN_IN_DIR = "~/run/"

9
10
11
# Either a file in which to write our pid, or None
PIDFILE = "bridgedb.pid"

12
13
14
15
16
# Either a file to log to, or None if we should log to the console.
LOGFILE = "bridgedb.log"
# One of "DEBUG", "INFO", "WARNING", "ERROR"...
LOGLEVEL = "INFO"

Roger Dingledine's avatar
Roger Dingledine committed
17
# Files from which we read bridge descriptors, on start and on SIGHUP.
18
19
20
21
22
BRIDGE_FILES = [ "./bridge-descriptors" ]

# File from which we read routerstatus entries, for learning which
# current bridges are Running.
STATUS_FILE = "networkstatus-bridges"
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38

# Only consider routers whose purpose matches this string.
BRIDGE_PURPOSE = "bridge"
# File to store persistent info in.
DB_FILE = "./bridgedist.db"
# File to log changes to persistent info in.  For debugging and bugfixing.
DB_LOG_FILE = "./bridgedist.log"
# File in which we store our secret HMAC root key.
MASTER_KEY_FILE = "./secret_key"

# How many clusters do we group IPs in when distributing bridges based on IP?
N_IP_CLUSTERS = 4

#==========
# Options related to HTTPS

39
# True if we are enabling distribution via HTTP or HTTPS; False otherwise.
40
41
42
43
44
45
46
47
HTTPS_DIST = True
# What proportion of bridges do we allocate to HTTP distribution?  See
# EMAIL_SHARE and RESERVED_SHARE.
HTTPS_SHARE=10
# An IP address (form "1.2.3.4") where we listen for HTTPS connections.
# "None" to listen on the default interface.
HTTPS_BIND_IP=None
# Port to listen on for incoming HTTPS connections
48
HTTPS_PORT=3443
49
50
51
52
# Certificate file
HTTPS_CERT_FILE="cert"
# Private key file.
HTTPS_KEY_FILE="privkey.pem"
53
54
55
56
57
# If true, there is a trusted proxy relaying incoming messages to us: take
# the *last* entry from its X-Forwarded-For header as the client's IP.
HTTPS_USE_IP_FROM_FORWARDED_HEADER = False

# IP and port to listen on for unencrypted HTTP connections.
58
59
HTTP_UNENCRYPTED_BIND_IP=None
HTTP_UNENCRYPTED_PORT=None
60
61
# As HTTPS_USE_IP_FROM_FORWARDED_HEADER, but for unencrypted connections.
HTTP_USE_IP_FROM_FORWARDED_HEADER = False
62
# How many bridges do we give back in an answer?
Roger Dingledine's avatar
Roger Dingledine committed
63
HTTPS_N_BRIDGES_PER_ANSWER=3
64
65
66
67

#==========
# Options related to Email

68
# True if we are enabling distribution via Email; false otherwise.
69
70
71
72
EMAIL_DIST = True
# What proportion of bridges do we allocate to Email distribution?  See
# HTTPS_SHARE and RESERVED_SHARE.
EMAIL_SHARE=10
73

Roger Dingledine's avatar
Roger Dingledine committed
74
# What email addresses do we use for outgoing email?  EMAIL_FROM_ADDR goes
75
76
77
78
79
# in the From: line in outgoing headers, and EMAIL_SMTP_FROM_ADDR goes in
# the MAIL FROM header in outgoing SMTP.
EMAIL_FROM_ADDR = "bridges@torproject.org"
EMAIL_SMTP_FROM_ADDR = "bridges@torproject.org"

80
81
82
# Reject any RCPT TO lines that aren't to this user.
EMAIL_USERNAME = "bridges"

83
84
85
86
87
88
# Canonical versions of domains that we will reply to.
EMAIL_DOMAINS = [ "gmail.com", "yahoo.com" ]
# Map from unofficial domain to canonical domain.
EMAIL_DOMAIN_MAP = { "mail.google.com" : "gmail.com",
                     "googlemail.com" : "gmail.com",
                     }
89
90
91
# Map from canonical domain to list of options for that domain.  Recognized
# options are:
#     "ignore_dots" -- the service ignores "." characters in email addresses.
92
93
#     "dkim" -- if there is not a X-DKIM-Authentication-Result header
#        with the value "pass", then drop the message.
94
95
#
# Note that unrecognized options are ignored; be sure to spell them right!
96
97
EMAIL_DOMAIN_RULES = { 'gmail.com' : ["ignore_dots", "dkim"],
                       'yahoo.com' : ["dkim"]
98
                       }
99
# If there are any IPs in this list, only allow incoming connections from
100
101
102
# those IPs.
EMAIL_RESTRICT_IPS=[]
# IP and port to listen on for email connections. Debugging only.
103
EMAIL_BIND_IP="127.0.0.1"
104
EMAIL_PORT=6725
Roger Dingledine's avatar
Roger Dingledine committed
105
# How many bridges do we give back in an answer?
106
EMAIL_N_BRIDGES_PER_ANSWER=3
107
108
109
110
111
112
113
114

#==========
# Options related to unallocated bridges.

# We split bridges into a group accessible by HTTPS queries; a group
# accessible by email queries; and a group that we don't assign to any
# query mechanism.  Once a bridge is assigned to either of the first
# two groups, it stays there persistently.  The bridges are allocated
Roger Dingledine's avatar
Roger Dingledine committed
115
# to these groups in a proportion of
116
117
118
#   HTTPS_SHARE : EMAIL_SHARE : RESERVED_SHARE
RESERVED_SHARE=2