本文介绍了ASP.NET MVC API:设置Cookie,则302/303重定向失去饼干的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个返回的Htt presponseMessage的API操作。
API地址是这样的:
Because redirecting to another page, even if under the same domain, the cookie is not valid across different pages. If path is not set, then the cookie is only valid with the original request targeting http://localhost/login?authcode=xxx
今天,我知道我需要声称有人吃之前仔细检查域和cookie的路径属性。
Today I learnt that I need to carefully examine the domain and the path attribute of the cookie before claiming that somebody ate it.
这篇关于ASP.NET MVC API:设置Cookie,则302/303重定向失去饼干的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!