跨站请求伪造

跨站请求伪造

 

veiw中
from django.template.context import RequestContext  导入RequestContext模块
 
return render_to_response('login.html',data,context_instance=RequestContext(request))  

html中设置Token:
  {% csrf_token %}

 

posted @ 2016-04-10 17:29  fengjian1585  阅读(143)  评论(0编辑  收藏  举报