Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <6ecc1619cf374b3c02d31db9021f4147@smtp.hushmail.com>
Date: Tue, 15 Jan 2013 22:40:34 +0100
From: magnum <john.magnum@...hmail.com>
To: john-dev@...ts.openwall.com
Subject: Re: --list=<conf section name> (was: --list= handling moved out of john.c)

On 15 Jan, 2013, at 22:27 , Frank Dittrich <frank_dittrich@...mail.com> wrote:
> On 01/15/2013 09:18 PM, magnum wrote:
>> On 15 Jan, 2013, at 20:56 , magnum <john.magnum@...hmail.com> wrote:
>> $ ../run/john --list=options  
>> Subsections of [options]:
>> opencl
>> mpi
>> 
>> $ ../run/john --list=options:opencl
>> Section [options:opencl] not found.
>> help[:WHAT], subformats, inc-modes, rules, externals, ext-filters,
>> ext-filters-only, ext-modes, build-info, hidden-options, encodings,
>> formats, format-details, format-all-details, format-methods[:WHICH],
>> sections, parameters:SECTION, list-data:SECTION,
>> <conf section name>
>> 
>> The latter is a bug, no? Or how was this supposed to work?
> 
> IMHO, it is just a confusing error message.
> --list=<conf section name> should list the subsections of that section.
> There are no Subsections which could be listed for [Options:OpenCL]
> 
> A real inconsistency is:
> 
> $ ./john --list=parameters:
> incremental:all      incremental:all7     incremental:alpha
> incremental:lanman   options:mpi
> incremental:all15    incremental:all8     incremental:digits
> markov:default       userclasses
> incremental:all6     incremental:alnum    incremental:digits8  options
> 
> or
> 
> $ ./john --list=parameters:options
> options      options:mpi
> 
> options:opencl is not listed as a possible completion, because
> [Options:OpenCL] is empty (doesn't contain any parameter definitions).
> 
> That's why I think fixing the error message text for the
> [Options:MPI] section might be easy. For [Options:OpenCL] it will be a
> little bit harder (but not impossible).
> 
> How important is a fix here?

Not important. I was just afraid something was b0rken that worked before.

> Would another message, e.g., "[options:mpi] doesn't have subsections" be OK?

Fine. I guess we should have things like Johnny first in mind. How would it handle the current error? Is the error written to stderr but other things to stdout?

> Can we have sections like [Section:Sub:SubSub] at all?

I don't think so.

> Another bug might be this one:
> (unstable-jumbo)run $ ./john --list=parameters:options:mpi
> mpiompverbose = Y
> mpiompmutex = Y
> (unstable-jumbo)run $ echo $?
> 0
> (unstable-jumbo)run $ ./john --list=parameters:options:opencl
> (unstable-jumbo)run $ echo $?
> 0
> 
> May be $? should be != 0 here.
> Or may be it should be 0 here, because [Options:OpenCL] exists, but it
> should be != 0 here (section doesn't exist):
> (unstable-jumbo)run $ ./john --list=parameters:options:none
> (unstable-jumbo)run $ echo $?
> 0
> or here (Section contains list data):
> (unstable-jumbo)run $ ./john --list=parameters:list.rules:single
> (unstable-jumbo)run $ echo $?
> 0

Ah yes, this is relevant for things like Johnny. I'm not sure how a developer of things using this "interface" would want it, but I assume some of those cases should return non-zero.

magnum

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.