[tor-commits] [metrics-tasks/master] Add the graphing code for #1890.

2012-03-28 Thread karsten
commit 0b1ba07f337f672fcc79d90c99cb1aa5b3bcac16
Author: Karsten Loesing karsten.loes...@gmx.net
Date:   Wed Mar 28 08:57:16 2012 +0200

Add the graphing code for #1890.
---
 task-1890/.gitignore|4 
 task-1890/deviant-consensus-times.R |   17 +
 2 files changed, 21 insertions(+), 0 deletions(-)

diff --git a/task-1890/.gitignore b/task-1890/.gitignore
new file mode 100644
index 000..add66bd
--- /dev/null
+++ b/task-1890/.gitignore
@@ -0,0 +1,4 @@
+*.pdf
+*.txt
+*.png
+
diff --git a/task-1890/deviant-consensus-times.R 
b/task-1890/deviant-consensus-times.R
new file mode 100644
index 000..68de181
--- /dev/null
+++ b/task-1890/deviant-consensus-times.R
@@ -0,0 +1,17 @@
+# Usage: Save consensus valid-after times to deviant-consensus-times.txt
+#with lines formatted as -MM-DD-HH-MM-SS-consensus and run
+#R --slave -f deviant-consensus-times.R
+library(ggplot2)
+c - read.table(deviant-consensus-times.txt, header = FALSE,
+  stringsAsFactors = FALSE)
+c - data.frame(
+  month = as.Date(paste(substr(c$V1, 1, 7), -01, sep = )),
+  datetime = as.POSIXct(paste(1971-03-, substr(c$V1, 9, 19), sep = ),
+  format = %Y-%m-%d-%H-%M-%S))
+ggplot(c, aes(x = datetime, y = month)) +
+geom_point(color = red) +
+scale_x_datetime(name = \nDay of month and time, format = %d) +
+scale_y_date(name = Month\n, format = %Y-%m) +
+opts(title = Deviant consensuses\n)
+ggsave(deviant-consensus-times.png, width = 8, height = 6, dpi = 72)
+

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [tor/master] Merge branch 'bug4011'

2012-03-28 Thread nickm
commit 8387d8571ff85fb36097cdda78267aac509ec53e
Merge: 86f1630 d20c6d2
Author: Nick Mathewson ni...@torproject.org
Date:   Wed Mar 28 03:33:00 2012 -0400

Merge branch 'bug4011'

 changes/bug4011|8 ++
 src/or/networkstatus.c |   57 +--
 2 files changed, 48 insertions(+), 17 deletions(-)

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [tor/master] Keep separate time-to-downloads for each consensus flavor

2012-03-28 Thread nickm
commit d20c6d2a374df080c7ca6b08ae9e0c6c6769c40c
Author: Nick Mathewson ni...@torproject.org
Date:   Wed Mar 28 02:55:33 2012 -0400

Keep separate time-to-downloads for each consensus flavor

This is a fix for bug 4011, where if we have a recent ns consensus we
won't even try fetching a microdesc consensus.  Fix on 0.2.3.1-alpha,
I believe.
---
 changes/bug4011|8 ++
 src/or/networkstatus.c |   57 +--
 2 files changed, 48 insertions(+), 17 deletions(-)

diff --git a/changes/bug4011 b/changes/bug4011
new file mode 100644
index 000..23afd13
--- /dev/null
+++ b/changes/bug4011
@@ -0,0 +1,8 @@
+  o Major bugfixes:
+
+- Do not allow the presence of one consensus flavor to keep us from
+  downloading another. Previously, we had one time to download a
+  consensus timer, which didn't understand the idea of having one
+  consensus but wanting to download another. Fixes bug 4011; fix on
+  0.2.3.1-alpha.
+
diff --git a/src/or/networkstatus.c b/src/or/networkstatus.c
index 44c2f26..afd531a 100644
--- a/src/or/networkstatus.c
+++ b/src/or/networkstatus.c
@@ -89,7 +89,7 @@ static time_t last_networkstatus_download_attempted = 0;
 /** A time before which we shouldn't try to replace the current consensus:
  * this will be at some point after the next consensus becomes valid, but
  * before the current consensus becomes invalid. */
-static time_t time_to_download_next_consensus = 0;
+static time_t time_to_download_next_consensus[N_CONSENSUS_FLAVORS];
 /** Download status for the current consensus networkstatus. */
 static download_status_t consensus_dl_status[N_CONSENSUS_FLAVORS];
 
@@ -1220,19 +1220,24 @@ update_consensus_networkstatus_downloads(time_t now)
   int i;
   const or_options_t *options = get_options();
 
