From f9b8f4261cf10a6903a211fea28917036cac8c2c Mon Sep 17 00:00:00 2001 From: "psyc://psyced.org/~lynX" <@> Date: Tue, 26 Jul 2011 07:58:06 +0200 Subject: [PATCH] + --- world/net/person.c | 5 ++++- world/net/psyc/parse.i | 4 ++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/world/net/person.c b/world/net/person.c index e5a1ca7..cfb2502 100644 --- a/world/net/person.c +++ b/world/net/person.c @@ -768,12 +768,15 @@ case "sha1": try, sha1(salt + v("password")))); rc = try == sha1(salt + v("password")); ARETURN(rc) +# ifdef TLS_HASH_SHA1 case "HMAC-SHA1": case "hmac-sha1": ARETURN(try == hmac(TLS_HASH_SHA1, v("password"), salt)) -#ifdef AUTH_HMAC_SECRET +# ifdef AUTH_HMAC_SECRET case "hmac-sha1-shared": ARETURN(try == hmac(TLS_HASH_SHA1, AUTH_HMAC_SECRET, salt + MYNICK)) +# endif +# endif #else # echo Driver is missing SHA1 support (needed for jabber) #endif diff --git a/world/net/psyc/parse.i b/world/net/psyc/parse.i index 29db96a..94c7dd3 100644 --- a/world/net/psyc/parse.i +++ b/world/net/psyc/parse.i @@ -981,8 +981,8 @@ protected int deliver(mixed ip, string host, string mc, string buffer, mapping c cvars["_INTERNAL_nick_target"] = u[UNick]; #endif P3(("DEBUG: is_localhost is %O for %O of %O\n", - is_localhost(u[UHost])), u[UHost], u) - unless (is_localhost((u[UHost])) { + is_localhost(u[UHost]), u[UHost], u)) + unless (is_localhost(u[UHost])) { if (trustworthy > 7) { P1(("RELAYING permitted for %O to %O (%O)\n", source, t, ME))