private static void ConfigureNancy(IAppBuilder app, TheBenchSettings configuration) { // https://github.com/NancyFx/Nancy/wiki/Hosting-nancy-with-owin app.UseNancy(new NancyOptions { Bootstrapper = new Bootstrapper(configuration), }); }
private static void ConfigureNancy(IAppBuilder app, TheBenchSettings configuration) { // https://github.com/NancyFx/Nancy/wiki/Hosting-nancy-with-owin app.UseNancy(new NancyOptions { Bootstrapper = new Bootstrapper(configuration), }); }
private static void ConfigureAuthentication(IAppBuilder app, TheBenchSettings configuration) { app.UseCookieAuthentication(new CookieAuthenticationOptions { AuthenticationType = configuration.Authentication.AuthenticationType, CookieHttpOnly = configuration.Authentication.CookieHttpOnly, CookieName = configuration.Authentication.CookieName, CookieSecure = configuration.Authentication.CookieSecure, ExpireTimeSpan = configuration.Authentication.AuthenticationCookieExpireTimeSpan, LoginPath = configuration.Authentication.LoginPath, LogoutPath = configuration.Authentication.LogoutPath, ReturnUrlParameter = configuration.Authentication.ReturnUrl, SlidingExpiration = configuration.Authentication.EnableSlidingExpiration }); }
private static void ConfigureAuthentication(IAppBuilder app, TheBenchSettings configuration) { app.UseCookieAuthentication(new CookieAuthenticationOptions { AuthenticationType = configuration.Authentication.AuthenticationType, CookieHttpOnly = configuration.Authentication.CookieHttpOnly, CookieName = configuration.Authentication.CookieName, CookieSecure = configuration.Authentication.CookieSecure, ExpireTimeSpan = configuration.Authentication.AuthenticationCookieExpireTimeSpan, LoginPath = configuration.Authentication.LoginPath, LogoutPath = configuration.Authentication.LogoutPath, ReturnUrlParameter = configuration.Authentication.ReturnUrl, SlidingExpiration = configuration.Authentication.EnableSlidingExpiration }); }
public void Configuration(IAppBuilder app) { // So that squishit works //Directory.SetCurrentDirectory(AppDomain.CurrentDomain.SetupInformation.ApplicationBase); var configuration = new TheBenchSettings(); if (configuration.General.RequireHttps) app.Use(typeof(RequireHttpsHandler)); // TODO: Read Docs //app.UseErrorPage(); ConfigureAuthentication(app, configuration); ConfigureStaticContent(app); ConfigureNancy(app, configuration); // http://katanaproject.codeplex.com/discussions/470920 app.UseStageMarker(PipelineStage.MapHandler); }
public void Configuration(IAppBuilder app) { // So that squishit works //Directory.SetCurrentDirectory(AppDomain.CurrentDomain.SetupInformation.ApplicationBase); var configuration = new TheBenchSettings(); if (configuration.General.RequireHttps) { app.Use(typeof(RequireHttpsHandler)); } // TODO: Read Docs //app.UseErrorPage(); ConfigureAuthentication(app, configuration); ConfigureStaticContent(app); ConfigureNancy(app, configuration); // http://katanaproject.codeplex.com/discussions/470920 app.UseStageMarker(PipelineStage.MapHandler); }
public Bootstrapper(TheBenchSettings configuration) { _configuration = configuration; }
public Bootstrapper(TheBenchSettings configuration) { _configuration = configuration; }