Exemple #1
0
 private static IAuthenticator CreateAuthenticator()
 {
     var accountService = new SimpleAccountService();
     accountService.Add("admin", "admin", new[] { "Admin", "User" });
     accountService.Add("user", "user", new[] { "User" });
     var basicAuth = new BasicAuthentication(accountService, "localhost");
     return basicAuth;
 }
Exemple #2
0
        private static IAuthenticator CreateAuthenticator()
        {
            var accountService = new SimpleAccountService();

            accountService.Add("admin", "admin", new[] { "Admin", "User" });
            accountService.Add("user", "user", new[] { "User" });
            var basicAuth = new BasicAuthentication(accountService, "localhost");

            return(basicAuth);
        }