• Welcome to TechPowerUp Forums, Guest! Please check out our forum guidelines for info related to our community.

Random Password Generator

FordGT90Concept

"I go fast!1!11!1!"
Joined
Oct 13, 2008
Messages
26,263 (4.34/day)
Location
IA, USA
System Name BY-2021
Processor AMD Ryzen 7 5800X (65w eco profile)
Motherboard MSI B550 Gaming Plus
Cooling Scythe Mugen (rev 5)
Memory 2 x Kingston HyperX DDR4-3200 32 GiB
Video Card(s) AMD Radeon RX 7900 XT
Storage Samsung 980 Pro, Seagate Exos X20 TB 7200 RPM
Display(s) Nixeus NX-EDG274K (3840x2160@144 DP) + Samsung SyncMaster 906BW (1440x900@60 HDMI-DVI)
Case Coolermaster HAF 932 w/ USB 3.0 5.25" bay + USB 3.2 (A+C) 3.5" bay
Audio Device(s) Realtek ALC1150, Micca OriGen+
Power Supply Enermax Platimax 850w
Mouse Nixeus REVEL-X
Keyboard Tesoro Excalibur
Software Windows 10 Home 64-bit
Benchmark Scores Faster than the tortoise; slower than the hare.
Check/uncheck a series of rules, modify attributes if desired, and click "Generate" to create a random password. It stores nothing on your computer for the sake of security.

