/// <summary> /// Adds the <see cref="LDAPAuthenticationMiddleware"/> into the OWIN runtime. /// </summary> /// <param name="app">The <see cref="IAppBuilder"/> passed to the configuration method</param> /// <param name="options">LDAPAuthenticationOptions configuration options</param> /// <returns>The updated <see cref="IAppBuilder"/></returns> public static IAppBuilder UseLDAPAuthentication(this IAppBuilder app, LDAPAuthenticationOptions options) { if (app == null) throw new ArgumentNullException("app"); if (options == null) throw new ArgumentNullException("options"); app.Use(typeof(LDAPAuthenticationMiddleware), app, options); app.UseStageMarker(PipelineStage.Authenticate); return app; }
/// <summary> /// Adds the <see cref="LDAPAuthenticationMiddleware"/> into the OWIN runtime. /// </summary> /// <param name="app">The <see cref="IAppBuilder"/> passed to the configuration method</param> /// <param name="options">LDAPAuthenticationOptions configuration options</param> /// <returns>The updated <see cref="IAppBuilder"/></returns> public static IAppBuilder UseLDAPAuthentication(this IAppBuilder app, LDAPAuthenticationOptions options) { if (app == null) { throw new ArgumentNullException("app"); } if (options == null) { throw new ArgumentNullException("options"); } app.Use(typeof(LDAPAuthenticationMiddleware), app, options); app.UseStageMarker(PipelineStage.Authenticate); return(app); }