Ideas for generating random password strings?

Does anyone have ideas/input to auto-generate random password strings with upper- and lower-case letters, numbers and special characters (8-10 characters in total)?

I know it’s possible to do something along those lines by combining different functions, but it seems a bit involved - and less intuitive - compared to the 4 lines of python code I normally use for this.

I know it’s possible to call a python script (or another program) and capture the output, but I am trying to “stay clean” as much as possible in this implementation.

Thank you in advance.

Hello Jan,

Here is a small EasyMorph project that generates a random alphanumeric string of a specified length. It uses a PowerShell script to generate a string. That script can be easily modified to include special characters to the generated strings.

GenerateRandomString.morph (3.1 KB)

Also, you can try to use the following expressions to generate random strings:

1 Like

Here is another approach, without PowerShell scripting. Generates random strings of any length with any character set.

generate-password.morph (2.4 KB)

@andrew.rybka @dgudkov
Thank you both for taking the time to look into this. I will check out both approaches.

@dgudkov these “challenges” appears to be like EasyMorp-sudoku for you :slight_smile:

I'm curious to find cases that cannot be handled in EasyMorph. I have to admit, this can be addictive sometimes :slight_smile:


Hi @dgudkov

Is it possible to generate a random string of only alphanumeric ASCII characters? The string with any symbols.


It’s sure possible! Here is the updated project. Tick checkboxes to select only the character groups you need:

  • Latin letters
  • Digits
  • Special characters

generate-password.morph (8.3 KB)

Thank you @dgudkov. I guess I have to iterate on the table to get values for each row.

The module returns a randomized string. You can iterate the module multiple times if multiple random strings are needed.