Skip to content
Permalink
Browse files

Fixed CSRF/static cache conflict

  • Loading branch information...
chrisgraham committed Jun 16, 2019
1 parent 1001d87 commit c309ac029e5ff6d298439fd90304bf0414c244e7
Showing with 5 additions and 0 deletions.
  1. +5 −0 sources/csrf_filter.php
@@ -29,6 +29,11 @@ function csrf_filter_active()
return false;
}
global $SITE_INFO;
if ((is_guest()) && ($SITE_INFO['any_guest_cached_too'] == '1')) {
return false;
}
$security_token_exceptions = get_option('security_token_exceptions');
$_security_token_exceptions = ($security_token_exceptions == '') ? array() : explode("\n", $security_token_exceptions);
return !in_array(get_page_name(), $_security_token_exceptions) && !in_array(get_zone_name(), $_security_token_exceptions);

0 comments on commit c309ac0

Please sign in to comment.
You can’t perform that action at this time.