[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [flashproxy/master] more docs for reg methods
commit d3dbe18920f39e6d365186f26a2feda98d81decc
Author: Ximin Luo <infinity0@xxxxxxx>
Date: Tue Nov 19 19:28:57 2013 +0000
more docs for reg methods
- mention how the client registration address is worked out
- add shorter usage synopses from man pages
---
flashproxy-client | 1 +
flashproxy-reg-appspot | 5 ++++-
flashproxy-reg-email | 4 +++-
flashproxy-reg-http | 5 ++++-
flashproxy-reg-url | 1 +
5 files changed, 13 insertions(+), 3 deletions(-)
diff --git a/flashproxy-client b/flashproxy-client
index 60068be..af20dcf 100755
--- a/flashproxy-client
+++ b/flashproxy-client
@@ -1007,6 +1007,7 @@ def main():
global unlinked_locals, unlinked_remotes
parser = argparse.ArgumentParser(
+ usage="%(prog)s --register [OPTIONS] [LOCAL][:PORT] [REMOTE][:PORT]",
formatter_class=argparse.RawDescriptionHelpFormatter,
description="""\
Wait for connections on a local and a remote port. When any pair of connections
diff --git a/flashproxy-reg-appspot b/flashproxy-reg-appspot
index ca78419..f0e4714 100755
--- a/flashproxy-reg-appspot
+++ b/flashproxy-reg-appspot
@@ -126,7 +126,10 @@ def get_external_ip():
f.close()
parser = argparse.ArgumentParser(
- description="Register with a facilitator through a Google App Engine app.")
+ usage="%(prog)s [OPTIONS] [REMOTE][:PORT]",
+ description="Register with a facilitator through a Google App Engine app. "
+ "If only the external port is given, the remote server guesses our "
+ "external address.")
# common opts
parser.add_argument("-4", help="name lookups use only IPv4.",
action="store_const", const=socket.AF_INET, dest="address_family")
diff --git a/flashproxy-reg-email b/flashproxy-reg-email
index a7e7d23..a151efd 100755
--- a/flashproxy-reg-email
+++ b/flashproxy-reg-email
@@ -63,9 +63,11 @@ def get_facilitator_pubkey():
return RSA.load_pub_key_bio(BIO.MemoryBuffer(DEFAULT_FACILITATOR_PUBKEY_PEM))
parser = argparse.ArgumentParser(
+ usage="%(prog)s [OPTIONS] [REMOTE][:PORT]",
description="Register with a flash proxy facilitator through email. Makes "
"a STARTTLS connection to an SMTP server and sends mail with a client IP "
- "address to a designated address.",
+ "address to a designated address. If only the external port is given, the "
+ "external address is guessed from the SMTP EHLO response.",
epilog="Using an SMTP server or email address other than the defaults will "
"not work unless you have made special arrangements to connect them to a "
"facilitator.")
diff --git a/flashproxy-reg-http b/flashproxy-reg-http
index 2fc0f23..a3ad246 100755
--- a/flashproxy-reg-http
+++ b/flashproxy-reg-http
@@ -38,7 +38,10 @@ def build_reg(addr, transport):
))
parser = argparse.ArgumentParser(
- description="Register with a flash proxy facilitator using an HTTP POST.")
+ usage="%(prog)s [OPTIONS] [REMOTE][:PORT]",
+ description="Register with a flash proxy facilitator using an HTTP POST. "
+ "If only the external port is given, the remote server guesses our "
+ "external address.")
# common opts
parser.add_argument("-4", help="name lookups use only IPv4.",
action="store_const", const=socket.AF_INET, dest="address_family")
diff --git a/flashproxy-reg-url b/flashproxy-reg-url
index fce6d05..e8789d5 100755
--- a/flashproxy-reg-url
+++ b/flashproxy-reg-url
@@ -38,6 +38,7 @@ def get_facilitator_pubkey():
return RSA.load_pub_key_bio(BIO.MemoryBuffer(DEFAULT_FACILITATOR_PUBKEY_PEM))
parser = argparse.ArgumentParser(
+ usage="%(prog)s [OPTIONS] REMOTE[:PORT]",
description="Print a URL, which, when retrieved, will cause the input "
"client address to be registered with the flash proxy facilitator.")
# common opts
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits