[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[or-cvs] when clients do --list-fingerprint, it"s misleading to
Update of /home/or/cvsroot/src/or
In directory moria.mit.edu:/home2/arma/work/onion/cvs/src/or
Modified Files:
main.c
Log Message:
when clients do --list-fingerprint, it's misleading to
give them one, because it will never be the same again
Index: main.c
===================================================================
RCS file: /home/or/cvsroot/src/or/main.c,v
retrieving revision 1.365
retrieving revision 1.366
diff -u -d -r1.365 -r1.366
--- main.c 10 Nov 2004 02:58:27 -0000 1.365
+++ main.c 11 Nov 2004 13:24:10 -0000 1.366
@@ -1040,6 +1040,11 @@
char buf[FINGERPRINT_LEN+1];
crypto_pk_env_t *k;
const char *nickname = get_options()->Nickname;
+ if(!server_mode(get_options())) {
+ printf("Clients don't have long-term identity keys. Exiting.");
+ return;
+ }
+ tor_assert(nickname);
if (init_keys() < 0) {
log_fn(LOG_ERR,"Error initializing keys; exiting");
return;
@@ -1052,7 +1057,7 @@
log_fn(LOG_ERR, "Error computing fingerprint");
return;
}
- printf("%s %s\n", nickname?nickname:"client", buf);
+ printf("%s %s\n", nickname, buf);
}
/** Entry point for password hashing: take the desired password from