I need to programmatically create a user, and the target domain schema (local user acct on a computer that is part of a domain with pass policy) may have complex password rules, or there may be no domain. Is there a way for ADSI to generate a password that meets the password requirements? Or is there a way to create the user with no password?
ADSI does not have a built in password generation function, but it should be simple enough to write yourself. You just need to know what the minimum length is and if complexity is enabled. If complexity is enabled, you need to include upper and lower case letters, numbers and some punctuation. You can create users without passwords in the disabled state, but you need to give them a password before you enable them if password complexity and mininum length settings are in place. Joe K. "ep" <reply@newgroup.only.please> wrote in message news:%23mwShd3lFHA.4056@TK2MSFTNGP10.phx.gbl... >I need to programmatically create a user, and the target domain schema > (local user acct on a computer that is part of a domain with pass policy) > may have complex password rules, or there may be no domain. > > Is there a way for ADSI to generate a password that meets the password > requirements? Or is there a way to create the user with no password? > >