forked from leftypol/leftypol
CSRF protection
This commit is contained in:
parent
4a9d497a94
commit
6229b82a43
8 changed files with 82 additions and 44 deletions
|
@ -150,3 +150,9 @@ function create_pm_header() {
|
|||
return $header;
|
||||
}
|
||||
|
||||
function make_secure_link_token($uri) {
|
||||
global $mod, $config;
|
||||
return substr(sha1($config['cookies']['salt'] . '-' . $uri . '-' . $mod['id']), 0, 8);
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue