TOR-ускорение

Tor Project

Данная статья написана некоторое время назад и описанные в ней методы ускорения TOR могут не работать, рекомендуем проверить другие статьи на тему VPN и других способов обхода блокировок.

Мы уже неоднократно рассказывали о средствах обхода Великого китайского фаерволла. И как многие уже поняли, самой универсальной программой является пакет из программ TOR+Vidalia и плагина FoxyProxy для браузера Firefox.
Единственный, но огромный минус этой системы — медленная скорость соединения.
Покопавшись в интернете, я нашёл несколько способов ускорить TOR.

Самое интересное решение это совмещение TOR+FoxyProxy, оптимизации браузера и TOR-соединения.

Чтобы оптимизировать Firefox наберите в адресной строке about:config, вы увидете длинный список настроек FF. С помощью встроенного поиска найдите параметры и измените их значения на те, которые написаны ниже:

network.http.keep-alive.timeout:600 (обычно 300ms тоже неплохо, но 600 лучше.) 
network.http.max-persistent-connections-per-proxy:16 (По умолчанию: 4)
network.http.pipelining:true (По умолчанию: false. Некоторые старые сервера не поддерживают эту настройку.)
network.http.pipelining.maxrequests:8 (нет значения по умолчанию)
network.http.proxy.keep-alive:true (По умолчанию - true, но перепроверьте)
network.http.proxy.pipelining:true (По умолчанию- false) 

Перезапускаем FireFox.

Теперь настраиваем TOR. Отключаем Tor и Vidalia, ищем файл конфигурации torrc (Пуск – Vidalia Bundle – Tor – torrc), сохраняем копию этого файла на всякий случай, затем вставляем в него следующий текст:

# This file was generated by Tor; if you edit it, comments will not be preserved
# The old torrc file was renamed to torrc.orig.1 or similar, and Tor will ignore it

# The advertised (external) address we should use.
#Address DELIBERATELY LEFT BLANK - LET TOR CALCULATE ON STARTUP
# Limit the maximum token buffer size (also known as burst) to the given
# number of bytes.
BandwidthBurst 8192KB

# A token bucket limits the average incoming bandwidth on this node to the
# specified number of bytes per second.
BandwidthRate 4096KB

#MaxAdvertisedBandwidth N bytes|KB|MB|GB|TB If set, we will not advertise more than this amount of bandwidth for our BandwidthRate. Server operators who want to reduce the number of clients who ask to build circuits through them (since this is proportional to advertised bandwidth rate) can thus reduce the CPU demands on their server without impacting network performance.
MaxAdvertisedBandwidth 50KB

# Administrative contact information to advertise for this server.
ContactInfo NAME at ISP dot com
#Try for at most NUM seconds when building circuits. If the circuit isn't open in that time, give up on it. (Default: 1 minute.)
CircuitBuildTimeout 5

# If set, Tor will accept connections from the same machine (localhost only)
# on this port, and allow those connections to control the Tor process using
# the Tor Control Protocol (described incontrol-spec.txt).
ControlPort 9051

# Serve directory information from this port, and act as a directory cache.
DirPort 9030

# Send a padding cell every N seconds to keep firewalls from closing our
# connections while Tor is not in use.
KeepalivePeriod 60

# Where to send logging messages.  Format is minSeverity[-maxSeverity]
# (stderr|stdout|syslog|file FILENAME).
Log notice stdout

# Force Tor to consider whether to build a new circuit every NUM seconds.
NewCircuitPeriod 15

# Set the server nickname.
Nickname YOURNICKNAME
# Advertise this port to listen for connections from Tor clients and servers.
ORPort 9001

# Let a socks connection wait NUM seconds unattached before we fail it. (Default: 2 minutes.)
SocksTimeout 30

# If we have keept a clean (never used) circuit around for NUM seconds, then close it. This way when the Tor client is entirely idle, it can expire all of its circuits, and then expire its TLS connections. Also, if we end up making a circuit that is not useful for exiting any of the requests we're receiving, it won't forever take up a slot in the circuit list. (Default: 1 hour.)
CircuitIdleTimeout 600

#NumEntryGuards NUM
#    If UseEntryGuards is set to 1, we will try to pick a total of NUM routers as long-term entries for our circuits. (Defaults to 3.)
NumEntryGuards 8

Перезапускаем Vidalia и Tor. И радуемся ускоренному TOR-у.

Можно к этому добавить использование расширения для Firefox – FasterFox, с настойками “Optimyzed”. Но знайте, что использование этого плагина с сетью TOR “подрывает” и снижает скорость интернет-соединения у других пользователей сети. Так что подумайте об использовании этого плагина хорошенько.

Если вы хотите углубиться в настройки TOR и ускорить его максимально, то советуем прочитать эти статьи:

Фото аватара

Автор: Александр Мальцев

Отец, сын и святой муж. В прошлой жизни — автор немногочисленных интернет-проектов о Китае и китайском языке. Теперь успокоился. Живу и работаю в Шанхае.

2 комментария

  1. Ещё для FF 3.5 надо network.proxy.socks_remote_dns в true надо поставить вместо false по-умолчанию

Добавить комментарий

Ваш адрес email не будет опубликован. Обязательные поля помечены *