I need to update active directory properties(attributes) through console application like Title,mail,sn,passwordQuestion,passwordAnswer.
DirectoryEntry.Properties["passwordQuestion"].Value = "What is your Favorite Color?";
DirectoryEntry.Properties["passwordAnswer"].Value = "green";
after updating , i check the attributes in Active Directory. All its fine.
the "password answer" saved as plan text.
After logged into asp.net portal with user's credential, it is working fine. After logout, When i goto click forgot password link, it ask the email address after that display the security password question and need to be enter the security password answer.
when i enter the security password answer in the text box , after click submit, it throw the error.
Invalid length for a Base-64 char array. Exception Stack Trace: at System.Convert.FromBase64String(String s) at System.Web.Security.ActiveDirectoryMembershipProvider.Decrypt(String encryptedString) at System.Web.Security.ActiveDirectoryMembershipProvider.ResetPassword(String
username, String passwordAnswer) at System.Web.Security.MembershipUser.ResetPassword(String passwordAnswer) at
But i update the passwordQuestion,passwordAnswer through web application(portal)
View Complete Post