PasswordMaker Forums

Other Editions => Other Editions - Feature Requests / Enhancements => Topic started by: dr4Ke on November 26, 2009, 09:24:59 AM

Title: Command line edition enhancements
Post by: dr4Ke on November 26, 2009, 09:24:59 AM
Hello everybody.
I'm a happy user of the Firefox edition.
passwordmaker is not available for Google Chrome and i'm testing it now.
So, while waiting for a new edition for this software, i decided to try the command line edition (c++).

I've done some little work on the c++ command line edition.
Here are my changes :
leet.cpp :
reading settings :
other changes :

Attached a diff file.

Would you mind take a look at my changes ?

Thank you.
dr4Ke.
Title: Re: Command line edition enhancements
Post by: Miquel 'Fire' Burns on November 26, 2009, 02:12:09 PM
I'll review when I have the chance.
Title: Re: Command line edition enhancements
Post by: Miquel 'Fire' Burns on November 26, 2009, 03:59:19 PM
I reviewed it, and noticed that you messed up the default settings on the help screen.

How will someone know the default values when they view the help? I'll check on that later.
Title: Re: Command line edition enhancements
Post by: dr4Ke on November 26, 2009, 05:46:49 PM
Ouch ! I didn't look much at the help screen.

I'll look at that tomorrow.
Title: Re: Command line edition enhancements
Post by: dr4Ke on November 27, 2009, 07:32:04 AM
I checked on that. The default settings are the same as before :

My version :
$ ./passwordmaker --verbose
Master Password:
Master Password: ********
Using settings file: passwordmaker.rdf
Using Account:
Use l33t: none
l33t level: 0
Hash Algorithm: MD5
Triming trailing zeroes: yes
URL:
Generated Password Length: 8
Username:
Modifier:
Characters: ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789`~!@#$%^&*()_-+={}|[]\:";'<>?,./
Generated Password Prefix:
Generated Password Suffix:
D4a8=qpD

Trunk version :
./passwordmaker --verbose
Master Password:
Master Password: youpi
Use l33t: none
l33t level: 0
Hash Algorithm: MD5
URL:
Generated Password Length: 8
Username:
Modifier:
Characters: ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789`~!@#$%^&*()_-+={}|[]\:";'<>?,./
Generated Password Prefix:
Generated Password Suffix:
D4a8=qpD


The change is about separate reading settings on the command line and in the settings file. It's why I changed default values on the tclap (to see the difference between the default value and a user's option on the command line). The real defaults values (used to process the password) are set when the pwmdefaults object is created and are copied in the settings object by the function getSettings only if there was the corresponding option was not given on the command line.

I hope this will clarify what I changed.

Hope that my english is readable.

Anyway, thanks for checking my changes. I'll be glad to contribute to the project.
dr4Ke.
Title: Re: Command line edition enhancements
Post by: Miquel 'Fire' Burns on November 27, 2009, 06:50:05 PM
Run ./passwordmaker -h as see what I mean by the default settings.
Title: Re: Command line edition enhancements
Post by: dr4Ke on November 30, 2009, 09:19:53 AM
Run ./passwordmaker -h as see what I mean by the default settings.

I did.
I don't see any change between my version and the original version in trunk (except the description string shown at the end of the help screen).