For testing, I am sending the request with credentials using
WebRequest request = WebRequest.Create("url");
request.Credentials = new NetworkCredential("user", "pass");
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
Then catch these on the other app using .NET Core's Middleware
public async Task Invoke(HttpContext context)
Accessing the request in context.Request
is successful but what I am still looking is where does the credentials be found inside context
?
Or there are other way around?