public AccountController(ISessionManagementService sessionManagementService, ITutorRepository tutorRepository, IUserRepository userRepository, IPasswordGenerationService passwordGenerationService)
 {
     _sessionManagementService  = sessionManagementService;
     _tutorRepository           = tutorRepository;
     _userRepository            = userRepository;
     _passwordGenerationService = passwordGenerationService;
 }
 public HomeworkController(IHomeworkRepository homeworkRepository,
                           IAcademicCourseRepository academicCourseRepository, ISessionManagementService sessionManagement, IStudentRepository studentRepository)
 {
     _homeworkRepository       = homeworkRepository;
     _viewMessageLogic         = new ViewMessageLogic(this);
     _academicCourseRepository = academicCourseRepository;
     _sessionManagement        = sessionManagement;
     _studentRepository        = studentRepository;
 }
 public GradeController(IGradeRepository gradeRepository, IAcademicGradeRepository academicGradeRepository, IPensumRepository pensumRepository, IEducationLevelRepository educationLevelRepository, ISessionManagementService sessionManagementService, IUserRepository userRepository)
 {
     _gradeRepository          = gradeRepository;
     _academicGradeRepository  = academicGradeRepository;
     _pensumRepository         = pensumRepository;
     _educationLevelRepository = educationLevelRepository;
     _sessionManagementService = sessionManagementService;
     _userRepository           = userRepository;
     _viewMessageLogic         = new ViewMessageLogic(this);
 }
Beispiel #4
0
 public EnrollController(IStudentRepository studentRepository,
                         IGradeRepository gradeRepository, IAcademicGradeRepository academicGradeRepository, IUserRepository userRepository, ISessionManagementService sessionManagementService)
 {
     _studentRepository        = studentRepository;
     _gradeRepository          = gradeRepository;
     _academicGradeRepository  = academicGradeRepository;
     _userRepository           = userRepository;
     _sessionManagementService = sessionManagementService;
     _viewMessageLogic         = new ViewMessageLogic(this);
 }
Beispiel #5
0
 public PersonalMessageController(ISessionManagementService sessionManagement, IUserRepository userRepository,
                                  INotificationRepository notificationRepository,
                                  IAcademicGradeRepository academicGradeRepository)
 {
     _sessionManagement       = sessionManagement;
     _userRepository          = userRepository;
     _notificationRepository  = notificationRepository;
     _academicGradeRepository = academicGradeRepository;
     _viewMessageLogic        = new ViewMessageLogic(this);
 }
 public StudentController(IStudentRepository studentRepository, ITutorRepository tutorRepository,
                          IContactInformationRepository contactInformationRepository, IAcademicGradeRepository academicGradeRepository, IUserRepository userRepository, ISessionManagementService sessionManagementService)
 {
     _academicGradeRepository      = academicGradeRepository;
     _userRepository               = userRepository;
     _sessionManagementService     = sessionManagementService;
     _studentRepository            = studentRepository;
     _tutorRepository              = tutorRepository;
     _contactInformationRepository = contactInformationRepository;
     _viewMessageLogic             = new ViewMessageLogic(this);
 }
 public AcademicYearController(IAcademicYearRepository academicYearRepository, IUserRepository userRepository, ISessionManagementService sessionManagementService, IGradeRepository gradeRepository, IPensumRepository pensumRepository, IAcademicGradeRepository academicGradeRepository, IAcademicCourseRepository academicCourseRepository)
 {
     _academicYearRepository   = academicYearRepository;
     _userRepository           = userRepository;
     _sessionManagementService = sessionManagementService;
     _gradeRepository          = gradeRepository;
     _pensumRepository         = pensumRepository;
     _academicGradeRepository  = academicGradeRepository;
     _academicCourseRepository = academicCourseRepository;
     _viewMessageLogic         = new ViewMessageLogic(this);
 }
