diff options
author | Guillaume <guillaumelacasa@hotmail.com> | 2013-06-12 22:12:40 +0200 |
---|---|---|
committer | Guillaume <guillaumelacasa@hotmail.com> | 2013-06-12 22:12:40 +0200 |
commit | b06c0faaf8881f9447f3fd682feffcf3ddae1990 (patch) | |
tree | 5e1b02b441e672171d2438e09880484131991a2f /TwoStepsAuthenticator.TestWebsite/Users/CustomMembership.cs | |
parent | 9cfb653f0b1ddcdc221a3abcb9e16769e0ab1d71 (diff) | |
download | TwoStepsAuthenticator-b06c0faaf8881f9447f3fd682feffcf3ddae1990.zip TwoStepsAuthenticator-b06c0faaf8881f9447f3fd682feffcf3ddae1990.tar.gz TwoStepsAuthenticator-b06c0faaf8881f9447f3fd682feffcf3ddae1990.tar.bz2 |
Test site ok
Diffstat (limited to 'TwoStepsAuthenticator.TestWebsite/Users/CustomMembership.cs')
-rw-r--r-- | TwoStepsAuthenticator.TestWebsite/Users/CustomMembership.cs | 157 |
1 files changed, 157 insertions, 0 deletions
diff --git a/TwoStepsAuthenticator.TestWebsite/Users/CustomMembership.cs b/TwoStepsAuthenticator.TestWebsite/Users/CustomMembership.cs new file mode 100644 index 0000000..4c2cc59 --- /dev/null +++ b/TwoStepsAuthenticator.TestWebsite/Users/CustomMembership.cs @@ -0,0 +1,157 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Web; +using System.Web.Security; + +namespace TwoStepsAuthenticator.TestWebsite.Users +{ + public class CustomMembership : MembershipProvider + { + public override string ApplicationName + { + get + { + throw new NotImplementedException(); + } + set + { + throw new NotImplementedException(); + } + } + + public override bool ChangePassword(string username, string oldPassword, string newPassword) + { + throw new NotImplementedException(); + } + + public override bool ChangePasswordQuestionAndAnswer(string username, string password, string newPasswordQuestion, string newPasswordAnswer) + { + throw new NotImplementedException(); + } + + public override MembershipUser CreateUser(string username, string password, string email, string passwordQuestion, string passwordAnswer, bool isApproved, object providerUserKey, out MembershipCreateStatus status) + { + throw new NotImplementedException(); + } + + public override bool DeleteUser(string username, bool deleteAllRelatedData) + { + throw new NotImplementedException(); + } + + public override bool EnablePasswordReset + { + get { throw new NotImplementedException(); } + } + + public override bool EnablePasswordRetrieval + { + get { throw new NotImplementedException(); } + } + + public override MembershipUserCollection FindUsersByEmail(string emailToMatch, int pageIndex, int pageSize, out int totalRecords) + { + throw new NotImplementedException(); + } + + public override MembershipUserCollection FindUsersByName(string usernameToMatch, int pageIndex, int pageSize, out int totalRecords) + { + throw new NotImplementedException(); + } + + public override MembershipUserCollection GetAllUsers(int pageIndex, int pageSize, out int totalRecords) + { + throw new NotImplementedException(); + } + + public override int GetNumberOfUsersOnline() + { + throw new NotImplementedException(); + } + + public override string GetPassword(string username, string answer) + { + throw new NotImplementedException(); + } + + public override MembershipUser GetUser(string username, bool userIsOnline) + { + throw new NotImplementedException(); + } + + public override MembershipUser GetUser(object providerUserKey, bool userIsOnline) + { + throw new NotImplementedException(); + } + + public override string GetUserNameByEmail(string email) + { + throw new NotImplementedException(); + } + + public override int MaxInvalidPasswordAttempts + { + get { throw new NotImplementedException(); } + } + + public override int MinRequiredNonAlphanumericCharacters + { + get { throw new NotImplementedException(); } + } + + public override int MinRequiredPasswordLength + { + get { throw new NotImplementedException(); } + } + + public override int PasswordAttemptWindow + { + get { throw new NotImplementedException(); } + } + + public override MembershipPasswordFormat PasswordFormat + { + get { throw new NotImplementedException(); } + } + + public override string PasswordStrengthRegularExpression + { + get { throw new NotImplementedException(); } + } + + public override bool RequiresQuestionAndAnswer + { + get { throw new NotImplementedException(); } + } + + public override bool RequiresUniqueEmail + { + get { throw new NotImplementedException(); } + } + + public override string ResetPassword(string username, string answer) + { + throw new NotImplementedException(); + } + + public override bool UnlockUser(string userName) + { + throw new NotImplementedException(); + } + + public override void UpdateUser(MembershipUser user) + { + throw new NotImplementedException(); + } + + public override bool ValidateUser(string username, string password) + { + if (String.IsNullOrEmpty(username) || String.IsNullOrEmpty(password)) + return false; + + var user = WebsiteUserStorage.GetUser(username); + return user != null && user.Password == password; + } + } +}
\ No newline at end of file |