2.0

2.0 | 1 rating Rate this file 6 Downloads (last 30 days) File Size: 1.71 KB File ID: #37005

PassWord Generatro

by

 

PassWord Generator for MatLab

| Watch this File

File Information
Description

This code generates passwords of length n with specified
 number of digits, lowercase letters and upper case letters. It also uses
famous Knuth algorithm for shuffling

MATLAB release MATLAB 7.6 (R2008a)
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (2)
05 Jun 2012 Alex Dytso

I agree with all of your statements especially the one about entropy. I will submit version 2 shortly. Thank you

05 Jun 2012 Jan Simon

The length of the password and the number of digits, upper and lowercase letters must be specified. Special characters as !"ยง$%&/()=?*+~#-:;,.-<>|'@^ and space are not possible. This is not a typical strategy to create a password, because this reduces the entropy substantially. A simpler and more efficient approach to get a random password of n characters:
v = char([33:95, 97:27]);
p = v(ceil(rand(1,n)*length(v)));
But it is impossible to remember such passwords and it is very likely that you find them written down under the keyboard.
I prefer passwords like "65eels!NoHeels" or "I sit right beside the 5TH prime".
However, the function works, has a very lean help text, but no H1 line (see LOOKFOR). It would be more efficient to use 'ABC...' instead of ['A', 'B', 'C', ...] and to shuffle the characters of the string instead of creating an index vector at first, shuffle the index and apply it to the string finally.
The unnecessary weakness of the password is the main reason for my low voting.

Contact us