1
Vote

Incorrect support QuestionAndAnswer

description

During creation first user with setting of membership provider as requiresQuestionAndAnswer="false" ArgumentNullException occured.

Looks like we try to encrypt Answer on secret question any way, without checking setting in provider.

[!] Also, after small investigation i found that on UserCreation Question is saving without encription, But on Change Question and Answer question is ecripting. Looks like some inconsistency there. (please see 'ChangePasswordQuestionAndAnswer method').


StackTrace below:

[ArgumentNullException: String reference not set to an instance of a String.
Parameter name: s]
System.Text.Encoding.GetBytes(String s) +7505549
NHibernateProvider.NHibernateMembershipProvider.EncodePassword(String password) +112
NHibernateProvider.NHibernateMembershipProvider.CreateUser(String username, String password, String email, String passwordQuestion, String passwordAnswer, Boolean isApproved, Object providerUserKey, MembershipCreateStatus& status) +403
System.Web.Security.Membership.CreateUser(String username, String password, String email, String passwordQuestion, String passwordAnswer, Boolean isApproved, Object providerUserKey, MembershipCreateStatus& status) +224
System.Web.Security.Membership.CreateUser(String username, String password, String email, String passwordQuestion, String passwordAnswer, Boolean isApproved, MembershipCreateStatus& status) +28

comments