P3P Header Info in MVC

后端 未结 3 963
执笔经年
执笔经年 2021-01-02 12:58

I\'m not sure where I\'m suppose to put this in my Asp.net MVC website:

HttpContext.Current.Response.AppendHeader(\"P3P\", \"CP=\\\\\\\"IDC DSP COR ADM DEVi          


        
3条回答
  •  孤独总比滥情好
    2021-01-02 13:39

    You should create a class that inherits ActionFilter and overrides OnResultExecuting() to add that header.

    Then, add it to the global filters collection.

提交回复
热议问题