Questions tagged [owin-middleware]

OWIN Middleware in the IIS integrated pipeline

266 questions
1
vote
1 answer

Why does Visual Studio skip some directories like Controllers, Classes, and App_Start when publishing to Azure?

I have a classic ASP.Net forms based website where I have added s set of API hits based on the OAuthAuthorizationServerProvider class. It works great locally, now I trying to publish it to an Azure App Service. The ASP.Net portion of the website…
1
vote
0 answers

Modifying Request body using Owin Middleware

I am trying to sanitize the requests body coming to an Asp.net (.Net 4.6) application with WebAPI 2 using OWIN/Katana. However, after modifying the body I am still getting the original text inside the API method. Example input…
insomniac
  • 11,146
  • 6
  • 44
  • 55
1
vote
1 answer

Jwt Bearer Authentication middleware always sets User.Identity.IsAuthenticated to false

I've added UseJwtBearerAuthentication middleware to my application to Authenticate all incoming requests: public void Configuration(IAppBuilder app) { var config = new HttpConfiguration(); WebApiConfig.Register(config); #region Autofac…
Abolfazl
  • 1,592
  • 11
  • 32
1
vote
1 answer

how to pass custom authentication property to openid connect middleware during signout?

I want to pass a url parameter to endsession endpoint of my idp. this is how I am trying to do this: in my client application's signout action I have : var authprops = new AuthenticationProperties { RedirectUri = postSignoutReturnUrl…
1
vote
1 answer

debugging or error log for UseWindowsAzureActiveDirectoryBearerAuthentication in a azure web site?

I have an asp.net azure web api site, say myapi.azuresites.net, and my custom domain is myapi.mycompany.net. In my web api, I use owin middleware to validate incoming token app.UseWindowsAzureActiveDirectoryBearerAuthentication( new…
daxu
  • 3,514
  • 5
  • 38
  • 76
1
vote
1 answer

Is threre a way to use custom activator for OWIN middlewares?

I would like to control the way how OWIN creates registered middlewares. For example when using following code to register MyCustomMiddleware: app.Use(); I want to be the one who calls MyCustomMiddleware constructor and pass all…
Ondra Netočný
  • 410
  • 3
  • 16
1
vote
0 answers

ASP MVC 5 HttpContext.Current.Request.IsAuthenticated is still TRUE after IIS app pool recycle

On IIS app pool recycle HttpContext.Current.Session items are null but HttpContext.Current.Request.IsAuthenticated is TRUE, how this this can be set false. We are using OWIN middleware Cookie based authentication scheme. Authorize filter is checking…
1
vote
0 answers

How to use IIS as reverse proxy for windows service built using aspnet core

This Windows service and has some web api controllers. The IIS which we want to use as reverse proxy already has some services hosted on it. Below is the Program class for windows service. Is it possible to use IIS as reverse proxy where IIS takes…
manojmore
  • 410
  • 2
  • 8
  • 20
1
vote
0 answers

OWIN with VB.NET Legacy Code ASP.NET Web Forms

I am trying to implement OWIN into our legacy vb.net web forms project we have to work with our SSO implementation on Azure. However on start-up I can not seem to be able to run the startup.vb class. I have added:
Sutoka
  • 11
  • 2
1
vote
1 answer

Azure AD multitenant app - check if user is authorized to use my app

I have developed a web site that integrates with Azure AD using asp.net and owin. I have registered the app as a multitenant app in AD, meaning that everyone with a work or school account can login to my application. That is fine, and is what I…
rgullhaug
  • 1,065
  • 2
  • 10
  • 19
1
vote
1 answer

Accessing Azure Key Vault from an OWIN Web API

I have been searching most of the day for this and cannot find an answer. I have a .net framework 4.7.2 web API using OWIN for authentication and startup. I want to include processes to store my secrets in an Azure KeyVault. I have added a connected…
Schroedingers Cat
  • 3,099
  • 1
  • 15
  • 33
1
vote
0 answers

How to extend OWIN Cookie before expiry?

I'm trying to handle ASP.net MVC 5, timeout session scenario. Here is my code I'm using which is working as well for session expiry. app.UseCookieAuthentication(new CookieAuthenticationOptions { ExpireTimeSpan = 200, …
afr0
  • 848
  • 1
  • 11
  • 29
1
vote
0 answers

ASP.NET WebApi always returns 401 Unauthorized

I am trying to create a new endpoint in my WebApi which will be called from another Server. So, I want to set up the S2S JWT bearer based authentication for my WebApp. The startup.cs code looks like this public void Configuration(IAppBuilder…
rkt
  • 1,171
  • 2
  • 9
  • 18
1
vote
0 answers

Azure AD Redirect URI(s) for applications that a multi tennant

I am responsible for a web application that we sell to customers all around the world, this application is a web application that I have been tasked with including functionality to surface O365 content within, this has lead me to the MS Graph API…
jcnewman83
  • 189
  • 1
  • 12
1
vote
0 answers

Login/logout issue for multiple IIS same applications under the same site

I have deployed same application as two sites[Production and Development] in IIS 8.0 with two port number. The problem is the follow: Open the browser and login the first application[Production]; Open another browser tab and login the second…
Jithin
  • 11
  • 2