CLR: simple password generator

Started by stanl, September 15, 2021, 03:00:36 AM

Previous topic - Next topic

stanl

takes password length and number of non-characters as parameters:
Code (WINBATCH) Select


;simple password generator with CLR
length = 10
nonchars = 3
ObjectClrOption('useany', 'System.Web')
oSecure = ObjectClrNew("System.Web.Security.Membership")
password = oSecure.GeneratePassword(length,nonchars)
Message("Password Created",password)
Exit



JTaylor

Thanks.  Was just looking for something like this the other day.   

Jim

stanl

Quote from: JTaylor on September 15, 2021, 06:20:52 AM
Thanks.  Was just looking for something like this the other day.   

Jim


You are welcome. See that this works well for sending out input passwords based on timer to receive a download.