[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [tor/maint-0.2.2] Rename get_client_identity_key to get_tlsclient_identity_key



commit 2a2301e41117ad8439dbe8039085202fa0d6f6ed
Author: Nick Mathewson <nickm@xxxxxxxxxxxxxx>
Date:   Thu Oct 21 13:53:31 2010 -0400

    Rename get_client_identity_key to get_tlsclient_identity_key
---
 src/or/connection_or.c |    2 +-
 src/or/main.c          |    2 +-
 src/or/or.h            |    2 +-
 src/or/router.c        |   10 +++++-----
 4 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/or/connection_or.c b/src/or/connection_or.c
index 7817db8..95cc02e 100644
--- a/src/or/connection_or.c
+++ b/src/or/connection_or.c
@@ -962,7 +962,7 @@ connection_or_check_valid_tls_handshake(or_connection_t *conn,
     started_here ? conn->_base.address : safe_str(conn->_base.address);
   const char *conn_type = started_here ? "outgoing" : "incoming";
   crypto_pk_env_t *our_identity =
-    started_here ? get_client_identity_key() :
+    started_here ? get_tlsclient_identity_key() :
                    get_server_identity_key();
   int has_cert = 0, has_identity=0;
 
diff --git a/src/or/main.c b/src/or/main.c
index 466801c..ba704f5 100644
--- a/src/or/main.c
+++ b/src/or/main.c
@@ -874,7 +874,7 @@ run_scheduled_events(time_t now)
   if (last_rotated_x509_certificate+MAX_SSL_KEY_LIFETIME_INTERNAL < now) {
     log_info(LD_GENERAL,"Rotating tls context.");
     if (tor_tls_context_init(public_server_mode(options),
-                             get_client_identity_key(),
+                             get_tlsclient_identity_key(),
                              is_server ? get_server_identity_key() : NULL,
                              MAX_SSL_KEY_LIFETIME_ADVERTISED) < 0) {
       log_warn(LD_BUG, "Error reinitializing TLS context");
diff --git a/src/or/or.h b/src/or/or.h
index a594d6f..4105ff4 100644
--- a/src/or/or.h
+++ b/src/or/or.h
@@ -4207,7 +4207,7 @@ crypto_pk_env_t *get_onion_key(void);
 time_t get_onion_key_set_at(void);
 void set_client_identity_key(crypto_pk_env_t *k);
 void set_server_identity_key(crypto_pk_env_t *k);
-crypto_pk_env_t *get_client_identity_key(void);
+crypto_pk_env_t *get_tlsclient_identity_key(void);
 crypto_pk_env_t *get_server_identity_key(void);
 int client_identity_key_is_set(void);
 int server_identity_key_is_set(void);
diff --git a/src/or/router.c b/src/or/router.c
index c53bb8b..f7a50ae 100644
--- a/src/or/router.c
+++ b/src/or/router.c
@@ -148,11 +148,11 @@ set_client_identity_key(crypto_pk_env_t *k)
   client_identitykey = k;
 }
 
-/** Returns the current client identity key; requires that the key has
- * been set.
+/** Returns the current client identity key for use on outgoing TLS
+ * connections; requires that the key has been set.
  */
 crypto_pk_env_t *
-get_client_identity_key(void)
+get_tlsclient_identity_key(void)
 {
   tor_assert(client_identitykey);
   return client_identitykey;
@@ -490,7 +490,7 @@ init_keys(void)
     set_client_identity_key(prkey);
     /* Create a TLS context. */
     if (tor_tls_context_init(0,
-                             get_client_identity_key(),
+                             get_tlsclient_identity_key(),
                              NULL,
                              MAX_SSL_KEY_LIFETIME_ADVERTISED) < 0) {
       log_err(LD_GENERAL,"Error creating TLS context for Tor client.");
@@ -586,7 +586,7 @@ init_keys(void)
 
   /* 3. Initialize link key and TLS context. */
   if (tor_tls_context_init(public_server_mode(options),
-                           get_client_identity_key(),
+                           get_tlsclient_identity_key(),
                            get_server_identity_key(),
                            MAX_SSL_KEY_LIFETIME_ADVERTISED) < 0) {
     log_err(LD_GENERAL,"Error initializing TLS context");



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