summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOthmar Gsenger <otti@anytun.org>2008-02-29 20:43:06 +0000
committerOthmar Gsenger <otti@anytun.org>2008-02-29 20:43:06 +0000
commitc80db6b975df70eda79c4e4d07ed5a0cc0d0ec99 (patch)
tree138369dc8c41d4ff4f61eef0fc8832a2465c6233
parentfixed anyctr controller (diff)
added showtable
-rw-r--r--anytun-showtables.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/anytun-showtables.cpp b/anytun-showtables.cpp
index 0a48a12..d9ae096 100644
--- a/anytun-showtables.cpp
+++ b/anytun-showtables.cpp
@@ -54,8 +54,15 @@ void output(ConnectionList &cl)
{
ConnectionMap::iterator it = cl.getBeginUnlocked();
mux_t mux = it->first;
- std::cout << "Connection: " << mux << std::endl;
ConnectionParam &conn( it->second );
+ std::cout << "Client " << mux << ": " ;
+ if( conn.remote_host_=="")
+ {
+ std::cout<< "not registered";
+ } else {
+ std::cout<< conn.remote_host_ << ':'<<conn.remote_port_;
+ }
+ std::cout << std::endl;
//std::cout << "Connection: Keyderivation-Type: " << conn.kd_.printType() << std::endl;
cl.clear();
}