From 43bd8835f748e1f734db6cff98a0e4fbf5d797de Mon Sep 17 00:00:00 2001
From: "psyc://psyced.org/~lynX" <@>
Date: Tue, 3 Mar 2009 03:17:24 +0100
Subject: [PATCH] show cipher in /tcp
---
CHANGESTODO | 16 ++++++++--------
makefile | 3 ++-
utility/pkggen.c | 2 +-
world/net/person.c | 5 ++++-
world/net/sockets.c | 31 ++++++++++++++++++++++++-------
5 files changed, 39 insertions(+), 18 deletions(-)
diff --git a/CHANGESTODO b/CHANGESTODO
index cc28bae..4d6e74e 100644
--- a/CHANGESTODO
+++ b/CHANGESTODO
@@ -6,14 +6,6 @@ Essentially: whenever you fix something, move that line to the end of file.
________________________________________________________________________
== currently being inspected ===========================================
¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
-+ should ignored people receive an echo for the sake of not being
- distinguishable from not ignored people? yes...
-
-? marenz says, remote topic isn't working
- http://about.psyc.eu/?title=Talk:Bug_Report&curid=1506&diff=10174&oldid=10173
-
-+ show chiffre in /tcp
-
- remote IRC place does not send names listing on /join
- remote IRC /part shows no reaction at first attempt
+++ not limited to IRC!! thx marenz
@@ -26,6 +18,8 @@ ________________________________________________________________________
- IRC shows "*** k kindly asks for your friendship." for remote
friendship requests. eh! where's the uniform!?
+- remote /topic shows wrong nick (abolish _nick and this problem disappears)
+
- /m freenode:symlynx hey
Sorry, _message_private is not supported by the IRC gateway.
huh? wasn't that once the point to make them? debug...
@@ -634,6 +628,9 @@ or switches in our muve code, because they will never be needed!
Circuit got _request_execute to psyc://psyced.org/~White Spaced Username from psyc://10.20.30.40:-54925/: QUIT
== PSYC 1.0 beta =======================================================
+- should ignored people receive an echo for the sake of not being
+ distinguishable from not ignored people? yes... but is a nasty change to do
+
TYPE CHECKING AT PARSING TIME
- unless trustworthy > 4 all incoming vars should be checked for legal
content, like chars in actions etc.. or maybe switch over the varnames
@@ -3909,3 +3906,6 @@ jabber/server
- fixed various iq errors as elmex noted:
pkggen
+ ported from cvs to git
+sockets
++ show encryption protocol and cipher in /tcp
+
diff --git a/makefile b/makefile
index d3f897a..2cba28d 100644
--- a/makefile
+++ b/makefile
@@ -1,5 +1,6 @@
# how do i check if $ENV{PAGER} is already set?
-PAGER=more
+# like this, says ketmar. probably gmake only.
+PAGER ?= more
##############################################################################
## INSTALLATION
diff --git a/utility/pkggen.c b/utility/pkggen.c
index 9d815e6..7f3f517 100644
--- a/utility/pkggen.c
+++ b/utility/pkggen.c
@@ -121,7 +121,7 @@ int main(int argc, char **argv) {
return 1;
}
- puts(">> Now is your chance to inspect a 'git diff master..origin/master'. Suspend now.");
+ puts(">> Suspend to inspect a '(cd data;git diff master..origin/master)'.");
sleep(4);
puts(">> Doing a git merge");
diff --git a/world/net/person.c b/world/net/person.c
index 1458729..2f18ed0 100644
--- a/world/net/person.c
+++ b/world/net/person.c
@@ -43,6 +43,10 @@
#include
#include
+#if __EFUN_DEFINED__(tls_query_connection_info)
+# include
+#endif
+
inherit NET_PATH "group/master";
inherit NET_PATH "lastlog";
@@ -319,7 +323,6 @@ qDescription(source, vars, profile, itsme) {
dv["_agent_design"] = v("layout");
}
#if __EFUN_DEFINED__(tls_query_connection_info)
-# include
if (interactive(ME) && tls_query_connection_state(ME)) {
array(mixed) tls = tls_query_connection_info(ME);
diff --git a/world/net/sockets.c b/world/net/sockets.c
index 6b34d47..74cf3b0 100644
--- a/world/net/sockets.c
+++ b/world/net/sockets.c
@@ -11,6 +11,10 @@
#include
#include
+#if __EFUN_DEFINED__(tls_query_connection_info)
+# include
+#endif
+
//#define NO_INHERIT // virtual ain't workin' .. but leavin it out neither
#include
@@ -20,6 +24,7 @@ static int smaller_object_name(object a, object b) {
list_sockets(guy, flags) {
array(object) u;
+ array(mixed) tls;
mapping uv;
string list, name, host, ip, idle, email, scheme, agent, layout;
int i, skip = 0;
@@ -48,7 +53,7 @@ list_sockets(guy, flags) {
host = uv["forwarded"];
unless (host) host = uv["host"];
ip = uv["ip"];
-#ifdef _flag_log_hosts
+#if 1 //def _flag_log_hosts // realtime inspection isn't logging
unless (host) host = query_ip_name(o);
unless(ip) ip = query_ip_number(o);
#endif
@@ -58,7 +63,6 @@ list_sockets(guy, flags) {
else if (idle = uv["idleTime"]) idle = timedelta(idle);
if (boss(o)) name += "*";
if (uv["visibility"] == "off") name = "°"+name;
-
list += sprintf(T("_list_user_technical_person",
"\n%4.4s%s %s %s %s (%s) <%s> %s"),
// scheme ? (layout && scheme=="ht" ?
@@ -82,9 +86,12 @@ list_sockets(guy, flags) {
}
else {
name = o->qName();
+#if __EFUN_DEFINED__(tls_query_connection_info)
+ tls = interactive(o) && tls_query_connection_info(o);
+#endif
if (name? flags & SOCKET_LIST_GHOST : flags & SOCKET_LIST_LINK)
list += sprintf(T("_list_user_technical_ghost",
- "\n%s %s %O %s (%s)"),
+ "\n%s %s %O %s (%s) %s %s"),
#if __EFUN_DEFINED__(tls_query_connection_state)
interactive(o) &&
tls_query_connection_state(o) ? "!" : " ",
@@ -93,13 +100,23 @@ list_sockets(guy, flags) {
#endif
(name && to_string(name)) || "",
o,
-#ifdef _flag_log_hosts
+#if 1 //def _flag_log_hosts // realtime inspection isn't logging
query_ip_name(o) || "",
- query_ip_number(o) || ""
+ query_ip_number(o) || "",
#else
- "", ""
+ "", "",
#endif
- );
+#if __EFUN_DEFINED__(tls_query_connection_info)
+ tls ? intp(tls[TLS_PROT]) ?
+ TLS_PROT_NAME(tls[TLS_PROT]) :
+ tls[TLS_PROT] : "",
+ tls ? intp(tls[TLS_CIPHER]) ?
+ TLS_CIPHER_NAME(tls[TLS_CIPHER]) :
+ tls[TLS_CIPHER] : ""
+#else
+ "", ""
+#endif
+ );
else skip++;
}
}