Skip to content

This module generate and returns a random password that includes numbers, letters and special characters.

License

Notifications You must be signed in to change notification settings

rstolpe/GenerateRandomPassword

Repository files navigation

GitHub
GitHub release (latest SemVer) Last release GitHub last commit
PSGallery downloads

GenerateRandomPassword

This module generates and returns a random password that contains lower and upper letters, numbers and special characters.
It can either generate one with the default options that are 12 characters long and contains 3 special characters,
or you can decide how long the password should be and how many special characters it should contain.
I have added the result from PSScriptAnalyzer in test folder

Links

Help

Below I have specified things that I think will help people with this module.
You can also see the API for each function in the help folder

Install

Install for current user

Install-Module -Name GenerateRandomPassword -Scope CurrentUser -Force

Install for all users

Install-Module -Name GenerateRandomPassword -Scope AllUsers -Force

Example

New-RSRandomPassword

Returns a random password that are 12 characters long and contains 1 special character.

New-RSRandomPassword -Length 20 -SpecialCharacters 4

Returns a random password that are 20 characters long and contains 4 special character.