But if i change the password to the same password, i can do that without any
"error" message!?!?
How can i archive that the password policy is checked and a message is given
back with a human readable text?
========================================================================================================
string message = "";
string LDAPPath = getDistinguishedName(LogonName);
try
{
DirectoryEntry deUser = new DirectoryEntry("LDAP://" +
Properties.Settings.Default.DomainFull + "/" + LDAPPath, adUser,
adPassword);
deUser.CommitChanges();
deUser.Invoke("SetPassword", Password);
deUser.CommitChanges();
message = "Password updated!";
}
catch (DirectoryServicesCOMException ex)
{
message = "ERROR: + ex.InnerException;
}
if(message.Contains("0x80072035"))
{
message = "INFO: The password doesn't meet the
requirements!";
}
return message;
========================================================================================================
I need a way to check:
- has the password the minimum lenght
- is complex enough
- are not used for the last x passwords (password cache)
???
Thank you for any help
Volkan
--
Richard Mueller
MVP Directory Services
Hilltop Lab - http://www.rlmueller.net
--
"Volkan Senguel" <volkan....@networkpixel.com> wrote in message
news:uWRn%239CJK...@TK2MSFTNGP03.phx.gbl...
"Exception has been thrown by the target of an invocation" @
"System.DirectoryServices"
at the line > deUser.Invoke("ChangePassword", Password);
?
any ideas?
thx
Volkan
"Richard Mueller [MVP]" <rlmuelle...@ameritech.nospam.net> schrieb im
Newsbeitrag news:uGI1RCFJ...@TK2MSFTNGP02.phx.gbl...
http://msdn.microsoft.com/en-us/library/ms180896.aspx
--
Richard Mueller
MVP Directory Services
Hilltop Lab - http://www.rlmueller.net
--
"Volkan Senguel" <volkan....@networkpixel.com> wrote in message
news:%23zwepSI...@TK2MSFTNGP03.phx.gbl...