Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Wed, 6 Jul 2011 07:22:02 +0400
From: Solar Designer <solar@...nwall.com>
To: john-dev@...ts.openwall.com
Subject: Re: prepare() vs. split()

On Tue, Jul 05, 2011 at 10:17:54PM -0500, JFoug wrote:
> Doesn't split always get call later than valid?   If so, you can not adjust 
> the data item, like you can within prepare.  With prepare, you can adjust 
> the data content sent TO the valid function.  Thus, it allows for allowing 
> legacy type formats to still 'work', or an easy way for things like raw 
> hashes to work, without having to make complex code in valid, or in the 
> get_binary, or other 'conversion' functions.
> 
> Can that be done in split?   I did not think so, but I have not used it too 
> much.

You have a valid point about valid().

With split() making changes, you need to have valid() accept pre-split
and post-split inputs.  With prepare() making changes, you don't have to
touch valid().

In this case, though, don't we actually want valid() to accept either
syntax?  That's how things were done e.g. for LM accepting both full
hashes with no tags and half-hashes with $LM$ tags.

Alexander

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.