Bug #64341 | MySQLMembershipProvider not correctly handle minRequiredPasswordLength | ||
---|---|---|---|
Submitted: | 15 Feb 2012 14:58 | Modified: | 14 May 2012 17:14 |
Reporter: | timz ttii | Email Updates: | |
Status: | Not a Bug | Impact on me: | |
Category: | Connector / NET | Severity: | S2 (Serious) |
Version: | 6.4.4 | OS: | Windows ( x32) |
Assigned to: | Roberto Ezequiel Garcia Ballesteros | CPU Architecture: | Any |
[15 Feb 2012 14:58]
timz ttii
[15 Feb 2012 21:55]
Roberto Ezequiel Garcia Ballesteros
Hi Timz! I reviewed your post and I think you need to update your MVC3 application in order to Membership provider work as you expected. If you change the minRequiredPasswordLength attribute in Web.config as you did, you should change the default minimum length value for Password in the MVC3 application too. You can change this value in AccountModels.cs / RegisterModel class / Password property / StringLength attribute / MinimumLength = 3 Please try this change and let me know if it works for you.
[16 Feb 2012 4:31]
timz ttii
Check the password is in a class of Membership. I had to write my MembershipProvider to get it working. Thank you!
[16 Feb 2012 18:52]
Roberto Ezequiel Garcia Ballesteros
After doing a last test, I noticed that the application is taking the default provider (AspNetSqlMembershipProvider) and its attributes. This provider is defined in machine.config file. To solve this situation you can: 1) Add <clear/> after <providers> tag and before any add provider 2) Set default provider Your configuration should be: <membership defaultProvider="MySQLMembershipProvider"> <providers> <clear/> <add name="MySQLMembershipProvider" ... I know you have your own provider, but it could be useful next time you wanted to use the MySqlMembership provider. Regards.
[17 Feb 2012 1:28]
timz ttii
Excellent! Thank you!