Beispiel #8
0
 public DataImportController(IDataImportService dataImportService
                             , IGradeRepository gradeRepository
                             , IAcademicYearRepository academicYearRepository, IAcademicGradeRepository academicGradeRepository, IUserRepository userRepository, ISessionManagementService sessionManagementService)
 {
     _dataImportService        = dataImportService;
     _gradeRepository          = gradeRepository;
     _academicYearRepository   = academicYearRepository;
     _academicGradeRepository  = academicGradeRepository;
     _userRepository           = userRepository;
     _sessionManagementService = sessionManagementService;
     _viewMessageLogic         = new ViewMessageLogic(this);
 }
 public NotificationController(ISessionManagementService sessionManagement, IUserRepository userRepository,
                               INotificationRepository notificationRepository, IPeopleRepository peopleRepository,
                               ITeacherRepository teacherRepository,
                               IAcademicCourseRepository academicCourseRepository, IStudentRepository studentRepository,
                               ITutorRepository tutorRepository, IGradeRepository gradeRepository,
                               IAcademicYearRepository academicYearRepository,
                               IEducationLevelRepository areaReporsitory, INotificationHandlerService notificationHandlerService, IAcademicGradeRepository academicGradeRepository, IEducationLevelRepository educationLevelRepository)
 {
     _sessionManagement          = sessionManagement;
     _userRepository             = userRepository;
     _notificationRepository     = notificationRepository;
     _peopleRepository           = peopleRepository;
     _teacherRepository          = teacherRepository;
     _academicCourseRepository   = academicCourseRepository;
     _tutorRepository            = tutorRepository;
     _studentRepository          = studentRepository;
     _gradeRepository            = gradeRepository;
     _academicYearRepository     = academicYearRepository;
     _areaReporsitory            = areaReporsitory;
     _notificationHandlerService = notificationHandlerService;
     _academicGradeRepository    = academicGradeRepository;
     _educationLevelRepository   = educationLevelRepository;
     _viewMessageLogic           = new ViewMessageLogic(this);
 }
Beispiel #10
0
 public StressHub(ISessionManagementService sessionService)
 {
     _sessionService = sessionService;
 }
Beispiel #11
0
    public ServerSideSessionTests()
    {
        _urls.Origin   = IdentityServerPipeline.BaseUrl;
        _urls.BasePath = "/";
        _pipeline.OnPostConfigureServices += s =>
        {
            s.AddSingleton <IServerUrls>(_urls);
            s.AddIdentityServerBuilder().AddServerSideSessions();
        };
        _pipeline.OnPostConfigure += app =>
        {
            _pipeline.Options.ServerSideSessions.RemoveExpiredSessionsFrequency = TimeSpan.FromMilliseconds(100);

            app.Map("/user", ep => {
                ep.Run(ctx =>
                {
                    if (ctx.User.Identity.IsAuthenticated)
                    {
                        ctx.Response.StatusCode = 200;
                    }
                    else
                    {
                        ctx.Response.StatusCode = 401;
                    }
                    return(Task.CompletedTask);
                });
            });
        };


        _pipeline.Users.Add(new TestUser
        {
            SubjectId = "bob",
            Username  = "******",
        });
        _pipeline.Users.Add(new TestUser
        {
            SubjectId = "alice",
            Username  = "******",
        });

        _pipeline.Clients.Add(new Client
        {
            ClientId            = "client",
            AllowedGrantTypes   = GrantTypes.Code,
            RequireClientSecret = false,
            RequireConsent      = false,
            RequirePkce         = false,
            AllowedScopes       = { "openid", "api" },
            AllowOfflineAccess  = true,
            CoordinateLifetimeWithUserSession = true,
            RefreshTokenUsage    = TokenUsage.ReUse,
            RedirectUris         = { "https://client/callback" },
            BackChannelLogoutUri = "https://client/bc-logout"
        });
        _pipeline.IdentityScopes.Add(new IdentityResources.OpenId());
        _pipeline.ApiScopes.Add(new ApiScope("api"));

        _pipeline.Initialize();

        _sessionStore      = _pipeline.Resolve <IServerSideSessionStore>();
        _ticketService     = _pipeline.Resolve <IServerSideTicketService>();
        _sessionMgmt       = _pipeline.Resolve <ISessionManagementService>();
        _grantStore        = _pipeline.Resolve <IPersistedGrantStore>();
        _refreshTokenStore = _pipeline.Resolve <IRefreshTokenStore>();
    }
Beispiel #12
0
 public LoginController(IUserRepository userRepository, ISessionManagementService sessionManagement)
 {
     _userRepository    = userRepository;
     _sessionManagement = sessionManagement;
 }
 public MyAccountController(ISessionManagementService sessionManagementService, IUserRepository userRepository)
 {
     _sessionManagementService = sessionManagementService;
     _userRepository           = userRepository;
     _viewMessageLogic         = new ViewMessageLogic(this);
 }
Beispiel #14
0
 public GameController(ISessionManagementService sessionService)
 {
     _sessionService = sessionService;
 }
Beispiel #15
0
 public StressHub(ISessionManagementService sessionService, ILogger <StressHub> logger)
 {
     _sessionService = sessionService;
     _logger         = logger;
 }
 public IndexModel(ISessionManagementService sessionManagementService)
 {
     _sessionManagementService = sessionManagementService;
 }
Beispiel #17
0
 public HomeController(ISessionManagementService sessionManagement)
 {
     _sessionManagement = sessionManagement;
 }
Beispiel #18
0
 public AccountController(ISessionManagementService sessionManagementService, ITutorRepository tutorRepository, IUserRepository userRepository)
 {
     _sessionManagementService = sessionManagementService;
     _tutorRepository          = tutorRepository;
     _userRepository           = userRepository;
 }