Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@dcomartin
Created August 21, 2015 01:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dcomartin/29640d3aafd0c243b8e6 to your computer and use it in GitHub Desktop.
Save dcomartin/29640d3aafd0c243b8e6 to your computer and use it in GitHub Desktop.
OwinMiddlwareClass
public class CustomMiddleware : OwinMiddleware
{
public CustomMiddleware(OwinMiddleware next) : base(next)
{
}
public async override Task Invoke(IOwinContext context)
{
context.Response.Headers["MachineName"] = Environment.MachineName;
await Next.Invoke(context);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment