[tor-commits] [pytorctl/master] Rename make_connection to preauth_connect and export it.
mikeperry at torproject.org
mikeperry at torproject.org
Sat Jun 18 00:30:17 UTC 2011
commit af306b53a668168ae92a6c919d4013b81d7e61ad
Author: Mike Perry <mikeperry-git at fscked.org>
Date: Fri Jun 17 17:29:43 2011 -0700
Rename make_connection to preauth_connect and export it.
---
TorCtl.py | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/TorCtl.py b/TorCtl.py
index 250dab1..c515c97 100755
--- a/TorCtl.py
+++ b/TorCtl.py
@@ -35,7 +35,8 @@ __all__ = ["EVENT_TYPE", "connect", "TorCtlError", "TorCtlClosed",
"NewDescEvent", "CircuitEvent", "StreamEvent", "ORConnEvent",
"StreamBwEvent", "LogEvent", "AddrMapEvent", "BWEvent",
"BuildTimeoutSetEvent", "UnknownEvent", "ConsensusTracker",
- "EventListener", "EVENT_STATE", "ns_body_iter" ]
+ "EventListener", "EVENT_STATE", "ns_body_iter",
+ "preauth_connect" ]
import os
import re
@@ -111,7 +112,7 @@ def connect(controlAddr="127.0.0.1", controlPort=9051, passphrase=None):
conn = None
try:
- conn, authType, authValue = _make_connection(controlAddr, controlPort)
+ conn, authType, authValue = preauth_connect(controlAddr, controlPort)
if authType == AUTH_TYPE.PASSWORD:
# password authentication, promting for the password if it wasn't provided
@@ -134,7 +135,7 @@ def connect(controlAddr="127.0.0.1", controlPort=9051, passphrase=None):
print exc
return None
-def _make_connection(controlAddr="127.0.0.1", controlPort=9051):
+def preauth_connect(controlAddr="127.0.0.1", controlPort=9051):
"""
Provides an uninitiated torctl connection components for the control port,
returning a tuple of the form...
More information about the tor-commits
mailing list