重命名CodeIgniter的跨站点请求伪造Cookie

时间:2011-07-14 13:17:08

标签: codeigniter cookies csrf

我尝试通过编辑config/config.php中的值来重命名CodeIgniter CSRF Coo​​kie:

$config['csrf_protection'] = TRUE;
$config['csrf_token_name'] = 'mysite_csrf';
$config['csrf_cookie_name'] = 'mysite_csrf';
$config['csrf_expire'] = 7200;

但是当我访问该网站时,Cookie仍显示为:ci_csrf_token

为什么会发生这种情况?

1 个答案:

答案 0 :(得分:0)

您使用的是哪个版本的CI? 2.0.x中出现错误

https://bitbucket.org/ellislab/codeigniter-reactor/issue/199