Openwall GNU/*/Linux - a small security-enhanced Linux distro for servers
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Sat, 13 Apr 2013 23:57:03 +0400
From: Alexander Cherepanov <cherepan@...me.ru>
To: john-dev@...ts.openwall.com
Subject: Re: testing all valid()s

Hi!

Just a small patch to fix strncmp in NETLM format.

-- 
Alexander Cherepanov

diff --git a/src/NETLM_fmt_plug.c b/src/NETLM_fmt_plug.c
index 4ae4e44..cee2c37 100644
--- a/src/NETLM_fmt_plug.c
+++ b/src/NETLM_fmt_plug.c
@@ -112,7 +112,7 @@ static int netlm_valid(char *ciphertext, struct fmt_main *self)
 {
   char *pos;
 
-  if (strncmp(ciphertext, "$NETLM$", 5)!=0) return 0;
+  if (strncmp(ciphertext, "$NETLM$", 7)!=0) return 0;
   if (ciphertext[23] != '$') return 0;
 
   if (strncmp(&ciphertext[24 + 2 * SALT_SIZE],

Powered by blists - more mailing lists

Your e-mail address:

Powered by Openwall GNU/*/Linux - Powered by OpenVZ