Openwall GNU/*/Linux - a small security-enhanced Linux distro for servers
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date: Wed, 15 Feb 2012 10:16:25 -0600
From: "jfoug" <jfoug@....net>
To: <john-dev@...ts.openwall.com>
Subject: Was:  RE: [john-users] sha1 + hex salt

I have made changes to the dynamic format.  The const values were 100% using
memcpy type stuff, and a length value along with them. However, when loading
a format, it used 

curdat.Consts[curdat.nConsts] = (unsigned
char*)str_alloc_copy(Setup->pConstants[curdat.nConsts].Const);
curdat.ConstsLen[curdat.nConsts] =
strlen(Setup->pConstants[curdat.nConsts].Const);

The str_alloc_copy, and the strlen, kind of blew the keeping of the
length's, and using memcpy's, lol.

I will get a patch out after I get a little more testing done.  Things are
working, but I want to make sure test suite still is happy with these
changes.


Now, both of these formats work exactly the same (for an 8 byte password,
with 8 bytes 'null' padding).  I still believe that the 'proper' format this
user requested is the 2201, which uses a 16 byte null padded buffer.

Jim.

######################################################################
#
######################################################################
[List.Generic:dynamic_2200]
Expression=SHA1($p.$c1) [8-byte null const appended SHA1]
Flag=MGF_SHA1_40_BYTE_FINISH
Func=DynamicFunc__clean_input
Func=DynamicFunc__append_keys
Func=DynamicFunc__append_input1_from_CONST1
Func=DynamicFunc__SHA1_crypt_input1_to_output1_FINAL
Test=$dynamic_2200$20c59472b34ec4b9678b7149d519a2338bc31ba9:92086390
CONST1=\x00\x00\x00\x00\x00\x00\x00\x00


######################################################################
#
######################################################################
[List.Generic:dynamic_2201]
Expression=SHA1($p) [16-byte null padded SHA1]
Flag=MGF_SHA1_40_BYTE_FINISH
Func=DynamicFunc__clean_input
Func=DynamicFunc__append_keys
Func=DynamicFunc__set_input_len_16
Func=DynamicFunc__SHA1_crypt_input1_to_output1_FINAL
Test=$dynamic_2201$20c59472b34ec4b9678b7149d519a2338bc31ba9:92086390

Powered by blists - more mailing lists

Your e-mail address:

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