Note: It has very little cross-rule checks in order to allow maximum flexibility. If the application is hitting max attempts, try adjusting rules to give it a better chance of success. For example, when "no duplicates is checked," make sure the minimum length is relatively low (there's only 94 characters by default).

Requires .NET Framework 4.8.

image.png


Icon meanings:
-Arrows pointing in cardinal directions: A random seed to use (default: R)
-#: Minimum number of passwords to produce (default: 1)
-Arrow pointing right: Minimum character limit (default: 8).
-Arrow pointing left: Maximum character limit (default: 32).
-Loop with arrow up: Minimum number of password attempts (default: R). The higher this number, the higher the randomness. Enter "R" without quotes to randomize it.
-Loop with arrow down: Maximum number of password attempts (default: 1000000). Enter "R" without quotes to randomize it (not recommended because odds are it will often take a very long time to complete).
-Plus: Adds characters to the randomization.
-X: Restricts passwords (forces another attempt).
-Pencil: The value is editable.

Version History:
-1.1.5: Updated to .NET Framework 4.8 and fixed a crash on multi-core processors where a racing condition could cause it to crash.
-1.1.4: Added option to set threads. M is the default which uses the processor count.
-1.1.3: Minimum number of attempts changed to R (random) and made the random seed editable.
-1.1.2: Lots of major and minor bugs fixed.
-1.1.1: Changed the "number of passwords to generate" icon and added a filter to the save dialog.
-1.1.0: Added Copy button to copy to clipboard; Save to save all results to a text file (one per line), changed textbox to combo box to show all results (regardless if more than one was intended or not), added another progress bar to show how many passwords were generated/requested, added "R" option to Min Attempts and Max Attempts which randomize the value, and added Min Attempts to increase overall randomness.
-1.0.4: Added "Exclude the following names, previous password, etc. (comma delimited)" rule.
-1.0.3: Removed the grave accent (`) from the list of default special characters. A lot of devices don't have the grave accent as a key to use when inputting a password.
-1.0.2: Removed some obsolete code.
-1.0.1: Added "starts with", "ends with", and "hex only" rules. Random generator more robust.
-1.0.0: Original release.

Uses modified:
-Jesper Borgstrup's Editable TextBlock in WPF for In-place Editing
 

Attachments

Last edited:
Thanks.

If anyone has new rule ideas, let me hear them. I designed to be as easy as possible to add more.
 
Would anyone be interested in this on Windows Phone 7?
 
could you make a random name graber. for instance i enter names of people and click button and it picks a winner? that would be useful for giveaways on tpu
 
One thing you may want to consider (which I put in Key-Z's password generator), is a "must start with" and "must end with" selection as some sites require passwords to start with a letter or number, or end with a special character. etc.
There could also be restrictions on which special characters are allowed, so I added a TextBox that allowed the user to limit which special characters the generator would use.
I also added "hex only" characters for WEP passwords.

I like your addition of adding the minimum number of a type of character. :toasT:
 
could you make a random name graber. for instance i enter names of people and click button and it picks a winner? that would be useful for giveaways on tpu
That's easy and I can do one better. Put one name (or any value) per line in a text file, drop the text file on a console program, and it will tell you a name it randomly selected.

Edit: Scratch that, I'm doing even better: a WPF application that will include a text editor as well.


One thing you may want to consider (which I put in Key-Z's password generator), is a "must start with" and "must end with" selection as some sites require passwords to start with a letter or number, or end with a special character. etc.
There could also be restrictions on which special characters are allowed, so I added a TextBox that allowed the user to limit which special characters the generator would use.
I also added "hex only" characters for WEP passwords.

I like your addition of adding the minimum number of a type of character. :toasT:
The start and end will add a lot of rules (8 total) but I can definitely do that.

One can narrow the list of special characters by simply click on the special characters rule and removing those they don't want or adding those they do want.

Well, "hex only" would be best achieved by unchecking a-z and special characters then deleting G-Z on the capitals line. Because I can, I think I will add it. It make take a lot of attempts to come up a password that is "hex only" though.
 
Last edited:
Very nice I just tried it about 100 times seemed to work with no problems. I tried different settings.

Now it would be cool if you could make the program so you can set a password for it and you can have an option to save the password and give it a Title like this

Title: TPU Forum
Pass: M>$9WC3Z!c/`Ft

560.jpg
 
I decide when I first started making it that it will not store anything on the computer (everything it does occurs in the volatile RAM) for security reasons. If I decide to turn it into a complete password locker in the future, I would do that.
 
Is there a way to edit the minimum and maximum characters?

Edit: NVM, for some reason double clicking on the text wasn't working at first. I closed the app and re-openned it and all is working now.
 
I decide when I first started making it that it will not store anything on the computer (everything it does occurs in the volatile RAM) for security reasons. If I decide to turn it into a complete password locker in the future, I would do that.

Could always make 2 versions:D But don't worry I still use a Excel file that is password protected for my stuff.
 
That's easy and I can do one better. Put one name (or any value) per line in a text file, drop the text file on a console program, and it will tell you a name it randomly selected.

Edit: Scratch that, I'm doing even better: a WPF application that will include a text editor as well.

I think we might need to have coding contests, Ford.
We both write the same utility, let the members vote on the one they like best, and the loser has to buy the winner a Steam game. :laugh:

BTW, nice job getting all the WPF stuff working well. I know what a PITA it can be. lol
 
You have no idea on the EditableTextBlock. I spent probably a whole 8 hours trying to get that damn thing working (went on a wild goose chase too). The application, in its present form, simply wouldn't work without it so I really needed it.
 
I can feel your pain. lol
Remember the fun with the MultiProgessBar ? Sheesh.

WPF is crazy powerful, I just don't know if I will ever really quite enjoy coding in XAML.
 
Nice! It wouldn't be a bad idea to add an option for the user to enable something like a password bank to store all the passwords that they create. You could also encrypt that file. :toast:

EDIT: I would create a button to send which password to the bank that I used.
 
Last edited:
Nice! It wouldn't be a bad idea to add an option for the user to enable something like a password bank to store all the passwords that they create. You could also encrypt that file. :toast:

EDIT: I would create a button to send which password to the bank that I used.
The key to encrypt/decrypt the file is the weakest link and the only way to overcome that vulnerability is to require a one-way password to access the bank. "One-way" means backup method required which also requires its own set of security. Like I said in a previous post, the idea doesn't interest me (largely because of security concerns). The way it is now allows you to store them however you prefer (text file, spreadsheet, third party password vault, etc.).

If I am in dire need of a new project, I would consider making another application that wraps around this one ("create new password" or "change existing password" would present what you see here). Don't get your hopes up. :p


I can feel your pain. lol
Remember the fun with the MultiProgessBar ? Sheesh.

WPF is crazy powerful, I just don't know if I will ever really quite enjoy coding in XAML.
We gave up on that, didn't we? Hey, it works in Windows Forms! :p


could you make a random name graber. for instance i enter names of people and click button and it picks a winner? that would be useful for giveaways on tpu
Done: http://www.techpowerup.com/forums/showthread.php?t=164848
 
Last edited:
1.0.1 uploaded with Kreij's rules added. I highly recommend you disable special characters when enabling "hex only" otherwise the odds are substantially lower it will find one. Also, it should go without saying that if you enable more than one "starts with" or "ends with" rule, you'll hit max attempts without exception because you've created an impossibility. :p
 
1.0.3 uploaded. I removed the grave accent because a lot of devices (e.g. Wii, Windows Phone 7, etc.) either don't have the grave accent available or they bury it in a lot of menus.
 
1.0.4 uploaded. I added a new rule for not allowing passwords to contain something like a previous password, social security number, etc. It is comma delimited so you do something like so:
name,000-000-0000,something,somethingelse,etc.
 
1.1.0 uploaded. Changes are extensive:
-added Copy button to copy to clipboard
-added Save button to save all results to a text file (one per line)
-changed textbox to combo box to show all results (regardless if more than one was intended or not)
-added another progress bar to show how many passwords were generated/requested
-added Min Attempts to increase overall randomness
-added "R" option to Min Attempts and Max Attempts which randomize the value
 
Last edited:
1.1.1 uploaded.
-Changed the "number of passwords to generate" icon.
-Added a filter to the save dialog (didn't have any previously, my mistake).
 
1.1.2 uploaded. Strongly recommended to upgrade to this one.
-The random number generator would burn out after about 100,000 iterations and only return 0 meaning all results after that point are worthless (they're the same). I got that fixed.
-The requires # of each type rules had a logical flaw where it would return true, instead of false, when the associated list to chars was disabled (making it impossible to be true). It now behaves as it should.
-The progress bar percent was stuck at 0%. That has been fixed.
-The program now aborts all threads when closed (e.g. you start to generate and close the program; it will now close instead of hang).
-It wasn't resetting the number of attempts when moving on to a new password. It now does.
-It now clears the execution time when clicking generate. It will display again when it finishes.
-The button returns to "generate" instead of being stuck on "stop" when max attempts have been reached.

Again, if you use RPG, I highly recommend updating.
 
Brilliant piece of software! :toast:
 
Back
Top