有什么方法可以更改作为响应返回的 Date 标头的值?我试图HttpResponse
在 WebAPI 操作中的消息上设置标题。
当我在 OWIN 配置中执行此操作时
app.Use((c, a) =>
{
c.Response.OnSendingHeaders(o =>
{
c.Response.Headers.Clear();
}, null);
return a();
});
我仍然收到 3 个标题:
Content-Length: 3705
Server: Microsoft-HTTPAPI/2.0
Date: Sat, 29 Mar 2014 18:53:32 GMT
有没有办法改变它们的价值?看起来他们在管道中被设置在非常低的水平。