-  if (!networkstatus_get_live_consensus(now))
-time_to_download_next_consensus = now; /* No live consensus? Get one now!*/
-  if (time_to_download_next_consensus  now)
-return; /* Wait until the current consensus is older. */
-
   for (i=0; i  N_CONSENSUS_FLAVORS; ++i) {
 /*  need some way to download unknown flavors if we are caching. */
 const char *resource;
 consensus_waiting_for_certs_t *waiting;
+networkstatus_t *c;
 
 if (! we_want_to_fetch_flavor(options, i))
   continue;
 
+c = networkstatus_get_latest_consensus_by_flavor(i);
+if (! (c  c-valid_after = now  now = c-valid_until)) {
+  /* No live consensus? Get one now!*/
+  time_to_download_next_consensus[i] = now;
+}
+
+if (time_to_download_next_consensus[i]  now)
+  return; /* Wait until the current consensus is older. */
+
 resource = networkstatus_get_flavor_name(i);
 
 if (!download_status_is_ready(consensus_dl_status[i], now,
@@ -1284,13 +1289,17 @@ networkstatus_consensus_download_failed(int 
status_code, const char *flavname)
 #define CONSENSUS_MIN_SECONDS_BEFORE_CACHING 120
 
 /** Update the time at which we'll consider replacing the current
- * consensus. */
-void
-update_consensus_networkstatus_fetch_time(time_t now)
+ * consensus of flavor bflav/b */
+static void
+update_consensus_networkstatus_fetch_time_impl(time_t now, int flav)
 {
   const or_options_t *options = get_options();
-  networkstatus_t *c = networkstatus_get_live_consensus(now);
-  if (c) {
+  networkstatus_t *c = networkstatus_get_latest_consensus_by_flavor(flav);
+  const char *flavor = networkstatus_get_flavor_name(flav);
+  if (! we_want_to_fetch_flavor(get_options(), flav))
+return;
+
+  if (c  c-valid_after = now  now = c-valid_until) {
 long dl_interval;
 long interval = c-fresh_until - c-valid_after;
 long min_sec_before_caching = CONSENSUS_MIN_SECONDS_BEFORE_CACHING;
@@ -1339,22 +1348,36 @@ update_consensus_networkstatus_fetch_time(time_t now)
 tor_assert(c-fresh_until  start);
 /* We must download the next one before c is invalid: */
 tor_assert(start+dl_interval  c-valid_until);
-time_to_download_next_consensus = start +crypto_rand_int((int)dl_interval);
+time_to_download_next_consensus[flav] =
+  start + crypto_rand_int((int)dl_interval);
 {
   char tbuf1[ISO_TIME_LEN+1];
   char tbuf2[ISO_TIME_LEN+1];
   char tbuf3[ISO_TIME_LEN+1];
   format_local_iso_time(tbuf1, c-fresh_until);
   format_local_iso_time(tbuf2, c-valid_until);
-  format_local_iso_time(tbuf3, time_to_download_next_consensus);
-  log_info(LD_DIR, Live consensus %s the most recent until %s and will 
+  format_local_iso_time(tbuf3, time_to_download_next_consensus[flav]);
+  log_info(LD_DIR, Live %s consensus %s the most recent until %s and will 

expire at %s; fetching the next one at %s.,
-   (c-fresh_until  now) ? will be : was,
+   flavor, (c-fresh_until  now) ? will be : was,
tbuf1, tbuf2, tbuf3);
 }
   } else {
-time_to_download_next_consensus = now;
-log_info(LD_DIR, No live 

[tor-commits] [tor/master] Write initial documentation for the contents of the state file

2012-03-28 Thread nickm
commit a9c0e9fec2ced629aefdc1436ec41467353cc9a0
Author: Nick Mathewson ni...@torproject.org
Date:   Wed Mar 28 04:08:07 2012 -0400

Write initial documentation for the contents of the state file

Fixes bug 2987.  There is still some information to go, but now we
have a place to put it.
---
 changes/bug2987|3 +
 doc/Makefile.am|3 +-
 doc/state-contents.txt |  105 
 src/or/config.c|2 +
 4 files changed, 112 insertions(+), 1 deletions(-)

diff --git a/changes/bug2987 b/changes/bug2987
new file mode 100644
index 000..727f376
--- /dev/null
+++ b/changes/bug2987
@@ -0,0 +1,3 @@
+  o Documentation
+- Begin a state-contents.txt file in doc to explain the contents of the
+  Tor state file. Fixes bug 2987.
diff --git a/doc/Makefile.am b/doc/Makefile.am
index d8d9fbe..d26f830 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -37,7 +37,8 @@ endif
 EXTRA_DIST = HACKING asciidoc-helper.sh  \
  $(html_in) $(man_in) $(txt_in)  \
  tor-rpm-creation.txt\
- tor-win32-mingw-creation.txt spec/README
+ tor-win32-mingw-creation.txt spec/README\
+state-contents.txt
 
 docdir = @docdir@
 
diff --git a/doc/state-contents.txt b/doc/state-contents.txt
new file mode 100644
index 000..730e2fb
--- /dev/null
+++ b/doc/state-contents.txt
@@ -0,0 +1,105 @@
+
+Contents of the Tor state file
+==
+
+The state file is structured with more or less the same rules as torrc.
+Recognized fields are:
+
+  TorVersion
+
+ The version of Tor that wrote this file
+
+  LastWritten
+
+ Time when this state file was written.
+ Given in ISO format (-MM-DD HH:MM:SS)
+
+  AccountingBytesReadInInterval (memory unit)
+  AccountingBytesWrittenInInterval  (memory unit)
+  AccountingExpectedUsage   (memory unit)
+  AccountingIntervalStart   (ISO time)
+  AccountingSecondsActive   (time interval)
+  AccountingSecondsToReachSoftLimit (time interval)
+  AccountingSoftLimitHitAt  (ISO time)
+  AccountingBytesAtSoftLimit(memory unit)
+
+ These fields describe the state of the accounting subsystem.
+
+ The IntervalStart is the time at which the current accounting
+ interval began.  We were expecting to use ExpectedUsage over the
+ course of the interval.  BytesRead/BytesWritten are the total
+ number of bytes transferred over the whole interval.  If Tor has
+ been active during the interval, then AccountingSecondsActive is
+ the amount of time for which it has been active.  We were expecting
+ to hit the bandwidth soft limit in SecondsToReachSoftLimit after we
+ became active.  When we hit the soft limit, we record
+ BytesAtSoftLimit.  If we hit the soft limit already, we did so at
+ SoftLimitHitAt.
+
+  EntryGuard
+  EntryGuardDownSince
+  EntryGuardUnlistedSince
+  EntryGuardAddedBy
+
+  These lines form sections related to entry guards.  Each section
+  starts with a single EntryGuard line, and is then followed by
+  information on the state of the Entry guard.
+
+  The EntryGuard line contains a nickname, then an identity digest, of
+  the guard.
+
+  The EntryGuardDownSince and EntryGuardUnlistedSince lines are present
+  if the entry guard is believed to be non-running or non-listed.  If
+  present, they contain a line in ISO format (-MM-DD HH:MM:SS).
+
+  The EntryGuardAddedBy line is optional.  It contains three
+  space-separated fields: the identity of the entry guard, the version of
+  Tor that added it, and the ISO time at which it was added.
+
+  TransportProxy
+
+ One or more of these may be present.
+
+ The format is transportname addr:port, to remember the address at
+ which a pluggable transport was listening.
+
+ [ why?]
+
+  BWHistoryReadEnds   (ISO time)
+  BWHistoryReadInterval   (integer, number of seconds)
+  BWHistoryReadValues (comma-separated list of integer)
+  BWHistoryReadMaxima (comma-separated list of integer)
+  BWHistoryWriteEnds
+  BWHistoryWriteInterval
+  BWHistoryWriteValues
+  BWHistoryWriteMaxima
+  BWHistoryDirReadEnds
+  BWHistoryDirReadInterval
+  BWHistoryDirReadValues
+  BWHistoryDirReadMaxima
+  BWHistoryDirWriteEnds
+  BWHistoryDirWriteInterval
+  BWHistoryDirWriteValues
+  BWHistoryDirWriteMaxima
+
+ These values record bandwidth history.  The Values fields are a list, 
for
+ some number of Intervals, of the total amount read/written during that
+ integer.  The Maxima are the highest burst for each interval.
+
+ Interval duration is set by the Interval field, in seconds.  The
+ Ends field is the ending time of the last interval in each list.
+
+ The *Read* and *Write* fields are the total amount read and
+ written; the 

[tor-commits] [tor/master] tab-man strikes back (fixup on a9c0e9fec2)

2012-03-28 Thread arma
commit c3a7bcf4e6652fe34714caaf94cb39e555df87b1
Author: Roger Dingledine a...@torproject.org
Date:   Wed Mar 28 04:06:56 2012 -0400

tab-man strikes back (fixup on a9c0e9fec2)
---
 doc/Makefile.am |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/doc/Makefile.am b/doc/Makefile.am
index d26f830..6cdd66d 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -38,7 +38,7 @@ EXTRA_DIST = HACKING asciidoc-helper.sh  \
  $(html_in) $(man_in) $(txt_in)  \
  tor-rpm-creation.txt\
  tor-win32-mingw-creation.txt spec/README\
-state-contents.txt
+ state-contents.txt
 
 docdir = @docdir@
 

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [translation/orbot] Update translations for orbot

2012-03-28 Thread translation
commit d5626414cd4ca2932db08f363a229de054d9bea9
Author: Translation commit bot translat...@torproject.org
Date:   Wed Mar 28 09:45:04 2012 +

Update translations for orbot
---
 values-fa/strings.xml |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/values-fa/strings.xml b/values-fa/strings.xml
index 23c9c25..9316757 100644
--- a/values-fa/strings.xml
+++ b/values-fa/strings.xml
@@ -97,7 +97,7 @@
   string name=wizard_permissions_no_root_msgYour device does not appear to 
be rooted or provide \'Superuser\' access.\n\nIn order to you to benefit from 
Tor, you will need to use apps built to work with Orbot, or that support HTTP 
or SOCKS proxy settings.\n\n/string
   !--TipsAndTricks screen--
   string name=wizard_tips_title روی آنها فعال استOrbot 
لیکیشنهایی که /string
-  string name=wizard_tips_gibberbotGibberbot: Secure chat app with 
Off-the-Record Encryption/string
+  string name=wizard_tips_gibberbotبرنامهٔ چت را با 
پنهان کنندهٔ بی‌ انتشار ایمنی‌ 
کنید:Gibberbot/string
   string 
name=gibberbot_apk_urlhttps://market.android.com/details?id=info.guardianproject.otr.app.im/string
   string name=wizard_tips_orwebORWEB (فقط آندروید 1.x) - 
مرورگر طراحی شده برای حفظ حریم خصوصی و 
افزونساز اوربات/string
   string 
name=orweb_apk_urlmarket://search?q=pname:nfo.guardianproject.browser/string
@@ -166,7 +166,7 @@
   string name=relayingدرحال بازپخش/string
   string name=enable_your_device_to_be_a_non_exit_relayدستگاه خود 
را برای یک بازپخش کننده غیر-خروجی فعال 
کنید/string
   string name=relay_portپورت بازپخش کننده/string
-  string name=listening_port_for_your_tor_relayListening port for your Tor 
relay/string
+  string name=listening_port_for_your_tor_relay شما Tor پورت 
شنونده برای باز پخش/string
   string name=enter_or_portپورت OR را وارد کنید/string
   string name=relay_nicknameنام مستعار بازپخش 
کننده/string
   string name=the_nickname_for_your_tor_relayنام مستعار 
بازپخش کننده شما/string

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [tor/master] Fix a bunch of check-spaces complaints

2012-03-28 Thread nickm
commit 77bc1b803e0d58b23ff48c2359300ef812f10ee1
Author: Sebastian Hahn sebast...@torproject.org
Date:   Wed Mar 28 15:02:15 2012 +0200

Fix a bunch of check-spaces complaints
---
 src/or/connection.c|3 ++-
 src/or/networkstatus.c |4 ++--
 src/test/test_util.c   |   11 ---
 3 files changed, 8 insertions(+), 10 deletions(-)

diff --git a/src/or/connection.c b/src/or/connection.c
index afdda92..c9093fe 100644
--- a/src/or/connection.c
+++ b/src/or/connection.c
@@ -913,7 +913,8 @@ connection_listener_new(const struct sockaddr 
*listensockaddr,
 #endif
   /* We need to set IPV6_V6ONLY so that this socket can't get used for
* IPv4 connections. */
-  if (setsockopt(s,IPPROTO_IPV6, IPV6_V6ONLY, (void*)one, sizeof(one))0) 
{
+  if (setsockopt(s,IPPROTO_IPV6, IPV6_V6ONLY,
+ (void*)one, sizeof(one))0) {
 int e = tor_socket_errno(s);
 log_warn(LD_NET, Error setting IPV6_V6ONLY flag: %s,
  tor_socket_strerror(e));
diff --git a/src/or/networkstatus.c b/src/or/networkstatus.c
index afd531a..910b99c 100644
--- a/src/or/networkstatus.c
+++ b/src/or/networkstatus.c
@@ -1357,8 +1357,8 @@ update_consensus_networkstatus_fetch_time_impl(time_t 
now, int flav)
   format_local_iso_time(tbuf1, c-fresh_until);
   format_local_iso_time(tbuf2, c-valid_until);
   format_local_iso_time(tbuf3, time_to_download_next_consensus[flav]);
-  log_info(LD_DIR, Live %s consensus %s the most recent until %s and will 

-   expire at %s; fetching the next one at %s.,
+  log_info(LD_DIR, Live %s consensus %s the most recent until %s and 
+   will expire at %s; fetching the next one at %s.,
flavor, (c-fresh_until  now) ? will be : was,
tbuf1, tbuf2, tbuf3);
 }
diff --git a/src/test/test_util.c b/src/test/test_util.c
index 9da4cb7..0f9d1a7 100644
--- a/src/test/test_util.c
+++ b/src/test/test_util.c
@@ -50,7 +50,6 @@ test_util_time(void)
 
   test_eq(-1005000L, tv_udiff(start, end));
 
-
   /* Test tor_timegm */
 
   /* The test values here are confirmed to be correct on a platform
@@ -77,7 +76,6 @@ test_util_time(void)
   a_time.tm_mday = 10;
   test_eq((time_t) -1, tor_timegm(a_time));
 
-
   /* Test {format,parse}_rfc1123_time */
 
   format_rfc1123_time(timestr, 0);
@@ -110,7 +108,6 @@ test_util_time(void)
   test_eq(-1, parse_rfc1123_time(Wed, 30 Mar 2011 23:59:61 GMT, t_res));
 #endif
 
-
   /* Test parse_iso_time */
 
   t_res = 0;
@@ -140,7 +137,6 @@ test_util_time(void)
   test_eq(-1, parse_iso_time(2011-00-30 23:59:59 GMT, t_res));
   test_eq(-1, parse_iso_time(2011-03-30 23:59, t_res));
 
-
   /* Test tor_gettimeofday */
 
   end.tv_sec = 4;
@@ -154,7 +150,6 @@ test_util_time(void)
   /* We might've timewarped a little. */
   tt_int_op(tv_udiff(start, end), =, -5000);
 
-
   /* Test format_iso_time */
 
   tv.tv_sec = (time_t)1326296338;
@@ -910,7 +905,8 @@ test_util_strmisc(void)
 
 wrap_string(sl, A test of string wrapping..., 6, ### , # );
 cp = smartlist_join_strings(sl, , 0, NULL);
-test_streq(cp, ### A\n# test\n# of\n# stri\n# ng\n# wrap\n# ping\n# 
...\n);
+test_streq(cp,
+   ### A\n# test\n# of\n# stri\n# ng\n# wrap\n# ping\n# ...\n);
 tor_free(cp);
 SMARTLIST_FOREACH(sl, char *, cp, tor_free(cp));
 smartlist_clear(sl);
@@ -924,7 +920,8 @@ test_util_strmisc(void)
 
 wrap_string(sl, Small test, 6, ### ,  );
 cp = smartlist_join_strings(sl, , 0, NULL);
-test_streq(cp, ### Sm\n a\n l\n l\n t\n e\n 
s\n t\n);
+test_streq(cp, ### Sm\n a\n l\n l\n t\n e
+   \n s\n t\n);
 tor_free(cp);
 SMARTLIST_FOREACH(sl, char *, cp, tor_free(cp));
 smartlist_clear(sl);

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [translation/vidalia] Update translations for vidalia

2012-03-28 Thread translation
commit 09821bf4fa30dbf87691d95de947cfe8b02d7d1b
Author: Translation commit bot translat...@torproject.org
Date:   Wed Mar 28 17:45:08 2012 +

Update translations for vidalia
---
 ru/vidalia_ru.po |   10 +-
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/ru/vidalia_ru.po b/ru/vidalia_ru.po
index ee7f021..8d267df 100644
--- a/ru/vidalia_ru.po
+++ b/ru/vidalia_ru.po
@@ -8,7 +8,7 @@ msgstr 
 Project-Id-Version: The Tor Project\n
 Report-Msgid-Bugs-To: https://trac.torproject.org/projects/tor\n;
 POT-Creation-Date: 2012-03-21 17:52+\n
-PO-Revision-Date: 2012-03-24 23:37+\n
+PO-Revision-Date: 2012-03-28 17:35+\n
 Last-Translator: liquixis liqui...@gmail.com\n
 Language-Team: Russian 
(http://www.transifex.net/projects/p/torproject/language/ru/)\n
 MIME-Version: 1.0\n
@@ -404,7 +404,7 @@ msgstr Закрыть Поток (Del)
 
 msgctxt ConfigDialog
 msgid General
-msgstr General
+msgstr Общие
 
 msgctxt ConfigDialog
 msgid Network
@@ -1962,11 +1962,11 @@ msgstr Ярлыки Vidalia
 
 msgctxt MainWindow
 msgid Setup Relaying
-msgstr Настройка ретрансляции
+msgstr Ретранслятор
 
 msgctxt MainWindow
 msgid Set up a relay and help the network grow
-msgstr Установите ретранслятор и помогите 
росту сети
+msgstr Настройте ретранслятор и помогите 
росту сети
 
 msgctxt MainWindow
 msgid View the Network
@@ -1978,7 +1978,7 @@ msgstr Обзор карты сети Tor
 
 msgctxt MainWindow
 msgid Use a New Identity
-msgstr Использовать Новую Личность
+msgstr Сменить личность
 
 msgctxt MainWindow
 msgid Make subsequent connections appear new

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [translation/vidalia_completed] Update translations for vidalia_completed

2012-03-28 Thread translation
commit 31a9e8831d1b62d2b62fb809f9759dfde372e62f
Author: Translation commit bot translat...@torproject.org
Date:   Wed Mar 28 17:45:11 2012 +

Update translations for vidalia_completed
---
 ru/vidalia_ru.po |   10 +-
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/ru/vidalia_ru.po b/ru/vidalia_ru.po
index ee7f021..8d267df 100644
--- a/ru/vidalia_ru.po
+++ b/ru/vidalia_ru.po
@@ -8,7 +8,7 @@ msgstr 
 Project-Id-Version: The Tor Project\n
 Report-Msgid-Bugs-To: https://trac.torproject.org/projects/tor\n;
 POT-Creation-Date: 2012-03-21 17:52+\n
-PO-Revision-Date: 2012-03-24 23:37+\n
+PO-Revision-Date: 2012-03-28 17:35+\n
 Last-Translator: liquixis liqui...@gmail.com\n
 Language-Team: Russian 
(http://www.transifex.net/projects/p/torproject/language/ru/)\n
 MIME-Version: 1.0\n
@@ -404,7 +404,7 @@ msgstr Закрыть Поток (Del)
 
 msgctxt ConfigDialog
 msgid General
-msgstr General
+msgstr Общие
 
 msgctxt ConfigDialog
 msgid Network
@@ -1962,11 +1962,11 @@ msgstr Ярлыки Vidalia
 
 msgctxt MainWindow
 msgid Setup Relaying
-msgstr Настройка ретрансляции
+msgstr Ретранслятор
 
 msgctxt MainWindow
 msgid Set up a relay and help the network grow
-msgstr Установите ретранслятор и помогите 
росту сети
+msgstr Настройте ретранслятор и помогите 
росту сети
 
 msgctxt MainWindow
 msgid View the Network
@@ -1978,7 +1978,7 @@ msgstr Обзор карты сети Tor
 
 msgctxt MainWindow
 msgid Use a New Identity
-msgstr Использовать Новую Личность
+msgstr Сменить личность
 
 msgctxt MainWindow
 msgid Make subsequent connections appear new

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [tor/master] Move the logging of 'My line' to debug level (#5151).

2012-03-28 Thread nickm
commit 341e37e38c8b341097ed0fcd3d396dca00578f47
Author: Linus Nordberg li...@nordberg.se
Date:   Mon Mar 19 05:12:19 2012 +0100

Move the logging of 'My line' to debug level (#5151).
---
 src/or/router.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/or/router.c b/src/or/router.c
index d86c5f3..fa89e61 100644
--- a/src/or/router.c
+++ b/src/or/router.c
@@ -1997,7 +1997,7 @@ router_dump_router_to_string(char *s, size_t maxlen, 
routerinfo_t *router,
 if (a) {
   tor_asprintf(extra_or_address,
or-address %s:%d\n, a, router-ipv6_orport);
-  log_notice(LD_OR, My line is %s, extra_or_address);
+  log_debug(LD_OR, My or-address line is %s, extra_or_address);
 }
   }
 



___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [tor/master] Add changes file.

2012-03-28 Thread nickm
commit bd4d8fc744548a234bc35132abd07dcc25c7d51f
Author: Linus Nordberg li...@nordberg.se
Date:   Tue Mar 27 15:00:34 2012 +0200

Add changes file.
---
 changes/bug5151 |4 
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/changes/bug5151 b/changes/bug5151
new file mode 100644
index 000..f872aa4
--- /dev/null
+++ b/changes/bug5151
@@ -0,0 +1,4 @@
+  o Minor bugfixes:
+- Fix bug stomping on ORPort option NoListen and ignoring option
+  NoAdvertise. Fixes bug 5151.
+- Move a debug printout from notice to debug level.



___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [tor/master] Fix cut'n'paste bug (#5151).

2012-03-28 Thread nickm
commit ce5489eec0a032aa98622c3dc0af1af7220a3ad4
Author: Linus Nordberg li...@nordberg.se
Date:   Mon Mar 19 04:55:17 2012 +0100

Fix cut'n'paste bug (#5151).
---
 src/or/config.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/or/config.c b/src/or/config.c
index 0c699b0..f9a3350 100644
--- a/src/or/config.c
+++ b/src/or/config.c
@@ -5774,7 +5774,7 @@ parse_port_config(smartlist_t *out,
   cfg-session_group = sessiongroup;
   cfg-isolation_flags = isolation;
   cfg-no_listen = no_listen;
-  cfg-no_listen = no_advertise;
+  cfg-no_advertise = no_advertise;
   cfg-all_addrs = all_addrs;
   cfg-ipv4_only = ipv4_only;
   cfg-ipv6_only = ipv6_only;



___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [tor/master] note that bug 5151 is on 0.2.3.9-alpha

2012-03-28 Thread nickm
commit 4703bf8792b69745bc87d4b2838c3b69b98e81b8
Author: Nick Mathewson ni...@torproject.org
Date:   Wed Mar 28 17:19:24 2012 -0400

note that bug 5151 is on 0.2.3.9-alpha
---
 changes/bug5151 |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/changes/bug5151 b/changes/bug5151
index f872aa4..4ea1219 100644
--- a/changes/bug5151
+++ b/changes/bug5151
@@ -1,4 +1,4 @@
   o Minor bugfixes:
 - Fix bug stomping on ORPort option NoListen and ignoring option
-  NoAdvertise. Fixes bug 5151.
+  NoAdvertise. Fixes bug 5151; bugfix on 0.2.3.9-alpha.
 - Move a debug printout from notice to debug level.

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [tor/master] Merge remote-tracking branch 'linus/bug5151'

2012-03-28 Thread nickm
commit 04a1696095f936e68b524ac3c4881bf404e450a5
Merge: 77bc1b8 bd4d8fc
Author: Nick Mathewson ni...@torproject.org
Date:   Wed Mar 28 17:18:30 2012 -0400

Merge remote-tracking branch 'linus/bug5151'

 changes/bug5151 |4 
 src/or/config.c |8 
 src/or/router.c |2 +-
 3 files changed, 9 insertions(+), 5 deletions(-)




___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [tor/master] Reorder initialisation of port_cfg to match order of members in struct.

2012-03-28 Thread nickm
commit bb2135fea68b53b4e75795c7b1bd632ce4f0d459
Author: Linus Nordberg li...@nordberg.se
Date:   Mon Mar 19 04:57:19 2012 +0100

Reorder initialisation of port_cfg to match order of members in struct.
---
 src/or/config.c |8 
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/or/config.c b/src/or/config.c
index f9a3350..55fe615 100644
--- a/src/or/config.c
+++ b/src/or/config.c
@@ -5768,13 +5768,13 @@ parse_port_config(smartlist_t *out,
 
 if (out  port) {
   port_cfg_t *cfg = tor_malloc_zero(sizeof(port_cfg_t));
-  cfg-type = listener_type;
-  cfg-port = port;
   tor_addr_copy(cfg-addr, addr);
-  cfg-session_group = sessiongroup;
+  cfg-port = port;
+  cfg-type = listener_type;
   cfg-isolation_flags = isolation;
-  cfg-no_listen = no_listen;
+  cfg-session_group = sessiongroup;
   cfg-no_advertise = no_advertise;
+  cfg-no_listen = no_listen;
   cfg-all_addrs = all_addrs;
   cfg-ipv4_only = ipv4_only;
   cfg-ipv6_only = ipv6_only;



___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [obfsproxy/master] Don't set bufferevent callbacks before forming the circuit.

2012-03-28 Thread asn
commit 4b754df88f8d658b4731ce93f2fcafcc34b72244
Author: George Kadianakis desnac...@riseup.net
Date:   Sat Mar 17 16:01:22 2012 -0700

Don't set bufferevent callbacks before forming the circuit.

Achieve that by splitting the circuit creation into three parts:
First, create the connection on the other side of the circuit. Then,
build the circuit. Finally, set up bufferevent callbacks.

Conflicts:

src/network.c
---
 src/network.c |  151 +++--
 1 files changed, 72 insertions(+), 79 deletions(-)

diff --git a/src/network.c b/src/network.c
index e42b195..219593f 100644
--- a/src/network.c
+++ b/src/network.c
@@ -150,7 +150,6 @@ static void conn_free_on_flush(struct bufferevent *bev, 
void *arg);
 static void circuit_create_socks(conn_t *up);
 static int circuit_add_down(circuit_t *circuit, conn_t *down);
 static void circuit_free(circuit_t *circuit);
-static conn_t *open_outbound(conn_t *conn, bufferevent_data_cb readcb);
 
 static void upstream_read_cb(struct bufferevent *bev, void *arg);
 static void downstream_read_cb(struct bufferevent *bev, void *arg);
@@ -339,48 +338,63 @@ static int
 conn_connect(conn_t *addr_conn, conn_t *connect_conn,
  bufferevent_data_cb readcb)
 {
-  bufferevent_setcb(buf, readcb, NULL, pending_conn_cb, newconn);
+  char *peername;
+  struct evutil_addrinfo *addr = config_get_target_addr(addr_conn-cfg);
+  struct bufferevent *buf = connect_conn-buffer;
+
+  if (!addr) {
+log_warn(%s: no target addresses available, 
safe_str(addr_conn-peername));
+return -1;
+  }
+
+  bufferevent_setcb(buf, readcb, NULL, pending_conn_cb, connect_conn);
 
   do {
 peername = printable_address(addr-ai_addr, addr-ai_addrlen);
+
 if (bufferevent_socket_connect(buf, addr-ai_addr, addr-ai_addrlen) = 0)
   goto success;
 log_info(%s: connection to %s failed: %s,
- safe_str(conn-peername), safe_str(peername),
+ safe_str(addr_conn-peername), safe_str(peername),
  evutil_socket_error_to_string(EVUTIL_SOCKET_ERROR()));
 free(peername);
 addr = addr-ai_next;
   } while (addr);
 
   log_warn(%s: all outbound connection attempts failed,
-   conn-peername);
+   addr_conn-peername);
 
-  conn_free(newconn);
-  return NULL;
+  return -1;
 
  success:
   log_info(%s (%s): Successful outbound connection to '%s'.,
-   safe_str(conn-peername), conn-cfg-vtable-name, 
safe_str(peername));
+   safe_str(addr_conn-peername),
+   addr_conn-cfg-vtable-name, safe_str(peername));
   bufferevent_enable(buf, EV_READ|EV_WRITE);
-  newconn-peername = peername;
-  obfs_assert(connections);
-  smartlist_add(connections, newconn);
+  connect_conn-peername = peername;
 
   /* If we are a server, we should note this connection and consider
  it in our heartbeat status messages. */
-  if (conn-mode == LSN_SIMPLE_SERVER)
-status_note_connection(conn-peername);
+  if (addr_conn-mode == LSN_SIMPLE_SERVER)
+status_note_connection(addr_conn-peername);
+
+  return 0;
 }
 
 /** Create the other side of connection bconn/b on a circuit. */
 static conn_t *
 create_other_side_of_conn(const conn_t *conn)
 {
+  struct event_base *base = bufferevent_get_base(conn-buffer);
+  struct bufferevent *buf;
+  conn_t *newconn;
+
   buf = bufferevent_socket_new(base, -1, BEV_OPT_CLOSE_ON_FREE);
   if (!buf) {
 log_warn(%s: unable to create outbound socket buffer, 
safe_str(conn-peername));
 return NULL;
   }
+
   newconn = proto_conn_create(conn-cfg);
   if (!newconn) {
 log_warn(%s: failed to allocate state for outbound connection,
@@ -391,6 +405,11 @@ create_other_side_of_conn(const conn_t *conn)
 
   /* associate bufferevent with the new connection. */
   newconn-buffer = buf;
+
+  obfs_assert(connections);
+  smartlist_add(connections, newconn);
+
+  return newconn;
 }
 
 /**
@@ -406,11 +425,22 @@ simple_client_listener_cb(conn_t *conn)
 
   bufferevent_setcb(conn-buffer, upstream_read_cb, NULL, error_cb, conn);
 
-  if (circuit_create(conn, open_outbound(conn, downstream_read_cb))) {
+  conn_t *newconn = create_other_side_of_conn(conn);
+  if (!newconn) {
+conn_free(conn);
+return;
+  }
+
+  if (circuit_create(conn, newconn)) {
 conn_free(conn);
 return;
   }
 
+  if (conn_connect(conn, newconn, downstream_read_cb)  0) {
+conn_free(conn); /* circuit_free() should also free newconn. */
+return;
+  }
+
   log_debug(%s: setup complete, safe_str(conn-peername));
 }
 
@@ -449,7 +479,18 @@ simple_server_listener_cb(conn_t *conn)
 
   bufferevent_setcb(conn-buffer, downstream_read_cb, NULL, error_cb, conn);
 
-  if (circuit_create(open_outbound(conn, upstream_read_cb), conn)) {
+  conn_t *newconn = create_other_side_of_conn(conn);
+  if (!newconn) {
+conn_free(conn);
+return;
+  }
+
+  if (circuit_create(newconn, conn)) {
+conn_free(conn);
+return;
+  }
+
+  if (conn_connect(conn, newconn, 

[tor-commits] [obfsproxy/master] Move connection-building code around.

2012-03-28 Thread asn
commit 292b9ac875a44966d74c89cf6f2deac18310f2e5
Author: George Kadianakis desnac...@riseup.net
Date:   Mon Mar 19 16:48:10 2012 -0700

Move connection-building code around.

In open_outbound{,_hostname}(), move the connection building
part to a new function called conn_connect(). Then move the
connection creation part of those functions, to
 create_other_side_of_conn().
---
 src/network.c |  137 -
 1 files changed, 77 insertions(+), 60 deletions(-)

diff --git a/src/network.c b/src/network.c
index 968bdf4..e42b195 100644
--- a/src/network.c
+++ b/src/network.c
@@ -331,6 +331,68 @@ listener_cb(struct evconnlistener *evcl, evutil_socket_t 
fd,
   }
 }
 
+/** Given a connection baddr_conn/b carrying addresses that we
+should connect to, use bconnect_conn/b to connect to
+them. Also, set the callbacks of the connecting bufferevent, with
+breadcb/b being the read callback. */
+static int
+conn_connect(conn_t *addr_conn, conn_t *connect_conn,
+ bufferevent_data_cb readcb)
+{
+  bufferevent_setcb(buf, readcb, NULL, pending_conn_cb, newconn);
+
+  do {
+peername = printable_address(addr-ai_addr, addr-ai_addrlen);
+if (bufferevent_socket_connect(buf, addr-ai_addr, addr-ai_addrlen) = 0)
+  goto success;
+log_info(%s: connection to %s failed: %s,
+ safe_str(conn-peername), safe_str(peername),
+ evutil_socket_error_to_string(EVUTIL_SOCKET_ERROR()));
+free(peername);
+addr = addr-ai_next;
+  } while (addr);
+
+  log_warn(%s: all outbound connection attempts failed,
+   conn-peername);
+
+  conn_free(newconn);
+  return NULL;
+
+ success:
+  log_info(%s (%s): Successful outbound connection to '%s'.,
+   safe_str(conn-peername), conn-cfg-vtable-name, 
safe_str(peername));
+  bufferevent_enable(buf, EV_READ|EV_WRITE);
+  newconn-peername = peername;
+  obfs_assert(connections);
+  smartlist_add(connections, newconn);
+
+  /* If we are a server, we should note this connection and consider
+ it in our heartbeat status messages. */
+  if (conn-mode == LSN_SIMPLE_SERVER)
+status_note_connection(conn-peername);
+}
+
+/** Create the other side of connection bconn/b on a circuit. */
+static conn_t *
+create_other_side_of_conn(const conn_t *conn)
+{
+  buf = bufferevent_socket_new(base, -1, BEV_OPT_CLOSE_ON_FREE);
+  if (!buf) {
+log_warn(%s: unable to create outbound socket buffer, 
safe_str(conn-peername));
+return NULL;
+  }
+  newconn = proto_conn_create(conn-cfg);
+  if (!newconn) {
+log_warn(%s: failed to allocate state for outbound connection,
+ safe_str(conn-peername));
+bufferevent_free(buf);
+return NULL;
+  }
+
+  /* associate bufferevent with the new connection. */
+  newconn-buffer = buf;
+}
+
 /**
This function is called when an upstream client connects to us in
simple client mode.
@@ -529,37 +591,6 @@ open_outbound(conn_t *conn, bufferevent_data_cb readcb)
   }
 
   newconn-buffer = buf;
-  bufferevent_setcb(buf, readcb, NULL, pending_conn_cb, newconn);
-
-  do {
-peername = printable_address(addr-ai_addr, addr-ai_addrlen);
-if (bufferevent_socket_connect(buf, addr-ai_addr, addr-ai_addrlen) = 0)
-  goto success;
-log_info(%s: connection to %s failed: %s,
- safe_str(conn-peername), safe_str(peername),
- evutil_socket_error_to_string(EVUTIL_SOCKET_ERROR()));
-free(peername);
-addr = addr-ai_next;
-  } while (addr);
-
-  log_warn(%s: all outbound connection attempts failed,
-   conn-peername);
-
-  conn_free(newconn);
-  return NULL;
-
- success:
-  log_info(%s (%s): Successful outbound connection to '%s'.,
-   safe_str(conn-peername), conn-cfg-vtable-name, 
safe_str(peername));
-  bufferevent_enable(buf, EV_READ|EV_WRITE);
-  newconn-peername = peername;
-  obfs_assert(connections);
-  smartlist_add(connections, newconn);
-
-  /* If we are a server, we should note this connection and consider
- it in our heartbeat status messages. */
-  if (conn-mode == LSN_SIMPLE_SERVER)
-status_note_connection(conn-peername);
 
   return newconn;
 }
@@ -575,40 +606,11 @@ open_outbound_hostname(conn_t *conn, int af, const char 
*addr, uint16_t port)
   struct bufferevent *buf;
   conn_t *newconn;
 
-  buf = bufferevent_socket_new(base, -1, BEV_OPT_CLOSE_ON_FREE);
-  if (!buf) {
-log_warn(%s: unable to create outbound socket buffer, 
safe_str(conn-peername));
-return NULL;
-  }
-  newconn = proto_conn_create(conn-cfg);
-  if (!newconn) {
-log_warn(%s: failed to allocate state for outbound connection,
- safe_str(conn-peername));
-bufferevent_free(buf);
-return NULL;
-  }
-
-  /* associate bufferevent with the new connection. */
-  newconn-buffer = buf;
-
   /* Set up a temporary FQDN peername. When we actually connect to the
  host, we will replace this peername with the IP address we
  connected to. */
   

[tor-commits] [obfsproxy/master] Don't poke connections or circuits after connect_hostname().

2012-03-28 Thread asn
commit 70e6947c81e7c0f42c94e837fdabec271b876567
Author: George Kadianakis desnac...@riseup.net
Date:   Mon Mar 19 17:10:06 2012 -0700

Don't poke connections or circuits after connect_hostname().

bufferevent_socket_connect_hostname() might fail immediately, and take
the whole circuit with it (since pending_socks_cb() and error_or_eof()
will be called). This means that we should not play with conn_t or
circuit_t after calling bufferevent_socket_connect_hostname().
---
 src/network.c |   11 ++-
 1 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/src/network.c b/src/network.c
index 219593f..1d73249 100644
--- a/src/network.c
+++ b/src/network.c
@@ -648,6 +648,12 @@ socks_read_cb(struct bufferevent *bev, void *arg)
   }
 
   bufferevent_setcb(newconn-buffer, downstream_read_cb, NULL, 
pending_socks_cb, newconn);
+  bufferevent_enable(newconn-buffer, EV_READ|EV_WRITE);
+
+  /* further upstream data will be processed once the downstream
+ side is established */
+  bufferevent_disable(conn-buffer, EV_READ|EV_WRITE);
+
   if (bufferevent_socket_connect_hostname(newconn-buffer, 
get_evdns_base(),
   af, addr, port)  0) {
 log_warn(%s: outbound connection to %s:%u failed: %s,
@@ -656,11 +662,6 @@ socks_read_cb(struct bufferevent *bev, void *arg)
 conn_free(conn);
 return;
   }
-  bufferevent_enable(newconn-buffer, EV_READ|EV_WRITE);
-
-  /* further upstream data will be processed once the downstream
- side is established */
-  bufferevent_disable(conn-buffer, EV_READ|EV_WRITE);
   return;
 }
 



___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [obfsproxy/master] Update changelog for #5156.

2012-03-28 Thread asn
commit fb132ee04e8480be31c3c17aba4ff9eb27821be0
Author: George Kadianakis desnac...@riseup.net
Date:   Sat Mar 17 16:29:33 2012 -0700

Update changelog for #5156.
---
 ChangeLog |2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index f719d58..83fbd6e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -3,6 +3,8 @@ Changes in version 0.1.2 - not yet released
#5157.
  - Implement obfsproxy --version. Fixes the rest of bug #5157.
  - Implement obfsproxy --help.
+ - Fix assertion failure when obfsproxy starts without network
+   connectivity. Fixes bug #5156.
 
 
 Changes in version 0.1.1 - 2012-03-09

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] r25582: {website} we don't translate the website anymore (website/trunk/getinvolved/en)

2012-03-28 Thread Roger Dingledine
Author: arma
Date: 2012-03-28 22:08:45 + (Wed, 28 Mar 2012)
New Revision: 25582

Modified:
   website/trunk/getinvolved/en/translation.wml
Log:
we don't translate the website anymore


Modified: website/trunk/getinvolved/en/translation.wml
===
--- website/trunk/getinvolved/en/translation.wml2012-03-27 23:08:04 UTC 
(rev 25581)
+++ website/trunk/getinvolved/en/translation.wml2012-03-28 22:08:45 UTC 
(rev 25582)
@@ -2,7 +2,7 @@
 # Revision: $Revision$
 # Translation-Priority: 4-optional
 
-#include head.wmi TITLE=Tor Website Translation Guidelines CHARSET=UTF-8
+#include head.wmi TITLE=Tor Translation Guidelines CHARSET=UTF-8
 div id=content class=clearfix
   div id=breadcrumbs
 a href=page indexHome raquo; /a
@@ -10,11 +10,11 @@
 a href=page getinvolved/translationTranslation Guidelines/a
   /div
   div id=maincol 
-h1Tor Website Translation Guidelines/h1
+h1Tor Translation Guidelines/h1
 hr
 
 p
-If you want to help translate the Tor website and documentation into
+If you want to help translate the Tor tools and documentation into
 other languages, here are some guidelines to help you do this as
 efficiently as possible.
 /p

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [translation/vidalia] Update translations for vidalia

2012-03-28 Thread translation
commit d1f759b6d4b65f13c62d81533bc5c0e343d3f11f
Author: Translation commit bot translat...@torproject.org
Date:   Wed Mar 28 22:15:08 2012 +

Update translations for vidalia
---
 fa/vidalia_fa.po |9 +
 1 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/fa/vidalia_fa.po b/fa/vidalia_fa.po
index 6c26dc7..be114e6 100644
--- a/fa/vidalia_fa.po
+++ b/fa/vidalia_fa.po
@@ -5,13 +5,14 @@
 # martin luther king sabztun...@gmail.com, 2012.
 # runasand runa.sand...@gmail.com, 2011.
 #   slander...@hotmail.com, 2012.
+#   s.sam...@gmail.com, 2012.
 msgid 
 msgstr 
 Project-Id-Version: The Tor Project\n
 Report-Msgid-Bugs-To: https://trac.torproject.org/projects/tor\n;
 POT-Creation-Date: 2012-03-21 17:52+\n
-PO-Revision-Date: 2012-03-25 08:42+\n
-Last-Translator: ms slander...@hotmail.com\n
+PO-Revision-Date: 2012-03-28 22:11+\n
+Last-Translator: ssampad s.sam...@gmail.com\n
 Language-Team: translati...@vidalia-project.net\n
 MIME-Version: 1.0\n
 Content-Type: text/plain; charset=UTF-8\n
@@ -2121,7 +2122,7 @@ msgid 
 \n
 Here's the last error message:\n
 %2
-msgstr 
+msgstr Vidalia نمی تواند راهی برای برقراری 
ارتباط با Tor پیدا کند زیرا به فایل: %1 دسترسی 
ندارد.\n\nآخرین پیغام خطا:\n%2
 
 msgctxt MainWindow
 msgid 
@@ -3121,7 +3122,7 @@ msgstr (ترافیک باز پخش برای شبکه 
تُر (بازپخش خر
 
 msgctxt ServerPage
 msgid Relay traffic inside the Tor network (non-exit relay)
-msgstr 
+msgstr باز پخش ترافیک درون شبکه Tor (بازپخش غیر 
خروجی)
 
 msgctxt ServerPage
 msgid Mirror the Relay Directory

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [translation/vidalia] Update translations for vidalia

2012-03-28 Thread translation
commit 1dc999b541d1a9155686d3b86d8443fd245d18c4
Author: Translation commit bot translat...@torproject.org
Date:   Wed Mar 28 22:45:09 2012 +

Update translations for vidalia
---
 fa/vidalia_fa.po |8 
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/fa/vidalia_fa.po b/fa/vidalia_fa.po
index be114e6..4263ed2 100644
--- a/fa/vidalia_fa.po
+++ b/fa/vidalia_fa.po
@@ -11,7 +11,7 @@ msgstr 
 Project-Id-Version: The Tor Project\n
 Report-Msgid-Bugs-To: https://trac.torproject.org/projects/tor\n;
 POT-Creation-Date: 2012-03-21 17:52+\n
-PO-Revision-Date: 2012-03-28 22:11+\n
+PO-Revision-Date: 2012-03-28 22:24+\n
 Last-Translator: ssampad s.sam...@gmail.com\n
 Language-Team: translati...@vidalia-project.net\n
 MIME-Version: 1.0\n
@@ -2122,14 +2122,14 @@ msgid 
 \n
 Here's the last error message:\n
 %2
-msgstr Vidalia نمی تواند راهی برای برقراری 
ارتباط با Tor پیدا کند زیرا به فایل: %1 دسترسی 
ندارد.\n\nآخرین پیغام خطا:\n%2
+msgstr \ویدالیا\ نمی تواند راهی برای برقراری 
ارتباط با \تُر\ پیدا کند زیرا به فایل: %1 
دسترسی ندارد.\n\nآخرین پیغام خطا:\n%2
 
 msgctxt MainWindow
 msgid 
 It seems Tor has stopped running since Vidalia started it.\n
 \n
 See the Advanced Message Log for more information.
-msgstr 
+msgstr به نظر می رسد که \تُر\ پس از اجرا شدن 
توسط Vidalia متوقف شده است.\n\nبرای کسب اطلاعات 
بیشتر می توانید قسمت گزارش پیام پیشرفته را 
مشاهده نمایید.
 
 msgctxt MainWindow
 msgid 
@@ -3122,7 +3122,7 @@ msgstr (ترافیک باز پخش برای شبکه 
تُر (بازپخش خر
 
 msgctxt ServerPage
 msgid Relay traffic inside the Tor network (non-exit relay)
-msgstr باز پخش ترافیک درون شبکه Tor (بازپخش غیر 
خروجی)
+msgstr باز پخش ترافیک درون شبکه \تُر\ (بازپخش 
داخلی)
 
 msgctxt ServerPage
 msgid Mirror the Relay Directory

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [translation/vidalia_help] Update translations for vidalia_help

2012-03-28 Thread translation
commit c9818d52fb1c2bf51d560e697be44efa4f2ea3a0
Author: Translation commit bot translat...@torproject.org
Date:   Wed Mar 28 22:45:19 2012 +

Update translations for vidalia_help
---
 fa/bridges.po |7 ---
 1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/fa/bridges.po b/fa/bridges.po
index e60de6e..4d0840f 100644
--- a/fa/bridges.po
+++ b/fa/bridges.po
@@ -2,13 +2,14 @@
 # Translators:
 #   aalaeiar...@gmail.com, 2011.
 # runasand runa.sand...@gmail.com, 2011.
+#   s.sam...@gmail.com, 2012.
 msgid 
 msgstr 
 Project-Id-Version: The Tor Project\n
 Report-Msgid-Bugs-To: https://trac.torproject.org/projects/tor\n;
 POT-Creation-Date: 2010-06-26 16:58+0200\n
-PO-Revision-Date: 2012-02-14 10:02+\n
-Last-Translator: arashaalaei aalaeiar...@gmail.com\n
+PO-Revision-Date: 2012-03-28 22:39+\n
+Last-Translator: ssampad s.sam...@gmail.com\n
 Language-Team: LANGUAGE l...@li.org\n
 MIME-Version: 1.0\n
 Content-Type: text/plain; charset=UTF-8\n
@@ -24,7 +25,7 @@ msgstr پل های انتقالی
 #. type: Content of: htmlbody
 #: en/bridges.html:19
 msgid a name=\about\/
-msgstr یک نام = درباره
+msgstr a name=\درباره\/
 
 #. type: Content of: htmlbodyh3
 #: en/bridges.html:20

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [translation/vidalia_help_completed] Update translations for vidalia_help_completed

2012-03-28 Thread translation
commit 0bd77986e3e079f5ffe75fc737856977c9ce7641
Author: Translation commit bot translat...@torproject.org
Date:   Wed Mar 28 22:45:23 2012 +

Update translations for vidalia_help_completed
---
 fa/bridges.po |7 ---
 1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/fa/bridges.po b/fa/bridges.po
index e60de6e..4d0840f 100644
--- a/fa/bridges.po
+++ b/fa/bridges.po
@@ -2,13 +2,14 @@
 # Translators:
 #   aalaeiar...@gmail.com, 2011.
 # runasand runa.sand...@gmail.com, 2011.
+#   s.sam...@gmail.com, 2012.
 msgid 
 msgstr 
 Project-Id-Version: The Tor Project\n
 Report-Msgid-Bugs-To: https://trac.torproject.org/projects/tor\n;
 POT-Creation-Date: 2010-06-26 16:58+0200\n
-PO-Revision-Date: 2012-02-14 10:02+\n
-Last-Translator: arashaalaei aalaeiar...@gmail.com\n
+PO-Revision-Date: 2012-03-28 22:39+\n
+Last-Translator: ssampad s.sam...@gmail.com\n
 Language-Team: LANGUAGE l...@li.org\n
 MIME-Version: 1.0\n
 Content-Type: text/plain; charset=UTF-8\n
@@ -24,7 +25,7 @@ msgstr پل های انتقالی
 #. type: Content of: htmlbody
 #: en/bridges.html:19
 msgid a name=\about\/
-msgstr یک نام = درباره
+msgstr a name=\درباره\/
 
 #. type: Content of: htmlbodyh3
 #: en/bridges.html:20

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [stem/master] Minor corrections for os.sysconf check

2012-03-28 Thread atagar
commit df2084b0e746e6c5036528b01884a168b3b513ce
Author: Damian Johnson ata...@torproject.org
Date:   Wed Mar 28 20:09:08 2012 -0700

Minor corrections for os.sysconf check

The patch from beckbaibai fixed his issue but left CLOCK_TICKS undefined on
Windows which would result in a NameError when using proc.get_stats (the
function *should* cause an error, but not that one).
---
 stem/util/proc.py |   13 +
 1 files changed, 9 insertions(+), 4 deletions(-)

diff --git a/stem/util/proc.py b/stem/util/proc.py
index 0e9f5ed..e8e253d 100644
--- a/stem/util/proc.py
+++ b/stem/util/proc.py
@@ -33,10 +33,12 @@ import stem.util.log as log
 
 # cached system values
 IS_PROC_AVAILABLE, SYS_START_TIME, SYS_PHYSICAL_MEMORY = None, None, None
-try:
-  CLOCK_TICKS = os.sysconf(os.sysconf_names[SC_CLK_TCK])
-except AttributeError:
-  pass
+CLOCK_TICKS = None
+
+# os.sysconf is only defined on unix
+try: CLOCK_TICKS = os.sysconf(os.sysconf_names[SC_CLK_TCK])
+except AttributeError: pass
+
 Stat = stem.util.enum.Enum((COMMAND, command), (CPU_UTIME, utime),
  (CPU_STIME, stime), (START_TIME, start time))
 
@@ -226,6 +228,9 @@ def get_stats(pid, *stat_types):
 IOError if it can't be determined
   
   
+  if CLOCK_TICKS == None:
+raise IOError(Unable to look up SC_CLK_TCK)
+  
   start_time, parameter = time.time(), process %s % , .join(stat_types)
   
   # the stat file contains a single line, of the form...

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [stem/master] fixed system module undefined in windows

2012-03-28 Thread atagar
commit f5950d01e1578a532c03da55165030f8c3ba3919
Author: Beck csyb...@gmail.com
Date:   Tue Mar 27 01:11:30 2012 -0500

fixed system module undefined in windows
---
 stem/util/proc.py |5 -
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/stem/util/proc.py b/stem/util/proc.py
index cbfc3c5..0e9f5ed 100644
--- a/stem/util/proc.py
+++ b/stem/util/proc.py
@@ -33,7 +33,10 @@ import stem.util.log as log
 
 # cached system values
 IS_PROC_AVAILABLE, SYS_START_TIME, SYS_PHYSICAL_MEMORY = None, None, None
-CLOCK_TICKS = os.sysconf(os.sysconf_names[SC_CLK_TCK])
+try:
+  CLOCK_TICKS = os.sysconf(os.sysconf_names[SC_CLK_TCK])
+except AttributeError:
+  pass
 Stat = stem.util.enum.Enum((COMMAND, command), (CPU_UTIME, utime),
  (CPU_STIME, stime), (START_TIME, start time))
 



___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits


[tor-commits] [stem/master] Typo corrections for descriptor changes

2012-03-28 Thread atagar
commit 222d58a9bad7e1675f70002fb00b2a9b962cfe63
Author: Damian Johnson ata...@torproject.org
Date:   Wed Mar 28 20:19:03 2012 -0700

Typo corrections for descriptor changes

Patch by karsten to fix numerous misspellings.
---
 stem/descriptor/__init__.py  |2 +-
 stem/descriptor/reader.py|6 +++---
 stem/descriptor/server_descriptor.py |8 
 3 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/stem/descriptor/__init__.py b/stem/descriptor/__init__.py
index 325ac4b..21f40c2 100644
--- a/stem/descriptor/__init__.py
+++ b/stem/descriptor/__init__.py
@@ -45,7 +45,7 @@ def parse_file(path, descriptor_file):
   desc._set_path(path)
   yield desc
   else:
-# unrecognized descritor type
+# unrecognized descriptor type
 raise TypeError(Unable to determine the descriptor's type. filename: 
'%s', first line: '%s' % (filename, first_line))
 
 class Descriptor:
diff --git a/stem/descriptor/reader.py b/stem/descriptor/reader.py
index 4683744..c81fe6e 100644
--- a/stem/descriptor/reader.py
+++ b/stem/descriptor/reader.py
@@ -193,7 +193,7 @@ class DescriptorReader:
   
   Arguments:
 targets (list)  - paths for files or directories to be read from
-follow_links (bool) - determines if we'll follow symlinks when transversing
+follow_links (bool) - determines if we'll follow symlinks when traversing
   directories
 buffer_size (int)   - descriptors we'll buffer before waiting for some to
   be read, this is unbounded if zero
@@ -323,7 +323,7 @@ class DescriptorReader:
   # this can take a while if, say, we're including the root directory
   if self._is_stopped.is_set(): break
   else:
-# This is a file. Register it's last modified timestamp and check if
+# This is a file. Register its last modified timestamp and check if
 # it's a file that we should skip.
 
 last_modified = int(os.stat(target).st_mtime)
@@ -396,7 +396,7 @@ class DescriptorReader:
   self._notify_skip_listeners(target, ReadFailed(exc))
   
   def _enqueue_descriptor(self, descriptor):
-# blocks until their is either room for the descriptor or we're stopped
+# blocks until there is either room for the descriptor or we're stopped
 
 while True:
   try:
diff --git a/stem/descriptor/server_descriptor.py 
b/stem/descriptor/server_descriptor.py
index a82a657..3460740 100644
--- a/stem/descriptor/server_descriptor.py
+++ b/stem/descriptor/server_descriptor.py
@@ -153,7 +153,7 @@ def _read_until_keyword(keyword, descriptor_file, inclusive 
= False):
   
   return content
 
-def _get_psudo_pgp_block(remaining_contents):
+def _get_pseudo_pgp_block(remaining_contents):
   
   Checks if given contents begins with a pseudo-Open-PGP-style block and, if
   so, pops it off and provides it back to the caller.
@@ -335,7 +335,7 @@ class ServerDescriptorV3(stem.descriptor.Descriptor):
   keyword, value = line_match.groups()
   
   try:
-block_contents = _get_psudo_pgp_block(remaining_contents)
+block_contents = _get_pseudo_pgp_block(remaining_contents)
   except ValueError, exc:
 if not validate: continue
 raise exc
@@ -429,7 +429,7 @@ class ServerDescriptorV3(stem.descriptor.Descriptor):
 # version followed by the os like the following...
 # platform Tor 0.2.2.35 (git-73ff13ab3cc9570d) on Linux x86_64
 #
-# There's no guerentee that we'll be able to pick these out the
+# There's no guarantee that we'll be able to pick these out the
 # version, but might as well try to save our caller the effot.
 
 platform_match = re.match(^Tor (\S*).* on (.*)$, self.platform)
@@ -479,7 +479,7 @@ class ServerDescriptorV3(stem.descriptor.Descriptor):
 # fingerprint
 
 if validate and not stem.util.tor_tools.is_valid_fingerprint(value):
-  raise ValueError(Hidden service digests should consist of fourty 
hex digits: %s % value)
+  raise ValueError(Extra-info digests should consist of fourty hex 
digits: %s % value)
 
 self.extra_info_digest = value
   elif keyword == hidden-service-dir:

___
tor-commits mailing list
tor-commits@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits